期刊:Nature Communications (2026-03-18) ·
DOI:10.1038/s41467-026-69856-5 ·
开源许可:GPL-3.0 (allowed)
上游仓库:https://github.com/Teichlab/celcomen @ 4165b5620cd6
# 1. 解压并自动构建隔离环境 + 运行真实数据自测
unzip celcomen-mcp.zip && cd celcomen-mcp
bash install.sh
.venv/bin/python selftest.py
# 2. 接入 Claude Code / Antigravity / Cursor (Stdio MCP)
claude mcp add celcomen -- "$PWD/.venv/bin/python" "$PWD/server.py"
# 3. 或启动远程 Streamable HTTP MCP 服务端供团队/网页直接调用
.venv/bin/python server.py --transport http --host 0.0.0.0 --port 8000
prepare_spatial_graph
MCP Verified ✓
Log-normalise, gene-centre and unit-norm scale a spatial AnnData, then build the k=6 spatial graph with Celcomen get_dataset_loaders.
{"n_cells": 196, "n_genes": 16, "n_samples": 1, "n_edges_total": 1176, "mean_degree": 6.0, "cells_dropped": 0, "mean_feature_norm": 1.0, "k_neighbors": 6}train_celcomen_model
MCP Verified ✓
Train Celcomen on a prepared dataset and export the learned intercellular and intracellular gene-gene matrices.
{"epochs": 100, "loss_first": 718.365234375, "loss_last": 119.07048797607422, "loss_drop_fraction": 0.8342479810013784, "n_genes": 16, "inter_offdiag_nonzero": 0, "intra_offdiag_nonzero": 64, "collapsed_to_identity": false, "inter_offdiag_mean": 0.0, "intra_offdiag_mean": 0.06826440244913101}predict_perturbation_counterfactual
MCP Verified ✓
Predict the spatial counterfactual of a single-cell gene knockout with Simcomen, subtracting a paired control run.
{"gene": "IFITM3", "perturbed_cell_index": 88, "n_neighbors_of_perturbed": 6, "effect_perturbed": 0.008248630911111832, "effect_neighbors": 0.000561432505492121, "effect_distal": 0.00035245108301751316, "perturbed_over_distal": 23.40361913628156, "neighbors_over_distal": 1.5929373820770005, "target_gene_initial_gap": -0.5470561981201172, "target_gene_final_gap": -0.5064554810523987, "steps": 50}rank_gene_interactions
MCP Verified ✓
Rank the strongest gene pairs in a trained Celcomen model and group genes into intracellular modules.
{"n_genes": 16, "intra_pairs_above_threshold": 31, "inter_pairs_above_threshold": 0, "n_intra_modules": 2, "intra_module_sizes": [8, 8], "max_intra_weight": 0.685032844543457, "max_inter_weight": 0.0}


