Repository navigation
Release 1.2.0
Classification responses now carry the provenance of the model that
produced them, so callers can pin and audit which exact weights generated
a given result.
POST /classify/severityresponses now include two new fields:model: the Hugging Face repository identifier that produced the
prediction (e.g.
CIRCL/vulnerability-severity-classification-RoBERTa-base).model_revision: the commit SHA of the snapshot that was loaded
from the Hugging Face Hub at startup, ornullwhen the source
does not carry revision metadata (for example, models loaded from
a local path).
- The revision is captured once in
SeverityClassifier.__init__from
model.config._commit_hash, which transformers stamps onto the
config duringfrom_pretrainedfor both fresh downloads and cached
snapshots. No extra Hugging Face API call is made at request time. - A new
SeverityResponsePydantic schema is wired as the endpoint's
response_model, so the OpenAPI documentation now describes every
response field, including the provenance metadata and the optional
errorfield returned when an unknown model is requested. errorresponses (unknown model) now also includemodeland
model_revision(the latter asnull) so the response shape stays
consistent across success and failure paths.
This is a backwards-compatible change for clients that read only
severity and confidence; the new keys are additive.