Skip to content

Contributing to comindly

Thanks for your interest in comindly. Bug reports, language and framework support, documentation fixes and code are all welcome.

Before you start

  • For anything beyond a small fix, open an issue first so we can agree on the approach.
  • Security issues go through SECURITY.md, not public issues.
  • By contributing, you agree that your contributions are licensed under the Apache License 2.0.
  • Sign off each commit (git commit -s) to certify the Developer Certificate of Origin: that you wrote the change or have the right to submit it under the project's license.

Development setup

You need Rust 1.95 or newer (the minimum supported version, checked in CI), plus protoc and cmake:

brew install protobuf cmake                          # macOS
sudo apt-get install -y protobuf-compiler cmake      # Debian/Ubuntu

git clone https://github.com/sayef/comindly && cd comindly
cargo test --workspace
cargo run -q -p comindly-engine -- eval crates/comindly-engine/tests/fixtures/org -v   # resolver quality

Tests that need a bucket or an LLM key are opt-in; everything else runs offline.

The web UI lives in ui/ (React, TypeScript, Vite), which is also the comindly-ui crate that embeds its build into the engine. Without a build, the engine serves a placeholder page. With Node 24:

cd ui && npm ci && npm run build && cd ..            # embedded on the next cargo build
comindly-engine --port 7878 &                        # API on 127.0.0.1:7878; open it once with `comindly app`
cd ui && npm run dev                                 # hot reload on 127.0.0.1:5173, /api proxied

Checklist for a pull request

  • cargo fmt --all and cargo clippy --workspace --all-targets -- -D warnings are clean.
  • UI changes build with npm run build in ui/ (type-checked).
  • cargo deny check passes (licences, advisories and sources; install with cargo install cargo-deny --locked).
  • New behaviour has tests. Resolver, contract and infrastructure changes add cases to crates/comindly-engine/tests/fixtures/org with gold edges in expected.toml, and comindly-engine eval stays at 100% precision and recall.
  • Real-world changes are checked on real repositories as well: no new spurious contracts, and a note in the pull request of what changed.
  • Performance changes include criterion results (cargo bench -p comindly-engine --bench graph); CI also posts a base-against-head comparison to the job summary of each pull request.
  • Determinism holds: the same repositories give the same graph, ids and ordering.
  • Changes to stored formats (Lance tables, ledger records, facts) keep reading what older versions wrote (#[serde(default)] on new fields).
  • Commands, MCP tools and configuration keys are reflected in the README, docs and the changelog (under ## [Unreleased]).

Project layout

A cargo workspace (see ARCHITECTURE.md):

  • crates/comindly-core: the engine, one module per pipeline stage. It reads no environment or files of its own; anything it needs is passed in. Language support lives in src/lang/ behind the LangSpec trait; contract linking in src/resolve/contracts.rs.
  • crates/comindly-api: the requests and answers of /api/v1, and the typed client.
  • crates/comindly-engine: the engine and its comindly-engine binary: the web app's API, MCP, jobs, accounts and roles, this machine's preferences and credentials, and the macOS window. Integration tests, fixtures, benches and examples live here too.
  • ui/: the web app, and the comindly-ui crate that embeds it.
  • The root: the comindly command line, which talks to an engine over /api/v1.

Style

  • Follow the surrounding code. Keep comments short: say what the code does, and put the reasoning in the pull request.
  • Prefer returning errors to panicking on bad input, especially on anything read from storage or repositories.
  • Precision over recall: an unresolved edge is better than a wrong one, and nothing reaches an agent's context unless it is grounded and trusted.
  • Measure before optimising, and include the numbers in the pull request.

Releasing

Every push to main opens or updates a release pull request (version bump and changelog entry). Merging it publishes nothing. To release, run the Release-plz workflow by hand (Actions → Release-plz → Run workflow, or gh workflow run release-plz.yml): it publishes the crates at one version, in dependency order, tags v<version>, creates the GitHub release, and the Release workflow attaches the binaries.

Commit messages

One short line in the imperative mood ("Add Express route detection"). The pull request description says why.