Millrace runtime rewrite baseline package
Project description
Millrace
Millrace is a thin-core autonomous runtime packaged as millrace_ai.
The runtime bootstraps all operational files under <workspace>/millrace-agents/ and keeps canonical source code in the package itself.
Source Layout
- importable code lives under
src/millrace_ai/ - tests mirror package ownership under
tests/assets/,tests/cli/,tests/config/,tests/runners/,tests/runtime/,tests/workspace/, andtests/integration/ - preserved compatibility facades remain at the package root for legacy imports such as
millrace_ai.control,millrace_ai.run_inspection,millrace_ai.runner,millrace_ai.entrypoints, and workspace support modules
Use docs/source-package-map.md for the old-to-new module map and the intentionally preserved facade list.
Quick Start
WORKSPACE=/absolute/path/to/workspace
uv run --extra dev python -m millrace_ai compile validate --workspace "$WORKSPACE"
uv run --extra dev python -m millrace_ai run once --workspace "$WORKSPACE"
uv run --extra dev python -m millrace_ai status --workspace "$WORKSPACE"
Equivalent installed CLI:
millrace compile validate --workspace "$WORKSPACE"
millrace run once --workspace "$WORKSPACE"
millrace status --workspace "$WORKSPACE"
Operator Surface
Use the shortest truthful forms for routine operation:
millrace run oncemillrace statusmillrace runs lsmillrace queue add-task <path-to-task.md|path-to-task.json>millrace pause,millrace resume,millrace stop
millrace status show remains available as the explicit subcommand form, but the canonical operator example is millrace status.
Use docs/OPERATOR_GUIDE.md for the current operator workflow and docs/runtime/millrace-cli-reference.md for the full command inventory, grouped forms, and alias details.
Work Artifacts
Canonical queue artifacts are lightweight headed markdown work documents (.md) under:
millrace-agents/tasks/{queue,active,done,blocked}/millrace-agents/specs/{queue,active,done,blocked}/millrace-agents/incidents/{incoming,active,resolved,blocked}/
Task/spec/incident files use a human-facing shape with an H1 title plus plain field headings such as:
# Add run inspection CLI
Task-ID: example-task-001
Title: Add run inspection CLI
Target-Paths:
- src/millrace_ai/cli/commands/runs.py
Acceptance:
- `millrace runs ls` reports persisted run summaries.
JSON remains runtime-internal for snapshot, diagnostics, mailbox archives, and event/log surfaces.
Stage Runner Resolution
Runtime stage execution now routes through a configurable runner dispatcher.
Resolution order per stage request:
request.runner_name(compiled from mode/stage bindings)runners.default_runnerfrom runtime config- fallback literal
codex_cli
Default adapter is Codex CLI. Add runner settings in <workspace>/millrace-agents/millrace.toml:
[runners]
default_runner = "codex_cli"
[runners.codex]
command = "codex"
args = ["exec"]
permission_default = "basic"
# permission_by_stage = { builder = "elevated" }
# permission_by_model = { "gpt-5.4" = "maximum" }
skip_git_repo_check = true
Permission levels map to Codex CLI flags:
basic:--full-autoelevated:-c approval_policy="never" --sandbox danger-full-accessmaximum:--dangerously-bypass-approvals-and-sandbox
Runtime Docs
docs/runtime/millrace-runtime-architecture.mddocs/runtime/millrace-cli-reference.mddocs/runtime/millrace-entrypoint-mapping.mddocs/runtime/millrace-runner-architecture.mddocs/source-package-map.md
Verification
Authoritative local verification commands:
uv run --extra dev python -m pytest -q
uv run --with ruff ruff check src/millrace_ai tests
uv run --with mypy mypy src/millrace_ai
Operational source + wheel checks (minimum functionality workspace):
WORKSPACE=/absolute/path/to/minimum-functionality-workspace
rm -rf "$WORKSPACE/millrace-agents"
uv run --extra dev python -m millrace_ai compile validate --workspace "$WORKSPACE"
uv run --extra dev python -m millrace_ai run once --workspace "$WORKSPACE"
uv run --extra dev python -m millrace_ai status --workspace "$WORKSPACE"
rm -rf "$WORKSPACE/millrace-agents"
uv build --wheel
python3 -m venv /tmp/millrace-wheel-test
source /tmp/millrace-wheel-test/bin/activate
pip install dist/*.whl
millrace compile validate --workspace "$WORKSPACE"
millrace run once --workspace "$WORKSPACE"
millrace status --workspace "$WORKSPACE"
For clean proof runs, refresh only "$WORKSPACE/millrace-agents/" in place. Do not mutate operator-authored files elsewhere in the workspace root.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file millrace_ai-0.11.1.tar.gz.
File metadata
- Download URL: millrace_ai-0.11.1.tar.gz
- Upload date:
- Size: 115.4 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
a4c63537021a2c4b3f6e48598f589949c96dbf393a9c681dbdf96e1d835ad346
|
|
| MD5 |
e7062fdd24db50cec71f9472d767f20b
|
|
| BLAKE2b-256 |
8c94f31acb37739d06a5ba0a3af0238b8ca73e91d7e70d3a726a7fff695d44f2
|
Provenance
The following attestation bundles were made for millrace_ai-0.11.1.tar.gz:
Publisher:
publish-to-pypi.yml on tim-osterhus/millrace
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
millrace_ai-0.11.1.tar.gz -
Subject digest:
a4c63537021a2c4b3f6e48598f589949c96dbf393a9c681dbdf96e1d835ad346 - Sigstore transparency entry: 1327965269
- Sigstore integration time:
-
Permalink:
tim-osterhus/millrace@c9eec70fba977632627132845df373e0e8115576 -
Branch / Tag:
refs/tags/v0.11.1 - Owner: https://github.com/tim-osterhus
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish-to-pypi.yml@c9eec70fba977632627132845df373e0e8115576 -
Trigger Event:
push
-
Statement type:
File details
Details for the file millrace_ai-0.11.1-py3-none-any.whl.
File metadata
- Download URL: millrace_ai-0.11.1-py3-none-any.whl
- Upload date:
- Size: 165.6 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
726eb2d33a1d4acbcbcf76b40260f0ba19a82cbabb3ee5116658b892c627585b
|
|
| MD5 |
cad18c3b3352b567133214c30563bf0a
|
|
| BLAKE2b-256 |
e95fbcaa401a906ebefbd97cb19ccb761da8a35d7089a160a2cab60b5598d8d8
|
Provenance
The following attestation bundles were made for millrace_ai-0.11.1-py3-none-any.whl:
Publisher:
publish-to-pypi.yml on tim-osterhus/millrace
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
millrace_ai-0.11.1-py3-none-any.whl -
Subject digest:
726eb2d33a1d4acbcbcf76b40260f0ba19a82cbabb3ee5116658b892c627585b - Sigstore transparency entry: 1327965389
- Sigstore integration time:
-
Permalink:
tim-osterhus/millrace@c9eec70fba977632627132845df373e0e8115576 -
Branch / Tag:
refs/tags/v0.11.1 - Owner: https://github.com/tim-osterhus
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish-to-pypi.yml@c9eec70fba977632627132845df373e0e8115576 -
Trigger Event:
push
-
Statement type: