Skip to main content

amr-mcp

CI PyPI

An MCP server that lets AI assistants (Claude, Codex, Cursor…) query antimicrobial resistance (AMR) data from public, free sources:

  • NCBI Reference Gene Catalog, the curated database behind AMRFinderPlus: ~11,500 AMR genes, point mutations, stress and virulence genes
  • NCBI E-utilities: protein and nucleotide sequences, PubMed references
  • UniProtKB: protein function, keywords and cross-references
  • AMRFinderPlus (optional, if installed locally): screen your own genomes

All data sources are public domain or freely accessible; no API keys are required.

Example questions

Which carbapenemases are reported in Klebsiella pneumoniae, and what is the original paper for KPC-2?

Give me the protein sequence of mcr-1.1 and its UniProt function annotation.

Run AMRFinderPlus on ~/data/isolate_17.fasta as Escherichia and explain the hits by drug class.

Tools

Tool What it does
search_amr_genes Search by text, drug class, subclass, organism or element type
get_amr_gene Exact record for an allele (blaKPC-2) or summary of a family (blaKPC)
list_drug_classes Drug classes and how many catalog entries each has
catalog_info Catalog version and size
fetch_sequence Protein or nucleotide FASTA from NCBI by accession
get_pubmed_references Title, journal, authors and DOI for PubMed IDs
search_uniprot / get_uniprot_entry UniProtKB search and entry details
run_amrfinder Run a local AMRFinderPlus install on a FASTA file

Installation

Run it with uv (no install step needed), or pip install amr-mcp.

Claude Code

claude mcp add amr -- uvx amr-mcp

Claude Desktop

Add to claude_desktop_config.json:

{
  "mcpServers": {
    "amr": { "command": "uvx", "args": ["amr-mcp"] }
  }
}

Configuration

Variable Purpose
NCBI_API_KEY Optional, free. Raises the NCBI rate limit from 3 to 10 requests/s
NCBI_EMAIL Optional. Contact e-mail NCBI asks tools to send
AMR_MCP_CACHE_DIR Where the catalog is cached (default ~/.cache/amr-mcp, refreshed every 30 days)

To enable run_amrfinder: conda install -c bioconda ncbi-amrfinderplus && amrfinder -u.

Development

python -m venv .venv && .venv/bin/pip install -e ".[dev]"
.venv/bin/pytest -m "not network"   # offline tests
.venv/bin/pytest                    # also hits the live NCBI/UniProt APIs

Data licensing

The NCBI Reference Gene Catalog and NCBI sequence data are US government works in the public domain. UniProt data is available under CC BY 4.0. Please cite the original sources when you publish results:

  • Feldgarden M, et al. AMRFinderPlus and the Reference Gene Catalog facilitate examination of the genomic links among antimicrobial resistance, stress response, and virulence. Sci Rep. 2021.
  • The UniProt Consortium. UniProt: the Universal Protein Knowledgebase. Nucleic Acids Res.

License

MIT


Developed with AI assistance (Claude Code); all code reviewed and tested by the author.

Metadata

Release files for amr-mcp 0.1.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for amr-mcp 0.1.0
File Size Uploaded Provenance Actions
amr_mcp-0.1.0.tar.gz 14.2 kB With provenance Details for amr_mcp-0.1.0.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for amr-mcp 0.1.0
File Interpreter ABI Platform Actions
amr_mcp-0.1.0-py3-none-any.whl Python 3 none any Details for amr_mcp-0.1.0-py3-none-any.whl

Total release size: 27.2 kB

Release files / amr_mcp-0.1.0.tar.gz

Download URL amr_mcp-0.1.0.tar.gz
Size 14.2 kB
Tags Source
SHA-256 checksum
How to use checksums
057d804e82004e8b0eefdcdb42d51f0bdf36a55c0de40d90a51a5cfdb9e68302
BLAKE2b-256 checksum
How to use checksums
3db613a23890ef9c1412a83d318d4454f44ddccb35f94f06a6d504498f6d4365
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Nov 3, 2026.

Transparency log

Release files / amr_mcp-0.1.0-py3-none-any.whl

Download URL amr_mcp-0.1.0-py3-none-any.whl
Size 13.0 kB
Tags Python 3
SHA-256 checksum
How to use checksums
6df6c44c9da50a5afc75001e5159de9eda7abbfed0aba44dcef4a0cde2e6ebd3
BLAKE2b-256 checksum
How to use checksums
e69d2607ecd1ae8fa2ac7b77217cdc241a56065ceab754af755b511c0fd7027a
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Nov 3, 2026.

Transparency log

Security for amr-mcp 0.1.0

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

Full provenance

All 2 files in this release have been uploaded with provenance metadata.

Select from 2 files

Attestation for amr_mcp-0.1.0.tar.gz

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Nov 3, 2026.

Transparency log

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page