The Problem
Distributed systems need a concise, formally‑checked specification language that can be integrated into existing tooling. Traditional TLA tools are heavy and lack modern IDE support, making iterative development painful.
What This Does
quint supplies a CLI, a Rust‑based evaluator, and a VS Code extension that together let developers write TLA‑style specifications, run them locally, and get instant invariant violations.
- The CLI (
quint/src/cli.ts) parses command line flags and delegates to the evaluator. - The evaluator (
evaluator/src/lib.rs+main.rs) executes the specification, performing model checking and reporting counterexamples. - The VS Code extension (
vscode/) offers syntax highlighting, diagnostics, and a REPL, all wired to the same Rust engine.
How It Is Wired
- Entry –
quint/src/cli.tsis the user‑facing executable. It usescommanderto parse--invariant,--seed, and--verbosity. - Dispatch –
cli.tscallsrunEvaluatorexported fromquint/src/index.ts. - Execution –
index.tsspawns the Rust binary compiled fromevaluator/src/main.rs. The binary loads the.qntfile, parses it with thequintgrammar, and executes the model. - Result – The Rust engine writes the result to stdout;
cli.tsstreams it back to the terminal. - Diagnostics – The VS Code extension (
vscode/src) invokes the same Rust binary via the same command path, capturing diagnostics in the editor.
The only external side effect is reading the specification file and writing console output; the evaluator itself does not touch the filesystem or network. The call graph is linear: cli.ts → index.ts → Rust binary → lib.rs. No recursive or cross‑module cycles are present, simplifying maintenance.
How To Use It
- Setup ``
sh npm i @informalsystems/quint -g`Thepackage.jsoninquint/declares@informalsystems/quint` as a global npm package.
- Configuration No environment variables are required for the core CLI. For the docs site,
docs/.env.exampleshows the variables needed to build the static site.
- Running ``
sh quint run path/to/spec.qnt --invariant=propertyName`Theruncommand is exposed byquint/src/cli.ts. ReplacepropertyNamewith an invariant defined in the.qnt` file.
- VS Code Install the
informal.quint-vscodeextension from the Marketplace. Opening a.qntfile triggers diagnostics automatically.
Real‑World Use
A blockchain protocol team can author consensus rules in .qnt, run quick checks locally, and embed the evaluator in their CI pipeline (.github/workflows/integration-tests.yml) to enforce invariants before merging. The Rust engine guarantees deterministic counterexamples, allowing developers to trace failures back to source lines.
Code Health & Issues
- Measured Findings
- Tests: 242 files in
quint/__tests__andevaluator/tests. - Documentation: 238 files across
docs/. - CI: Workflows in
.github/workflows/cover linting, testing, and release. - No structural red flags detected; all packages have lockfiles (
package-lock.json,Cargo.lock). - Observations
- Low: No obvious security secrets.
- Low: License present (
LICENSE). - Low: Documentation is comprehensive but scattered across many files.
The Bottom Line
quint delivers a pragmatic TLA‑style specification framework with a Rust engine and IDE support. Its linear call graph and clear separation of concerns make it easy to extend or replace the evaluator. Teams building formally‑verified distributed protocols should consider it, especially when they need quick execution and editor integration.