@mobrienv/autoloop 0.3.0 → 0.7.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +140 -43
- package/bin/autoloop +1 -1
- package/dist/index.d.ts +6 -0
- package/dist/index.js +19 -0
- package/dist/index.js.map +1 -0
- package/dist/testing/mock-backend.js +3 -5
- package/dist/testing/mock-backend.js.map +1 -1
- package/package.json +32 -10
- package/plugins/autoloop/.claude-plugin/plugin.json +1 -1
- package/dist/agent-map.d.ts +0 -10
- package/dist/agent-map.js +0 -58
- package/dist/agent-map.js.map +0 -1
- package/dist/backend/acp-client.d.ts +0 -38
- package/dist/backend/acp-client.js +0 -288
- package/dist/backend/acp-client.js.map +0 -1
- package/dist/backend/index.d.ts +0 -10
- package/dist/backend/index.js +0 -71
- package/dist/backend/index.js.map +0 -1
- package/dist/backend/kiro-bridge.d.ts +0 -17
- package/dist/backend/kiro-bridge.js +0 -84
- package/dist/backend/kiro-bridge.js.map +0 -1
- package/dist/backend/kiro-worker.d.ts +0 -1
- package/dist/backend/kiro-worker.js +0 -92
- package/dist/backend/kiro-worker.js.map +0 -1
- package/dist/backend/run-command.d.ts +0 -7
- package/dist/backend/run-command.js +0 -50
- package/dist/backend/run-command.js.map +0 -1
- package/dist/backend/run-kiro.d.ts +0 -3
- package/dist/backend/run-kiro.js +0 -16
- package/dist/backend/run-kiro.js.map +0 -1
- package/dist/backend/run-mock.d.ts +0 -1
- package/dist/backend/run-mock.js +0 -6
- package/dist/backend/run-mock.js.map +0 -1
- package/dist/backend/run-pi.d.ts +0 -5
- package/dist/backend/run-pi.js +0 -5
- package/dist/backend/run-pi.js.map +0 -1
- package/dist/backend/types.d.ts +0 -21
- package/dist/backend/types.js +0 -2
- package/dist/backend/types.js.map +0 -1
- package/dist/chains/budget.d.ts +0 -7
- package/dist/chains/budget.js +0 -54
- package/dist/chains/budget.js.map +0 -1
- package/dist/chains/load.d.ts +0 -18
- package/dist/chains/load.js +0 -129
- package/dist/chains/load.js.map +0 -1
- package/dist/chains/render.d.ts +0 -2
- package/dist/chains/render.js +0 -74
- package/dist/chains/render.js.map +0 -1
- package/dist/chains/run.d.ts +0 -17
- package/dist/chains/run.js +0 -260
- package/dist/chains/run.js.map +0 -1
- package/dist/chains/types.d.ts +0 -38
- package/dist/chains/types.js +0 -2
- package/dist/chains/types.js.map +0 -1
- package/dist/chains.d.ts +0 -6
- package/dist/chains.js +0 -5
- package/dist/chains.js.map +0 -1
- package/dist/commands/chain.d.ts +0 -1
- package/dist/commands/chain.js +0 -53
- package/dist/commands/chain.js.map +0 -1
- package/dist/commands/config.d.ts +0 -1
- package/dist/commands/config.js +0 -74
- package/dist/commands/config.js.map +0 -1
- package/dist/commands/dashboard.d.ts +0 -1
- package/dist/commands/dashboard.js +0 -68
- package/dist/commands/dashboard.js.map +0 -1
- package/dist/commands/guide.d.ts +0 -1
- package/dist/commands/guide.js +0 -33
- package/dist/commands/guide.js.map +0 -1
- package/dist/commands/inspect.d.ts +0 -1
- package/dist/commands/inspect.js +0 -203
- package/dist/commands/inspect.js.map +0 -1
- package/dist/commands/list.d.ts +0 -1
- package/dist/commands/list.js +0 -15
- package/dist/commands/list.js.map +0 -1
- package/dist/commands/loops.d.ts +0 -1
- package/dist/commands/loops.js +0 -72
- package/dist/commands/loops.js.map +0 -1
- package/dist/commands/memory.d.ts +0 -1
- package/dist/commands/memory.js +0 -65
- package/dist/commands/memory.js.map +0 -1
- package/dist/commands/pi-adapter.d.ts +0 -1
- package/dist/commands/pi-adapter.js +0 -6
- package/dist/commands/pi-adapter.js.map +0 -1
- package/dist/commands/run.d.ts +0 -1
- package/dist/commands/run.js +0 -292
- package/dist/commands/run.js.map +0 -1
- package/dist/commands/runs.d.ts +0 -1
- package/dist/commands/runs.js +0 -50
- package/dist/commands/runs.js.map +0 -1
- package/dist/commands/task.d.ts +0 -1
- package/dist/commands/task.js +0 -74
- package/dist/commands/task.js.map +0 -1
- package/dist/commands/worktree.d.ts +0 -1
- package/dist/commands/worktree.js +0 -162
- package/dist/commands/worktree.js.map +0 -1
- package/dist/config.d.ts +0 -31
- package/dist/config.js +0 -261
- package/dist/config.js.map +0 -1
- package/dist/dashboard/app.d.ts +0 -12
- package/dist/dashboard/app.js +0 -23
- package/dist/dashboard/app.js.map +0 -1
- package/dist/dashboard/routes/api.d.ts +0 -3
- package/dist/dashboard/routes/api.js +0 -130
- package/dist/dashboard/routes/api.js.map +0 -1
- package/dist/dashboard/routes/pages.d.ts +0 -2
- package/dist/dashboard/routes/pages.js +0 -14
- package/dist/dashboard/routes/pages.js.map +0 -1
- package/dist/dashboard/views/alpine-vendor.d.ts +0 -1
- package/dist/dashboard/views/alpine-vendor.js +0 -10
- package/dist/dashboard/views/alpine-vendor.js.map +0 -1
- package/dist/dashboard/views/shell.d.ts +0 -1
- package/dist/dashboard/views/shell.js +0 -746
- package/dist/dashboard/views/shell.js.map +0 -1
- package/dist/events/decode.d.ts +0 -2
- package/dist/events/decode.js +0 -45
- package/dist/events/decode.js.map +0 -1
- package/dist/events/encode.d.ts +0 -2
- package/dist/events/encode.js +0 -33
- package/dist/events/encode.js.map +0 -1
- package/dist/events/guards.d.ts +0 -5
- package/dist/events/guards.js +0 -42
- package/dist/events/guards.js.map +0 -1
- package/dist/events/types.d.ts +0 -26
- package/dist/events/types.js +0 -2
- package/dist/events/types.js.map +0 -1
- package/dist/harness/config-helpers.d.ts +0 -35
- package/dist/harness/config-helpers.js +0 -411
- package/dist/harness/config-helpers.js.map +0 -1
- package/dist/harness/coordination.d.ts +0 -1
- package/dist/harness/coordination.js +0 -127
- package/dist/harness/coordination.js.map +0 -1
- package/dist/harness/display.d.ts +0 -21
- package/dist/harness/display.js +0 -176
- package/dist/harness/display.js.map +0 -1
- package/dist/harness/emit.d.ts +0 -15
- package/dist/harness/emit.js +0 -240
- package/dist/harness/emit.js.map +0 -1
- package/dist/harness/index.d.ts +0 -13
- package/dist/harness/index.js +0 -240
- package/dist/harness/index.js.map +0 -1
- package/dist/harness/iteration.d.ts +0 -16
- package/dist/harness/iteration.js +0 -131
- package/dist/harness/iteration.js.map +0 -1
- package/dist/harness/journal.d.ts +0 -31
- package/dist/harness/journal.js +0 -178
- package/dist/harness/journal.js.map +0 -1
- package/dist/harness/metareview.d.ts +0 -4
- package/dist/harness/metareview.js +0 -48
- package/dist/harness/metareview.js.map +0 -1
- package/dist/harness/metrics.d.ts +0 -12
- package/dist/harness/metrics.js +0 -180
- package/dist/harness/metrics.js.map +0 -1
- package/dist/harness/parallel.d.ts +0 -37
- package/dist/harness/parallel.js +0 -237
- package/dist/harness/parallel.js.map +0 -1
- package/dist/harness/prompt.d.ts +0 -46
- package/dist/harness/prompt.js +0 -403
- package/dist/harness/prompt.js.map +0 -1
- package/dist/harness/scratchpad.d.ts +0 -2
- package/dist/harness/scratchpad.js +0 -67
- package/dist/harness/scratchpad.js.map +0 -1
- package/dist/harness/stop.d.ts +0 -5
- package/dist/harness/stop.js +0 -70
- package/dist/harness/stop.js.map +0 -1
- package/dist/harness/tools.d.ts +0 -3
- package/dist/harness/tools.js +0 -65
- package/dist/harness/tools.js.map +0 -1
- package/dist/harness/types.d.ts +0 -110
- package/dist/harness/types.js +0 -2
- package/dist/harness/types.js.map +0 -1
- package/dist/harness/wave/finalize-wave.d.ts +0 -9
- package/dist/harness/wave/finalize-wave.js +0 -87
- package/dist/harness/wave/finalize-wave.js.map +0 -1
- package/dist/harness/wave/launch-branches.d.ts +0 -6
- package/dist/harness/wave/launch-branches.js +0 -314
- package/dist/harness/wave/launch-branches.js.map +0 -1
- package/dist/harness/wave/parse-objectives.d.ts +0 -3
- package/dist/harness/wave/parse-objectives.js +0 -32
- package/dist/harness/wave/parse-objectives.js.map +0 -1
- package/dist/harness/wave/types.d.ts +0 -43
- package/dist/harness/wave/types.js +0 -2
- package/dist/harness/wave/types.js.map +0 -1
- package/dist/harness/wave.d.ts +0 -6
- package/dist/harness/wave.js +0 -159
- package/dist/harness/wave.js.map +0 -1
- package/dist/isolation/index.d.ts +0 -4
- package/dist/isolation/index.js +0 -3
- package/dist/isolation/index.js.map +0 -1
- package/dist/isolation/resolve.d.ts +0 -39
- package/dist/isolation/resolve.js +0 -118
- package/dist/isolation/resolve.js.map +0 -1
- package/dist/isolation/run-scope.d.ts +0 -21
- package/dist/isolation/run-scope.js +0 -50
- package/dist/isolation/run-scope.js.map +0 -1
- package/dist/json.d.ts +0 -8
- package/dist/json.js +0 -82
- package/dist/json.js.map +0 -1
- package/dist/loops/health.d.ts +0 -16
- package/dist/loops/health.js +0 -152
- package/dist/loops/health.js.map +0 -1
- package/dist/loops/list.d.ts +0 -6
- package/dist/loops/list.js +0 -21
- package/dist/loops/list.js.map +0 -1
- package/dist/loops/policy.d.ts +0 -6
- package/dist/loops/policy.js +0 -41
- package/dist/loops/policy.js.map +0 -1
- package/dist/loops/render.d.ts +0 -19
- package/dist/loops/render.js +0 -100
- package/dist/loops/render.js.map +0 -1
- package/dist/loops/show.d.ts +0 -8
- package/dist/loops/show.js +0 -31
- package/dist/loops/show.js.map +0 -1
- package/dist/loops/watch.d.ts +0 -14
- package/dist/loops/watch.js +0 -143
- package/dist/loops/watch.js.map +0 -1
- package/dist/main.d.ts +0 -1
- package/dist/main.js +0 -148
- package/dist/main.js.map +0 -1
- package/dist/markdown.d.ts +0 -10
- package/dist/markdown.js +0 -66
- package/dist/markdown.js.map +0 -1
- package/dist/memory-render.d.ts +0 -6
- package/dist/memory-render.js +0 -81
- package/dist/memory-render.js.map +0 -1
- package/dist/memory.d.ts +0 -22
- package/dist/memory.js +0 -318
- package/dist/memory.js.map +0 -1
- package/dist/pi-adapter.d.ts +0 -1
- package/dist/pi-adapter.js +0 -220
- package/dist/pi-adapter.js.map +0 -1
- package/dist/profiles.d.ts +0 -12
- package/dist/profiles.js +0 -71
- package/dist/profiles.js.map +0 -1
- package/dist/registry/derive.d.ts +0 -8
- package/dist/registry/derive.js +0 -88
- package/dist/registry/derive.js.map +0 -1
- package/dist/registry/discover.d.ts +0 -20
- package/dist/registry/discover.js +0 -98
- package/dist/registry/discover.js.map +0 -1
- package/dist/registry/harness.d.ts +0 -7
- package/dist/registry/harness.js +0 -63
- package/dist/registry/harness.js.map +0 -1
- package/dist/registry/index.d.ts +0 -6
- package/dist/registry/index.js +0 -6
- package/dist/registry/index.js.map +0 -1
- package/dist/registry/read.d.ts +0 -11
- package/dist/registry/read.js +0 -50
- package/dist/registry/read.js.map +0 -1
- package/dist/registry/rebuild.d.ts +0 -5
- package/dist/registry/rebuild.js +0 -22
- package/dist/registry/rebuild.js.map +0 -1
- package/dist/registry/types.d.ts +0 -28
- package/dist/registry/types.js +0 -2
- package/dist/registry/types.js.map +0 -1
- package/dist/registry/update.d.ts +0 -2
- package/dist/registry/update.js +0 -7
- package/dist/registry/update.js.map +0 -1
- package/dist/tasks-render.d.ts +0 -2
- package/dist/tasks-render.js +0 -44
- package/dist/tasks-render.js.map +0 -1
- package/dist/tasks.d.ts +0 -24
- package/dist/tasks.js +0 -184
- package/dist/tasks.js.map +0 -1
- package/dist/topology.d.ts +0 -31
- package/dist/topology.js +0 -309
- package/dist/topology.js.map +0 -1
- package/dist/usage.d.ts +0 -9
- package/dist/usage.js +0 -159
- package/dist/usage.js.map +0 -1
- package/dist/utils.d.ts +0 -21
- package/dist/utils.js +0 -349
- package/dist/utils.js.map +0 -1
- package/dist/worktree/clean.d.ts +0 -12
- package/dist/worktree/clean.js +0 -98
- package/dist/worktree/clean.js.map +0 -1
- package/dist/worktree/create.d.ts +0 -14
- package/dist/worktree/create.js +0 -71
- package/dist/worktree/create.js.map +0 -1
- package/dist/worktree/index.d.ts +0 -10
- package/dist/worktree/index.js +0 -6
- package/dist/worktree/index.js.map +0 -1
- package/dist/worktree/list.d.ts +0 -9
- package/dist/worktree/list.js +0 -24
- package/dist/worktree/list.js.map +0 -1
- package/dist/worktree/merge.d.ts +0 -11
- package/dist/worktree/merge.js +0 -129
- package/dist/worktree/merge.js.map +0 -1
- package/dist/worktree/meta.d.ts +0 -17
- package/dist/worktree/meta.js +0 -34
- package/dist/worktree/meta.js.map +0 -1
- package/presets/autocode/README.md +0 -81
- package/presets/autocode/autoloops.toml +0 -30
- package/presets/autocode/harness.md +0 -26
- package/presets/autocode/miniloops.toml +0 -22
- package/presets/autocode/roles/build.md +0 -34
- package/presets/autocode/roles/critic.md +0 -40
- package/presets/autocode/roles/finalizer.md +0 -43
- package/presets/autocode/roles/planner.md +0 -40
- package/presets/autocode/topology.toml +0 -32
- package/presets/autodoc/README.md +0 -42
- package/presets/autodoc/autoloops.toml +0 -21
- package/presets/autodoc/harness.md +0 -19
- package/presets/autodoc/miniloops.toml +0 -21
- package/presets/autodoc/roles/auditor.md +0 -39
- package/presets/autodoc/roles/checker.md +0 -43
- package/presets/autodoc/roles/publisher.md +0 -51
- package/presets/autodoc/roles/writer.md +0 -37
- package/presets/autodoc/topology.toml +0 -31
- package/presets/autofix/README.md +0 -56
- package/presets/autofix/autoloops.toml +0 -24
- package/presets/autofix/harness.md +0 -25
- package/presets/autofix/miniloops.toml +0 -21
- package/presets/autofix/roles/closer.md +0 -48
- package/presets/autofix/roles/diagnoser.md +0 -43
- package/presets/autofix/roles/fixer.md +0 -28
- package/presets/autofix/roles/verifier.md +0 -31
- package/presets/autofix/topology.toml +0 -33
- package/presets/autoideas/README.md +0 -73
- package/presets/autoideas/autoloops.toml +0 -18
- package/presets/autoideas/harness.md +0 -31
- package/presets/autoideas/miniloops.toml +0 -18
- package/presets/autoideas/roles/analyst.md +0 -32
- package/presets/autoideas/roles/reviewer.md +0 -36
- package/presets/autoideas/roles/scanner.md +0 -26
- package/presets/autoideas/roles/synthesizer.md +0 -61
- package/presets/autoideas/topology.toml +0 -32
- package/presets/automerge/README.md +0 -3
- package/presets/automerge/autoloops.toml +0 -12
- package/presets/automerge/harness.md +0 -10
- package/presets/automerge/miniloops.toml +0 -12
- package/presets/automerge/roles/merge.md +0 -10
- package/presets/automerge/topology.toml +0 -10
- package/presets/autoperf/README.md +0 -56
- package/presets/autoperf/autoloops.toml +0 -21
- package/presets/autoperf/harness.md +0 -21
- package/presets/autoperf/miniloops.toml +0 -21
- package/presets/autoperf/roles/judge.md +0 -38
- package/presets/autoperf/roles/measurer.md +0 -36
- package/presets/autoperf/roles/optimizer.md +0 -35
- package/presets/autoperf/roles/profiler.md +0 -38
- package/presets/autoperf/topology.toml +0 -32
- package/presets/autopr/README.md +0 -99
- package/presets/autopr/autoloops.toml +0 -22
- package/presets/autopr/harness.md +0 -27
- package/presets/autopr/miniloops.toml +0 -22
- package/presets/autopr/roles/collector.md +0 -55
- package/presets/autopr/roles/drafter.md +0 -38
- package/presets/autopr/roles/publisher.md +0 -28
- package/presets/autopr/roles/validator.md +0 -31
- package/presets/autopr/topology.toml +0 -32
- package/presets/autoqa/README.md +0 -76
- package/presets/autoqa/autoloops.toml +0 -21
- package/presets/autoqa/harness.md +0 -30
- package/presets/autoqa/miniloops.toml +0 -21
- package/presets/autoqa/roles/executor.md +0 -43
- package/presets/autoqa/roles/inspector.md +0 -45
- package/presets/autoqa/roles/planner.md +0 -55
- package/presets/autoqa/roles/reporter.md +0 -74
- package/presets/autoqa/topology.toml +0 -31
- package/presets/autoresearch/README.md +0 -63
- package/presets/autoresearch/autoloops.toml +0 -18
- package/presets/autoresearch/harness.md +0 -28
- package/presets/autoresearch/miniloops.toml +0 -18
- package/presets/autoresearch/roles/benchmarker.md +0 -34
- package/presets/autoresearch/roles/evaluator.md +0 -33
- package/presets/autoresearch/roles/implementer.md +0 -26
- package/presets/autoresearch/roles/strategist.md +0 -43
- package/presets/autoresearch/topology.toml +0 -31
- package/presets/autoreview/README.md +0 -51
- package/presets/autoreview/autoloops.toml +0 -21
- package/presets/autoreview/harness.md +0 -20
- package/presets/autoreview/miniloops.toml +0 -21
- package/presets/autoreview/roles/checker.md +0 -36
- package/presets/autoreview/roles/reader.md +0 -33
- package/presets/autoreview/roles/suggester.md +0 -26
- package/presets/autoreview/roles/summarizer.md +0 -57
- package/presets/autoreview/topology.toml +0 -31
- package/presets/autosec/README.md +0 -51
- package/presets/autosec/autoloops.toml +0 -21
- package/presets/autosec/harness.md +0 -20
- package/presets/autosec/miniloops.toml +0 -21
- package/presets/autosec/roles/analyst.md +0 -38
- package/presets/autosec/roles/hardener.md +0 -36
- package/presets/autosec/roles/reporter.md +0 -63
- package/presets/autosec/roles/scanner.md +0 -38
- package/presets/autosec/topology.toml +0 -31
- package/presets/autosimplify/README.md +0 -83
- package/presets/autosimplify/autoloops.toml +0 -26
- package/presets/autosimplify/harness.md +0 -25
- package/presets/autosimplify/miniloops.toml +0 -22
- package/presets/autosimplify/roles/reviewer.md +0 -38
- package/presets/autosimplify/roles/scoper.md +0 -42
- package/presets/autosimplify/roles/simplifier.md +0 -51
- package/presets/autosimplify/roles/verifier.md +0 -40
- package/presets/autosimplify/topology.toml +0 -32
- package/presets/autospec/README.md +0 -84
- package/presets/autospec/autoloops.toml +0 -21
- package/presets/autospec/harness.md +0 -23
- package/presets/autospec/miniloops.toml +0 -21
- package/presets/autospec/roles/clarifier.md +0 -39
- package/presets/autospec/roles/critic.md +0 -41
- package/presets/autospec/roles/designer.md +0 -37
- package/presets/autospec/roles/planner.md +0 -38
- package/presets/autospec/roles/researcher.md +0 -33
- package/presets/autospec/topology.toml +0 -38
- package/presets/autotest/README.md +0 -55
- package/presets/autotest/autoloops.toml +0 -21
- package/presets/autotest/harness.md +0 -21
- package/presets/autotest/miniloops.toml +0 -21
- package/presets/autotest/roles/assessor.md +0 -57
- package/presets/autotest/roles/runner.md +0 -31
- package/presets/autotest/roles/surveyor.md +0 -39
- package/presets/autotest/roles/writer.md +0 -37
- package/presets/autotest/topology.toml +0 -32
package/presets/autopr/README.md
DELETED
|
@@ -1,99 +0,0 @@
|
|
|
1
|
-
# AutoPR miniloop
|
|
2
|
-
|
|
3
|
-
Use when you want to turn the current branch into an accurate, reviewable pull request.
|
|
4
|
-
|
|
5
|
-
AutoPR inspects repo and branch state, normalizes any structured PR request, drafts a reviewer-useful title/body, validates that the draft matches the actual diff and evidence, and then creates or updates the PR. It can optionally arm auto-merge or immediately merge if checks are already green.
|
|
6
|
-
|
|
7
|
-
Shape:
|
|
8
|
-
- collector — resolves the request, repo state, base/head branches, checks, and existing PR state
|
|
9
|
-
- drafter — writes the PR title/body/checklist
|
|
10
|
-
- validator — attacks mismatches, fake claims, weak reviewer guidance, and missing evidence
|
|
11
|
-
- publisher — creates or updates the PR and optionally arms/executes merge behavior
|
|
12
|
-
|
|
13
|
-
## Fail-closed contract
|
|
14
|
-
|
|
15
|
-
AutoPR is not a PR-hallucination preset.
|
|
16
|
-
|
|
17
|
-
- A PR draft must match the real diff and real verification evidence.
|
|
18
|
-
- Missing checks, ambiguous branch state, missing `gh` auth, or unknown mergeability should block publication instead of being papered over.
|
|
19
|
-
- `publish-and-arm` should enable auto-merge and stop; it should not poll CI.
|
|
20
|
-
- `publish-and-merge-if-green` should merge only when green *now* or otherwise arm auto-merge if supported.
|
|
21
|
-
|
|
22
|
-
## Remote-first base comparison
|
|
23
|
-
|
|
24
|
-
AutoPR always compares the PR branch against `origin/<base>` (the remote tracking ref), not the local `<base>` ref. This prevents a dangerous class of bugs where local main is ahead of or diverged from origin/main:
|
|
25
|
-
|
|
26
|
-
- **Merge-base, commit list, and file diff** are all computed against `origin/<base>`. This ensures the PR body accurately describes what GitHub will show in the PR diff.
|
|
27
|
-
- **Inherited unpublished commit guard**: If the head branch includes commits that exist on local `<base>` but not on `origin/<base>`, these would silently appear in the GitHub PR. AutoPR detects this and blocks publication (`pr.blocked`) with a clear explanation, advising the user to push the base branch first.
|
|
28
|
-
- **Local/remote divergence disclosure**: When local `<base>` differs from `origin/<base>` (even without inherited commits leaking into the head branch), the collector records the divergence status in `pr-context.md` so the drafter and validator are aware.
|
|
29
|
-
|
|
30
|
-
The validator independently recomputes the diff against `origin/<base>` and rejects drafts whose scope doesn't match the remote-based diff.
|
|
31
|
-
|
|
32
|
-
## How it works
|
|
33
|
-
|
|
34
|
-
1. **Collector** reads the launch prompt, optional `.autoloop/pr-request.md`, git state, and GitHub state and writes `.autoloop/pr-context.md`.
|
|
35
|
-
2. **Drafter** writes `.autoloop/pr-draft.md` with title, body, verification, risks, and reviewer focus.
|
|
36
|
-
3. **Validator** checks the draft against the actual diff, branch state, and evidence and either routes back for revision or validates it.
|
|
37
|
-
4. **Publisher** creates or updates the PR and records the result in `.autoloop/pr-result.md`.
|
|
38
|
-
|
|
39
|
-
## Inputs
|
|
40
|
-
|
|
41
|
-
### Primary input
|
|
42
|
-
|
|
43
|
-
Run it with a normal objective prompt:
|
|
44
|
-
|
|
45
|
-
```bash
|
|
46
|
-
autoloop run autopr "Open a PR for the current branch against main and enable auto-merge if checks pass."
|
|
47
|
-
```
|
|
48
|
-
|
|
49
|
-
### Optional structured request
|
|
50
|
-
|
|
51
|
-
If `.autoloop/pr-request.md` exists, AutoPR should treat its frontmatter as the highest-priority structured request. Recommended fields:
|
|
52
|
-
|
|
53
|
-
```md
|
|
54
|
-
---
|
|
55
|
-
base: main
|
|
56
|
-
mode: publish-and-arm
|
|
57
|
-
draft: false
|
|
58
|
-
reviewers:
|
|
59
|
-
- alice
|
|
60
|
-
- bob
|
|
61
|
-
labels:
|
|
62
|
-
- dashboard
|
|
63
|
-
- ux
|
|
64
|
-
issue: 123
|
|
65
|
-
rfc: docs/rfcs/dashboard-event-rendering.md
|
|
66
|
-
title_hint: Improve dashboard event rendering and prompt display
|
|
67
|
-
---
|
|
68
|
-
|
|
69
|
-
Open a PR for the dashboard UI work.
|
|
70
|
-
Call out that tests passed and that this is UI-only.
|
|
71
|
-
```
|
|
72
|
-
|
|
73
|
-
Supported frontmatter fields:
|
|
74
|
-
- `base`
|
|
75
|
-
- `mode` (`publish`, `publish-and-arm`, `publish-and-merge-if-green`)
|
|
76
|
-
- `draft`
|
|
77
|
-
- `reviewers`
|
|
78
|
-
- `labels`
|
|
79
|
-
- `issue`
|
|
80
|
-
- `rfc`
|
|
81
|
-
- `title_hint`
|
|
82
|
-
|
|
83
|
-
## Files
|
|
84
|
-
|
|
85
|
-
- `autoloops.toml` — loop + backend config
|
|
86
|
-
- `topology.toml` — role deck + handoff graph
|
|
87
|
-
- `harness.md` — shared harness rules loaded every iteration
|
|
88
|
-
- `roles/collector.md`
|
|
89
|
-
- `roles/drafter.md`
|
|
90
|
-
- `roles/validator.md`
|
|
91
|
-
- `roles/publisher.md`
|
|
92
|
-
|
|
93
|
-
## Shared working files created by the loop
|
|
94
|
-
|
|
95
|
-
- `.autoloop/pr-request.md` — optional structured request with frontmatter
|
|
96
|
-
- `.autoloop/pr-context.md` — normalized publish context and repo evidence
|
|
97
|
-
- `.autoloop/pr-draft.md` — title/body/checklist draft
|
|
98
|
-
- `.autoloop/pr-result.md` — final PR URL/number and publish disposition
|
|
99
|
-
- `.autoloop/progress.md` — phase, blockers, and verification notes
|
|
@@ -1,22 +0,0 @@
|
|
|
1
|
-
event_loop.max_iterations = 100
|
|
2
|
-
event_loop.completion_event = "task.complete"
|
|
3
|
-
event_loop.completion_promise = "LOOP_COMPLETE"
|
|
4
|
-
# Require the validation gate before publishing is considered complete.
|
|
5
|
-
event_loop.required_events = ["pr.validated"]
|
|
6
|
-
|
|
7
|
-
backend.kind = "command"
|
|
8
|
-
backend.command = "claude"
|
|
9
|
-
backend.timeout_ms = 3000000
|
|
10
|
-
# For deterministic local harness testing only:
|
|
11
|
-
# backend.kind = "command"
|
|
12
|
-
# backend.command = "../../examples/mock-backend.sh"
|
|
13
|
-
|
|
14
|
-
review.enabled = true
|
|
15
|
-
review.timeout_ms = 300000
|
|
16
|
-
|
|
17
|
-
memory.prompt_budget_chars = 8000
|
|
18
|
-
harness.instructions_file = "harness.md"
|
|
19
|
-
|
|
20
|
-
core.state_dir = ".autoloop"
|
|
21
|
-
core.journal_file = ".autoloop/journal.jsonl"
|
|
22
|
-
core.memory_file = ".autoloop/memory.jsonl"
|
|
@@ -1,27 +0,0 @@
|
|
|
1
|
-
<!-- category: planning -->
|
|
2
|
-
This preset turns the current branch into a reviewable pull request.
|
|
3
|
-
|
|
4
|
-
Global rules:
|
|
5
|
-
- Shared working files are the source of truth: `{{STATE_DIR}}/pr-request.md`, `{{STATE_DIR}}/pr-context.md`, `{{STATE_DIR}}/pr-draft.md`, `{{STATE_DIR}}/pr-result.md`, and `{{STATE_DIR}}/progress.md`.
|
|
6
|
-
- The job is to publish an accurate PR, not to implement missing code or babysit CI forever.
|
|
7
|
-
- Fresh context every iteration: re-read the shared working files, git state, and relevant source before acting.
|
|
8
|
-
- Use the event tool instead of prose-only handoffs.
|
|
9
|
-
- Missing evidence means no publish. If checks were not run, say so explicitly in the PR draft.
|
|
10
|
-
- Do not invent verification, issue links, labels, reviewers, or mergeability state.
|
|
11
|
-
- Prefer exact git / gh CLI evidence over summaries from earlier iterations.
|
|
12
|
-
- **Remote-first base comparison (mandatory)**: All base-branch comparisons — merge-base, commit list, file diff — must use the remote tracking ref (`origin/<base>`), not the local ref. If local `<base>` and `origin/<base>` diverge, the collector must record the divergence in `pr-context.md` and block if the head branch inherits unpublished local-only commits. This prevents the PR body from misrepresenting what GitHub will actually show in the diff.
|
|
13
|
-
- If `{{STATE_DIR}}/pr-request.md` exists, treat its frontmatter as the highest-priority structured request.
|
|
14
|
-
- The freeform objective prompt is still valid input, but structured request fields override it.
|
|
15
|
-
- Derive defaults when safe: head branch from git, base branch from repo default or `main`, mode defaults to `publish`, draft defaults to `false`.
|
|
16
|
-
- Do not publish from a dirty, ambiguous, or detached repo state without calling that out and blocking.
|
|
17
|
-
- If a PR already exists for the head branch, update it instead of creating a duplicate unless the request explicitly says otherwise.
|
|
18
|
-
- `publish-and-arm` means enable platform auto-merge if supported; do not keep polling.
|
|
19
|
-
- `publish-and-merge-if-green` means merge immediately only if checks are already green and mergeability is confirmed right now; otherwise arm auto-merge if available, or block with evidence.
|
|
20
|
-
- Stay inside collector -> drafter -> validator -> publisher. Do not merge responsibilities.
|
|
21
|
-
- Only the publisher may emit `task.complete`.
|
|
22
|
-
|
|
23
|
-
Role boundaries (strict):
|
|
24
|
-
- The collector normalizes the request and repo state into `{{STATE_DIR}}/pr-context.md`; it does not draft or publish.
|
|
25
|
-
- The drafter writes `{{STATE_DIR}}/pr-draft.md`; it does not validate or publish.
|
|
26
|
-
- The validator checks the draft against the actual repo state and request; it does not publish.
|
|
27
|
-
- The publisher performs the side effect (`gh pr create`, `gh pr edit`, `gh pr merge --auto`, etc.) and records the result.
|
|
@@ -1,22 +0,0 @@
|
|
|
1
|
-
event_loop.max_iterations = 100
|
|
2
|
-
event_loop.completion_event = "task.complete"
|
|
3
|
-
event_loop.completion_promise = "LOOP_COMPLETE"
|
|
4
|
-
# Require the validation gate before publishing is considered complete.
|
|
5
|
-
event_loop.required_events = ["pr.validated"]
|
|
6
|
-
|
|
7
|
-
backend.kind = "pi"
|
|
8
|
-
backend.command = "pi"
|
|
9
|
-
backend.timeout_ms = 3000000
|
|
10
|
-
# For deterministic local harness testing only:
|
|
11
|
-
# backend.kind = "command"
|
|
12
|
-
# backend.command = "../../examples/mock-backend.sh"
|
|
13
|
-
|
|
14
|
-
review.enabled = true
|
|
15
|
-
review.timeout_ms = 300000
|
|
16
|
-
|
|
17
|
-
memory.prompt_budget_chars = 8000
|
|
18
|
-
harness.instructions_file = "harness.md"
|
|
19
|
-
|
|
20
|
-
core.state_dir = ".miniloop"
|
|
21
|
-
core.journal_file = ".miniloop/journal.jsonl"
|
|
22
|
-
core.memory_file = ".miniloop/memory.jsonl"
|
|
@@ -1,55 +0,0 @@
|
|
|
1
|
-
You are the collector.
|
|
2
|
-
|
|
3
|
-
Do not draft the PR. Do not validate claims. Do not publish.
|
|
4
|
-
|
|
5
|
-
Your job:
|
|
6
|
-
1. Normalize the PR request into shared working files.
|
|
7
|
-
2. Inspect the actual repo and GitHub state.
|
|
8
|
-
3. Decide whether the loop has enough clean context to draft a PR.
|
|
9
|
-
|
|
10
|
-
On every activation:
|
|
11
|
-
- Read `{{STATE_DIR}}/pr-request.md`, `{{STATE_DIR}}/pr-context.md`, `{{STATE_DIR}}/pr-draft.md`, `{{STATE_DIR}}/pr-result.md`, and `{{STATE_DIR}}/progress.md` if they exist.
|
|
12
|
-
- Re-read the latest scratchpad/journal context before deciding.
|
|
13
|
-
- Re-check the live repo state; do not trust stale summaries.
|
|
14
|
-
|
|
15
|
-
On first activation:
|
|
16
|
-
- Parse the launch objective.
|
|
17
|
-
- If `{{STATE_DIR}}/pr-request.md` exists, read its frontmatter and body and treat that as the highest-priority structured request.
|
|
18
|
-
- Inspect git state directly: current branch, detached-head status, dirty files, commits ahead/behind, merge-base, changed files, likely base branch.
|
|
19
|
-
- **Remote-first base resolution**: Always resolve the base branch to its remote tracking ref (`origin/<base>`, or the remote specified in the request). Compute merge-base, commit list, and file diff against `origin/<base>`, never against the local `<base>` ref.
|
|
20
|
-
- **Local/remote divergence check**: Compare local `<base>` against `origin/<base>`. If they differ, record the divergence in `{{STATE_DIR}}/pr-context.md` (local ahead by N commits, behind by M, or diverged).
|
|
21
|
-
- **Inherited unpublished commit guard**: If the head branch includes commits that are on local `<base>` but NOT on `origin/<base>`, these are inherited unpublished commits that would silently appear in the GitHub PR diff. Emit `pr.blocked` with a clear explanation listing the inherited commits and advising the user to push the base branch first.
|
|
22
|
-
- Inspect platform state directly when possible: `gh auth status`, existing PR for head branch, check status, mergeability, repo default branch.
|
|
23
|
-
- Create or refresh:
|
|
24
|
-
- `{{STATE_DIR}}/pr-context.md` — normalized request, repo state, verification evidence, blockers, and publish intent.
|
|
25
|
-
- `{{STATE_DIR}}/progress.md` — current phase, resolved inputs, unresolved blockers.
|
|
26
|
-
- Emit `pr.context_ready` when the request is normalized and the repo state is clean enough for drafting.
|
|
27
|
-
- Emit `pr.blocked` if publication is not safely draftable yet.
|
|
28
|
-
|
|
29
|
-
On later activations (`pr.blocked`, `draft.blocked`, `publish.blocked`):
|
|
30
|
-
- Re-read the shared files and re-check the live state.
|
|
31
|
-
- If the blocker is gone, refresh `{{STATE_DIR}}/pr-context.md` and emit `pr.context_ready`.
|
|
32
|
-
- If the blocker persists, update `{{STATE_DIR}}/progress.md` with exact evidence and emit `pr.blocked` again.
|
|
33
|
-
|
|
34
|
-
Required output in `{{STATE_DIR}}/pr-context.md`:
|
|
35
|
-
- Request summary
|
|
36
|
-
- Base branch (local ref AND remote tracking ref)
|
|
37
|
-
- Remote merge-base commit hash
|
|
38
|
-
- Local/remote base divergence status (in-sync, local-ahead, diverged)
|
|
39
|
-
- Head branch
|
|
40
|
-
- Mode (`publish`, `publish-and-arm`, `publish-and-merge-if-green`)
|
|
41
|
-
- Draft flag
|
|
42
|
-
- Reviewers / labels / issue / RFC if known
|
|
43
|
-
- Existing PR state
|
|
44
|
-
- Verification evidence actually available
|
|
45
|
-
- Key files changed
|
|
46
|
-
- Risks / publish blockers
|
|
47
|
-
|
|
48
|
-
Rules:
|
|
49
|
-
- Prefer derived facts over prompt wishes.
|
|
50
|
-
- If base is unspecified, infer repo default branch or fall back to `main`, and say which one you chose. Always verify `origin/<base>` exists; if not, block.
|
|
51
|
-
- If the branch is detached, ambiguous, unpublished, or there is no meaningful diff, block.
|
|
52
|
-
- If `gh` is unavailable or unauthenticated, block with exact command evidence.
|
|
53
|
-
- Do not claim checks passed unless you found actual evidence.
|
|
54
|
-
- Do not silently invent reviewers, labels, issue links, or mergeability.
|
|
55
|
-
- If an existing PR already matches the head branch, record update-vs-create intent explicitly.
|
|
@@ -1,38 +0,0 @@
|
|
|
1
|
-
You are the drafter.
|
|
2
|
-
|
|
3
|
-
Do not inspect platform auth. Do not validate claims. Do not publish.
|
|
4
|
-
|
|
5
|
-
Your job:
|
|
6
|
-
1. Turn the normalized context into a reviewable PR title and body.
|
|
7
|
-
2. Make the draft useful to human reviewers.
|
|
8
|
-
3. Record exactly what the PR should say.
|
|
9
|
-
|
|
10
|
-
On every activation:
|
|
11
|
-
- Read `{{STATE_DIR}}/pr-request.md`, `{{STATE_DIR}}/pr-context.md`, `{{STATE_DIR}}/pr-draft.md`, and `{{STATE_DIR}}/progress.md`.
|
|
12
|
-
- Read the relevant changed files and docs only as needed to make the draft concrete.
|
|
13
|
-
|
|
14
|
-
Process:
|
|
15
|
-
1. Draft or refresh `{{STATE_DIR}}/pr-draft.md` with:
|
|
16
|
-
- `## Title`
|
|
17
|
-
- `## Body`
|
|
18
|
-
- `## Publish Notes`
|
|
19
|
-
2. The body should usually include:
|
|
20
|
-
- Summary
|
|
21
|
-
- Why
|
|
22
|
-
- What changed
|
|
23
|
-
- Verification
|
|
24
|
-
- Risks / follow-ups
|
|
25
|
-
- Reviewer focus
|
|
26
|
-
3. If the request includes issue/RFC/title hints, use them when accurate.
|
|
27
|
-
4. Update `{{STATE_DIR}}/progress.md` with what changed in the draft.
|
|
28
|
-
5. Emit `pr.drafted` when the draft is specific and publishable.
|
|
29
|
-
6. Emit `draft.blocked` if the context is too weak to write an accurate draft.
|
|
30
|
-
|
|
31
|
-
Rules:
|
|
32
|
-
- Be concise but reviewer-useful.
|
|
33
|
-
- Do not claim tests/checks that are not present in `{{STATE_DIR}}/pr-context.md`.
|
|
34
|
-
- Do not merely restate commit messages; explain the change in reviewer terms.
|
|
35
|
-
- Surface risk honestly. A small PR can still have risky UI or behavior changes.
|
|
36
|
-
- The title should be specific enough to stand alone in a PR list.
|
|
37
|
-
- If verification is missing, say so plainly instead of faking confidence.
|
|
38
|
-
- If reviewer focus is obvious, spell it out; this is one of the preset's main values.
|
|
@@ -1,28 +0,0 @@
|
|
|
1
|
-
You are the publisher.
|
|
2
|
-
|
|
3
|
-
Do not redraft. Do not validate. Your job is to publish the validated PR and record the result.
|
|
4
|
-
|
|
5
|
-
On every activation:
|
|
6
|
-
- Read `{{STATE_DIR}}/pr-context.md`, `{{STATE_DIR}}/pr-draft.md`, `{{STATE_DIR}}/pr-result.md`, and `{{STATE_DIR}}/progress.md`.
|
|
7
|
-
- Re-check the live GitHub and git state before performing side effects.
|
|
8
|
-
|
|
9
|
-
Process:
|
|
10
|
-
1. Determine whether to create a new PR or update an existing PR for the head branch.
|
|
11
|
-
2. Use the validated title/body from `{{STATE_DIR}}/pr-draft.md`.
|
|
12
|
-
3. Apply requested metadata when supported and evidenced: draft state, reviewers, labels.
|
|
13
|
-
4. Respect the normalized mode from `{{STATE_DIR}}/pr-context.md`:
|
|
14
|
-
- `publish` → create/update PR and stop
|
|
15
|
-
- `publish-and-arm` → create/update PR, then enable auto-merge if supported
|
|
16
|
-
- `publish-and-merge-if-green` → create/update PR, then merge immediately only if checks are green and mergeability is confirmed now; otherwise enable auto-merge if supported; otherwise block
|
|
17
|
-
5. Write `{{STATE_DIR}}/pr-result.md` with PR number, URL, final mode disposition, metadata applied, and any blockers encountered.
|
|
18
|
-
6. Update `{{STATE_DIR}}/progress.md` with exact commands run and final state.
|
|
19
|
-
7. Emit `task.complete` only when the requested publish action succeeded.
|
|
20
|
-
8. Emit `publish.blocked` if publish or merge behavior could not be completed safely.
|
|
21
|
-
|
|
22
|
-
Rules:
|
|
23
|
-
- Use exact command evidence (`gh pr create`, `gh pr edit`, `gh pr merge --auto`, etc.) and record failures verbatim enough to debug.
|
|
24
|
-
- Do not poll CI. If checks are pending and auto-merge can be armed, arm it and complete.
|
|
25
|
-
- Do not merge on wishful thinking; immediate merge requires green checks and confirmed mergeability now.
|
|
26
|
-
- If reviewer or label application fails after PR creation, record partial success explicitly.
|
|
27
|
-
- If the PR was created/updated but the requested arm/merge behavior failed, treat that as blocked unless the normalized request said plain `publish`.
|
|
28
|
-
- Never emit `task.complete` without recording the PR URL or equivalent durable result in `{{STATE_DIR}}/pr-result.md`.
|
|
@@ -1,31 +0,0 @@
|
|
|
1
|
-
You are the validator.
|
|
2
|
-
|
|
3
|
-
Do not publish. Do not rewrite the whole request. Your job is to attack weak or inaccurate PR drafts.
|
|
4
|
-
|
|
5
|
-
On every activation:
|
|
6
|
-
- Read `{{STATE_DIR}}/pr-request.md`, `{{STATE_DIR}}/pr-context.md`, `{{STATE_DIR}}/pr-draft.md`, and `{{STATE_DIR}}/progress.md`.
|
|
7
|
-
- Read the actual repo state directly: git diff, changed files, branch/base info, and verification evidence.
|
|
8
|
-
- **Remote-first validation**: Independently compute the diff against `origin/<base>` (not local `<base>`). This is the ground truth for what GitHub will show in the PR.
|
|
9
|
-
|
|
10
|
-
Process:
|
|
11
|
-
1. Check the draft against reality:
|
|
12
|
-
- title matches the actual change
|
|
13
|
-
- body matches changed files and behavior
|
|
14
|
-
- verification claims are evidenced
|
|
15
|
-
- risks are disclosed
|
|
16
|
-
- reviewer focus is useful and concrete
|
|
17
|
-
- requested mode/base/draft semantics are reflected in publish notes
|
|
18
|
-
2. Record validation notes in `{{STATE_DIR}}/progress.md`.
|
|
19
|
-
3. If the draft is materially inaccurate, incomplete, or too vague, emit `pr.revise` with the concrete defect.
|
|
20
|
-
4. If the draft is accurate and strong enough to publish, emit `pr.validated`.
|
|
21
|
-
|
|
22
|
-
Rules:
|
|
23
|
-
- Start skeptical. Absence of obvious errors is not enough.
|
|
24
|
-
- Do not approve invented verification, fake issue links, or unsupported mergeability claims.
|
|
25
|
-
- If the diff is bigger or riskier than the title/body suggest, reject it.
|
|
26
|
-
- If the draft hides uncertainty that a reviewer would need to know, reject it.
|
|
27
|
-
- Prefer one more drafting loop over a misleading PR.
|
|
28
|
-
- Minor phrasing nits are not enough for `pr.revise`; focus on material accuracy and reviewer usefulness.
|
|
29
|
-
- **Remote-based scope check**: Compare the draft's claimed changed-files and scope against the `origin/<base>`-based diff. Reject (`pr.revise`) if they don't match — this catches cases where local base divergence caused the collector to undercount or overcount changes.
|
|
30
|
-
- **Inherited commit disclosure**: Reject if `pr-context.md` does not record the remote merge-base hash or does not disclose local/remote base divergence status. A draft built on local-only comparisons is unreliable.
|
|
31
|
-
- **Diff mismatch guard**: If `git diff origin/<base>...HEAD --stat` shows files not mentioned in the draft, or the draft mentions files not in the remote diff, reject with specifics.
|
|
@@ -1,32 +0,0 @@
|
|
|
1
|
-
name = "autopr"
|
|
2
|
-
completion = "task.complete"
|
|
3
|
-
|
|
4
|
-
[[role]]
|
|
5
|
-
id = "collector"
|
|
6
|
-
emits = ["pr.context_ready", "pr.blocked"]
|
|
7
|
-
prompt_file = "roles/collector.md"
|
|
8
|
-
|
|
9
|
-
[[role]]
|
|
10
|
-
id = "drafter"
|
|
11
|
-
emits = ["pr.drafted", "draft.blocked"]
|
|
12
|
-
prompt_file = "roles/drafter.md"
|
|
13
|
-
|
|
14
|
-
[[role]]
|
|
15
|
-
id = "validator"
|
|
16
|
-
emits = ["pr.validated", "pr.revise"]
|
|
17
|
-
prompt_file = "roles/validator.md"
|
|
18
|
-
|
|
19
|
-
[[role]]
|
|
20
|
-
id = "publisher"
|
|
21
|
-
emits = ["task.complete", "publish.blocked"]
|
|
22
|
-
prompt_file = "roles/publisher.md"
|
|
23
|
-
|
|
24
|
-
[handoff]
|
|
25
|
-
"loop.start" = ["collector"]
|
|
26
|
-
"pr.blocked" = ["collector"]
|
|
27
|
-
"pr.context_ready" = ["drafter"]
|
|
28
|
-
"draft.blocked" = ["collector"]
|
|
29
|
-
"pr.drafted" = ["validator"]
|
|
30
|
-
"pr.revise" = ["drafter"]
|
|
31
|
-
"pr.validated" = ["publisher"]
|
|
32
|
-
"publish.blocked" = ["collector"]
|
package/presets/autoqa/README.md
DELETED
|
@@ -1,76 +0,0 @@
|
|
|
1
|
-
# AutoQA miniloop
|
|
2
|
-
|
|
3
|
-
Use when you want comprehensive validation of a codebase without writing custom test harnesses.
|
|
4
|
-
|
|
5
|
-
AutoQA inspects a target repo, discovers what validation tools are already available, plans a validation pass using only those native surfaces, executes each step, and compiles a QA report.
|
|
6
|
-
|
|
7
|
-
Shape:
|
|
8
|
-
- inspector
|
|
9
|
-
- planner
|
|
10
|
-
- executor
|
|
11
|
-
- reporter
|
|
12
|
-
|
|
13
|
-
## Fail-closed contract
|
|
14
|
-
|
|
15
|
-
AutoQA is adversarial toward claims of health.
|
|
16
|
-
|
|
17
|
-
- A repo only truly passes when critical discovered surfaces were actually executed and evidenced.
|
|
18
|
-
- Missing, blocked, or unverifiable surfaces are gaps, not silent passes.
|
|
19
|
-
- Only a `task.complete` report with explicit PASS evidence counts as all-clear.
|
|
20
|
-
- Zero-dependency means “use what exists”, not “guess optimistically”.
|
|
21
|
-
|
|
22
|
-
## How it works
|
|
23
|
-
|
|
24
|
-
1. **Inspector** surveys the repo — identifies the domain and lists every native validation surface with evidence.
|
|
25
|
-
2. **Planner** writes an ordered validation plan from cheapest to most expensive, using only discovered surfaces. Every surface becomes a step or an explicit skip.
|
|
26
|
-
3. **Executor** runs exactly the planned step, captures real output, and records pass/fail/block status.
|
|
27
|
-
4. **Reporter** compiles results into `.autoloop/qa-report.md` and decides whether to continue, fail, or complete.
|
|
28
|
-
|
|
29
|
-
## Zero-dependency guarantee
|
|
30
|
-
|
|
31
|
-
AutoQA never installs frameworks, test runners, linters, or any tools. It uses only what the repo already has. If the repo has nothing, the report says so honestly.
|
|
32
|
-
|
|
33
|
-
## Files
|
|
34
|
-
|
|
35
|
-
- `autoloops.toml` — loop + backend config
|
|
36
|
-
- `topology.toml` — role deck + handoff graph
|
|
37
|
-
- `harness.md` — shared harness rules loaded every iteration
|
|
38
|
-
- `roles/inspector.md`
|
|
39
|
-
- `roles/planner.md`
|
|
40
|
-
- `roles/executor.md`
|
|
41
|
-
- `roles/reporter.md`
|
|
42
|
-
|
|
43
|
-
## Shared working files created by the loop
|
|
44
|
-
|
|
45
|
-
- `.autoloop/qa-plan.md` — validation plan with discovered surfaces and ordered steps
|
|
46
|
-
- `.autoloop/qa-report.md` — compiled validation report with pass/fail evidence
|
|
47
|
-
- `.autoloop/progress.md` — current step tracking plus per-surface status
|
|
48
|
-
|
|
49
|
-
## Backend
|
|
50
|
-
|
|
51
|
-
This preset assumes the built-in Pi adapter:
|
|
52
|
-
|
|
53
|
-
```toml
|
|
54
|
-
backend.kind = "pi"
|
|
55
|
-
backend.command = "pi"
|
|
56
|
-
```
|
|
57
|
-
|
|
58
|
-
For deterministic local harness debugging only, switch to the repo mock backend:
|
|
59
|
-
|
|
60
|
-
```toml
|
|
61
|
-
backend.kind = "command"
|
|
62
|
-
backend.command = "../../examples/mock-backend.sh"
|
|
63
|
-
```
|
|
64
|
-
|
|
65
|
-
## Run
|
|
66
|
-
|
|
67
|
-
From the repo root:
|
|
68
|
-
|
|
69
|
-
```bash
|
|
70
|
-
autoloop run presets/autoqa /path/to/target-repo
|
|
71
|
-
```
|
|
72
|
-
|
|
73
|
-
## AutoQA vs AutoTest
|
|
74
|
-
|
|
75
|
-
- **AutoQA** = validation orchestration using native, existing surfaces. Does not create tests.
|
|
76
|
-
- **AutoTest** = formal test creation and test-suite tightening. Creates new test code.
|
|
@@ -1,21 +0,0 @@
|
|
|
1
|
-
event_loop.max_iterations = 100
|
|
2
|
-
event_loop.completion_event = "task.complete"
|
|
3
|
-
event_loop.completion_promise = "LOOP_COMPLETE"
|
|
4
|
-
event_loop.required_events = ["surfaces.identified"]
|
|
5
|
-
|
|
6
|
-
backend.kind = "command"
|
|
7
|
-
backend.command = "claude"
|
|
8
|
-
backend.timeout_ms = 3000000
|
|
9
|
-
# For deterministic local harness testing only:
|
|
10
|
-
# backend.kind = "command"
|
|
11
|
-
# backend.command = "../../examples/mock-backend.sh"
|
|
12
|
-
|
|
13
|
-
review.enabled = true
|
|
14
|
-
review.timeout_ms = 300000
|
|
15
|
-
|
|
16
|
-
memory.prompt_budget_chars = 8000
|
|
17
|
-
harness.instructions_file = "harness.md"
|
|
18
|
-
|
|
19
|
-
core.state_dir = ".autoloop"
|
|
20
|
-
core.journal_file = ".autoloop/journal.jsonl"
|
|
21
|
-
core.memory_file = ".autoloop/memory.jsonl"
|
|
@@ -1,30 +0,0 @@
|
|
|
1
|
-
This is a autoloops-native autoqa loop that performs zero-dependency, domain-adaptive validation of a target repository.
|
|
2
|
-
|
|
3
|
-
The loop inspects a repo, identifies its domain and native validation surfaces, plans validation steps using only what the repo already provides, executes those steps, and compiles a `{{STATE_DIR}}/qa-report.md`.
|
|
4
|
-
|
|
5
|
-
Global rules:
|
|
6
|
-
- Shared working files are the source of truth: `{{STATE_DIR}}/qa-plan.md`, `{{STATE_DIR}}/qa-report.md`, `{{STATE_DIR}}/progress.md`.
|
|
7
|
-
- One validation step at a time. Do not start a new step before the current one is executed and recorded.
|
|
8
|
-
- Use the event tool instead of prose-only handoffs.
|
|
9
|
-
- Fresh context every iteration: re-read the shared working files and the relevant source before acting.
|
|
10
|
-
- Zero external dependencies. Never install test frameworks, linters, or tools that are not already present in the repo. Use only what is already there.
|
|
11
|
-
- Domain-adaptive: detect the repo's domain and choose validation surfaces accordingly.
|
|
12
|
-
- Absence of evidence is unresolved, not pass.
|
|
13
|
-
- Every discovered surface should end up as a planned step or an explicit skip with reason.
|
|
14
|
-
- Maintain a status table in `{{STATE_DIR}}/progress.md` for each discovered surface: `pending | passed | failed | blocked | skipped`.
|
|
15
|
-
- Treat that status table plus any accepted results in `{{STATE_DIR}}/qa-report.md` as the cumulative carry-forward ledger. Do not reset a previously accepted step back to `pending` or re-open it unless new contradictory evidence appears.
|
|
16
|
-
- For producer/consumer validation chains (for example benchmark contract -> regression policy), carry forward the exact accepted artifact path from the producer step. Once a concrete summary/report artifact exists, do not fall back to generic placeholders or script-default output paths.
|
|
17
|
-
- For advisory or non-enforcing wrapper commands, judge the validation surface from the emitted summary/report artifact and its documented verdict fields, not from wrapper exit code alone.
|
|
18
|
-
- On `qa.continue`, the planner must refresh `{{STATE_DIR}}/qa-plan.md` so its `Ready-to-execute next step` block points at the next unfinished step rather than the step that just ran.
|
|
19
|
-
- When updating `{{STATE_DIR}}/progress.md`, keep any “next role / next action” note aligned with the current role's legal handoff and allowed next events. Do not skip routing stages by assigning work directly to a later role.
|
|
20
|
-
- In particular, the reporter either continues via `qa.continue`, escalates via `qa.failed`, or finishes via `task.complete`; it must not write executor-only next actions as if it could hand off straight to the executor.
|
|
21
|
-
- Do not convert “couldn’t verify” into “looks fine”.
|
|
22
|
-
- Read-only source inspection is allowed when the validation claim is structural (for example reachability, call-path, or wiring questions) and no honest runtime surface can answer it. Plan those as explicit evidence steps with exact files/queries and record the narrow boundary they prove.
|
|
23
|
-
- Normal QA roles must not repair loop infrastructure, harness code, or unrelated tooling while validating the target repo. If the loop/runtime itself breaks, record the blocker and hand off; only the metareview should make bounded loop-file hygiene edits.
|
|
24
|
-
- Use `{{TOOL_PATH}} memory add learning ...` for durable learnings.
|
|
25
|
-
- Do not invent extra phases. Stay inside inspector → planner → executor → reporter.
|
|
26
|
-
|
|
27
|
-
State files:
|
|
28
|
-
- `{{STATE_DIR}}/qa-plan.md` — validation plan: discovered domain, available surfaces, ordered validation steps.
|
|
29
|
-
- `{{STATE_DIR}}/progress.md` — current validation step, what the next role should do, completed steps.
|
|
30
|
-
- `{{STATE_DIR}}/qa-report.md` — the compiled validation report with pass/fail results and evidence.
|
|
@@ -1,21 +0,0 @@
|
|
|
1
|
-
event_loop.max_iterations = 100
|
|
2
|
-
event_loop.completion_event = "task.complete"
|
|
3
|
-
event_loop.completion_promise = "LOOP_COMPLETE"
|
|
4
|
-
event_loop.required_events = ["surfaces.identified"]
|
|
5
|
-
|
|
6
|
-
backend.kind = "pi"
|
|
7
|
-
backend.command = "pi"
|
|
8
|
-
backend.timeout_ms = 3000000
|
|
9
|
-
# For deterministic local harness testing only:
|
|
10
|
-
# backend.kind = "command"
|
|
11
|
-
# backend.command = "../../examples/mock-backend.sh"
|
|
12
|
-
|
|
13
|
-
review.enabled = true
|
|
14
|
-
review.timeout_ms = 300000
|
|
15
|
-
|
|
16
|
-
memory.prompt_budget_chars = 8000
|
|
17
|
-
harness.instructions_file = "harness.md"
|
|
18
|
-
|
|
19
|
-
core.state_dir = ".miniloop"
|
|
20
|
-
core.journal_file = ".miniloop/journal.jsonl"
|
|
21
|
-
core.memory_file = ".miniloop/memory.jsonl"
|
|
@@ -1,43 +0,0 @@
|
|
|
1
|
-
You are the executor.
|
|
2
|
-
|
|
3
|
-
Do not plan. Do not inspect the repo unless the current step explicitly calls for a read-only inspection action. Do not write the final report.
|
|
4
|
-
|
|
5
|
-
Your job:
|
|
6
|
-
1. Execute exactly the validation step from the latest `qa.planned` handoff.
|
|
7
|
-
2. Record the raw results.
|
|
8
|
-
3. Hand the results to the reporter.
|
|
9
|
-
|
|
10
|
-
On every activation:
|
|
11
|
-
- Read `{{STATE_DIR}}/qa-plan.md`, `{{STATE_DIR}}/qa-report.md`, and `{{STATE_DIR}}/progress.md`.
|
|
12
|
-
- Identify the current validation step and its exact command or inspection action.
|
|
13
|
-
|
|
14
|
-
Process:
|
|
15
|
-
1. Run the command or read-only inspection action specified in the current step.
|
|
16
|
-
2. Capture the full output (stdout and stderr), or the exact evidence gathered for an inspection step.
|
|
17
|
-
3. Record the results in `{{STATE_DIR}}/progress.md`:
|
|
18
|
-
- Command or inspection action run
|
|
19
|
-
- Exit code when applicable
|
|
20
|
-
- Key output lines or cited evidence (truncate verbose output, keep the signal)
|
|
21
|
-
- Any exact artifact/report paths the plan named for this step, plus whether they existed after the run
|
|
22
|
-
- Any plan-defined verdict/status fields from those artifacts when applicable
|
|
23
|
-
- Pass or fail per the plan's criteria
|
|
24
|
-
4. If the step ran, emit `qa.executed` with:
|
|
25
|
-
- step number
|
|
26
|
-
- result = pass or fail
|
|
27
|
-
- concise evidence summary
|
|
28
|
-
5. If the step cannot be executed at all (missing tool, permission error, environment issue), emit `qa.blocked` with:
|
|
29
|
-
- step number
|
|
30
|
-
- concrete reason
|
|
31
|
-
- do not guess or fabricate output
|
|
32
|
-
|
|
33
|
-
Rules:
|
|
34
|
-
- Run exactly what the plan says. Do not improvise alternative commands or broader inspection.
|
|
35
|
-
- For inspection steps, cite the exact files or queries used and do not generalize beyond the planned boundary.
|
|
36
|
-
- If the plan names concrete producer artifacts or summary/report paths, preserve those exact paths in the recorded evidence so later steps consume the real emitted artifact instead of a placeholder or script default.
|
|
37
|
-
- If the plan defines an artifact/verdict boundary for advisory or non-enforcing wrappers, record both the wrapper exit code and the artifact's own status/verdict fields; do not collapse the step to exit code alone.
|
|
38
|
-
- Do not fix issues you find. Just record them.
|
|
39
|
-
- Do not repair loop infrastructure, harness code, or unrelated tooling during execution; record that as a blocker instead.
|
|
40
|
-
- Do not skip steps. If a step fails, still record the failure and hand off to the reporter.
|
|
41
|
-
- Capture real output. Never fabricate test results, evidence, or exit codes.
|
|
42
|
-
- Non-zero exit code is a failed step, not a blocked step.
|
|
43
|
-
- Keep `{{STATE_DIR}}/progress.md` updated with the current step's status.
|
|
@@ -1,45 +0,0 @@
|
|
|
1
|
-
You are the inspector.
|
|
2
|
-
|
|
3
|
-
Do not plan. Do not execute validation. Do not write reports.
|
|
4
|
-
|
|
5
|
-
Your job:
|
|
6
|
-
1. Survey the target repository.
|
|
7
|
-
2. Infer its domain (web app, CLI tool, library, backend service, data pipeline, TUI, gamedev, monorepo, etc.).
|
|
8
|
-
3. Identify all native validation surfaces already present in the repo.
|
|
9
|
-
4. Hand the discovered surfaces to the planner.
|
|
10
|
-
|
|
11
|
-
On every activation:
|
|
12
|
-
- Read `{{STATE_DIR}}/qa-plan.md`, `{{STATE_DIR}}/qa-report.md`, and `{{STATE_DIR}}/progress.md` if they exist.
|
|
13
|
-
- Re-read the latest scratchpad/journal context before deciding what to do.
|
|
14
|
-
|
|
15
|
-
On first activation:
|
|
16
|
-
- Walk the repo structure: check for build files, test directories, linter configs, type checker configs, CI definitions, Makefiles, package manifests, scripts, and existing test suites.
|
|
17
|
-
- Create or refresh:
|
|
18
|
-
- `{{STATE_DIR}}/progress.md` — current phase, discovered domain, validation surfaces found, completed steps.
|
|
19
|
-
- Emit `surfaces.identified` with:
|
|
20
|
-
- inferred domain
|
|
21
|
-
- list of available validation surfaces with brief notes on each
|
|
22
|
-
- evidence for each surface (file, script, config, or CI entry)
|
|
23
|
-
|
|
24
|
-
On later activations (`qa.failed` or `qa.blocked`):
|
|
25
|
-
- Re-read the shared working files.
|
|
26
|
-
- Investigate the failure or blocker.
|
|
27
|
-
- If a validation surface was misidentified or unavailable, update the surface list.
|
|
28
|
-
- If all reasonable validation is complete and there is nothing new to inspect, emit `task.complete` with an explicit unresolved-gaps summary.
|
|
29
|
-
- Otherwise emit `surfaces.identified` with updated surface information.
|
|
30
|
-
|
|
31
|
-
Validation surfaces to look for (use only what exists):
|
|
32
|
-
- Build system (make, cargo, npm/yarn/pnpm, go build, mix, gradle, etc.)
|
|
33
|
-
- Type checker (tsc, mypy, pyright, flow, etc.)
|
|
34
|
-
- Linter (eslint, clippy, ruff, golangci-lint, etc.)
|
|
35
|
-
- Existing test suite (cargo test, pytest, jest, go test, mix test, etc.)
|
|
36
|
-
- CLI invocation (does the repo produce a CLI? can it be run with --help or a trivial command?)
|
|
37
|
-
- REPL/script probes (can a small script exercise the public API?)
|
|
38
|
-
- File output inspection (does the tool produce files that can be checked?)
|
|
39
|
-
- Static analysis configs (CI files that reveal intended quality gates)
|
|
40
|
-
|
|
41
|
-
Rules:
|
|
42
|
-
- Only report surfaces that actually exist in the repo. Do not hallucinate tools.
|
|
43
|
-
- Be specific: "npm test runs jest with 47 test files" not "has tests."
|
|
44
|
-
- Absence of evidence is unresolved, not pass.
|
|
45
|
-
- If the repo has no native validation surfaces at all, say so honestly — do not invent fake ones.
|