biocontext_kb.core.biorxiv#

bioRxiv and medRxiv preprint search tools.

These tools provide access to bioRxiv and medRxiv preprint servers for searching and retrieving preprint metadata. bioRxiv focuses on biological sciences while medRxiv focuses on medical sciences.

Functions#

get_biorxiv_preprint_details(doi[, server])

Get detailed preprint metadata by DOI. Retrieves title, authors, abstract, date, version, category, license, and publication status.

get_recent_biorxiv_preprints([server, start_date, ...])

Search bioRxiv/medRxiv preprints by date range or recent count. Specify one search method: date range, days, or recent_count.

Package Contents#

biocontext_kb.core.biorxiv.get_biorxiv_preprint_details(doi, server='biorxiv')#

Get detailed preprint metadata by DOI. Retrieves title, authors, abstract, date, version, category, license, and publication status.

Returns:

Preprint metadata including doi, title, authors, abstract, date, version, category, license, publication status or error message.

Return type:

dict

Parameters:
  • doi (Annotated[str, Field(description="Preprint DOI (e.g., '10.1101/2020.09.09.20191205')")])

  • server (Annotated[str, Field(description="'biorxiv' or 'medrxiv'")])

biocontext_kb.core.biorxiv.get_recent_biorxiv_preprints(server='biorxiv', start_date=None, end_date=None, days=None, recent_count=None, category=None, cursor=0, max_results=100)#

Search bioRxiv/medRxiv preprints by date range or recent count. Specify one search method: date range, days, or recent_count.

Returns:

Search results with server, search_params, total_returned, papers list (each with title, authors, abstract, metadata), pagination info or error message.

Return type:

dict

Parameters:
  • server (Annotated[str, Field(description="'biorxiv' or 'medrxiv'")])

  • start_date (Annotated[Optional[str], Field(description='Start date (YYYY-MM-DD)')])

  • end_date (Annotated[Optional[str], Field(description='End date (YYYY-MM-DD)')])

  • days (Annotated[Optional[int], Field(description='Search last N days (1-365, alternative to date range)', ge=1, le=365)])

  • recent_count (Annotated[Optional[int], Field(description='Most recent N preprints (1-1000, alternative to date range)', ge=1, le=1000)])

  • category (Annotated[Optional[str], Field(description="Filter by subject (e.g., 'cell biology', 'neuroscience')")])

  • cursor (Annotated[int, Field(description='Pagination: starting position', ge=0)])

  • max_results (Annotated[int, Field(description='Max results per page (1-500)', ge=1, le=500)])