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.
npx agentmods add skills/shangbiolab/spatialclaw/spatial-trajectorynpx skills add ShangBioLab/SpatialClaw --skill spatial-trajectorygit clone --depth 1 https://github.com/ShangBioLab/SpatialClawWrote 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.
[](https://agentmods.dev/skills/shangbiolab/spatialclaw/spatial-trajectory)<a href="https://agentmods.dev/skills/shangbiolab/spatialclaw/spatial-trajectory"><img src="https://agentmods.dev/badge/skills/shangbiolab/spatialclaw/spatial-trajectory.svg" alt="Measured on agentmods" height="20"></a>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.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5 | $0.00018 | $0.01530 |
| Opus 5 | $0.00009 | $0.00765 |
| Sonnet 5 | $0.00004 | $0.00306 |
| Haiku 4.5 | $0.00002 | $0.00153 |
Grade A, and why
spatial-trajectory 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 3d ago.
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.
How it starts
The opening of the file, as written. The whole thing — 171 lines — stays where its author put it; the contents beside it link to each section on GitHub.
🛤️ Spatial Trajectory
You are Spatial Trajectory, a specialised SPATIALCLAW agent for trajectory inference and pseudotime computation in spatial transcriptomics data. Your role is to order cells along developmental trajectories and infer cell fate decisions.
Why This Exists
- Without it: Users must manually select root cells, tune diffusion parameters, and integrate spatial context
- With it: Automated DPT computation with spatial-aware root selection and visualisation
- Why SPATIALCLAW: Combines pseudotime with spatial coordinates for tissue-level developmental maps
Workflow
- Calculate: Map single-cell expression relationships using KNN graphs.
- Execute: Embed pseudotime probabilities over topological layout.
- Assess: Perform path transition testing.
- Generate: Save developmental trajectory tree or continuous pseudo-values.
- Report: Synthesize continuous ordering mappings into reporting structures.
Core Capabilities
- Diffusion pseudotime (DPT): Built-in scanpy DPT — always available, no extra dependencies
- Root cell selection: By specific barcode or automatic (max/min DC1)
- Trajectory gene correlation: Spearman correlation with FDR correction to find pseudotime-associated genes
- Enhanced CellRank: Multi-kernel support (Velocity+Connectivity, Pseudotime+Connectivity), terminal state identification, fate probabilities, driver gene detection
- Optional Palantir: When available, use Palantir for multi-scale diffusion-based pseudotime
Root Cell Selection Strategies
| Strategy | Parameter | Method | Best for |
|---|---|---|---|
| Automatic | (default) | Max DC1 value | Quick exploration |
| By barcode | --root-cell |
Exact cell barcode | Precise control |
Trajectory Gene Correlation
After pseudotime computation, the system automatically identifies genes whose expression changes along the trajectory:
- Spearman rank correlation between each gene's expression and pseudotime
- FDR correction (Benjamini-Hochberg) for multiple testing
- Returns top genes with direction (increasing or decreasing along trajectory)
What ships with it
2 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.
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.
- 3d ago First seen · 171 lines · 18 tokens per session scan A 78e62f4baa6f
spatial-trajectory is a skill published in the GitHub repository ShangBioLab/SpatialClaw (11 stars, last pushed 3mo ago), licensed Apache-2.0. It adds 18 tokens to every session and 1,530 once invoked, about $0.0001 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-08-30.
Other skills, from other repositories
spatial-trajectory
Load when inferring pseudotime / lineage trajectories on a preprocessed spatial AnnData via DPT (default — diffusion pseudotime), CellRank (terminal-state + fate-probability), or Palantir (waypoint branch probabilities). Skip when the data has spliced/unspliced layers and you want velocity-driven dynamics (use…
sc-pseudotime
Load when ordering cells along a developmental trajectory in a normalised scRNA AnnData via DPT, Palantir, VIA, CellRank, Slingshot (R), or Monocle3 (R). Skip when ranking marker genes per cluster (use sc-markers); RNA velocity vector fields (use sc-velocity).
Developmental Gene Panel Design Workflow
Panel design for DEVELOPING / dynamic systems (embryonic organs, differentiation, regeneration). The target experiment is usually a LATE / terminal stage, but the biology is a trajectory: terminal cell types are end-products of earlier lineage programs. A panel built from the target stage alone resolves terminal…
trajectory-analysis
Single-cell trajectory inference pipeline covering diffusion pseudotime (DPT), PAGA, RNA velocity with scVelo, and fate mapping with CellRank. Use when the user mentions pseudotime, trajectory, lineage, differentiation, RNA velocity, scVelo, CellRank, PAGA, diffusion map, fate probabilities, terminal states…
bulkrna-trajblend
Load when placing bulk RNA-seq samples on a single-cell reference's pseudotime axis (NNLS deconvolution + nearest-neighbour mapping). Skip when plain cell-type proportions (use bulkrna-deconvolution); native single-cell trajectory inference (use sc-pseudotime).
sc-consensus-pseudotime
Load when you want a single-cell pseudotime ordering robust to the choice of trajectory method — fanning out DPT/Palantir/VIA from a shared root, rank-aligning them, and voting a consensus pseudotime with per-cell uncertainty. Skip when you have branching multi-lineage trajectories; no defined root.