Thanks for considering a contribution to the Active Inference Institute's computational meta-analysis of the Active Inference and Free Energy Principle literature. This is a public research repository: everything you push is visible, so keep all contributions grounded in the actual repository state and never include private credentials, internal paths, or personal tooling names.
AGENTS.md— project overview, architecture, and invariant rules.docs/README.md— documentation hub index and onboarding order.docs/documentation-index.md— flat index of every long-lived document.docs/reference/architecture.md— pipeline design and module map.docs/reference/scripts.md— per-script CLI reference.TODO.md— authoritative forward backlog (Minor / Medium / Major) with acceptance gates; check it before starting work.
- Open an issue first for anything non-trivial (new pipeline stage, changed hypothesis set, schema change) so the scope is agreed before code lands.
- Branch from
mainand keep the change focused; one logical change per pull request. - Follow the thin-orchestrator pattern. All computation lives in
src/; scripts inscripts/handle only I/O, argument parsing, and logging. - Preserve the documented invariants — deterministic seeds (
seed=42), the 0.6min_confidenceextraction floor, the RDF namespacehttp://activeinference.institute/ontology/, and the H1–H8 alias order insrc/manuscript/variables.py(which must matchSTANDARD_HYPOTHESES). - Write tests without mocks. The suite enforces a zero-mock policy: use
pytest-httpserverfor HTTP paths, realAssertionobjects and real computations everywhere else. See the testing guide. - Keep the documentation dual. Every module you add needs its
README.md(human-readable) andAGENTS.md(agent-facing) entries updated, plus the relevant reference guide.
# Python 3.12+ is required (see pyproject.toml)
uv sync --extra dev
# One entry point; every arm runs the same command CI runs.
./run.sh lint # ruff check src/ scripts/ tests/
./run.sh types # mypy src/
./run.sh test-fast # pytest without the slow figure tests (default arm)
./run.sh test-full # pytest with the 90% coverage gate
./run.sh docs # relative links and documentation index
./run.sh gnn # pinned GNN conformance check
./run.sh render # manuscript PDF/HTML into .render-check/.github/workflows/ci.yml calls those same arms; hosted GitHub Actions is
billing-locked for this organization, so the local runs are the gate. The
commands themselves live only in scripts/gate.py. Measured wall times are in
docs/_generated/gate_arms.md, refreshed by
./run.sh bench.
Documentation changes are welcome and are held to the same accuracy standard as
code: every claim (test counts, corpus size, file paths, flags, schema fields)
must match the current repository state. Run ./run.sh docs after doc edits
(and ./run.sh lint/./run.sh types if Python files were touched), and keep
generated output/ artifacts out of the diff unless the change intentionally
regenerates them. Do not hand-edit numbers in docs/_generated/gate_arms.md;
refresh them with ./run.sh bench.
By contributing you agree that your contributions are licensed under CC-BY-4.0, matching the repository.