Repository navigation
Add GoldilocksExt3 (Fp^3) StarkModel, Tensor-Batched STARK & Pruned-MMCS Soundness - #6
Merged
Merged
Conversation
…CS soundness - Add tensor-batched STARK verifiers (checkAfterChallengesTensor, verifyTensor, shardOkTensor, verifyBatchTensor) in CertiFri/Stark/Verifier.lean over Fri.verifyClaimsFromTensor. - Construct GoldilocksExt3.starkModel (Exec.Stark.StarkModel Goldilocks GoldilocksExt3 Fp3Model) for Fp[Y]/(Y^3 - Y - 1) over Goldilocks p = 2^64 - 2^32 + 1 and instantiate Horner-FRI STARK soundness corollaries. - Prove full adaptive-ROM tensor-batched STARK soundness over shape-independent multi-slot challenges UTensorChal: * Compiled.Params.acceptsTensor_of_outcome_verifyWithTensor_view_com * UniformTensor fraction bounds & FreeTensor/RunTensor challenger trace alignment * PcsSoundTensor: unconditional UD rbrSound_pcsTensor_ud (via Tensor2DMCA) and CurveListCA-parameterized Johnson rbrSound_pcsTensor_johnson_of_curveListCA * StateTensor / GoodLogTensor: RbrSound rbrSound_sdoomedTensor_ud, sdoomedTensor_nil, settles_interpTensor, prob_not_goodLogTensor_le * SoundnessTensor: unconditional verifyTensor / verifyBatchTensor AIR & LogUp lookup-balance theorems * PrunedTensor: monadic path restoration (restorePathsM, restoreShardPathsM), pruned-to-unpruned bridge, and unconditional soundness for verifyTensor / verifyBatchTensor with CertiFri.P3.prunedMmcs. - Instantiate the full Fp3 tensor STARK soundness stack in P3/GoldilocksExt3Soundness.lean, including DynamicRom-compatible RbrSound exports (rbrSound_starkTensor_ud, sdoomedTensor_nil_fp3, settles_interpTensor_fp3), unconditional Johnson tensor PCS RbrSound (rbrSound_pcsTensor_johnson via curveListCA_fp3), and concrete Digest (2^256) / Digest64 (2^512) pruned batch STARK theorems. - Wire all 13 new proof modules into Proofs/CertiFriProofs.lean and pin #check / #print axioms guards in Proofs/CertiFriProofs/Audit128.lean. Verified with ci.sh lean-build, axioms (174 modules, 10826 constants, strictly [propext, Classical.choice, Quot.sound]), and leanchecker.
arthurpaulino
previously approved these changes
Nov 27, 2026
…-arity folding
Generalize CertiFRI's tensor-batched FRI verifier, folding proximity gaps,
sponge-chained executable soundness, and unpruned/pruned-MMCS GoldilocksExt3
STARK soundness from binary folding (logArity = 1) to arbitrary per-round
variable-arity schedules (arities : List Nat, 1 <= a <= maxLogArity, covering
logArity in {1, 2, 3} / fold factors 2, 4, 8):
- CertiFri/MultiArity.lean, CertiFri/Pcs.lean, CertiFri/Stark/Verifier.lean:
add iterated binary foldRowMulti, canonical scheduleOfShape with soundness
and binary-compatibility lemmas (scheduleValid_scheduleOfShape,
scheduleOfShape_binary), multi-arity tensor FRI & STARK verifiers
(verifyTensorMultiArity, verifyTensorMultiArity/verifyBatchTensorMultiArity),
and compact 8-ary profiles FriParams.compact400KBBalanced (lb = 4,
maxLogArity = 3, logFinalPolyLen = 8, q = 58, queryPow = 28) and
FriParams.ultraCompact400KBZk (q = 55, queryPow = 30).
- Proofs/CertiFriProofs/Theory/MultiArity/{Fold,Ldt,PcsRbrTensor,CompiledTensor}.lean:
prove iterated binary fold equals coset polynomial evaluation
(foldRowMultiM_eq_foldAtPow), unconditional unique-decoding and
CurveListCA Johnson multi-arity fold proximity gaps (stepMCAArity_ud,
stepMCAArity_of_curveListCA_rel) with exact 2^a cancellation, and
multi-arity tensor PCS round-by-round and compiled Merkle soundness.
- Proofs/CertiFriProofs/Exec/MultiArity/{TensorExec,SpongeSoundness,StarkState,StarkSoundness}.lean:
lift multi-arity folding through executable FRI refinement, incremental
sponge chaining (c = 3 / 2), shape-independent adaptive-ROM RbrSound, and
unpruned/pruned-MMCS multi-arity tensor STARK & lookup-balance soundness.
- Proofs/CertiFriProofs/P3/GoldilocksExt3MultiAritySoundness.lean & Audit128.lean:
instantiate GoldilocksExt3 (Fp3Model) with 100% unconditional 128-bit
Johnson bounds (<= N / 2^128 under BLAKE2b-512 Digest64 and BLAKE3-256
Digest) for compact400KBBalanced and ultraCompact400KBZk, plus unpruned
and pruned-MMCS STARK soundness, pinned in Audit128.lean via #guard_msgs.
Verified with zero warnings/errors via scripts/ci.sh lean-build, axioms
(184 modules, 12399 constants, strictly [propext, Classical.choice, Quot.sound]),
and leanchecker.
arthurpaulino
approved these changes
Nov 27, 2026
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.
Extends$\mathbb{F}_{p^3} = \mathbb{F}_p[Y]/(Y^3 - Y - 1)$ over Goldilocks $p = 2^{64} - 2^{32} + 1$ ) tensor-batched STARK verification, including pruned-MMCS verification (
CertiFRI's unconditional tensor-FRI soundness stack to full Protocolv6cubic-extension (CertiFri.P3.prunedMmcs), LogUp lookup-balance soundness, and direct adaptive-ROMRbrSoundexports matchingix'sIx.Cert.MultiStark.soundness_dynamic_rominterface.1. Tensor-Batched STARK Verifier (
CertiFri/Stark/Verifier.lean)checkAfterChallengesTensor,verifyTensor,shardOkTensor, andverifyBatchTensorcallingFri.verifyClaimsFromTensor.2. Cubic Extension
StarkModel(Proofs/CertiFriProofs/P3/GoldilocksExt3Model.lean)CertiFri.P3.GoldilocksExt3.starkModel : Exec.Stark.StarkModel Goldilocks GoldilocksExt3 Fp3Modeltogether withFp3Model.extData,natCast_inj,natCast_inj_le, andtwo_ne_zero(exposinggoldilocks_twoAdicGenerator_sqinP3/Goldilocks.lean).Fp^3STARK corollaries (soundness_verify,soundness_verifyBatch,soundness_verify_lookups,soundness_verifyBatch_lookups).3. Adaptive-ROM Tensor STARK & Pruned-MMCS Soundness (11 New Modules under
Proofs/CertiFriProofs/)Theory/Compiled/AcceptsComTensor.lean&Theory/Stark/UniformTensor.lean: compiled acceptance and uniform fraction bounds over shape-independent multi-slot challengesUTensorChal.Exec/Stark/{FreeTensor,RunTensor,PcsSoundTensor,StateTensor,GoodLogTensor,ChainTensor,ShardGoodTensor,SoundnessTensor}.lean:FreeTensor,RunTensor).rbrSound_pcsTensor_ud(viaTensor2DMCA) andCurveListCA-parameterized JohnsonrbrSound_pcsTensor_johnson_of_curveListCA.rbrSound_sdoomedTensor_ud,sdoomedTensor_nil,settles_interpTensor, andprob_not_goodLogTensor_le.verifyTensorandverifyBatchTensor.Exec/Stark/PrunedTensor.lean: monadic pruned path restoration (restorePathsM,restoreShardPathsM, query-count preservation) and pruned-to-unpruned bridge yielding unconditional soundness forverifyTensor/verifyBatchTensorwithCertiFri.P3.prunedMmcs.4. Concrete
Fp^3&DynamicRomExports (Proofs/CertiFriProofs/P3/GoldilocksExt3Soundness.lean)Ix.Cert.MultiStark.soundness_dynamic_romplugs (rbrSound_starkTensor_ud,sdoomedTensor_nil_fp3,settles_interpTensor_fp3) over shape-independentUTensorChal Fp3Model fslots slots width.RbrSound(rbrSound_pcsTensor_johnson, dischargingCurveListCAinternally viacurveListCA_fp3).soundness_verifyBatchTensorPruned_digest32&soundness_verifyBatchTensorPruned_lookups_digest32(2^256,BLAKE3-256)soundness_verifyBatchTensorPruned_digest64&soundness_verifyBatchTensorPruned_lookups_digest64(2^512,BLAKE2b-512)Proofs/CertiFriProofs.leanand fenced with#guard_msgs#check+#print axiomsinProofs/CertiFriProofs/Audit128.lean.Verification
All checks ran cleanly on
0b8b1c6efwith zero warnings, zerosorry, zeronative_decide, zerobv_decide, and every theorem strictly⊆ [propext, Classical.choice, Quot.sound]:./scripts/ci.sh lean-build: PASS (59/59CertiFri+9,095/9,095CertiFriProofsjobs)./scripts/ci.sh axioms: PASS (174modules,10,826constants,6,459theorems)./scripts/ci.sh leanchecker: PASS (all174modules replayed in Lean 4 kernel)