675 Commits

Author SHA1 Message Date
Balazs Komuves
15bb9599f3
Merge branch 'main' into codex 2025-01-31 10:52:35 +01:00
Balazs Komuves
d682f58af5
Merge remote-tracking branch 'origin/main' into codex
# Conflicts:
#	plonky2/src/gates/lookup.rs
2025-01-31 10:47:49 +01:00
Robin Salen
0362deb648
Bump patch version 2025-01-30 15:15:15 -05:00
Linda Guiga
753389a2ca
Fix padding for LookupTableGate (#1661) 2025-01-31 05:02:20 +09:00
Balazs Komuves
f7b4e62f2e
add rudimentary hash counting statistics 2025-01-30 19:40:36 +01:00
Robin Salen
6eb63f0200
Bump versions 2025-01-28 11:41:20 -05:00
Linda Guiga
091047f7f1
Fix padding in LookupTableGate (#1656)
* Fix soundness in Lookups

* FIx recursion
2025-01-29 01:39:13 +09:00
Balazs Komuves
23dff50624
add "test vectors" for gate constraints, to help debugging 2025-01-27 11:54:59 +01:00
Nikita Masych
cc0834ae07
fix: correct visibility in gate_serialization macros (#1650)
* fix: correct visibility in gate_serialization macros

* chore: cargo fmt
2025-01-22 15:51:09 +00:00
Balazs Komuves
ec5437b315
add an example with two different lookup tables 2025-01-17 11:09:23 +01:00
Eduard S.
892f51bd12
fix: use u64 in BaseSplitGenerator (#1647)
The BaseSplitGenerator was casting fields (which fit in u64) into usize.
This doesn't work in 32-bit architectures where usize is 32 bits, like
wasm32.  Keeping the value at u64 allows it to work in 32-bit
architectures.
2025-01-14 02:18:52 +09:00
carlogf
02e80e9af0
add serialization and deserialization for BytesHash (#1645)
* add serialization and deserialization for BytesHash

* fix cargo clippy precedence errors

---------

Co-authored-by: fdecroix <fdecroix@eryx.co>
2025-01-07 23:17:33 +09:00
Balazs Komuves
1079f0f3ce
export field elements (in the witness) as strings, as javascript handles JSON numbers as floats (53 bit precision is not enough for Goldilocks) 2024-12-17 18:28:27 +01:00
Balazs Komuves
b4085c3071
when exporting the witness, handle the lookup selector columns too 2024-12-17 14:45:09 +01:00
Balazs Komuves
dfb35e1781
remove poseidon_crandall.rs (it's empty) 2024-12-13 20:50:50 +01:00
Balazs Komuves
9f9c67d373
include <D=2> in the Reducing*Gate id 2024-12-13 19:43:28 +01:00
Balazs Komuves
32753831d2
export the constant columns (selectors too) for third-party tooling 2024-12-13 11:35:36 +01:00
Balazs Komuves
4625d3a63c
serializing circuit data in the recursion example 2024-12-12 11:29:51 +01:00
Balazs Komuves
790042102d
export witness from the bench_recursion example 2024-12-12 11:10:36 +01:00
Balazs Komuves
62ce94e260
remove batch_fri/*: it's not used anywhere and that's just confusing 2024-12-09 18:31:34 +01:00
Balazs Komuves
172bee1ba1
fix rust warnings; make bench_recursion work 2024-12-06 16:44:58 +01:00
Balazs Komuves
1e31a1ad9a
add lookup example circuit 2024-12-06 14:14:17 +01:00
Balazs Komuves
be9ea35a15
band-aid quick fix for https://github.com/0xPolygonZero/plonky2/issues/1641 2024-12-06 14:12:42 +01:00
Balazs Komuves
b233c55be6
add prover options to export the witness (+ gates + selectors) for third party visualization 2024-12-05 12:36:53 +01:00
Balazs Komuves
155a0ce24e
add a single selector vector into SelectorsInfo to make life easier 2024-12-05 12:02:34 +01:00
Balazs Komuves
301ae79b6f
add "short id" for gates, for easier interop with third-party tooling (untested) 2024-12-05 00:12:47 +01:00
Balazs Komuves
99aac4dd08
config option to turn off randomizing unused wires (makes debugging easier as it becomes deterministic)
if you turn it off apparently you have something like a 10^-13 chance of the proof failing, and since it's deterministic (unless zero knowledge), it will always fail.

remark: now it's off by default. Don't forget to turn it back in production
2024-12-04 23:08:52 +01:00
Nikita Masych
356aefb686
fix: changed conditioning for timing functionality in circuit_builder (#1640) 2024-11-27 17:37:14 +00:00
Robin Salen
6d1b99e5ca
v1.0.0 release (#1637)
* Update CHANGELOG

* Bump versions
2024-11-26 02:58:04 +09:00
Sai
7203b7ad0b
Unified Recursion Circuit for Multi-Degree Starky Proof Verification (#1635)
* add test

* wip

* update witness util

* degree_bits: usize->target

* wip

* fix

* opt

* passed 3 tests

* fix

* convert g to g_ext

* hack observe final poly coeffs

* wip

* poc works

* wip

* pass tests

* more in test

* better test

* fix ci

* clippy

* fix

* fix

* start on multi steps

* wip

* set all zeros

* wip

* challenge passes

* work

* poc done

* fix non std build

* add comments

* update stark verifier

* fix clippy

* fix test build

* fix tests

* add comments

* add checks

* polish the checks

* more checks

* comments
2024-11-26 01:58:08 +09:00
Robin Salen
2488cdacd4
Fix DummyProofGenerator serialization (#1634)
* Fix dummy generator serialization

* Tweak

* Update CODEOWNERS
2024-10-17 22:31:21 +09:00
Sai
7959bd22ce
Refactor CTL Handling (#1629)
* refactor

* fmt

* fmt

* sync target version

* fix

* fix clippy

* fix clippy
2024-10-09 08:29:34 -07:00
Arman Aurobindo
41dc325e61
changed to web-time in circuit_builder (#1624)
* changed to web-time in circuit_builder

* Rustfmt

---------

Co-authored-by: Robin Salen <30937548+Nashtare@users.noreply.github.com>
2024-09-10 21:08:10 +00:00
Simon Perriard
a4efbe8369
Fix example and documentation rendering (#1614)
* Fix starky runnable doc example and fix cargo doc

* Formatting and Clippy

* bump katex version and add config.toml

* Update README for local doc and add flag for docs.rs

* Add missing whitespace

---------

Co-authored-by: Robin Salen <30937548+Nashtare@users.noreply.github.com>
Co-authored-by: Ben <bmarsh94@gmail.com>
2024-08-29 12:22:37 +00:00
Robin Salen
9fdf1b8ef4
Add connect_array convenience method in CircuitBuilder (#1620)
* Add connect_array method

* Pacify clippy

* Wording
2024-08-27 20:56:19 +00:00
Robin Salen
349beae143
Do not panic on wire set twice or generator not run issues (#1611)
* Do not panic on wire set twice or generator not run issues

* No std
2024-08-08 03:53:14 +09:00
Sai
0e363e16a3
Add Support for Batch STARKs with Proving, Verification, and Recursion (#1600)
* add batch starks

* fix build

* fix ci

* address comments from hratoanina

* address comments from Nashtare

* fix tests

* address comments from hratoanina

* Update plonky2/src/batch_fri/recursive_verifier.rs

Co-authored-by: Robin Salen <30937548+Nashtare@users.noreply.github.com>

* Update plonky2/src/hash/merkle_proofs.rs

Co-authored-by: Robin Salen <30937548+Nashtare@users.noreply.github.com>

* Update plonky2/src/batch_fri/verifier.rs

Co-authored-by: Robin Salen <30937548+Nashtare@users.noreply.github.com>

---------

Co-authored-by: Robin Salen <30937548+Nashtare@users.noreply.github.com>
2024-07-15 22:43:07 +00:00
Robin Salen
4090881d5c
chore: fix clippy (#1609) 2024-07-16 07:28:16 +09:00
Gio
4813d563d0
chore: replace stale link (#1602) 2024-06-16 23:58:13 +09:00
Daniel-Aaron-Bloom
15836d9d8c
doc+fix: clippy::doc-lazy-continuation (#1594) 2024-05-29 07:20:44 +09:00
Linda Guiga
dc77c77f2b
Changes to prepare for dummy segment removal in zk_evm's continuations (#1587)
* Make select_proof_with_pis public

* Add API methods for dummy segment removal

* Change visibility of dummy_circuit

* Return actual verifier data

* Fix Clippy

* Apply comments

---------

Co-authored-by: Hamy Ratoanina <hamy.ratoanina@toposware.com>
2024-05-03 14:10:38 +01:00
yanziseeker
1f6c04f62c
Update circuit_data.rs 2024-04-24 21:30:39 +08:00
Matthias Görgens
72c1c90748
Remove obsolete function ceil_div_usize (#1574) 2024-04-19 22:00:03 +09:00
Robin Salen
76da138338
Bump versions pre-release (#1569) 2024-04-16 20:10:19 +09:00
Matthias Goergens
0731fec251 Simplify types: remove option from CTL filters
CTL filters can already express perfectly well the behaviour that we
gave for `None`.  No need to complicated anything.

Plus some random lint fixes that clippy demanded..
2024-04-15 17:14:54 +08:00
Hamy Ratoanina
54cee24b36
Bump versions pre-release (#1557) 2024-03-21 14:34:41 -04:00
Alonso González
4f8e631550
Prove Starks without constraints (#1552)
* Enable starks without constraints

* Clippy

* Add test stark without constraints

* Missing file

* Missing changes in the recursive side

* Fix bug with recursion

* Missing import

* Clippy

* Apply suggestions from code review

Co-authored-by: Robin Salen <30937548+Nashtare@users.noreply.github.com>

* Address reviews

* Fix TODO

* Apply suggestions from code review

Co-authored-by: Linda Guiga <101227802+LindaGuiga@users.noreply.github.com>

* More reviews

* Fix bug in eval_helper_columns

* Apply suggestions from code review

Co-authored-by: Robin Salen <30937548+Nashtare@users.noreply.github.com>

* Address reviews

* Allow <= blowup_factor + 1 constraints + reviews

* Add unconstrined Stark

* Missing file

* Remove asserts

---------

Co-authored-by: Robin Salen <30937548+Nashtare@users.noreply.github.com>
Co-authored-by: Linda Guiga <101227802+LindaGuiga@users.noreply.github.com>
2024-03-15 11:43:45 +00:00
Nicholas Ward
316e13ea4b example documentation fix 2024-03-04 14:05:16 -08:00
Robin Salen
44dc0f96ff
Add mention to versions in local dependencies (#1546) 2024-02-28 06:27:21 +00:00
Robin Salen
0817fd8e98
Pacify clippy (#1547) 2024-02-28 15:21:34 +09:00