Expand description
Finding a DOI’s arXiv preprint when Unpaywall does not name one (#636, ADR-0062).
The #325 fallback fetches an arXiv preprint in place of a blocked or missing publisher copy, but only one Unpaywall reports. A paper can be closed at its publisher, unknown to Unpaywall, and on arXiv all the same (measured on 10.1103/bbnt-brjz, arXiv:2512.07923). Three ways to find it, tried in order, each stopping the search when it answers:
- Crossref
relation.has-preprint– in the Crossref record the fetch already holds, so it costs no request. Anarxivid, or an arXiv DOI (10.48550/arXiv.<id>). - OpenAlex
locations[]– a location whose landing page isarxiv.org/abs/<id>. One request toapi.openalex.org, and only when the user enabled OpenAlex (DOIGET_ENABLE_OPENALEX), so a default fetch contacts no host it did not before. - arXiv search by title and first author – one request to arXiv’s API, at arXiv’s own rate. A hit counts only when its title is the record’s title (compared letters and digits only, case-folded), its authors include the first author’s surname, and it does not name a different published DOI.
Each answer says which of the three found it; nothing here fetches.
Structs§
- Found
- A preprint found for a DOI.
- Found
Doi - A non-arXiv preprint found for a DOI (#640): its own DOI, fetched through the ordinary OA route (the location Unpaywall reports for it).
Enums§
- FoundBy
- Which method found a preprint.
Constants§
- ADS_
TOKEN_ ENV - The user’s own NASA ADS token (#644). Never shipped, never logged.
Functions§
- find
- Look for a preprint of
doi: Crossref’s relation, then OpenAlex (whenopenalex_enabled), then arXiv’s search.crossref_messageis the record the fetch already holds. - find_
preprint_ doi - Look for a non-arXiv preprint of
doi(#640): Crossref’s relation, then bioRxiv and medRxivpubswhenbiorxiv_enabled. - from_
ads_ answer - The arXiv id in an ADS search answer’s first record: the
identifierentryarXiv:<id>(ADS’s search syntax lists arXiv ids among a record’s identifiers). Nothing else is read (#644). - from_
crossref - The arXiv id Crossref’s
relation.has-preprintnames, if any. - from_
inspire_ record - The arXiv id INSPIRE-HEP’s record gives (
metadata.arxiv_eprints), if any. Nothing else in the record is read (#642): itsdocumentsare files whose provenance and licence are not stated per file. - from_
openalex_ work - The arXiv id of an OpenAlex work’s arXiv location, if any.
- preprint_
doi_ from_ crossref - A non-arXiv preprint DOI Crossref’s
relation.has-preprintnames: any DOI but an arXiv one (10.48550), whichfrom_crossrefhandles.