Clausura CLI
A CLI that runs a bounded LLM agent task in CI and returns a pass or fail verdict from rules rather than from model prose.
Install
Other ways to install
Access and checks
How we reviewExtended access. The tool runs code or makes network calls and only reads external data.
- The agent reads repository code and sends fragments to the chosen model provider.
- The provider key lives in pipeline secrets and spends tokens.
This is third-party code. Review the repository files before installing.
What it does
Clausura targets CI/CD pipelines. An agent gets a bounded task over the code, finds problems and returns structured findings. A deterministic rule engine decides how serious they are, and the pipeline gets exit code 0, 1, 2 or 3 plus a SARIF 2.1.0 report. Each run is capped by iterations, time and token budget. If a cap is hit the build fails by default, and no question ever reaches a human mid-run. The agent uses skills, MCP tools and preflight checks. OpenAI-compatible APIs (including DeepSeek, Groq and Ollama) and Anthropic are supported. It ships as a static binary with no dependencies.
Who it is for. CI engineers and platform teams that want an AI reviewer with a reproducible verdict instead of an interactive assistant.
Good fit when
- A pull request must fail when the model review finds violations above a threshold.
- Several repositories are checked against shared conventions for style and structure.
- Interface translations are checked for locale coverage inside the pipeline.
- You need a run log with events and findings for later review.
Not a fit when
- You want interactive code editing with a dialogue: Claude Code and similar agents fit that.
- You need a check with no calls to an outside model API: Clausura does not run without a provider.
- The task is open-ended with no criteria: the rule engine has nothing to evaluate.
Example request
Run clausura in this repository with a rule to fail on critical convention violations.Limitations
A key for the chosen provider is required, and model calls go over the network and spend tokens. The user writes the verdict rules, so there are no ready sets for every language and check quality depends on configuration. The README sample marks version `1.0.0` built in May 2026; see the repository for current releases. The project is small and the README covers only CI runs, with no interactive mode. The last commit dates to September 2026.
How to disable. Delete the `clausura` binary from `/usr/local/bin` or `~/.local/bin` and remove the run step from the pipeline file.
FAQ
How do I install Clausura?
Run `curl -fsSL https://raw.githubusercontent.com/liuyanghejerry/Clausura/main/install.sh | bash`; the script verifies the tarball against `checksums.txt`. `cargo install clausura-cli` and a Docker image also exist.
What do the exit codes mean?
Code 0 is success, 1 a violated rule with action `fail`, 2 a runtime error or incomplete run, 3 invalid configuration.
Which models are supported?
Any with an OpenAI-compatible `/chat/completions`, including OpenAI, DeepSeek, Groq and Ollama, plus Anthropic through the Messages API.
How does it differ from Claude Code in CI?
Claude Code counts a stopped agent as success. Clausura scores structured findings with rules and fails when limits are exceeded.
Can spending be capped?
Yes. `max_iterations`, `timeout_secs`, `token_budget` and `max_total_tokens` set the ceiling for a run.
Is Clausura safe to install?
Extended access. The tool runs code or makes network calls and only reads external data.
Discussion
No questions or reviews yet.
README in short
The README contrasts Clausura with general agent harnesses in a table: success semantics, verdict, run bounds and extensions. Install options, providers and configuration follow.