consensus-domains
Load when you want a verified multi-method consensus over spatial tissue domains on a preprocessed spatial AnnData — fanning out N domain methods, ranking…
от lilinji★ 18 звёзд на GitHub
Установить consensus-domains в Claude Code и Claude Desktop
Зарегайся, чтобы установить скилл
Создай бесплатный аккаунт, чтобы открыть команду установки и сохранить скилл в библиотеку.
- Открой команду установки в одну строку
- Сохраняй скиллы в синхронизируемую библиотеку
- Уведомления, когда скиллы обновляются
Об этом скилле
consensus-domains
When to use
The user has a preprocessed spatial AnnData (typically already QC'd via
spatial-preprocess) and wants a more trustworthy tissue-domain
assignment than any single method can produce — because the user knows
single-method results disagree on cancer / non-standard tissues, or
because the analysis is going to drive a downstream decision (cell-type
deconvolution, region-specific DE, paper figure).
This skill fans out spatial-domains over N method choices, computes a
typed statistical consensus, and surfaces the cross-method
disagreement explicitly. It does NOT replace spatial-domains; it
wraps it.
Inputs & Outputs
Inputs
- File types:
.h5ad - Requires a preprocessed AnnData (
Xnormalised, PCA/neighbours present)
Outputs
consensus_labels.tsvmember_scores.csvmember_intrinsic_panel.csvcross_method_nmi.csvplan.jsonreport.mdresult.json
Flow
- Plan —
runtime/consensus/plan.propose_membersreadsspatial-domains'param_hints(from itsskill.yaml), queries the evaluation-chair LLM (or falls back deterministically), produces N PlannedMember entries. - Fan out —
runtime/consensus/team.run_teaminvokesomicsclaw.skill.runner.run_skill("spatial-domains", ...)per member withmax_parallel = min(N, cpu_count//2, 4)and a 600 s per-member timeout.cancel_eventis propagated through. - Score —
runtime/consensus/scoring.score_all_membersranks survivors by compositealpha * cross_NMI + beta * mean_local_puritywith themax_class_frac > 0.8hard filter. - BC pick — on the CLI surface in interactive mode, prompt the
user with the top-K-by-score default; on Desktop/Channel surfaces
(or
--non-interactive), accept the default. - Consensus — invoke the chosen operator
(
kmode/weighted/lca) on the selected base clusterings. - Report — write
report.mdstarting with the mandatory ADR 0010 banner; persistplan.jsonfor audit; ready for graph-memory storage underanalysis://typed/<run_id>.
Gotchas
- A path is allowed to fail loudly. If fewer than 2 members survive
the fan-out, this skill raises
InsufficientSurvivorsErrorand does NOT silently downgrade to narrative consensus. Re-run with--membersadjusted or fall back to the dedicated narrative skill (when shipped). - Banner is non-configurable. The
[A: Verified consensus]header is enforced byruntime/consensus/dispatch.output_banner. Do not editreport.mdto strip it before distribution. - Member intrinsic quality is a multi-metric panel (ADR 0028). Spatial-domain
members are scored on a normalized panel of three unsupervised metrics —
chaos(1-hop coherence),pas(anomaly rate),mlami(multi-scale spatial-graph AMI) — combined into one[0,1]intrinsic for the β term of the BC composite score. The per-member breakdown is written tomember_intrinsic_panel.csv. Pass--no-spatial-panelto score on the singlemean_local_puritysignal instead. --n-clustersis reserved — accepted but not consumed. The operator returns however many clusters the math yields (bounded at the max member k); passing--n-clusterschanges nothing today (disposition pending DEC-5).- LCA requires R + diceR. When unavailable, the skill prints an
installation hint and exits non-zero rather than silently switching
operators. Pass
--operator kmodeto bypass. requires_preprocessed: true— the underlying spatial-domains members expectobsm["X_pca"]andobsm["spatial"]populated. Runspatial-preprocessfirst.
Key CLI
# Minimal interactive run (CLI surface) — LLM picks 5, you confirm BCs
oc run consensus-domains --input preprocessed.h5ad --output out/
# Non-interactive (server / scripted)
oc run consensus-domains --input preprocessed.h5ad --output out/ \
--non-interactive
# Explicit members + weighted operator
oc run consensus-domains --input preprocessed.h5ad --output out/ \
--members banksy,graphst,sedr,leiden,spagcn \
--operator weighted
# SACCELERATOR-style benchmark (run ALL eligible methods)
oc run consensus-domains --input preprocessed.h5ad --output out/ --all
See also
references/methodology.md— the consensus scoring + operator rationalereferences/output_contract.md—consensus_labels.tsv/member_scores.csv/plan.jsonschemareferences/parameters.md— every CLI flag (generated fromskill.yaml)- Adjacent skills:
spatial-preprocess(upstream — produces the input),spatial-domains(the per-member method this wraps),consensus-interpret(downstream — narrates the consensus result),sc-consensus-clustering(parallel — the single-cell analogue) - ADR 0010/0011/0016 — runtime layer, scoring protocol, workflow-r
Разрешённые инструменты
Инструменты, которые скиллу разрешено вызывать.
Без ограничений — скилл может использовать любой инструмент.
Вложенные файлы
- consensus_domains.py
- references/methodology.md
- references/output_contract.md
- references/parameters.md
- skill.yaml
FAQ
Что делает скилл consensus-domains?
Load when you want a verified multi-method consensus over spatial tissue domains on a preprocessed spatial AnnData — fanning out N domain methods, ranking base clusterings, and emitting a typed consensus with cross-method disagreement. Skip when one method suffices (use spatial-domains); the data is single-cell (use sc-consensus-clustering).
Как установить скилл consensus-domains?
Скопируй папку скилла в ~/.claude/skills (вкладка Claude Code выше делает это одной командой), либо поставь как плагин.
Скилл consensus-domains запускает скрипты?
Да, скилл несёт исполняемые скрипты. Проверь исходник перед установкой.
Похожие скиллы
skill-creator
AnthropicCreate new skills, modify and improve existing skills, and measure skill performance. Use when users want to create a skill from scratch, edit, or optimize an…
discernment-nudge
AnthropicAfter you give a substantive answer or draft that the user may act on — advice or recommendations, drafted artifacts such as goals, plans, pitches, proposals…
data-consolidate
AnthropicJoins the plant's scheduled exports and connector data into one working dataset — ERP items (NetSuite or Infor M3), sales orders, production work orders…
inspection-to-capa
AnthropicRuns the quality chain end to end: writes the nonconformance against the requirement it violates, searches history at the moment of writing to say whether…