Repository navigation
Add per-problem metadata files with descriptions - #331
Merged
Merged
Conversation
dweindl
force-pushed
the
problem-metadata
branch
from
October 12, 2026 13:57
1da0034 to
c6c55cc
Compare
Each problem now has `problems/<ProblemID>/metadata.yaml` for metadata that applies to both PEtab versions. For now, it holds a single required field, `description`: one plain-ASCII sentence (20-160 characters) that states the model type, the biological system and, where informative, the data. It is short enough to fit a future overview table column. Descriptions are added for all 35 problems. Further fields are planned and will be added separately. The metadata is kept out of `problem.yaml` so it isn't duplicated across `v1/` and `v2/` and doesn't interfere with PEtab YAML validation. * Add JSON schema `schemas/metadata.schema.json`, shipped in the package via `MANIFEST.in`. Unknown fields are rejected, so new fields require a schema change. * Add `get_metadata()` and the `bmp-check-metadata` CLI, which validates all metadata files; run it in the "Tests" workflow. * Add `jsonschema` and `pyyaml` as explicit dependencies. * Document the file in CONTRIBUTING.md and the PR template. 🤖 Drafted with AI assistance Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
dweindl
force-pushed
the
problem-metadata
branch
from
October 12, 2026 14:09
c6c55cc to
54d3b3d
Compare
dweindl
marked this pull request as ready for review
October 12, 2026 14:10
dilpath
approved these changes
Oct 13, 2026
dilpath
left a comment
Member
There was a problem hiding this comment.
short_descriptioninstead ofdescription? In future, I think all information that is normally stored in the github issues will be inside the metadata file so there is a single-source of information, and then we will need some generic description field where a lot of hints/tips/experiences/additional references/longer descriptions etc. can go- implement an object model for metadata, e.g. with pydantic and possibly mkstd? Will simplify things a bit I think, e.g. adding new fields and validating files.
Comment on lines
+17
to
+18
| # version-independent metadata (`<MODELS_DIR>/<ProblemID>/metadata.yaml`) | ||
| METADATA_FILENAME: str = "metadata.yaml" |
Member
There was a problem hiding this comment.
Suggested change
| # version-independent metadata (`<MODELS_DIR>/<ProblemID>/metadata.yaml`) | |
| METADATA_FILENAME: str = "metadata.yaml" | |
| METADATA_FILENAME: str = "metadata.yaml" |
Address review on PEtab-dev#331: * Model `metadata.yaml` by the pydantic model `ProblemMetadata` and validate files against it. `get_metadata()` now returns a `ProblemMetadata` instance. The packaged JSON schema is generated from the model via `write_metadata_schema()`; a test checks that it is up to date. Replaces the `jsonschema` dependency by `pydantic`. * Rename `description` to `short_description`, leaving `description` for a future longer free-form description. * Drop a redundant comment in `C.py`. 🤖 Drafted with AI assistance Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Member
Author
Changed to |
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.
Adds a machine-readable, PEtab-version-independent metadata file
problems/<ProblemID>/metadata.yamlfor each problem. For now, it holds a single required field,short_description: one plain-ASCII sentence (20–160 characters) stating the model type (reaction network, compartmental epidemiological model, cell population model, ...), the biological system and, where informative, the data. It's kept short so it can later go into the overview table. The name leaves room for a later free-formdescriptionfield for longer text (hints, experiences, additional references, ...). Further fields (e.g., a structured model type, DOI) are planned and will be added separately.Example (
Boehm_JProteomeRes2014):The metadata is kept out of
problem.yamlso it isn't duplicated acrossv1/and the upcomingv2/, and doesn't interfere with PEtab YAML validation.Changes:
metadata.yamlwith a short description for all 35 problems. Descriptions were written based on the publications and model files; please check the ones for problems you know well.ProblemMetadatadefining the metadata format. Unknown fields are rejected, so each new field requires a model change.benchmark_models_petab/schemas/metadata.schema.json, generated fromProblemMetadataviawrite_metadata_schema()and included in the package viaMANIFEST.in; a test checks that it is up to date.get_metadata(id_), returning aProblemMetadata, and abmp-check-metadataCLI that validates all metadata files; added as a step to the "Tests" workflow.pydanticandpyyamladded as explicit dependencies (both are already transitive dependencies of recentpetabversions).🤖 Drafted with AI assistance