Real-time global intelligence dashboard. AI-powered news aggregation, geopolitical monitoring, and infrastructure tracking in a unified situational awareness interface
MCP server for spatial transcriptomics analysis
ChatSpatial gives MCP clients a structured way to analyze spatial transcriptomics data through curated tools and validated parameters. Instead of generating arbitrary scripts, the agent selects from analysis methods for loading data, visualization, spatial domains, deconvolution, cell communication, and related workflows.
Builders who use Claude Code, Codex, or other MCP clients for spatial transcriptomics analysis.
You can ask an agent to run spatial analysis workflows with more consistent, reproducible tool calls instead of ad-hoc code.
What it does
Schema-validated MCP tools
Exposes 20 MCP tools with validated parameters so the agent stays within known analysis paths.
Spatial transcriptomics workflows
Covers loading, preprocessing, visualization, spatial domains, deconvolution, communication, annotation, differential expression, trajectory, velocity, and spatial statistics.
Multi-client support
Works with any MCP-compatible client, including Claude Code, Claude Desktop, and Codex.
Docker runtime
Provides a container image for local or reproducible deployment.
Optional full method families
Supports an expanded `chatspatial[full]` install for more method backends when needed.
How to get it
- 1Codex
codex mcp add chatspatial -- uvx --from chatspatial chatspatial server
- 2Claude Code
claude mcp add --scope user chatspatial -- \ uvx --from chatspatial chatspatial server
- 3The command above installs the standard runtime. To make all 15 composable Python method…
uvx --from 'chatspatial[full]' chatspatial server
- 4Docker quick start
docker pull ghcr.io/cafferychen777/chatspatial:v1.4.0
- 5Minimal example prompt
Load /absolute/path/to/spatial_data.h5ad and show me the tissue structure
README
ChatSpatial replaces ad-hoc LLM code generation with schema-enforced orchestration. Instead of generating arbitrary scripts, the LLM selects tools and parameters from a curated registry, making spatial transcriptomics workflows more reproducible across sessions and clients.
ChatSpatial exposes 20 schema-validated MCP tools that orchestrate 66 spatial transcriptomics methods across 15 analytical categories. The tools are the stable natural-language interface; the methods are the analysis backends selected through tool parameters.
The server implements MCP 2026-07-28 through the official Python SDK v2 and
continues to serve 2025-11-25 clients through SDK-managed protocol negotiation.
STDIO remains the secure local default; Streamable HTTP is available for
explicitly configured HTTP deployments.
Start Here
Install uv once, then
register ChatSpatial without creating or managing a Python environment:
Codex:
codex mcp add chatspatial -- uvx --from chatspatial chatspatial server
Claude Code:
claude mcp add --scope user chatspatial -- \
uvx --from chatspatial chatspatial server
uvx creates an isolated environment on first launch and reuses its cache on
later launches. Restart the MCP client after adding the server.
The command above installs the standard runtime. To make all 15 composable Python method families available in the same isolated MCP environment, use:
uvx --from 'chatspatial[full]' chatspatial server
full includes CellRank, FastCCC, the maintained spatial-domain and
registration backends, annotation, enrichment, and the other portable Python
families. R bridges, AESTETIK, and rctd-py remain separate because they have
system, platform, or large-runtime requirements. See the installation guide
before enabling those families.
Then:
- Run your first analysis — Quick Start
- Choose optional method families or a persistent environment — Installation Guide
- Configure another MCP client — Configuration Guide
- Inspect or reproduce the manuscript results — Reproducibility workspace
Docker quick start:
docker pull ghcr.io/cafferychen777/chatspatial:v1.4.0
Minimal example prompt:
Load /absolute/path/to/spatial_data.h5ad and show me the tissue structure
If you use Docker, mount host data to /data and prompt with the container path, for example /data/spatial_data.h5ad.
ChatSpatial works with any MCP-compatible client — Claude Code, Claude Desktop, Codex, OpenCode, and other MCP-capable tools.
Capabilities
Current coverage includes 66 methods across 15 analytical categories, exposed through 20 MCP tools. Supports 10x Visium, Xenium, Slide-seq v2, MERFISH, seqFISH.
| Category | Example methods |
|---|---|
| Data Loading & Preprocessing | Scanpy I/O, QC, Normalization, HVG, PCA, Neighbors |
| Visualization | Spatial plots, Embedding plots, Gene expression overlays |
| Spatial Domain Identification | SpaGCN, STAGATE, GraphST, BANKSY, AESTETIK, Leiden, Louvain |
| Deconvolution | FlashDeconv, Cell2location, RCTD (spacexr or rctd-py), DestVI, Stereoscope, SPOTlight, Tangram, CARD |
| Cell-Cell Communication | LIANA+, CellPhoneDB, CellChat (cellchat_r), FastCCC |
| Cell Type Annotation | Tangram, scANVI, CellAssign, mLLMCelltype, scType, SingleR |
| Differential Expression | Wilcoxon, t-test, Logistic Regression, pyDESeq2 |
| Trajectory Inference | CellRank, Palantir, DPT |
| RNA Velocity | scVelo, VeloVI |
| Spatial Statistics | Moran's I, Local Moran, Geary's C, Getis-Ord Gi*, Ripley's K, Co-occurrence, Neighborhood Enrichment, Centrality Scores, Local Join Count, Network Properties |
| Enrichment Analysis | GSEA, ORA, Enrichr, ssGSEA, Spatial EnrichMap |
| Spatially Variable Genes | SpatialDE, SPARK-X, FlashS |
| Multi-sample Integration | Harmony, BBKNN, Scanorama, scVI |
| CNV Analysis | InferCNVPy, Numbat |
| Spatial Registration | PASTE, STalign |
Documentation
| Guide | Use this when... |
|---|---|
| Installation | You need optional methods or a persistent Python environment |
| Docker | You want a reproducible container runtime or local dependency resolution fails |
| Configuration | You need exact MCP client syntax or the runtime path model |
| Quick Start | ChatSpatial is installed and you want the first successful analysis |
| Concepts | You need to choose an analysis strategy from a biological question |
| Examples | You want copy-pasteable natural-language workflow prompts |
| Methods Reference | You need canonical tool names, method names, parameters, and defaults |
| Troubleshooting | Setup, data loading, or analysis behavior is not working |
| Full Docs | You want the complete documentation site |
Reproducibility
The manuscript experiment scripts, small aggregate result tables, and
supplementary tables are versioned in reproducibility/.
Large datasets, raw provider checkpoints, generated analysis directories, and
manuscript source files are intentionally kept outside Git. The reproducibility
workspace documents both the manuscript-era package baseline and the
current-checkout development workflow so historical evidence is not silently
regenerated with a different ChatSpatial release.
Citation
If you use ChatSpatial in your research, please cite:
@article{Yang2026.02.26.708361,
author = {Yang, Chen and Zhang, Xianyang and Chen, Jun},
title = {ChatSpatial: Schema-Enforced Agentic Orchestration for Reproducible and Cross-Platform Spatial Transcriptomics},
elocation-id = {2026.02.26.708361},
year = {2026},
doi = {10.64898/2026.02.26.708361},
publisher = {Cold Spring Harbor Laboratory},
URL = {https://www.biorxiv.org/content/early/2026/03/01/2026.02.26.708361},
journal = {bioRxiv}
}
ChatSpatial orchestrates many excellent third-party methods. Please also cite the original tools your analysis used.
Contributing
Documentation improvements, bug reports, and new analysis methods are all welcome. See CONTRIBUTING.md.
Files in the repo
- .agents
- .github
- assets
- chatspatial
- constraints
- docs
- reproducibility
- scripts
- tests
- .dockerignore
- .gitignore
- .pre-commit-config.yaml
- .readthedocs.yaml
- CHANGELOG.md
- CITATION.cff
- CODE_OF_CONDUCT.md
- CONTRIBUTING.md
- DOCKER.md
- Dockerfile
- install_r_dependencies.R
- INSTALLATION.md
- LICENSE
- Makefile
- MANIFEST.in
- pyproject.toml
- README.md
- SECURITY.md
- server.json
Discussion (0)
Ask about usage, or say what you built with itSign in to join the discussion.
No comments yet. Be the first to say what this is good for.
More connectors
High-performance code intelligence MCP server. Indexes codebases into a persistent knowledge graph — average repo in milliseconds. 158 languages, sub-ms queries, 99% fewer tokens. Single static binary, zero dependencies.

Universal provider proxy for OpenAI Codex & Claude Code — use any LLM (Claude, Gemini, Grok, DeepSeek, Ollama…) with Codex CLI, App, SDK, and Claude Code
Git-native persistent memory for AI coding agents. Implements Google OKF v0.2 with sub-300µs in-memory BM25 search, embedded MCP server, and progressive disclosure. Slashes token bloat by 80% with zero external databases or dependencies. Built in pure Go.
Local-first code intelligence graph for MCP and CLI. Builds a persistent map of your codebase so AI coding tools read only what matters, with benchmarked context reductions on reviews and large-repo workflows.
Stop your AI from making things up — it proposes, deterministic tools decide, every claim checked against ground truth with evidence. Grounded facts and context survive resets. Reverse engineering is the proving ground. MCP server + CLI.