datasets

Search Medical Papers

Search medical and biomedical papers with a natural-language question. Federates PubMed, PMC full-text, ClinicalTrials.gov, and Semantic Scholar, then synthesizes a cited answer.

Implementation: invokes the medical-agent Lambda (TypeScript, Mastra, Claude Sonnet). Streaming responses flow through the captain-stream S2 basin — identical pattern to /v2/collections/{name}/query.

post/v2/datasets/scientific/medical/ask

Request body

include_trialsboolean

Whether the agent may call ClinicalTrials.gov.

max_sourcesinteger

Target number of cited sources in the final answer.

questionstring required

Natural-language question.

recency_yearsinteger nullable

Prefer evidence within the last N years where the question allows.

streamboolean

If true, response is text/event-stream; otherwise JSON.

Response

Synthesized answer with cited sources. Returns JSON by default; when stream=true the response is text/event-stream with tool.start, tool.end, text.delta, and run.end events.

answerstring required

Synthesized answer with inline citations.

domainstring required

The scientific domain, e.g. 'medical'.

gapsstring[]

Things the agent could not find or verify.

latency_msinteger

End-to-end wall-clock latency.

tool_callsinteger

Number of tool calls the agent made.

Changes

No recorded changes to this endpoint across all 1 revision of this API.