Introducing Achronyme — a language for zero-knowledge proofs. Read the announcement arrow_right_alt

Crate Map

Workspace crate dependencies and responsibilities.

The Achronyme workspace contains 19 crates. All share the same version and Rust edition. The post-cleanup layering (closed 2026-04-24) groups them into four tiers: leaves with no workspace dependencies, vocabulary crates, IR/compiler stack, and top-level orchestration.

Crate overview

CratePathPurpose
diagnosticscrates/diagnostics/Spans, errors, suggestions, rustc-style renderer (zero-dep leaf)
memorycrates/memory/FieldElement<F> (BN254/BLS12-381/Goldilocks), FieldBackend trait, heap arenas, GC
ach-macroscrates/ach-macros/Proc macros: #[ach_native], #[ach_module]
achronyme-parsercrates/achronyme-parser/Lexer, Pratt+recursive-descent parser, owned AST types
resolvecrates/resolve/Symbol table, builtin registry, unified dispatch resolver (Movimiento 2)
lysis-typescrates/lysis-types/InstructionKind<F>, NodeId shared with the Lysis VM
constraintscrates/constraints/Variable, LinearCombination, R1CS + Plonkish system, Poseidon, binary export
ir-corecrates/ir-core/SSA leaf: Instruction<F>, SsaVar, Visibility, IrType
ir-forgecrates/ir-forge/ProveIR templates, AST→ProveIR compiler, Lysis lift walker
ircrates/ir/IR passes (DCE, CSE, const-fold, taint), module loader, inspector, ProveIR orchestration
zkccrates/zkc/Constraint compiler: R1CS backend, Plonkish backend, witness ops, oracle scaffold
akronccrates/akronc/Bytecode compiler for the Akron VM (was compiler)
akroncrates/akron/Register-based general-purpose bytecode VM (was vm)
artikcrates/artik/Witness-computation SSA VM (was witness) — see Artik
lysiscrates/lysis/Third VM, structural template instantiator with hash-consing — in progress
circomcrates/circom/Circom 2.x frontend: lexer, parser, analysis, lowering — see Circom Frontend
provingcrates/proving/Groth16 (arkworks), PlonK (halo2-KZG), Solidity verifier generation
achronyme-stdcrates/std/Standard library via NativeModule trait
clicrates/cli/Command-line interface, proof orchestration

Crate renames (post-cleanup)

The structural cleanup of 2026-04-18 → 2026-04-24 renamed three crates and split ir into three:

Old nameNew nameReason
vmakronDistinguish from the witness VM and the in-progress Lysis VM
witnessartikMatch the bytecode magic ARTK and the file extension .artik
compilerakroncDisambiguate from the constraint compiler zkc; “akron compiler”
irir-core + ir + ir-forgeBreak dependency cycles; expose SSA primitives as a leaf crate

The old names appear in git history pre-2026-04-18 and in some legacy file-path comments — they all map mechanically to the new names.

Dependency tiers

Tier 0 — Foundation (zero workspace deps)

diagnostics, memory, ach-macros, lysis-types. Pure leaves. Together they define the universal vocabulary of the workspace: spans, errors, field elements, opcode token shapes, and proc macros.

Tier 1 — Vocabulary

achronyme-parser (depends on diagnostics) — surface AST.

resolve (depends on achronyme-parser, diagnostics) — symbol table, builtin registry, ModuleGraph. Hosts SymbolId, CallableKind, Availability. After Movimiento 2, all dispatch (method call, Type::MEMBER, native call) goes through resolve rather than ad-hoc table lookups.

constraints (depends on memory) — LinearCombination, ConstraintSystem, PlonkishSystem, Poseidon parameters, .r1cs/.wtns binary writers in iden3 format.

ir-core (depends on memory, diagnostics) — SSA Instruction<F>, SsaVar, Visibility, IrType. Leaf crate so ir and ir-forge can both depend on it without forming a cycle.

Tier 2 — IR and circuit compilation

ir-forge (depends on ir-core, achronyme-parser, resolve, diagnostics, lysis-types, circom for lowering hooks)

ProveIR data types (ProveIR, CircuitExpr, CircuitNode, CaptureDef), AST→ProveIR compiler (ProveIrCompiler), Lysis lift walker. The single layer where compile-time symbolic circuit reasoning happens. See ProveIR.

ir (depends on ir-core, ir-forge, resolve)

