deepspot-m — Claude Code skill: what it does, how to install
Reads a 224x224 H&E tile and returns predicted log1p-CPM expression for the genes you ask about. Useful when you want spatial transcriptomics from a slide you have already scanned.
npx skills add K-Dense-AI/scientific-agent-skills --skill deepspot-m -a claude-codeWhat deepspot-m does
The skill hands DeepSpot-M to your agent. One histology tile goes in, one predicted value per queried gene comes out, laid on the same tile grid. The gene panel travels with the weights and is exposed as model.gene_names, covering ~19k protein-coding symbols; anything outside it raises a KeyError that names the offender.
Loading goes through DeepSpotM.from_pretrained with a source argument (evo2, orthrus, prott5, scgpt, apertus), which decides which frozen gene embedding builds the projections. One source per run. image_processor turns the PIL image into a tensor, predict_genes(batch, genes) gives values in the order of your symbol list.
Prerequisites: uv pip install deepspotm==1.0.0, Python 3.10+ and a PyTorch build matching your CUDA runtime. The weights are gated, and approval is not authentication, since hf auth login is a separate step on the machine that downloads. Code sits under PolyForm Noncommercial, weights under CC-BY-NC-SA-4.0, and the access form restricts eligibility to academic or nonprofit researchers without commercial affiliations. That makes a funded collaboration a real blocker, so check it before you start. The optional histolab 0.7.0 tiler needs its own Python 3.10 or 3.11 environment with OpenSlide.
What it helps with
- predict gene expression from an H&E tile without sequencing
- tile a whole slide and keep the prediction grid aligned
- compare output across different gene embedding sources
- export the expression matrix to AnnData/H5AD
- catch a wrong-sized crop before it reaches the model
Example prompts for the agent
- Load DeepSpot-M and predict `EPCAM` and `CD3D` for `tile.png`.
- Tile `slide.svs` at 224x224, run every tile through DeepSpot-M and write the matrix to H5AD.
- Run the same tiles through `source="scgpt"` and `source="evo2"` and compare.
How to install deepspot-m
1Skills CLI (Vercel)
npx skills add K-Dense-AI/scientific-agent-skills --skill deepspot-m -a claude-code2Manually: put the files in place
~/.claude/skills/deepspot-m/SKILL.mdCopy the whole skill folder; for one project use .claude/skills/deepspot-m/
1Skills CLI (Vercel)
npx skills add K-Dense-AI/scientific-agent-skills --skill deepspot-m -a codex2Manually: put the files in place
.agents/skills/deepspot-m/SKILL.mdFor all projects use ~/.agents/skills/
1Skills CLI (Vercel)
npx skills add K-Dense-AI/scientific-agent-skills --skill deepspot-m -a cursor2Manually: put the files in place
.cursor/skills/deepspot-m/SKILL.mdCursor also reads .agents/skills/ and .claude/skills/
1GitHub CLI
gh skill install K-Dense-AI/scientific-agent-skills deepspot-m2Manually: put the files in place
.github/skills/deepspot-m/SKILL.md1Skills CLI (Vercel)
npx skills add K-Dense-AI/scientific-agent-skills --skill deepspot-m -a gemini-cli2Platform CLI
gemini skills install https://github.com/K-Dense-AI/scientific-agent-skills --path skills/deepspot-mManually: put the files in place
.devin/skills/deepspot-m/SKILL.mdThe legacy .windsurf/skills/ path still works
Skills CLI (Vercel)
npx skills add K-Dense-AI/scientific-agent-skills --skill deepspot-m -a opencodeClaude.ai
Zip the folder and upload it in Settings → Capabilities → Skills
From the same set120
The whole set →Similar
Questions about deepspot-m
How do I install deepspot-m in Claude Code?
Run npx skills add K-Dense-AI/scientific-agent-skills --skill deepspot-m -a claude-code. The skill lands at ~/.claude/skills/deepspot-m/SKILL.md.
What does deepspot-m do?
It produces virtual spatial transcriptomics: a histology tile goes in, predicted log1p-CPM values come out for genes from the ~19k-symbol panel.
Can it run on CPU?
Yes, CPU is supported and CUDA is optional. The gated weights are still required, and the machine has to be authenticated with hf auth login after approval.