Thanks for contributing to the Active Inference Institute's Journal-Utilities! This project is a public submodule of the ActiveInferenceInstitute org — anything merged is public. Please read this whole page before opening a PR.
uv sync --all-extras
cp .env.example .env # fill in real values; never commit .envPython 3.12+ and uv are required. All commands
below are run from the repo root.
src/journal_utilities/— the package (per-moduleREADME.md+AGENTS.md).scripts/— one-off and journal-maintenance CLIs (documented inscripts/README.md).run.py— the pipeline CLI entry point; all pipeline options come fromconfig.ini.docs/— module guides (one file per module);docs/README.mdis the index.tests/— pytest suite (seetests/README.mdandtests/AGENTS.mdfor the mock policy: real methods and real fixtures; mocks only for external I/O that can't run in CI).
If you modify a module, update its doc (docs/<module>.md). If you add a
script, document it in scripts/README.md. If you add a config option, document
it in docs/configuration.md and config.ini. Stale docs are bugs here.
uv run pytest tests/ -q # full suite (currently ~475 passed)
uv run ruff check src/ tests/ scripts/ # lint — matches CI
uv run mypy src # type check — matches CI
uv run python run.py journal-check # read-only journal integrity gateThe CI workflow (.github/workflows/test.yml) runs pytest, ruff, and mypy — a
PR must be green on all of them. If you change the journal-maintenance scripts,
also run the validate_journal.py gate against the sibling journal.
- Formatting follows the repo's
blackconvention (make format); lint viaruff(make lint). - Commits use conventional-style messages:
docs: …,fix: …,feat: …,chore: …, with a short scope when useful (e.g.docs(scripts): …). - Prefer small, logical commits over one large diff.
- Never commit
cookies.txt,.env, or any credential.cookies.txtwas once leaked in this repo's history and was purged; it is gitignored and the downloader runs cookie-free by default. - Never use
--cookies-from-browserwith a tracked output path. - No internal/private paths in committed files — use repo-relative paths and
neutral placeholders (see
.env.example). - PRs that add secrets or private paths will be rejected and reported.
- Branch off
main(git checkout -b fix/your-change). - Make the change, run the gate workflow above.
- Open the PR with a short description of what and why.
- CI must pass; a maintainer will review.
This project is released under CC0 1.0 Universal (public domain dedication). By contributing you agree to dedicate your contribution to the public domain under the same terms.