doublet-detection-validation

doublet-detection-validation is a skill for Claude Code from GGbond-bo/MemOmics-Agent. It costs 139 tokens per session (3,635 once invoked), scanned A, original, MIT.

A method for checking whether single-cell sequencing data has been incorrectly labelled as containing doublets, where one measured droplet contains two cells. It compares detection results with evidence before recommending removal.

In plain words
What is it for?
Compare tools such as DoubletFinder, Scrublet, and scDblFinder; report clearly defined rates; and decide whether to retain, flag, or remove cells.
Why use it?
Algorithm labels can include many false positives, especially in weak data, so deleting every flagged cell can remove real cells and distort results.

Skill for Claude Code

Written for Claude Code: when-to-use in frontmatter.

Good fit Compare tools such as DoubletFinder, Scrublet, and scDblFinder; report clearly defined rates; and decide whether to retain, flag, or remove cells.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/ggbond-bo/memomics-agent/doublet-detection-validation
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.

Any agent
npx skills add GGbond-bo/MemOmics-Agent --skill doublet-detection-validation
Clone the repo
git clone --depth 1 https://github.com/GGbond-bo/MemOmics-Agent

Made for: Claude Code.

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 doublet-detection-validation

README.md
[![agentmods](https://agentmods.dev/badge/skills/ggbond-bo/memomics-agent/doublet-detection-validation/github.svg)](https://agentmods.dev/skills/ggbond-bo/memomics-agent/doublet-detection-validation)
Your own site
<a href="https://agentmods.dev/skills/ggbond-bo/memomics-agent/doublet-detection-validation"><img src="https://agentmods.dev/badge/skills/ggbond-bo/memomics-agent/doublet-detection-validation/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for doublet-detection-validation

Your own site · 80×15
<a href="https://agentmods.dev/skills/ggbond-bo/memomics-agent/doublet-detection-validation"><img src="https://agentmods.dev/badge/skills/ggbond-bo/memomics-agent/doublet-detection-validation.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 139 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 3,635 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
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.1 $0.00139 $0.03635
Opus 5.5 $0.00056 $0.01454
Sonnet 5.5 $0.00028 $0.00727
Haiku 4.5 $0.00014 $0.00364

Measured 1mo ago against content hash a2d9836a48b0, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

doublet-detection-validation 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 1mo 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.

memomics_home/skills/bioinformatics/doublet-detection-validation/SKILL.md · 185 lines

How it starts

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

双细胞检测验证与剔除决策协议

适用范围:任何"检测一下双细胞 / 比例高不高 / 要不要剔除"的请求。 本文档管判定(该不该信这些标签、该不该剔、剔多少);具体 QC 过滤参数与流程见 scrna-qc。

0. 先看判据表

情形 结论
in silico benchmark 的 F1 ≤ ~0.35 不应硬剔:全保留 + doublet_flag + 下游敏感性分析
benchmark F1 ≥ ~0.6 且 FPR ≤ 5% 可按该档剔除,并在报告中给出 precision/recall
未做 benchmark 没有资格说"比例 = 算法标签数",只能并列多口径 + 明确标注"未验证"

三条配套铁律:

  1. 报"双细胞比例"必须同时给出口径(哪档阈值 / 几个细胞 / 分母是什么)。单点估计禁止。
  2. 剔除任何细胞前,必须已有四步证据链(§2)。
  3. 不允许把 flag 率当真实比例报(例:flag 7.50% 而 benchmark precision 0.31 ⇒ 检测到的真 doublet 下界仅 ≈2.3%)。

1. 口径必须写清(最容易出错的地方)

同一数据集能算出横跨一个数量级的"双细胞比例",而且全都"正确":

口径 含义 陷阱
算法 flag 率 某阈值判为 doublet 的细胞占比 不是真实比例,含大量假阳性
双方法交集(core) 两法都判为 doublet 若其中一方来自假阳性档,交集同样不安全
真实比例下界 precision × flag 率 最可信的"真 doublet 至少有这么多"
传统经验率 0.8%/1000(新化学)或 7.5%/1000(旧文献) 是先验,不是本数据测出来的

报告表格必须含四列:口径名 / 细胞数 / 占比 / 该口径的性质(推荐 · 仅敏感性 · 已废弃)。 分母要审计——"4.55% core"若不写清来自哪两组交叉,等于没交代。


2. 四步证据链(缺任一步 → 不给剔除建议)

步骤 1 — 双方法交叉比对

两个输入同一份 counts、算法原理相互独立的方法:

  • R:DoubletFinder(PCA + KNN + pANN)
  • Python:scrublet(模拟双细胞 + 分类器)

输出:混淆矩阵、Jaccard、Cohen's Kappa、交集 / 差集 / 并集。

🔑 关键预期:kappa 0.035–0.165 是常态(示例数据实测)。低一致性本身说明"信号弱、单法不可信", 而不是"需要挑一个更对的方法"。不要把低 kappa 当作选方法的依据,它是"必须做 benchmark"的信号。

两档敏感性都要跑(用来暴露假阳性爆炸):

档 DoubletFinder nExp scrublet expected_doublet_rate
保守 n_cells/1000 × 0.8 0.008
传统 n_cells/1000 × 7.5 0.075

🔴 假阳性爆炸的特征信号:自动阈值低于该档分数的中位数/p95 → 判出的比例远超预期。 症状是"score 分布整体被压低、无双峰分离"。 ⇒ 该档只能作假阳性诊断,不得作剔除口径。 (实测:rate=0.008 档阈值 0.0142 而 obs median 0.0095 → 判 27.3% 为 doublet,而真细胞误判 32.8%。)

步骤 2 — in silico benchmark(决定性的那一步)

用本数据真实 counts 造已知真值:

# 合成 doublet = 随机两个真实细胞 counts 相加(异源配对)
pairs = rng.integers(0, n_obs, size=(INJ, 2))
pairs = pairs[pairs[:, 0] != pairs[:, 1]]
X_syn = X[pairs[:, 0], :] + X[pairs[:, 1], :]
X_mix = sp.vstack([X, X_syn]).tocsr()
is_syn = np.r_[np.zeros(n_obs, bool), np.ones(X_syn.shape[0], bool)]   # ← 真值标签

Read the full file on GitHub · 185 lines

Files

What ships with it

3 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. 1mo ago First seen · 185 lines · 139 tokens per session scan A a2d9836a48b0

Subscribe to this mod's changes

doublet-detection-validation is a skill published in the GitHub repository GGbond-bo/MemOmics-Agent (33 stars, last pushed 14d ago), licensed MIT. It adds 139 tokens to every session and 3,635 once invoked, about $0.0006 per session on Opus 5.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-10-14.

Related

doublet-detection-validation compared with skills from other repositories

doublet-detection-validation next to 6 skills from other repositories
ModTypeStarsLast pushLicenceScanTokensWorks with
doublet-detection-validationGGbond-bo/MemOmics-AgentSkill3314d agoMITA139Claude Code
instrument-data-to-allotropeanthropics/knowledge-work-pluginsSkill37k4d agoApache-2.0A123Claude Code
matlabK-Dense-AI/scientific-agent-skillsSkill59k7d agoMITA44Claude Code
exploratory-data-analysisK-Dense-AI/scientific-agent-skillsSkill59k7d agoMITA83Claude Code
phylogeneticsK-Dense-AI/scientific-agent-skillsSkill59k7d agoMITA71Claude Code, Codex
research-engineerdavila7/claude-code-templatesSkill34ktodayMITA43Claude Code, Codex
mapping-to-snomedmaziyarpanahi/openmedSkill5.9ktodayApache-2.0A205Claude Code