feat(registry): spec 026 model rights gates, index projection, crate types (#620) - #624
Merged
Merged
Conversation
…types (#620) Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
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.
Summary
Implements spec
026-model-rights-compliance(decision-log entry 127) for registry-side schema, CI, index and crate. Signing andrevoked.jsonvalidation are #621; the catalog is #622.check_new_contracts_declare_model_rights(ADD-only forward gate, wired intocapability-validation). Every objectai.modelsentry on a newly added model-backed contract must declare:commercial_use/redistribution/derivatives.unknownis rejected.redistribution: forbidden;derivatives: forbiddentogether with a derivation; a non-redistributable SPDX marker together withredistribution: allowed.license_files/notice_filesas{url, sha256}on Registry Release assets, which CI fetches and digest-verifies. NOTICE is required whenattribution_requiredis true.revision, or insidesource_url.derivation, either an object ornull, whoseconverted_sha256must appear in the crate'smodel-weights.json.data_obligations, which are validated when present.verification.status: maintainer-declared.LicenseRef-*needsevidence_url.rights_change {reason, evidence_url}.build_index.py): each entry gainsstatus(active|deprecated|revokedfromdeprecated.json/revoked.json) and a derivedmodel_usage[] {id, usage_class}. The full ModelRef record still rides verbatim inai.traverse-registry0.26.0: newmodel_rightsmodule with typedPublicAiDeclaration/PublicModelRef/ rights enums /ModelDerivationDeclaration/PublicRecordStatus.PublicRegistryCapabilityRecordgainsai,statusandmodel_usage(allserde(default), so olderindex.jsonfiles still deserialize). Exact and range resolution now skip revoked as well as deprecated records.docs/model-rights.mdcovers publisher and consumer obligations plus every error code.examples/model-rights/is the SC-005 package (LICENSE, NOTICE, attribution, provenance, derivation, data obligations); its sha256 values are real hashes of the files inrelease-assets/.Notable choices
derivationis a required key;nullmeans shipped verbatim. CI cannot detect a conversion it is never told about, so requiring the key turns spec FR-006's "when weights differ" into an explicit statement instead of silence.ai) deserializes with the new crate types.Governing Spec
Project Item
Closes #620
Definition of Done
cargo testandclippy -D warningsfortraverse-registryare green;pre_pr_check.shis greenValidation
python3 -m unittest scripts/ci/tests/test_capability_validation.py: 32 new spec 026 testspython3 -m unittest scripts/ci/tests/test_build_index.py: 5 new spec 026 testscargo test -p traverse-registry --locked: 233 lib tests, including 10 newcargo clippy -p traverse-registry --all-targets --locked -- -D warningsbash scripts/ci/pre_pr_check.sh🤖 Generated with Claude Code