feat(repr): expose exact backend model revisions#83
Merged
Conversation
Backends now report the exact commit they resolved through a model_revision property, and accept a `repository@revision` model identifier to pin one. The local emotion2vec path has no hub commit to report, so it falls back to a content SHA-256 over the model directory. This is what lets a training run record which encoder weights produced it, rather than trusting a mutable tag.
jsugg
force-pushed
the
feat/backend-model-revision
branch
from
July 15, 2026 21:10
7172d58 to
e194825
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Makes it possible to record which encoder weights produced a training run,
instead of trusting a mutable tag like
mainto mean the same thing later.What changes
model_revisionproperty returning the exactcommit resolved by the loaded model (
config._commit_hash).repository@revisionform; the revision is passedthrough to the loader so a pinned revision is what actually gets fetched.
to a
content-sha256:digest computed over the model directory. A localdirectory with no revision at all returns
Nonerather than inventing one.Scope
Additive only — the property is new, and an identifier without
@behavesexactly as before. No caller reads
model_revisionyet; the training readinesswork consumes it to bind prepared plans to a verified backend commit, and is
what motivated this.
Verification
make lint,make type(mypy + pyright clean) and the 231 backend/repr testspass. Pre-push gate passed.