Welcome! We're glad you're interested in contributing to Synth.
- Rust (stable toolchain)
- Cargo
- Git
- Bazel (for full build including verification)
- Nix (optional, for building Rocq proofs via Bazel)
# Clone the repository
git clone https://github.com/pulseengine/synth.git
cd synth
# Build with Cargo
cargo build
# Run tests
cargo test --workspace
# Build with Bazel (all crates)
bazel build //crates:synthThe formal verification proofs require Rocq 9.0 (or Coq 8.20+):
# Install Rocq via opam
cd coq
make install-deps
# Build all proofs
make
# Validate (check for Admitted proofs)
make validate# Format all code
cargo fmt
# Check formatting
cargo fmt --all -- --check
# Run clippy
cargo clippy --workspace --all-targets -- -D warnings# Run all tests
cargo test --workspace
# Run Z3 verification tests (requires libz3-dev)
cargo test -p synth-verify --features z3-solver,arm
# Bazel build + test
bazel build //crates:synth //crates:synth-test- Fork the repository
- Create a feature branch:
git checkout -b feature/your-feature - Make your changes
- Ensure
cargo fmt,cargo clippy, andcargo testpass - Push to your fork and submit a pull request
- Ensure all CI checks pass
- Follow Rust API guidelines
- Use descriptive variable and function names
- Add documentation comments for public APIs
- Keep functions focused and small
- Write tests for new functionality
If you're contributing to the Rocq proofs:
- Proofs are in
coq/Synth/organized by domain (Common, ARM, WASM, Synth) - All proofs must use
From Stdlibimports (Rocq 9 style) - Prefer
QedoverAdmitted— document any remaining admits with a TODO - Run
make validateto check for admitted proofs
By contributing to Synth, you agree that your contributions will be licensed under the Apache License 2.0.