spatial-domains

spatial-domains is a skill for Claude Code, Codex from TianGzlab/OmicsClaw. It costs 80 tokens per session (2,029 once invoked), scanned A, original, Apache-2.0.

A spatial transcriptomics tool for dividing tissue into regions or niches based on nearby locations and their gene-expression patterns. A niche is a local tissue environment made up of neighbouring cells or spots.

In plain words
What is it for?
Use it to assign spatial-domain labels to spots with Leiden, Louvain, SpaGCN, STAGATE, GraphST, BANKSY, or CellCharter.
Why use it?
It helps find meaningful tissue areas when ordinary expression-based clustering misses the importance of physical location.

Skill for Claude CodeCodex

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add skills/tiangzlab/omicsclaw/spatial-domains
Any agent
npx skills add TianGzlab/OmicsClaw --skill spatial-domains
Clone the repo
git clone --depth 1 https://github.com/TianGzlab/OmicsClaw

Made for: Claude Code, Codex.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for spatial-domains

README.md
[![agentmods](https://agentmods.dev/badge/skills/tiangzlab/omicsclaw/spatial-domains.svg)](https://agentmods.dev/skills/tiangzlab/omicsclaw/spatial-domains)
Your own site
<a href="https://agentmods.dev/skills/tiangzlab/omicsclaw/spatial-domains"><img src="https://agentmods.dev/badge/skills/tiangzlab/omicsclaw/spatial-domains.svg" alt="Measured on agentmods" height="20"></a>
Per session 80 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 2,029 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5 $0.00080 $0.02029
Opus 5 $0.00040 $0.01014
Sonnet 5 $0.00016 $0.00406
Haiku 4.5 $0.00008 $0.00203

Measured yesterday against content hash b432cf057f00, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

spatial-domains scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured yesterday.

The scan reads SKILL.md. This mod also ships 3 executable files (spatial_domains.py, tests/__init__.py, tests/test_spatial_domains.py), listed below but not scanned — reading those needs a real analyzer, not pattern matching.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

skills/spatial/spatial-domains/SKILL.md · 153 lines

How it starts

The opening of the file, as written. The whole thing — 153 lines — stays where its author put it; the contents beside it link to each section on GitHub.

spatial-domains

When to use

The user has a preprocessed spatial AnnData (obsm["X_pca"] and obsm["spatial"] populated) and wants tissue regions / niches identified per spot (obs["spatial_domain"]). Seven methods:

  • leiden (default) — spatial-weighted Leiden (--resolution, --spatial-weight). No GPU.
  • louvain — spatial-weighted Louvain. No GPU.
  • spagcn — graph convolutional, fixed-K (--n-domains, --epochs, --spagcn-p). Requires torch + SpaGCN.
  • stagate — graph attention with cell-type-aware regularisation (--stagate-alpha, --pre-resolution, --rad-cutoff / --k-nn). Requires torch + torch-geometric.
  • graphst — graph-self-supervised (--epochs, --dim-output, --n-domains). Auto-detects 10x platform. Requires torch + GraphST.
  • banksy — neighbourhood expression matrix + PCA (--lambda-param, --num-neighbours). 0.2 = cell-typing mode, 0.8 = domain mode.
  • cellcharter — niche-graph clustering with auto-k (--auto-k, --auto-k-min/--auto-k-max, --n-layers). Requires cellcharter + pyro-ppl.

For spatially variable genes use spatial-genes; for spot-level cell-type labels use spatial-annotate.

Inputs & Outputs

Inputs

  • File types: .h5ad
  • Expects obsm: spatial

Outputs

  • tables/domain_assignments.csv
  • tables/domain_counts.csv
  • tables/domain_method_embedding_points.csv
  • tables/domain_neighbor_mixing.csv
  • tables/domain_spatial_points.csv
  • tables/domain_summary.csv
  • tables/domain_umap_points.csv
  • figures/domain_local_purity_histogram.png
  • figures/domain_local_purity_spatial.png
  • figures/domain_neighbor_mixing.png
  • figures/domain_sizes.png
  • figures/pca_domains.png
  • figures/spatial_domains.png
  • figures/umap_domains.png
  • processed.h5ad
  • report.md
  • result.json
  • Processed AnnData (saves_h5ad) — adds obs: spatial_domain; obsm: X_stagate, X_graphst, X_banksy_pca, X_cellcharter

Read the full file on GitHub · 153 lines

Files

What ships with it

9 files beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. yesterday First seen · 153 lines · 80 tokens per session scan A b432cf057f00

Subscribe to this mod's changes

spatial-domains is a skill published in the GitHub repository TianGzlab/OmicsClaw (160 stars, last pushed 1mo ago), licensed Apache-2.0. It adds 80 tokens to every session and 2,029 once invoked, about $0.0004 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-09-03.

Related

Other skills, from other repositories

spatial-domain-identification

Identify tissue regions and spatial niches from preprocessed spatial transcriptomics data using Leiden, Louvain, SpaGCN, STAGATE, GraphST, or BANKSY.

ShangBioLab/SpatialClaw · 40 tokens

biotech-expert

Expert in biotechnology systems, genomics, LIMS, bioinformatics pipelines, lab automation, and bioprocess management. Use when the user mentions genomics, bioinformatics, LIMS, lab automation, bioprocessing, or gene sequencing, or when the task involves Genomics and Sequencing Technologies, Laboratory Information…

personamanagmentlayer/pcl · 83 tokens

spatial-deconvolution

Cell-type deconvolution for spatial transcriptomics by mapping a single-cell RNA-seq reference onto spatial data.

ShangBioLab/SpatialClaw · 28 tokens

spatial-niches

Python API skill for spatial niche and tissue microenvironment discovery, characterization, and cross-condition comparison.

ShangBioLab/SpatialClaw · 24 tokens

pkpd-modeling

Pharmacokinetic and pharmacodynamic modelling and simulation - non-compartmental analysis, compartmental and population PK, PK/PD and exposure-response, TMDD, PBPK orientation, bioequivalence, allometric scaling and first-in-human dose, drug interaction prediction, and Bayesian therapeutic drug monitoring. Use when…

K-Dense-AI/scientific-agent-skills · 273 tokens

neuropixels-analysis

Analyze Neuropixels extracellular recordings end-to-end with SpikeInterface. Covers loading SpikeGLX/Open Ephys/NWB data, preprocessing, drift/motion correction, Kilosort4 (and CPU) spike sorting, quality metrics, and unit curation (threshold-based, model-based UnitRefine, and AI-assisted visual review). Use when…

K-Dense-AI/scientific-agent-skills · 98 tokens