Skip to content

docs: conceptual data-model overview (D2) - #27

Merged
nceglia merged 2 commits into
mainfrom
docs/d2-conceptual-overview
Jun 8, 2026
Merged

docs: conceptual data-model overview (D2)#27
nceglia merged 2 commits into
mainfrom
docs/d2-conceptual-overview

Conversation

@nceglia

@nceglia nceglia commented Jun 8, 2026

Copy link
Copy Markdown
Owner

Summary

Adds docs/concepts/data-model.md — the end-to-end mental model a new user needs before the API reference. Covers:

  • The hierarchical model: clonotype prior p_c → local p_ct (per clone×covariate) → per-cell phenotype = softmax(classifier logits + log p_ct), on top of the scVI/VampPrior latent.
  • The data model register_model writes — a table of every .uns/.obsm/.obs key with meaning + shape (tcri_p_ct, X_tcri_logits, X_tcri_probabilities, the ct_* arrays, …).
  • Indexing (ct_to_c / ct_to_cov / ct_array) shown concretely, plus the filtered-view gotcha (the add utils to setup.py #4 guard).
  • Point estimate vs. posterior samples, how the joint distribution feeds entropy / mutual information / flux, and the three temperatures (prior / guide / query).

Also:

  • index.md: page added to the toctree (after quickstart).
  • conf.py: enable MyST dollarmath so $…$ renders.

Verification

  • python -m sphinx -b html docs <out>build succeeded, 0 warnings.
  • Page renders with its tables; cross-refs (register_model, joint_distribution*) resolve; math renders via MathJax; page is in the sidebar toctree.

Independent of the open theme PR (#26) — different conf.py regions, merges cleanly either order.

Closes Notion D2.

🤖 Generated with Claude Code

nceglia and others added 2 commits June 8, 2026 00:04
New docs/concepts/data-model.md — the end-to-end mental model for TCRi:
the hierarchical generative model (clonotype prior p_c -> local p_ct per
clone x covariate -> per-cell phenotype = classifier logits + log prior),
the objects register_model writes to .uns/.obsm/.obs (with shapes), the
ct_to_c / ct_to_cov / ct_array indexing, point-estimate vs posterior
sampling, how the joint distribution feeds the entropy/MI/flux metrics,
and the three temperatures.

- index.md: add concepts/data-model to the toctree (after quickstart).
- conf.py: enable MyST dollarmath so $...$ math renders.

Builds clean (0 warnings); cross-references resolve; math renders via mathjax.

Closes Notion D2.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
@nceglia
nceglia marked this pull request as ready for review June 8, 2026 04:15
@nceglia
nceglia merged commit 57732f1 into main Jun 8, 2026
2 checks passed
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.

1 participant