PubMed Corpus
MedRAG ships with a pre-loaded, continuously maintained index of PubMed abstracts. Your queries search it alongside your own documents, with no upload or setup on your side.
Availability
| Plan | PubMed access |
|---|---|
| Free | No |
| PAYG | No |
| Standard | Yes |
| Enterprise | Yes |
GET /v1/corpora tells you whether your tenant has access: the pubmed_abstracts entry has
"accessible": true when your plan includes it.
The PubMed abstracts are NLM open access with no restrictions on derivative use, so no Data Use Agreement is required. You can query the corpus as soon as your plan includes it.
What is in it
- Titles and abstracts from PubMed, embedded with the same multilingual model as your own documents.
- Each abstract is one retrievable unit. Full-text articles are not included.
- Queries and results work in all supported languages: you can ask in Dutch and get English abstracts back, optionally translated into your query language.
Querying
There is no separate endpoint. POST /v1/query searches your own knowledge bases and every platform corpus
your plan includes, and ranks all results together.
curl -X POST https://medrag.eu/v1/query \
-H "Authorization: Bearer $MEDRAG_API_KEY" \
-H "Content-Type: application/json" \
-d '{"query": "metformin first-line treatment type 2 diabetes", "top_k": 10}'
PubMed results have "source": "pubmed_abstracts":
{
"results": [
{
"content": "Metformin remains the first-line pharmacological therapy for type 2 diabetes...",
"score": 0.84,
"source": "pubmed_abstracts",
"source_record_id": "12345678",
"metadata": {"doc_type": "abstract"}
}
]
}
source_record_idis the PubMed ID (PMID). Link to an abstract withhttps://pubmed.ncbi.nlm.nih.gov/<source_record_id>/.- Results from your own documents have
"source": "tenant"and the document fields described in the API reference. - To search only your own documents, pass
knowledge_base_ids. - Use
metadata_filterto narrow platform-corpus results.
Citing and clinical use
PubMed results are literature references. They are information retrieval, not medical advice, and they have not been reviewed for clinical applicability. Always cite the PMID and check the original publication.