feat(hosted): add retention and measured scale gates - #79
Merged
Merged
Conversation
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.
The hosted context foundation lacked enforceable retention and honest production-scale evidence. A stale hold release could race newer policy, checkpoint deletion and key destruction were not independently bound, build and benchmark freshness could drift, and local predicate checks could be mistaken for hosted data-plane proof.
This change adds revision-CAS retention commands, per-cycle versioned DEKs, remote-object deletion verification before independently receipted managed-KMS destruction, and crash-safe cleanup owned by the original operation identity. Managed-key rotation preserves the immutable key version for every opaque key reference and requires a current signed provider qualification for every version still used by a non-expired cycle. It also binds checkpoint/hydrate identity, runtime package-tree bytes, the exact data-plane case generator, and live hosted-readiness evidence.
The clean-source measurement harness records capacity, recall, retrieval latency, resident memory, checkpoint, hydrate, and actual index rebuild. The deterministic one-million-case local isolation run is explicitly
predicateevidence and cannot qualify reach; qualification requires a separate independently signed hosted data-plane receipt.FileCycleKeyProviderremains canary-only.wheel_digestis signed provenance; the runtime enforces the imported Python package-tree digest, while CI or release custody must independently verify a claimed wheel artifact.Validation:
python -m pytest -q— 637 passed, 5 skippedpython -m pytest -q tests/test_retention_scale.py— 24 passedpython -m pytest -q tests/test_hosted_context.py— 13 passedaether_context, compileall, schema regeneration, andgit diff --check— passedLive provider credentials, managed infrastructure, a randomized million-case hosted data-plane receipt, and the Gate 8 observation window remain external rollout gates. This PR does not claim those gates have passed.