OpenCite aggregates results from many academic sources, deduplicates them, and
presents them as text, JSON, BibTeX, or CSV. It also retrieves PDFs, fetches
structured full-text, and converts PDFs to markdown.
IDSet is frozen. It centralizes every identifier type (DOI, PMID, PMCID,
OpenAlex, S2, arXiv) so cross-API lookup and deduplication have one source of
truth.
Provenance.Paper.data_sources records which APIs contributed data to a
merged record.
Rate-limited clients.BaseClient provides a token-bucket rate limiter,
retry with backoff, and httpx session management. Each source has its own
limit (OpenAlex 100 req/s, PubMed 10 req/s, Semantic Scholar 1 req/s, arXiv
3 req/s, and so on).
Parallel fan-out, sequential drain.SearchOrchestrator.search() launches
one task per source, then awaits them, merges, deduplicates, sorts, and
truncates to max_results. Pending tasks are always cancelled and drained so
none outlives the call.
Full-text shortcuts. When converting, OpenCite prefers PMC BioC structured
full-text for open-access articles (no PDF needed) and HTML full-text for
arXiv ar5iv and bioRxiv/medRxiv .full.
PDF priority chain. Publisher APIs (if tokens are configured) -> OpenAlex /
S2 PDF locations -> PMC OA -> direct arXiv/bioRxiv URL -> DOI content
negotiation.