IR orchestration: passes (const_fold, cse, dce, bool_prop, taint, bound_inference), evaluator, module loader, inspector graph builder. Hosts the CircomLibraryHandle trait.

zkc (depends on ir-core, constraints, memory)

The constraint compiler. R1CS backend (compile_to_r1cs), Plonkish backend, witness operations (WitnessOp), oracle scaffolding for the Lysis Phase 3.C gate.

circom (depends on achronyme-parser, diagnostics, ir-forge, resolve)

Full Circom 2.x frontend. Lifts non-inlinable function bodies to Artik via lowering::artik_lift.

Tier 3 — Bytecode + VMs

akronc (depends on achronyme-parser, resolve, diagnostics)

Bytecode compiler for the Akron VM. Owns the bytecode optimizer (peephole, const-fold, dead-store elim).

akron (depends on memory, constraints, ir, ir-forge)

Register-based general-purpose VM. 43 opcodes, mark-sweep tri-color GC, 64-bit tagged values. Loads .achb files via akron::loader. Hosts prove {} execution at runtime via the ProveHandler trait.

artik (depends on memory)

Dedicated witness-computation VM. ~25 opcodes, SSA-style registers, no heap, no GC. Loads .artik blobs embedded in WitnessOp::ArtikCall.

lysis (depends on memory, artik, lysis-types)

Third VM — in progress. Structural template instantiator with hash-consing interner. See Lysis VM. Walker lives in ir-forge::lysis_lift; oracle scaffold in zkc::lysis_oracle.

Tier 4 — Top-level orchestration

proving (depends on constraints, memory)

In-process Groth16 (ark-groth16 + ark-bn254) and PlonK (halo2 KZG, PSE fork). Generates Solidity verifiers for on-chain Groth16 verification.

achronyme-std (depends on akron, memory, ach-macros)

Standard library natives via the NativeModule trait. 16 natives, registered through #[ach_native] proc macros.

cli (depends on akron, akronc, ir, ir-forge, zkc, circom, proving, resolve, achronyme-std)

User-facing binary. Dispatches ach run, ach circuit, ach circom, ach prove, ach inspect, ach init. Owns the DefaultCircomWitnessHandler and the ProveHandler implementations injected into Akron.

Dependency graph

diagnostics ─── lysis-types ─── ach-macros        (Tier 0 leaves)
    │                                  │
    ├── achronyme-parser               │
    │       │                          │
    │       └── resolve                │
    │              │                   │
    ├── memory ────┼── constraints     │
    │              │       │           │
    │              ├── ir-core         │
    │              │       │           │
    │              ├── ir-forge ◀──────┴── (uses lysis-types)
    │              │       │
    │              ├── ir ─┘
    │              │
    │              ├── zkc
    │              │
    │              ├── circom
    │              │
    │              ├── akronc
    │              │
    │              ├── akron
    │              │       │
    │              ├── artik
    │              │       │
    │              └── lysis ◀───── (uses artik, lysis-types)

    ├── proving
    ├── achronyme-std
    └── cli ◀── (uses everything)

Key entry points

TaskCrateFunction
Parse .ach sourceachronyme-parserparse_program(source)
Parse .circom sourcecircomcircom::parser::parse_circom(source)
Compile bytecodeakroncCompiler::compile(&program)
Compile prove blockir-forgeProveIrCompiler::compile_prove_block(...)
Compile circom templatecircomcompile_to_prove_ir(source)
Instantiate ProveIRirProveIR::instantiate(captures, ...)
Lower AST to IR (circuit)irIrLowering::lower_circuit(source, pub, wit)
Optimize IRirpasses::optimize(&mut program)
Compile to R1CSzkccompile_to_r1cs(program)
Compile to PlonkishzkcPlonkishCompiler::compile_ir(program)
Generate witnesszkccompile_to_r1cs_with_witness(program, inputs)
Run Akron VMakronVm::run(function)
Run Artikartikartik::execute_with_budget(program, ctx, budget)
Run Lysis (in-progress)lysislysis::execute(program, sink)
Lift Circom function to Artikcircomlowering::artik_lift::lift(...)
Lift ProveIR to Lysisir-forgelysis_lift::Walker::lift(...)
Generate Groth16 proofprovingproving::groth16::prove(cs, witness, pk)
Generate PlonK proofprovingproving::halo2_proof::prove(cs, witness, pk)
Solidity verifierprovingproving::solidity::generate(...)
Run CLIclimain() → command dispatch

Cross-references

Navigation