Skip to content

fix(celltypist): model-qualify predict output filenames#34

Merged
Marius1311 merged 1 commit into
mainfrom
fix/celltypist-predict-model-qualified-filenames
Jun 26, 2026
Merged

fix(celltypist): model-qualify predict output filenames#34
Marius1311 merged 1 commit into
mainfrom
fix/celltypist-predict-model-qualified-filenames

Conversation

@Marius1311

Copy link
Copy Markdown
Member

What

cta crosscheck celltypist predict keyed its two outputs only by level:

save_table(res, wd, f"celltypist_pred_{level}.csv")
save_table(summary, wd, f"celltypist_cluster_summary_{level}.csv")

So predicting a second model at the same level — Immune_All_Low then Immune_All_High to break a tie, a path the skill explicitly recommends — silently overwrote the first model's predictions and cluster summary. No warning.

Fix

Interpolate safe_cluster_id(model) into both filenames, exactly as the sibling markers command already does (celltypist_model_markers_<model>.csv):

  • celltypist_pred_<level>_<model>.csv
  • celltypist_cluster_summary_<level>_<model>.csv

A repo-wide grep confirms nothing in src/ reads the old names (only the human consumes these evidence tables), so there is no downstream coupling to update.

Test

  • pytest tests/test_smoke.py tests/test_registry_sync.py → 7 passed.
  • Import check: module imports clean; safe_cluster_id('Immune_All_Low')Immune_All_Low.

Fixes #33

🤖 Generated with Claude Code

`cta crosscheck celltypist predict` wrote celltypist_pred_<level>.csv and
celltypist_cluster_summary_<level>.csv keyed only by level, so predicting a
second model at the same level (e.g. Immune_All_Low then Immune_All_High to
break a tie — a recommended path) silently overwrote the first model's outputs.

Interpolate safe_cluster_id(model) into both filenames, matching the sibling
`markers` command (celltypist_model_markers_<model>.csv). No code reads the old
names, so there's no downstream coupling.

Fixes #33

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
@Marius1311 Marius1311 force-pushed the fix/celltypist-predict-model-qualified-filenames branch from ee29eb2 to ef95ff3 Compare June 26, 2026 08:44
@Marius1311 Marius1311 merged commit 21ccc83 into main Jun 26, 2026
0 of 2 checks passed
@Marius1311 Marius1311 deleted the fix/celltypist-predict-model-qualified-filenames branch June 26, 2026 08:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

cta crosscheck celltypist predict: output filenames not model-qualified → second model silently overwrites the first

1 participant