sc-velocity-prep
БесплатноБез исполняемых скриптовНе проверенLoad when generating spliced / unspliced layers from Cell Ranger BAM, FASTQ, STARsolo output, or velocyto loom — the prerequisite for sc-velocity. Skip when…
от mdbabumiamssm★ 36 звёзд на GitHubОб этом скилле
sc-velocity-prep
When to use
The user has raw Cell Ranger output (BAM + barcodes), STARsolo output,
or paired FASTQs and needs an AnnData with layers["spliced"] /
layers["unspliced"] (and optional layers["ambiguous"]) before
running sc-velocity. Two backends:
velocyto(default) — runsvelocyto runagainst a Cell Ranger BAM using a GTF. Produces a.loomand reads it back into AnnData.starsolo— re-runs alignment from FASTQ via STARsolo with the Velocyto solo subworkflow, or loads existing STARsolo Velocyto output directly when detected.
--base-h5ad lets you merge the velocity layers into an
already-processed AnnData (preserves obs / obsm / clustering).
For velocity estimation itself use sc-velocity. For non-velocity
scRNA preprocessing use sc-preprocessing.
Inputs & Outputs
| Input | Format | Required |
|---|---|---|
Cell Ranger run dir / STARsolo dir / FASTQ dir / .loom |
path | yes (unless --demo) |
| GTF | .gtf (--gtf) |
required for BAM-backed velocyto |
| STAR index | dir (--reference) |
required for FASTQ-backed STARsolo |
| Chemistry | 10xv2 / 10xv3 / 10xv4 (--chemistry) |
required for FASTQ STARsolo |
| Optional base AnnData | .h5ad (--base-h5ad) |
merge layers into existing object |
| Output | Path | Notes |
|---|---|---|
| Velocity-ready AnnData | processed.h5ad |
adds layers["spliced"], layers["unspliced"], layers["ambiguous"] |
| Layer totals | tables/velocity_layer_summary.csv |
molecules per layer |
| Top genes | tables/top_velocity_genes.csv |
highest-abundance velocity genes |
| Figures | figures/velocity_layer_summary.png, figures/velocity_layer_fraction.png, figures/velocity_gene_balance.png, figures/velocity_top_genes_stacked.png |
always |
| Report | report.md + result.json |
always |
Flow
- Resolve
--input(Cell Ranger dir / STARsolo dir / FASTQ /.loom). - For
velocyto: locate BAM + barcodes, validate--gtf(or auto-pick fromresources/singlecell/references/gtf/), runvelocyto run, load.loom. - For
starsolo: detect existing STARsolo Velocyto output and load directly, OR re-run STARsolo Velocyto with--reference+--chemistry+ auto-detected--whitelist. - Optionally merge layers into
--base-h5ad. - Compute layer totals (
tables/velocity_layer_summary.csv) and top-gene balance. - Save
processed.h5ad, tables, figures,report.md,result.json.
Gotchas
- BAM-backed velocyto needs a GTF.
sc_velocity_prep.py:397raisesValueError("BAM-backed velocyto preparation requires a GTF file. Pass--gtf /abs/path/to/genes.gtf, or keep one underresources/singlecell/references/gtf/. ..."). Auto-detection only fires if a project-local GTF lives at the recommended path. - FASTQ-backed STARsolo needs a STAR index AND explicit chemistry.
sc_velocity_prep.py:437raisesValueError("FASTQ-backed STARsolo velocity preparation requires a STAR genome directory. ...")if--referenceis missing and nothing's atresources/singlecell/references/starsolo/.sc_velocity_prep.py:444raisesValueError("FASTQ-backed STARsolo velocity preparation requires an explicit--chemistry.")when--chemistry autois left as the default — STARsolo cannot infer 10x v2 vs v3 vs v4 from FASTQ alone. - STARsolo whitelist is auto-guessed; missing → hard fail.
sc_velocity_prep.py:458raisesValueError("Could not infer a compatible STARsolo whitelist. Pass--whitelist /abs/path/to/3M-february-2018.txt, or keep the whitelist underresources/singlecell/references/whitelists/. ..."). The guesser uses the reference path + chemistry; a non-standard reference layout breaks it. - STARsolo Velocyto matrix loader has a fallback for index-name quirks.
sc_velocity_prep.py:100is documented as "with a local fallback for index-name quirks";:112raisesFileNotFoundError(f"Could not locate STARsolo Velocyto matrices under: {path}")when nothing matches even with the fallback. Common when STARsolo finished partial / was killed mid-run. --inputmandatory unless--demo(parser.error, exit code 2).sc_velocity_prep.py:373callsparser.error("--input required when not using --demo"). Once provided,:376raisesFileNotFoundError(f"Input path not found: {input_path}")for a missing path.--methodchoices are exactlyvelocyto/starsolo.sc_velocity_prep.py:346declares the choices via argparse;kb-pythonis mentioned in upstream-prep docstrings but is not a valid--methodvalue here. Use the dedicated kb-python tooling outside OmicsClaw if you need that path.
Key CLI
# Demo (synthetic loom; does NOT exercise velocyto / STARsolo)
python omicsclaw.py run sc-velocity-prep --demo --output /tmp/sc_velo_prep_demo
# velocyto from a Cell Ranger run (BAM-backed)
python omicsclaw.py run sc-velocity-prep \
--input /data/cellranger_run/ --output results/ \
--method velocyto --gtf /refs/Homo_sapiens.GRCh38.gtf
# Load exist
Установить sc-velocity-prep в Claude Code и Claude Desktop
Зарегайся, чтобы установить скилл
Создай бесплатный аккаунт, чтобы открыть команду установки и сохранить скилл в библиотеку.
- Открой команду установки в одну строку
- Сохраняй скиллы в синхронизируемую библиотеку
- Уведомления, когда скиллы обновляются
Разрешённые инструменты
Инструменты, которые скиллу разрешено вызывать.
Без ограничений — скилл может использовать любой инструмент.
FAQ
Что делает скилл sc-velocity-prep?
Load when generating spliced / unspliced layers from Cell Ranger BAM, FASTQ, STARsolo output, or velocyto loom — the prerequisite for sc-velocity. Skip when AnnData already has spliced+unspliced layers (go straight to sc-velocity) or for any non-velocity preprocessing (use sc-preprocessing).
Как установить скилл sc-velocity-prep?
Скопируй папку скилла в ~/.claude/skills (вкладка Claude Code выше делает это одной командой), либо поставь как плагин.
Скилл sc-velocity-prep запускает скрипты?
Нет, скилл состоит только из инструкций (SKILL.md), без исполняемых скриптов.
Похожие скиллы
theme-factory
Toolkit for styling artifacts with a theme. These artifacts can be slides, docs, reportings, HTML landing pages, etc. There are 10 pre-set themes with…
от Anthropicaccess
Manage Discord channel access — approve pairings, edit allowlists, set DM/group policy. Use when the user asks to pair, approve someone, check who's allowed…
от Anthropicconfigure
Set up the Discord channel — save the bot token and review access policy. Use when the user pastes a Discord bot token, asks to configure Discord, asks "how…
от Anthropicaccess
Manage iMessage channel access — approve pairings, edit allowlists, set DM/group policy. Use when the user asks to pair, approve someone, check who's allowed…
от Anthropic