Skip to content

feat(literature): implement Europe PMC adapter, literature MCP tools, and CLI (v0.7.0) - #19

Merged
engkinandatama merged 1 commit into
CORE-Lab-Research:mainfrom
engkinandatama:feat/phase-1.5-literature-v0.7.0
Sep 29, 2026
Merged

engkinandatama merged 1 commit into
CORE-Lab-Research:mainfrom
engkinandatama:feat/phase-1.5-literature-v0.7.0

Conversation

@engkinandatama

Copy link
Copy Markdown
Collaborator

Summary of Changes

  • Schema Models: Added PublicationEntity and LiteratureContext in src/biocontext/schemas.py with full citation metadata (PMID, PMCID, DOI, title, authors, journal, year, abstract text, citation count, open access URL).
  • Literature Adapter: Implemented LiteratureAdapter in src/biocontext/adapters.py connecting to the Europe PMC REST API (https://www.ebi.ac.uk/europepmc/webservices/rest/search), supporting search by topic/gene symbol, canonical PubMed ID (EXT_ID:<pmid> AND SRC:MED), PMCID, and DOI.
  • EntityResolver Integration: Added get_supporting_publications(query, limit) and get_publication_details(identifier) with automated rate limiting and cache support.
  • FastMCP Tools: Exposed get_supporting_publications and get_publication_details tools on the MCP server.
  • CLI Commands: Added biocontext literature <query> and biocontext paper <identifier> CLI subcommands with tabular rich console formatting.
  • Testing: Added comprehensive test suite in tests/test_literature_adapter.py covering PMID, PMCID, DOI lookups, entity searches, and MCP server endpoints.
  • Documentation: Updated README.md and docs/API.md reflecting the 12 MCP tools and new CLI subcommands. Bumped version to 0.7.0 in pyproject.toml.

@engkinandatama
engkinandatama merged commit 194bc40 into CORE-Lab-Research:main Sep 29, 2026
4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant