diff --git a/AGENTS.md b/AGENTS.md index 22581d0..0bf0231 100644 --- a/AGENTS.md +++ b/AGENTS.md @@ -1,4 +1,4 @@ - + # Disinto — Agent Instructions ## What this repo is diff --git a/action/AGENTS.md b/action/AGENTS.md index 88fafcb..1ef4f0b 100644 --- a/action/AGENTS.md +++ b/action/AGENTS.md @@ -1,4 +1,4 @@ - + # Action Agent **Role**: Execute operational tasks described by action formulas — run scripts, diff --git a/dev/AGENTS.md b/dev/AGENTS.md index 2648b4d..1c378a4 100644 --- a/dev/AGENTS.md +++ b/dev/AGENTS.md @@ -1,12 +1,15 @@ - + # Dev Agent **Role**: Implement issues autonomously — write code, push branches, address CI failures and review feedback. -**Trigger**: `dev-poll.sh` runs every 10 min via cron. It scans for ready -backlog issues (all deps closed) or orphaned in-progress issues and spawns -`dev-agent.sh `. +**Trigger**: `dev-poll.sh` runs every 10 min via cron. It performs a direct-merge +scan first (approved + CI green PRs — including chore/gardener PRs without issue +numbers), then checks the agent lock and scans for ready backlog issues (all deps +closed) or orphaned in-progress issues to spawn `dev-agent.sh `. +The direct-merge scan runs before the lock check so approved PRs get merged even +while a dev-agent session is active on another issue. **Key files**: - `dev/dev-poll.sh` — Cron scheduler: finds next ready issue, handles merge/rebase of approved PRs, tracks CI fix attempts diff --git a/gardener/AGENTS.md b/gardener/AGENTS.md index 3d28bb4..44fa402 100644 --- a/gardener/AGENTS.md +++ b/gardener/AGENTS.md @@ -1,4 +1,4 @@ - + # Gardener Agent **Role**: Backlog grooming — detect duplicate issues, missing acceptance diff --git a/lib/AGENTS.md b/lib/AGENTS.md index cdb36d4..eccb689 100644 --- a/lib/AGENTS.md +++ b/lib/AGENTS.md @@ -1,4 +1,4 @@ - + # Shared Helpers (`lib/`) All agents source `lib/env.sh` as their first action. Additional helpers are diff --git a/planner/AGENTS.md b/planner/AGENTS.md index 9f74980..6bd46cf 100644 --- a/planner/AGENTS.md +++ b/planner/AGENTS.md @@ -1,22 +1,31 @@ - + # Planner Agent **Role**: Strategic planning using a Prerequisite Tree (Theory of Constraints), executed directly from cron via tmux + Claude. Phase 0 (preflight): pull latest code, load persistent memory and prerequisite -tree from `planner/MEMORY.md` and `planner/prerequisite-tree.md`. Phase 1 +tree from `planner/MEMORY.md` and `planner/prerequisite-tree.md`. Also reads +all available formulas: factory formulas (`$FACTORY_ROOT/formulas/*.toml`) and +project-specific formulas (`$PROJECT_REPO_ROOT/formulas/*.toml`). Phase 1 (prediction-triage): triage `prediction/unreviewed` issues filed by the Predictor — for each prediction: promote to action, promote to backlog, watch (relabel to prediction/backlog), or dismiss with reasoning. Phase 2 (update-prerequisite-tree): scan repo state + open/closed issues, mark resolved prerequisites, discover new ones, update the tree. Phase 3 (file-at-constraints): identify the top 3 unresolved prerequisites that block -the most downstream objectives — file issues ONLY at these constraints. No -issues filed past the bottleneck. Phase 4 (journal-and-memory): write updated -prerequisite tree + daily journal entry (committed to git) and update -`planner/MEMORY.md` (committed to git). Phase 5 (commit-and-pr): one commit -with all file changes, push, create PR. AGENTS.md maintenance is handled by -the Gardener. +the most downstream objectives — file issues at these constraints as either +`backlog` (code changes, dev-agent) or `action` (run existing formula, +action-agent). Phase 4 (dispatch-idle-formulas): dispatch formulas that have not +run in 7+ days as action issues — runs independently of the constraint budget. +Phase 5 (journal-and-memory): write updated prerequisite tree + daily journal +entry (committed to git) and update `planner/MEMORY.md` (committed to git). +Phase 6 (commit-and-pr): one commit with all file changes, push, create PR. +AGENTS.md maintenance is handled by the Gardener. + +**Artifacts use `$PROJECT_REPO_ROOT`**: All planner artifacts (journal, +prerequisite tree, memory, vault state) live under `$PROJECT_REPO_ROOT/planner/` +and `$PROJECT_REPO_ROOT/vault/`, not `$FACTORY_ROOT`. Each project manages its +own planner state independently. **Trigger**: `planner-run.sh` runs daily via cron (accepts an optional project TOML argument, defaults to `projects/disinto.toml`). It creates a tmux session diff --git a/predictor/AGENTS.md b/predictor/AGENTS.md index c7c34ea..4a4d654 100644 --- a/predictor/AGENTS.md +++ b/predictor/AGENTS.md @@ -1,4 +1,4 @@ - + # Predictor Agent **Role**: Infrastructure pattern detection (the "goblin"). Runs a 3-step diff --git a/review/AGENTS.md b/review/AGENTS.md index 849657e..4043624 100644 --- a/review/AGENTS.md +++ b/review/AGENTS.md @@ -1,4 +1,4 @@ - + # Review Agent **Role**: AI-powered PR review — post structured findings and formal diff --git a/supervisor/AGENTS.md b/supervisor/AGENTS.md index 038e6fa..7e3a193 100644 --- a/supervisor/AGENTS.md +++ b/supervisor/AGENTS.md @@ -1,4 +1,4 @@ - + # Supervisor Agent **Role**: Health monitoring and auto-remediation, executed as a formula-driven diff --git a/vault/AGENTS.md b/vault/AGENTS.md index a105f18..a9573c2 100644 --- a/vault/AGENTS.md +++ b/vault/AGENTS.md @@ -1,4 +1,4 @@ - + # Vault Agent **Role**: Dual-purpose gate — action safety classification and resource procurement.