Skip to content

Commit

Permalink
Groth16/MSM contracts and calldata generators for Starknet Sepolia (#146
Browse files Browse the repository at this point in the history
)
  • Loading branch information
feltroidprime authored Aug 11, 2024
1 parent b07f998 commit a504e55
Show file tree
Hide file tree
Showing 63 changed files with 81,012 additions and 20,197 deletions.
4 changes: 4 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
*.json
!*_input.json
!*Proof.json
!frobenius_*.json
__pycache__
venv
*.env
Expand All @@ -16,3 +17,6 @@ tools/garaga_rs/Cargo.lock

src/cairo/target/
*target*


!tools/starknet/groth16_contract_generator/examples/*.json
1 change: 1 addition & 0 deletions build/frobenius_cache/frobenius_0_12_1.json
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
{"k_expressions": [" + 0x1 * f_0 + 0x12 * f_6", " + 0x1d8c...5955 * f_1 + 0x217e...a71a * f_7", " + 0x242b...21a7 * f_2 + 0x3598...2536 * f_8", " + 0x2143...d5ed * f_3 + 0x1885...f771 * f_9", " + 0x2c84...048b * f_4 + 0xc33b...a7b5 * f_10", " + 0x1b00...cfa8 * f_5 + 0x215d...3977 * f_11", " + 0x3064...fd46 * f_6", " + 0x2469...62ac * f_1 + 0x12d7...a3f2 * f_7", " + 0x16c9...cba2 * f_2 + 0xc38d...dba0 * f_8", " + 0x7c03...b0e3 * f_3 + 0xf20e...275a * f_9", " + 0x2c14...8126 * f_4 + 0x3df9...f8bc * f_10", " + 0x12ac...2c4b * f_5 + 0x1563...2d9f * f_11"], "constants_list": [[[0, 1], [6, 18]], [[1, 13365409060938474037306578913838458522380504351979534994799168652879942015317], [7, 15149388816844991028686460567044464535476179991058260916837039682243069519642]], [[2, 16360020762774556598013388786114916077431217727990580677342011753074458436007], [8, 1515075255943902619915209849611390435230609634891435693592219128690297546038]], [[3, 15045457014669079880857698262349813226890047910746430923333052506178758170093], [9, 11091343436809180351614910509573166200913051272729455615890601373803728140145]], [[4, 20136284445039654443521573293420200948986700144072064670248776058768820274315], [10, 5519090358942869774631834397357627544196820822321065521472227381981946161077]], [[5, 12213237718317714435432069045728674390396718360292308943147966475590979932072], [11, 15091102541443398914402572935544421557437151058424932771830130262738472679799]], [[6, 21888242871839275222246405745257275088696311157297823662689037894645226208582]], [[1, 16469823323077808223889137241176536799009286646108169935659301613961712198316], [7, 8522833810900801184939826831418816566315806805318288667889869241765284193266]], [[2, 10307601595873709700152284273816112264069230130616436755625194854815875713954], [8, 5528222109064718624233016959142359011265093429307242985347026141570767772576]], [[3, 3505843767911556378687030309984248845540243509899259641013678093033130930403], [9, 6842785857170195341388707482907461861806263246551392739355985388466468038490]], [[4, 19937756971775647987995932169929341994314640652964949448313374472400716661030], [10, 1751958426799620778724832451837074139709611013225758992440261835876405934268]], [[5, 8447204650696766136447902020341177575205426561248465145919723016860428151883], [11, 9675005153521560786814336699528600698299592797005514719541071419054246276511]]]}
1 change: 1 addition & 0 deletions build/frobenius_cache/frobenius_0_12_2.json
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
{"k_expressions": [" + 0x1 * f_0", " + 0x3064...fd49 * f_1", " + 0x3064...fd48 * f_2", " + 0x3064...fd46 * f_3", " + 0x59e2...fffe * f_4", " + 0x59e2...ffff * f_5", " + 0x1 * f_6", " + 0x3064...fd49 * f_7", " + 0x3064...fd48 * f_8", " + 0x3064...fd46 * f_9", " + 0x59e2...fffe * f_10", " + 0x59e2...ffff * f_11"], "constants_list": [[[0, 1]], [[1, 21888242871839275220042445260109153167277707414472061641714758635765020556617]], [[2, 21888242871839275220042445260109153167277707414472061641714758635765020556616]], [[3, 21888242871839275222246405745257275088696311157297823662689037894645226208582]], [[4, 2203960485148121921418603742825762020974279258880205651966]], [[5, 2203960485148121921418603742825762020974279258880205651967]], [[6, 1]], [[7, 21888242871839275220042445260109153167277707414472061641714758635765020556617]], [[8, 21888242871839275220042445260109153167277707414472061641714758635765020556616]], [[9, 21888242871839275222246405745257275088696311157297823662689037894645226208582]], [[10, 2203960485148121921418603742825762020974279258880205651966]], [[11, 2203960485148121921418603742825762020974279258880205651967]]]}
1 change: 1 addition & 0 deletions build/frobenius_cache/frobenius_0_12_3.json
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
{"k_expressions": [" + 0x1 * f_0 + 0x12 * f_6", " + 0x13d0...dd76 * f_1 + 0x18a0...7a66 * f_7", " + 0xc3a5...3ae6 * f_2 + 0x2ce0...77f4 * f_8", " + 0xf20e...275a * f_3 + 0x17de...05d6 * f_9", " + 0x1bfe...9cc0 * f_4 + 0x697b...2fbd * f_10", " + 0x7a0e...c6fe * f_5 + 0x1b76...267f * f_11", " + 0x3064...fd46 * f_6", " + 0xabf8...c101 * f_1 + 0x1c93...1fd1 * f_7", " + 0x4f1d...86de * f_2 + 0x2429...c261 * f_8", " + 0x28a4...4c64 * f_3 + 0x2143...d5ed * f_9", " + 0x23d5...239f * f_4 + 0x1465...6087 * f_10", " + 0x16db...2499 * f_5 + 0x28c3...3649 * f_11"], "constants_list": [[[0, 1], [6, 18]], [[1, 8962796994142561318020731828686235839805240740882031587688271515838210497910], [7, 11139888828927304715070170254258059606344477568910959609173468391830532880998]], [[2, 5530884290053922304144789698142497171615764627662268383765069573573149473510], [8, 20297833428213404246748847976138555224655679424027567639634210889891384752116]], [[3, 6842785857170195341388707482907461861806263246551392739355985388466468038490], [9, 10796899435030094870631495235684108887783259884568368046798436520841498068438]], [[4, 12662075878685592334176167466297648270258898084773409719342381002174283488448], [10, 2981953136242954199074806921510952041507639786040776490510130360411260071869]], [[5, 3450433697903417549302685618164879376276650884475927416516222736246212970238], [11, 12422063293602986478931835435357103568858507930143618368233720881093900838527]], [[6, 21888242871839275222246405745257275088696311157297823662689037894645226208582]], [[1, 303847389135065887422783454877609941456349188919719272345083954437860409601], [7, 12925445877696713904225673916571039248891070416415792075000766378807015710673]], [[2, 2236595495967245188281701248203181795121068902605861227855261137820944008926], [8, 16357358581785352918101616047114777917080546529635555278923968321072076735073]], [[3, 18382399103927718843559375435273026243156067647398564021675359801612095278180], [9, 15045457014669079880857698262349813226890047910746430923333052506178758170093]], [[4, 16208900380737693084919495127334387981393726419856888799917914180988844123039], [10, 9226166993153682888070238278959626818437413072524413943346656892470942720135]], [[5, 10338197737521362862238855242243140895517409139741313354160881284257516364953], [11, 18437809173935857672943720127092395712419660272821896246172815158399013238345]]]}
1 change: 1 addition & 0 deletions build/frobenius_cache/frobenius_0_6_1.json
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
{"k_expressions": [" + 0x1 * f_0 + 0x12 * f_3", " + 0x242b...21a7 * f_1 + 0x3598...2536 * f_4", " + 0x2c84...048b * f_2 + 0xc33b...a7b5 * f_5", " + 0x3064...fd46 * f_3", " + 0x16c9...cba2 * f_1 + 0xc38d...dba0 * f_4", " + 0x2c14...8126 * f_2 + 0x3df9...f8bc * f_5"], "constants_list": [[[0, 1], [3, 18]], [[1, 16360020762774556598013388786114916077431217727990580677342011753074458436007], [4, 1515075255943902619915209849611390435230609634891435693592219128690297546038]], [[2, 20136284445039654443521573293420200948986700144072064670248776058768820274315], [5, 5519090358942869774631834397357627544196820822321065521472227381981946161077]], [[3, 21888242871839275222246405745257275088696311157297823662689037894645226208582]], [[1, 10307601595873709700152284273816112264069230130616436755625194854815875713954], [4, 5528222109064718624233016959142359011265093429307242985347026141570767772576]], [[2, 19937756971775647987995932169929341994314640652964949448313374472400716661030], [5, 1751958426799620778724832451837074139709611013225758992440261835876405934268]]]}
1 change: 1 addition & 0 deletions build/frobenius_cache/frobenius_0_6_2.json
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
{"k_expressions": [" + 0x1 * f_0", " + 0x3064...fd48 * f_1", " + 0x59e2...fffe * f_2", " + 0x1 * f_3", " + 0x3064...fd48 * f_4", " + 0x59e2...fffe * f_5"], "constants_list": [[[0, 1]], [[1, 21888242871839275220042445260109153167277707414472061641714758635765020556616]], [[2, 2203960485148121921418603742825762020974279258880205651966]], [[3, 1]], [[4, 21888242871839275220042445260109153167277707414472061641714758635765020556616]], [[5, 2203960485148121921418603742825762020974279258880205651966]]]}
1 change: 1 addition & 0 deletions build/frobenius_cache/frobenius_0_6_3.json
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
{"k_expressions": [" + 0x1 * f_0 + 0x12 * f_3", " + 0xc3a5...3ae6 * f_1 + 0x2ce0...77f4 * f_4", " + 0x1bfe...9cc0 * f_2 + 0x697b...2fbd * f_5", " + 0x3064...fd46 * f_3", " + 0x4f1d...86de * f_1 + 0x2429...c261 * f_4", " + 0x23d5...239f * f_2 + 0x1465...6087 * f_5"], "constants_list": [[[0, 1], [3, 18]], [[1, 5530884290053922304144789698142497171615764627662268383765069573573149473510], [4, 20297833428213404246748847976138555224655679424027567639634210889891384752116]], [[2, 12662075878685592334176167466297648270258898084773409719342381002174283488448], [5, 2981953136242954199074806921510952041507639786040776490510130360411260071869]], [[3, 21888242871839275222246405745257275088696311157297823662689037894645226208582]], [[1, 2236595495967245188281701248203181795121068902605861227855261137820944008926], [4, 16357358581785352918101616047114777917080546529635555278923968321072076735073]], [[2, 16208900380737693084919495127334387981393726419856888799917914180988844123039], [5, 9226166993153682888070238278959626818437413072524413943346656892470942720135]]]}
1 change: 1 addition & 0 deletions build/frobenius_cache/frobenius_1_12_1.json
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
{"k_expressions": [" + 0x1 * f_0 + 0x2 * f_6", " + 0x1808...14c5 * f_1 + 0x1808...14c5 * f_7", " + 0x5f19...ffff * f_2", " + 0xd5e1...9812 * f_9", " + 0x1a01...aaad * f_4 + 0x1a01...aaaf * f_10", " + 0xb659...022c * f_5 + 0xb659...022c * f_11", " + 0x1a01...aaaa * f_6", " + 0xfc3e...4af3 * f_1 + 0x1f87...95e6 * f_7", " + 0x1a01...aaac * f_2 + 0x1a01...aaac * f_8", " + 0x6af0...cc09 * f_3", " + 0x5f19...fffe * f_10", " + 0x144e...2995 * f_5 + 0xe9b7...a87f * f_11"], "constants_list": [[[0, 1], [6, 2]], [[1, 3699099184852670630486504326366823957760732022002356992020042909103225195948437585701677765097109891745284740289733], [7, 3699099184852670630486504326366823957760732022002356992020042909103225195948437585701677765097109891745284740289733]], [[2, 793479390729215512621379701633421447060886740281060493010456487427281649075476305620758731620351]], [[9, 2057464292470212699950648958431590554769679873859515792311286236065221686597310451751142621105086029381756709738514]], [[4, 4002409555221667392624310435006688643935503118305586438271171395842971157480381377015405980053539358417135540939437], [10, 4002409555221667391830831044277473131314123416672164991210284655561910664469924889588124330978063052796376809319087]], [[5, 1754153922101215937019363459062510355973529075922864898999271009044415232054910173010132757073180257089147177468460], [11, 1754153922101215937019363459062510355973529075922864898999271009044415232054910173010132757073180257089147177468460]], [[6, 4002409555221667393417789825735904156556882819939007885332058136124031650490837864442687629129015664037894272559786]], [[1, 151655185184498381465642749684540099398075398968325446656007613510403227271200139370504932015952886146304766135027], [7, 303310370368996762931285499369080198796150797936650893312015227020806454542400278741009864031905772292609532270054]], [[2, 4002409555221667392624310435006688643935503118305586438271171395842971157480381377015405980053539358417135540939436], [8, 4002409555221667392624310435006688643935503118305586438271171395842971157480381377015405980053539358417135540939436]], [[3, 1028732146235106349975324479215795277384839936929757896155643118032610843298655225875571310552543014690878354869257]], [[10, 793479390729215512621379701633421447060886740281060493010456487427281649075476305620758731620350]], [[5, 3125332594171059424908108096204648978570118281977575435832422631601824034463382777937621250592425535493320683825557], [11, 2248255633120451456398426366673393800583353744016142986332787127079616418435927691432554872055835406948747095091327]]]}
1 change: 1 addition & 0 deletions build/frobenius_cache/frobenius_1_12_2.json
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
{"k_expressions": [" + 0x1 * f_0", " + 0x5f19...ffff * f_1", " + 0x5f19...fffe * f_2", " + 0x1a01...aaaa * f_3", " + 0x1a01...aaac * f_4", " + 0x1a01...aaad * f_5", " + 0x1 * f_6", " + 0x5f19...ffff * f_7", " + 0x5f19...fffe * f_8", " + 0x1a01...aaaa * f_9", " + 0x1a01...aaac * f_10", " + 0x1a01...aaad * f_11"], "constants_list": [[[0, 1]], [[1, 793479390729215512621379701633421447060886740281060493010456487427281649075476305620758731620351]], [[2, 793479390729215512621379701633421447060886740281060493010456487427281649075476305620758731620350]], [[3, 4002409555221667393417789825735904156556882819939007885332058136124031650490837864442687629129015664037894272559786]], [[4, 4002409555221667392624310435006688643935503118305586438271171395842971157480381377015405980053539358417135540939436]], [[5, 4002409555221667392624310435006688643935503118305586438271171395842971157480381377015405980053539358417135540939437]], [[6, 1]], [[7, 793479390729215512621379701633421447060886740281060493010456487427281649075476305620758731620351]], [[8, 793479390729215512621379701633421447060886740281060493010456487427281649075476305620758731620350]], [[9, 4002409555221667393417789825735904156556882819939007885332058136124031650490837864442687629129015664037894272559786]], [[10, 4002409555221667392624310435006688643935503118305586438271171395842971157480381377015405980053539358417135540939436]], [[11, 4002409555221667392624310435006688643935503118305586438271171395842971157480381377015405980053539358417135540939437]]]}
1 change: 1 addition & 0 deletions build/frobenius_cache/frobenius_1_12_3.json
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
{"k_expressions": [" + 0x1 * f_0 + 0x2 * f_6", " + 0xca2f...1299 * f_1 + 0xca2f...1299 * f_7", " + 0x1a01...aaaa * f_2", " + 0xca2f...1299 * f_9", " + 0x1a01...aaaa * f_4 + 0x1a01...aaa9 * f_10", " + 0xd5e1...9812 * f_5 + 0xd5e1...9812 * f_11", " + 0x1a01...aaaa * f_6", " + 0x6af0...cc09 * f_1 + 0xd5e1...9812 * f_7", " + 0x1 * f_2 + 0x1 * f_8", " + 0x1352...dea2 * f_3", " + 0x1 * f_10", " + 0x1352...dea2 * f_5 + 0xca2f...1299 * f_11"], "constants_list": [[[0, 1], [6, 2]], [[1, 1944945262751454693467140867304313601787202946079492093020771900058809963893527412691545008023929634656137562821273], [7, 1944945262751454693467140867304313601787202946079492093020771900058809963893527412691545008023929634656137562821273]], [[2, 4002409555221667393417789825735904156556882819939007885332058136124031650490837864442687629129015664037894272559786]], [[9, 1944945262751454693467140867304313601787202946079492093020771900058809963893527412691545008023929634656137562821273]], [[4, 4002409555221667393417789825735904156556882819939007885332058136124031650490837864442687629129015664037894272559786], [10, 4002409555221667393417789825735904156556882819939007885332058136124031650490837864442687629129015664037894272559785]], [[5, 2057464292470212699950648958431590554769679873859515792311286236065221686597310451751142621105086029381756709738514], [11, 2057464292470212699950648958431590554769679873859515792311286236065221686597310451751142621105086029381756709738514]], [[6, 4002409555221667393417789825735904156556882819939007885332058136124031650490837864442687629129015664037894272559786]], [[1, 1028732146235106349975324479215795277384839936929757896155643118032610843298655225875571310552543014690878354869257], [7, 2057464292470212699950648958431590554769679873859515792311286236065221686597310451751142621105086029381756709738514]], [[2, 1], [8, 1]], [[3, 2973677408986561043442465346520108879172042883009249989176415018091420807192182638567116318576472649347015917690530]], [[10, 1]], [[5, 2973677408986561043442465346520108879172042883009249989176415018091420807192182638567116318576472649347015917690530], [11, 1944945262751454693467140867304313601787202946079492093020771900058809963893527412691545008023929634656137562821273]]]}
1 change: 1 addition & 0 deletions build/frobenius_cache/frobenius_1_6_1.json
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
{"k_expressions": [" + 0x1 * f_0 + 0x2 * f_3", " + 0x5f19...ffff * f_1", " + 0x1a01...aaad * f_2 + 0x1a01...aaaf * f_5", " + 0x1a01...aaaa * f_3", " + 0x1a01...aaac * f_1 + 0x1a01...aaac * f_4", " + 0x5f19...fffe * f_5"], "constants_list": [[[0, 1], [3, 2]], [[1, 793479390729215512621379701633421447060886740281060493010456487427281649075476305620758731620351]], [[2, 4002409555221667392624310435006688643935503118305586438271171395842971157480381377015405980053539358417135540939437], [5, 4002409555221667391830831044277473131314123416672164991210284655561910664469924889588124330978063052796376809319087]], [[3, 4002409555221667393417789825735904156556882819939007885332058136124031650490837864442687629129015664037894272559786]], [[1, 4002409555221667392624310435006688643935503118305586438271171395842971157480381377015405980053539358417135540939436], [4, 4002409555221667392624310435006688643935503118305586438271171395842971157480381377015405980053539358417135540939436]], [[5, 793479390729215512621379701633421447060886740281060493010456487427281649075476305620758731620350]]]}
1 change: 1 addition & 0 deletions build/frobenius_cache/frobenius_1_6_2.json
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
{"k_expressions": [" + 0x1 * f_0", " + 0x5f19...fffe * f_1", " + 0x1a01...aaac * f_2", " + 0x1 * f_3", " + 0x5f19...fffe * f_4", " + 0x1a01...aaac * f_5"], "constants_list": [[[0, 1]], [[1, 793479390729215512621379701633421447060886740281060493010456487427281649075476305620758731620350]], [[2, 4002409555221667392624310435006688643935503118305586438271171395842971157480381377015405980053539358417135540939436]], [[3, 1]], [[4, 793479390729215512621379701633421447060886740281060493010456487427281649075476305620758731620350]], [[5, 4002409555221667392624310435006688643935503118305586438271171395842971157480381377015405980053539358417135540939436]]]}
1 change: 1 addition & 0 deletions build/frobenius_cache/frobenius_1_6_3.json
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
{"k_expressions": [" + 0x1 * f_0 + 0x2 * f_3", " + 0x1a01...aaaa * f_1", " + 0x1a01...aaaa * f_2 + 0x1a01...aaa9 * f_5", " + 0x1a01...aaaa * f_3", " + 0x1 * f_1 + 0x1 * f_4", " + 0x1 * f_5"], "constants_list": [[[0, 1], [3, 2]], [[1, 4002409555221667393417789825735904156556882819939007885332058136124031650490837864442687629129015664037894272559786]], [[2, 4002409555221667393417789825735904156556882819939007885332058136124031650490837864442687629129015664037894272559786], [5, 4002409555221667393417789825735904156556882819939007885332058136124031650490837864442687629129015664037894272559785]], [[3, 4002409555221667393417789825735904156556882819939007885332058136124031650490837864442687629129015664037894272559786]], [[1, 1], [4, 1]], [[5, 1]]]}
Loading

0 comments on commit a504e55

Please sign in to comment.