spec: Draft streaming prover approaches#642
Conversation
Codex Code ReviewFindings Low: spec/streaming.typ has an unfinished sentence in the No security vulnerabilities, VM behavior bugs, or significant performance issues found in the PR diff. The changes are documentation-only. I could not run a Typst/Shiroa build because neither |
|
|
||
| To distribute this workload across worker nodes or multiple GPUs, it is possible to "send off" | ||
| each batch of tables being retired to the next available worker. | ||
| With some care, it is likely possible to decouple the Fiat-Shamir challenges of multiple retirement batches, |
There was a problem hiding this comment.
Medium — Cryptographic soundness concern: Decoupling Fiat-Shamir challenges across retirement batches is non-trivial. If batches can derive challenges before all prior commitments from other concurrent batches are fixed, an adversary might be able to adaptively choose table contents in a later batch based on a challenge sampled by an earlier one, breaking the soundness reduction.
Before this claim is carried into implementation it should either:
- Reference a known-safe technique (e.g. parallel composition with independent random oracles, a random beacon, etc.), or
- Precisely define what "decouple" means here and argue why cross-batch influence is impossible given the ordering constraints.
There was a problem hiding this comment.
The underlying idea is that the randomizer for a batch depends on the batch itself, so any offset elsewhere will be randomized with a different challenge
| all table-to-table interactions can be proven within a single epoch. | ||
|
|
||
| To deal with cross-epoch memory, we introduce a "local-to-global" table per epoch that, in essence, | ||
| is an epoch-local memory initialiation and finalization mechanism. |
There was a problem hiding this comment.
Bug (editorial) + Medium — Soundness gap:
- Typo: "initialiation" → "initialization".
- The spec does not state what prevents the same address from appearing in more than one epoch's initialization segment simultaneously. If a malicious prover can claim a memory cell is "initialized" (with an arbitrary value) in two different epochs' local-to-global tables, it could forge values. The spec should explicitly state the constraint that enforces each address has at most one initialization across all epochs, and reference how this ties into the global LogUp token balance in
memory.typ.
There was a problem hiding this comment.
2 is clearly enforced by the global memory LogUp described by the approach
Review SummaryThis is a pure specification document (no code changes). Findings are focused on correctness of the prose and cryptographic protocol descriptions. Editorial (fix before merging)
Medium - Cryptographic soundness (address before implementation)
No Rust code, unsafe blocks, or cryptographic implementations were changed. |
The goal of this PR is to have a central place to discuss these options, so that we can potentially compare some implementation-based data and decide on which tradeoffs to go for.
The long-term goal is to pick a single approach and work that out properly in its own PR.