Skip to main content

Courant

Physics acceptance testing for machine-produced simulation. Courant is a read-only, deterministic gate between a simulation (an AI agent's or an engineer's) and the person who signs it. Without a task specification it decides whether an OpenFOAM run is valid; with the task the run was asked to solve, it decides whether the run is the problem that was asked.

Every verdict is accept, reject or insufficient, and every reason cites the file it read, the method, the threshold and the value. Deterministic code decides every verdict; no language model is in the verdict's path. Courant never edits a case, never runs a solver, and its checks never use the network.

Licensed under the Apache License 2.0.

Install

pip install 'courant-dev[mcp]'      # Python 3.11 or later; the command is `courant`

The distribution is named courant-dev (PyPI's courant is an unrelated project); the import package and the commands are courant and courant-mcp.

A single-file binary for Linux and macOS, which needs no Python, is attached to every release, with SHA256SUMS and its Ed25519 signature:

curl -fsSL https://github.com/courantdev/courant/releases/latest/download/install.sh | sh

The installer checks the binary's SHA-256 against the release's SHA256SUMS, and the signature of SHA256SUMS against the release key it carries when python3 with the cryptography package or OpenSSL 3 is on the machine. With neither, it says that only the checksum was checked and how to check the signature by hand; COURANT_REQUIRE_SIGNATURE=1 makes it refuse instead. courant update installs nothing unless the signature verifies against the key built into the binary.

Try it offline

These run on the real OpenFOAM runs that ship inside the package, with no network:

courant demo                     # four real runs and an HTML report
courant verify --about           # the error rates published for this version

What it does

Command What it does
courant verify <case or log> accept, reject or insufficient (exit 0, 2 or 3; courant.verdict/2), with the basis it was judged on and what was not checked. --spec with --spec-sha256 checks every value a task specification names against the case. --html, --report md, --json, --pack and --check-pack (an evidence pack anyone can re-derive), --batch with --junit, --record, --about
courant spec init / hash / check / lock / confirm / extract Draft a task specification from a reference case, lock it by hash, and check a case against it before or after its run
courant gate The CI check, and the GitHub Action: verify the runs a repository names, one summary row per run, one evidence pack per run
courant preflight <case> A broken setup, caught before the solver spends anything
courant convergence <case> Where the monitored answer stopped changing, and the iterations, wall clock and core-hours after it
courant watch <case> A read-only live advisory while the solver runs, with --exit-on-fail for job scripts
courant audit <dir> What a folder of runs cost, and how much of it bought nothing
courant test run --judge … The Courant Test: score any judge, including an AI model, on real OpenFOAM runs
courant mcp The same tools for any AI agent over MCP, read-only and confined to the directories named; score_agent_output tells an agent, before it reports, whether its run is a silent error
courant doctor, courant update, courant version Diagnostics and a support bundle you send yourself; a signed update of the binary

The checks never use the network. A command contacts something only when that is its purpose and you ran it, and it names the host first: courant update (github.com), courant doctor --models, and a language model you name (NETWORK.md). Start with GETTING-STARTED.md.

What is measured

On OpenFOAM v2406, with every figure carrying its denominator (courant verify --about prints the rates that ship with each version):

  • Detection: 31 of 31 real runs judged correctly. 0 of 23 wrong results accepted and 0 of 8 good results rejected.
  • The wrong problem: on 20 real runs with the right physics and a wrong input (inlet doubled, viscosity tripled, gravity rotated, geometry scaled, end time cut), the verdict without a specification rejected 8 of 20; against the task specification, 20 of 20.
  • Before the run: preflight caught 8 of 23 broken setups, and flagged 0 of 8 good ones.
  • Fixed budgets: where the answer settled, 1,023 of 1,999 iterations (51.2%, pitzDaily) and 547 of 999 (54.8%, T3A) came after it.
  • Reproducible: evidence packs re-derive byte for byte, 31 of 31.

"Certified" here means measured against a real solver, with the error rate published. It is not a regulator's approval. Courant has no account, no telemetry and no service of its own.

Contributing and security

See CONTRIBUTING.md and SECURITY.md.

Copyright 2026 Shivanshu Dwivedi (Courant, https://courant.dev)

Metadata

Release files for courant-dev 0.5.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for courant-dev 0.5.0
File Size Uploaded
courant_dev-0.5.0.tar.gz 2.3 MB Details

Built distribution (wheel)

Table of built distributions (wheels) for courant-dev 0.5.0
File Interpreter ABI Platform
courant_dev-0.5.0-py3-none-any.whl Python 3 none any Details

Total release size: 4.7 MB

Release files / courant_dev-0.5.0.tar.gz

Download URL courant_dev-0.5.0.tar.gz
Size 2.3 MB
Tags Source
SHA-256 checksum
How to use checksums
4ddfb4413c428d7823d0740c5446425ed194cb3de6c0e03b4121d9d7be5792d6
BLAKE2b-256 checksum
How to use checksums
6fa4d1d5d1d0d3ab45c6af1416fd6d4610670944c8526e4bf4619ef3b8e03999
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 12, 2026.

Transparency log

Release files / courant_dev-0.5.0-py3-none-any.whl

Download URL courant_dev-0.5.0-py3-none-any.whl
Size 2.4 MB
Tags Python 3
SHA-256 checksum
How to use checksums
163e3816fda27661ccf145d1bc72ca57268417290861933adfaac5fa8dd82a0f
BLAKE2b-256 checksum
How to use checksums
f0a9b72e7a0cd8ee2749d9e63e95055976d72231864ac47b28e630727bbd2f37
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 12, 2026.

Transparency log

Release history Release notifications | RSS feed

This release

0.5.0 This release

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page