Sign MLflow model artifacts with Vouch Credentials for verifiable model lineage.
Project description
vouch-mlflow
Sign MLflow model artifacts with Vouch Credentials, so a registered model carries verifiable lineage: who registered it, on whose authority, and a content digest that breaks if the weights are tampered with.
This complements OpenSSF Model Signing. OMS proves an artifact is intact and signed by a key; Vouch adds the agent and delegation dimension, which principal or pipeline registered the model, traceable back to an accountable human.
Install
pip install vouch-mlflow
It has no hard dependency on MLflow. The helpers work on any file or directory path, so they fit any artifact store.
Sign at registration time
from vouch import Signer
from vouch_mlflow import sign_model
signer = Signer(private_key=PRIV_JWK, did="did:web:ml.acme.com")
# After mlflow.log_model(...) wrote the model to a local path:
credential = sign_model(signer, "runs:/abc/model_local_path", name="fraud-detector")
# Attach to the run so it travels with the model:
import mlflow, json
mlflow.set_tag("vouch_credential", json.dumps(credential, separators=(",", ":")))
Verify on load
from vouch_mlflow import verify_model
ok, passport = verify_model(model_path, credential, public_key=registrant_pubkey)
if not ok:
raise RuntimeError("Model signature invalid or weights changed since signing")
verify_model checks both the signature and that the on-disk content still
matches the digest the credential was bound to.
License
Apache-2.0.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file vouch_mlflow-0.1.0.tar.gz.
File metadata
- Download URL: vouch_mlflow-0.1.0.tar.gz
- Upload date:
- Size: 3.1 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.13.9
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
588672b0592a2d1d7d568eb160f766dc172fcc4b08602d5c1d4fa9d25e3851f2
|
|
| MD5 |
5c84cb4759f59ae9fe917822ecc88f62
|
|
| BLAKE2b-256 |
8b5e7070b49c46d26bd4dc1241f6f4e85a18b5b8335a5df6ced07b79bff7ae5b
|
File details
Details for the file vouch_mlflow-0.1.0-py3-none-any.whl.
File metadata
- Download URL: vouch_mlflow-0.1.0-py3-none-any.whl
- Upload date:
- Size: 2.6 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.13.9
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
94e6c142deb5a24a7b73e1559eef43692deb72bffb799683df66b87c7bb51eed
|
|
| MD5 |
44626f8b653fbe2e65461cedb8aa254e
|
|
| BLAKE2b-256 |
892c0d2907bd46937d5e6e2f5031060159adf3150a77ea722eca562274c1ca25
|