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.
Motivation
page_opsmodule to reduce duplication and clarify responsibilities.make ci-checktarget and parameterizing evidence output paths.Description
hyperquant/page_ops.pywithhash_page,relative_rms,max_abs_error,top_rank_factors,quantize_page_int8, andprotected_maskfunctions and replaced in-place implementations incontext_codec.pyandresident_tier.pywith calls into this module.protected_vector_indicessupport end-to-end: API model (ResidentPlanRequest),create_apprequest handling,ContextCodec.compressand resident-tier builders/readers now accept and apply protected indices via theprotected_masklogic.payload_sha256for materialized pages and validating it on open/read, and improved decoding by factoring_decode_pageand tightening error messages.VECTOR_PREFER_NATIVE_FWHT_DEFAULTusage in the API so/v1/vector/decompresswill prefer native FWHT only when both the server default and envelope indicate it.scripts/build_proof_pack.pyto accept--output-dir, make displayed paths relative to repository or evidence dir, and use the parameterized evidence directory throughout.Makefileto use a singlemake ci-checktarget that runs compile checks, native build smoke test,pytest -q,python -m build, and an optional lightweight proof-pack generation controlled by an environment flag.tests/test_page_ops.py, expandedtests/test_resident_tier.pyandtests/test_api.pyto cover the new page ops, protected indices, payload hash enforcement, and server FWHT policy.Testing
pytest -q, including new teststests/test_page_ops.pyand updated API/resident tests, and all tests passed.make ci-check, which ranpython -m compileall, the native FWHT build,pytest -q, andpython -m build, and the checks completed successfully.python scripts/build_proof_pack.py --skip-tests --iterations 1 --warmup 0 --slice-iterations 1 --output-dir <tmpdir>, which produced expected artifacts and hash manifest.Codex Task