omicverse-single-cell-cellmatch-ontology
Installation
SKILL.md
OmicVerse Single-Cell — Cell Ontology Mapping (CellMatch)
Goal
Take an annotated single-cell AnnData whose obs[<cell_name_col>] carries free-text cell-type labels (often author-specific shorthand) and map every label to a canonical Cell Ontology (CL) term via NLP. Output is adata.obs['cell_ontology'] (matched CL term name), adata.obs['cell_ontology_cl_id'] (e.g. CL:0000084), and adata.obs['cell_ontology_score'] (cosine similarity).
Three escalating modes:
- Plain mapping — sentence-transformer cosine-similarity match. Fastest; works on clean labels.
- LLM abbreviation expansion — calls an LLM to expand
'TIL-1'→'tissue-resident memory CD8+ T cell'before matching. Required when labels are short / acronym-heavy. - Cell Taxonomy enhancement — adds species + tissue context via the Jin 2023 Cell Taxonomy resource; matches against species-specific taxonomies as well as CL.
This skill addresses the gap noted in coverage analysis: single-cell-annotation skill handles CellTypist / SCSA / gpt4celltype annotators, but doesn't cover the post-annotation problem of mapping author-text to a standard ontology.