Skip to content

feat(circuit_params): report multiverifier component sizes#404

Merged
ilyalesokhin-starkware merged 1 commit into
mainfrom
ilya/circuit-params-multiverifier
Jul 21, 2026
Merged

feat(circuit_params): report multiverifier component sizes#404
ilyalesokhin-starkware merged 1 commit into
mainfrom
ilya/circuit-params-multiverifier

Conversation

@ilyalesokhin-starkware

@ilyalesokhin-starkware ilyalesokhin-starkware commented Jul 21, 2026

Copy link
Copy Markdown
Contributor

Type

  • feature
  • bugfix
  • dev (no functional changes, no API changes)
  • fmt (formatting, renaming)
  • build
  • docs
  • testing

Description

Breaking changes?

  • yes
  • no

This change is Reviewable

@cursor

cursor Bot commented Jul 21, 2026

Copy link
Copy Markdown

PR Summary

Low Risk
Offline sizing/measurement tooling and dependency pins only; no runtime proof or verification path changes in this repo.

Overview
Extends the circuit-params CLI so it reports AIR component sizes for both the leaf Cairo verifier circuit and the multiverifier circuit that checks two leaf-verifier proofs.

Leaf sizes are still emitted for every trace log size in the requested range under a leaf: header. Multiverifier topology is built from a preprocessed leaf circuit (empty proofs, matching upstream multiverifier tests) and printed once under multiverifier: at max_trace_log_size. Shared sizing logic is refactored into component_sizes / context builders.

Workspace deps add circuit-verifier, circuit-multiverifier, and circuits from stwo-circuits (b14285a); circuit-common enables the prover feature for preprocessing. The CLI integration test expects the new output shape.

Reviewed by Cursor Bugbot for commit 14dc54d. Bugbot is set up for automated code reviews on this repo. Configure here.

Comment thread crates/circuit_params/src/main.rs Outdated
@ilyalesokhin-starkware
ilyalesokhin-starkware changed the base branch from ilya/circuit-params-sizes to graphite-base/404 July 21, 2026 07:37
@ilyalesokhin-starkware
ilyalesokhin-starkware force-pushed the ilya/circuit-params-multiverifier branch from af6b3f2 to 18cadb3 Compare July 21, 2026 07:52
@ilyalesokhin-starkware
ilyalesokhin-starkware changed the base branch from graphite-base/404 to ilya/circuit-params-sizes July 21, 2026 07:52
@ilyalesokhin-starkware
ilyalesokhin-starkware force-pushed the ilya/circuit-params-multiverifier branch from 18cadb3 to 55f1397 Compare July 21, 2026 08:07
Comment thread crates/circuit_params/src/main.rs
@codecov

codecov Bot commented Jul 21, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 67.85%. Comparing base (764b6fb) to head (14dc54d).

Additional details and impacted files
@@            Coverage Diff             @@
##             main     #404      +/-   ##
==========================================
+ Coverage   67.58%   67.85%   +0.26%     
==========================================
  Files          42       42              
  Lines        5411     5456      +45     
==========================================
+ Hits         3657     3702      +45     
  Misses       1754     1754              
Files with missing lines Coverage Δ
crates/circuit_params/src/main.rs 98.31% <100.00%> (+1.02%) ⬆️
🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@ilyalesokhin-starkware
ilyalesokhin-starkware force-pushed the ilya/circuit-params-multiverifier branch from 55f1397 to 01b124d Compare July 21, 2026 08:58

@cursor cursor Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Cursor Bugbot has reviewed your changes and found 1 potential issue.

Fix All in Cursor

❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, have a team admin enable autofix in the Cursor dashboard.

Reviewed by Cursor Bugbot for commit 01b124d. Configure here.

Comment thread crates/circuit_params/src/main.rs
@YairVaknin-starkware YairVaknin-starkware removed their assignment Jul 21, 2026
@YairVaknin-starkware
YairVaknin-starkware self-requested a review July 21, 2026 09:45
@ilyalesokhin-starkware
ilyalesokhin-starkware changed the base branch from ilya/circuit-params-sizes to graphite-base/404 July 21, 2026 10:41
Comment thread crates/circuit_params/src/main.rs
@ilyalesokhin-starkware
ilyalesokhin-starkware force-pushed the ilya/circuit-params-multiverifier branch from 01b124d to b763425 Compare July 21, 2026 11:56
@ilyalesokhin-starkware
ilyalesokhin-starkware changed the base branch from graphite-base/404 to ilya/circuit-params-sizes July 21, 2026 11:56

@ilyalesokhin-starkware ilyalesokhin-starkware left a comment

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@ilyalesokhin-starkware resolved 1 discussion.
Reviewable status: 0 of 5 files reviewed, all discussions resolved (waiting on YairVaknin-starkware).

@ilyalesokhin-starkware
ilyalesokhin-starkware changed the base branch from ilya/circuit-params-sizes to graphite-base/404 July 21, 2026 12:42
@ilyalesokhin-starkware
ilyalesokhin-starkware force-pushed the ilya/circuit-params-multiverifier branch from b763425 to 17cb051 Compare July 21, 2026 13:05
@ilyalesokhin-starkware
ilyalesokhin-starkware changed the base branch from graphite-base/404 to ilya/circuit-params-sizes July 21, 2026 13:05
@ilyalesokhin-starkware
ilyalesokhin-starkware changed the base branch from ilya/circuit-params-sizes to graphite-base/404 July 21, 2026 13:32

@YairVaknin-starkware YairVaknin-starkware left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@YairVaknin-starkware reviewed 5 files and all commit messages, and made 1 comment.
Reviewable status: all files reviewed, 1 unresolved discussion (waiting on ilyalesokhin-starkware).


crates/circuit_params/src/main.rs line 140 at r4 (raw file):

    let preprocessed_column_log_sizes = preprocessed_leaf.preprocessed_trace.log_sizes();

    // `ProofConfig` expects the components in ascending log-size order.

Where is this enforced?

Code quote:

/ `ProofConfig` expects the components in ascending log-size order.

@ilyalesokhin-starkware
ilyalesokhin-starkware force-pushed the ilya/circuit-params-multiverifier branch from 17cb051 to dcc249a Compare July 21, 2026 15:15
@graphite-app
graphite-app Bot changed the base branch from graphite-base/404 to main July 21, 2026 15:16
Report the multiverifier circuit's per-component sizes alongside the leaf
verifier's. The leaf verifier is reported for every trace log size in the
range; the multiverifier (which verifies two proofs of the leaf circuit) is
built once from the leaf at max_trace_log_size.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
@ilyalesokhin-starkware
ilyalesokhin-starkware force-pushed the ilya/circuit-params-multiverifier branch from dcc249a to 14dc54d Compare July 21, 2026 15:16
@ilyalesokhin-starkware

Copy link
Copy Markdown
Contributor Author

crates/circuit_params/src/main.rs line 140 at r4 (raw file):

Previously, YairVaknin-starkware wrote…

Where is this enforced?

It is not enforced directly.
we can discuss how to enforce that.

ilyalesokhin-starkware commented Jul 21, 2026

Copy link
Copy Markdown
Contributor Author

Merge activity

@ilyalesokhin-starkware
ilyalesokhin-starkware merged commit 705ad6a into main Jul 21, 2026
14 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants