Repository navigation
feat(submission): link model references through a DomainPlugins bibtex hook - #182
Merged
Merged
Conversation
modelentry_from_model only linked a reference when the Model row was created, so a model scored before its bibtex was known never got one. Link it whenever bibtex is given and the row has none. Plugin bibtex often has a doi but no url, which made reference_from_bibtex fail; fall back to the doi.org url.
Scoring read model.bibtex, which domain models do not have. Add DomainPlugins.load_model_bibtex (None by default) and pass its result to modelentry_from_model, so domains opt in without mutating model objects. Also strip a doi.org or doi: prefix before building the doi fallback url.
KartikP
marked this pull request as ready for review
October 12, 2026 14:53
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.
Scored models never get a reference (paper citation) in the database.
Changes
DomainPlugins.load_model_bibtex(identifier) -> Optional[str], returning None by default.RunScoringEndpointpasses its result tomodelentry_from_model, instead of readingmodel.bibtex, which no domain's model objects have. Domains opt in by overriding it, and model objects are never changed. The earlyload_modelcall stays, so a model that fails to load still fails before any score row is created.modelentry_from_modellinks the reference whenever bibtex is given and the row has no reference yet. Before, it did this only when the row was first created. An existing reference is never replaced.reference_from_bibtexfalls back tohttps://doi.org/<doi>when the bibtex has nourl. A doi written with ahttps://doi.org/ordoi:prefix is stripped first, so the url is not doubled.Tests
Release
feat:, because it adds a public hook: minor release (2.5.0). vision#2597 overrides the hook and needs this release.Context
The 13
mehrer2020_alexnet_training_seed_*prod rows were back-filled by hand (reference 165).