Enrichr MCP Server
以下摘录自该仓库的 README(片段) · 在 GitHub 读完整 README →
A Model Context Protocol (MCP) server that provides gene set enrichment analysis using the Enrichr API. This server supports all available gene set libraries from Enrichr and returns only statistically significant results (corrected-$p$ File -> Settings, then drag and drop the file into the Settings window.
Cursor / VS Code
Use the buttons below to install with default settings:
Claude Code
Or install as a Claude Code plugin:
Smithery
Manual Configuration
Add to your MCP client config (e.g., .cursor/mcp.json):
Features
- **Two Tools**: enrichr_analysis for running enrichment, suggest_libraries for discovering relevant libraries
- **Custom Background Correction**: Test against your own background gene set (e.g. only the genes expressed in your assay) instead of the whole genome
- **Live Library Catalog**: The library list is fetched from Enrichr at runtime, so new releases appear automatically and retired libraries are never suggested
- **Guided Workflow**: enrichment_analysis prompt for end-to-end analysis with interpretation
- **22 Library Categories**: Programmatic category mapping for all libraries (pathways, cancer, kinases, etc.)
- **Parallel Library Queries**: All libraries queried in parallel for fast multi-database analysis
- **Structured Output**: Returns both human-readable text and structured JSON for programmatic use
- **Configurable Output Formats**: Detailed, compact, or minimal to manage token usage
- **TSV Export**: Save complete results to TSV files
Tools
suggest_libraries
Discover the most relevant Enrichr libraries for a research question. Use this before enrichr_analysis to pick the best libraries for your specific topic. Searches Enrichr's **live** library catalog, so it never recommends a library that Enrichr has retired. When two libraries are equally relevant, the newer vintage ranks first (GO_Biological_Process_2026 over ..._2021).
**Parameters:**
- query (required): Research context (e.g., "DNA repair", "breast cancer drug resistance")
- category (optional): Filter by category (e.g., cancer, pathways, kinases)
- maxResults (optional): Max results to return (default: 10, max: 50)
**Returns:**
- Ranked list of libraries with relevance scores, categories, and descriptions
- Structured JSON with suggestions array
enrichr_analysis
Perform enrichment analysis across multiple Enrichr libraries in parallel.
**Parameters:**
- genes (required): Array of gene symbols (e.g., ["TP53", "BRCA1", "EGFR"]) — minimum 2
- libraries (optional): Array of Enrichr library names to query (defaults to configured libraries)
- background (optional): Custom background gene set — minimum 20 genes. See below.
- description (optional): Description for the gene list
- maxTerms (optional): Maximum terms per library (default: 50)
- format (optional): Output format: detailed, compact, minimal
- outputFile (optional): Path to save complete results as TSV file
**Returns:**
- Text content with formatted significant terms (name, p-values, odds ratio, combined score, overlapping genes)
- Structured JSON output with full result data, including backgroundCorrected per library
Background correction
By default Enrichr tests your gene list against the **whole genome**. If your genes
were drawn from a restricted universe — only the genes expressed in your tissue, or
a targeted panel — the whole-genome default overstates significance, often by many
orders of magnitude. Pass background with the universe the list was drawn from:
The difference is not cosmetic. For a 16-gene DNA-damage list, the top GO term moves
from an adjusted p of 1.2e-16 (whole genome) to 1.8e-5 (48-gene background), and the
number of "significant" terms drops from 359 to 10.
Background correction runs against Enrichr's separate speedrichr service, which is