@aopslabs/aops 0.3.31 → 0.3.33

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.
Files changed (147) hide show
  1. package/README.md +11 -3
  2. package/aops-assets-release/aops-assets.json.gz +0 -0
  3. package/aops-assets-release/disciplines/build-review-chat/SKILL.md +33 -0
  4. package/aops-assets-release/disciplines/coordinator-loop/SKILL.md +33 -0
  5. package/aops-assets-release/disciplines/design-first-consensus/SKILL.md +30 -0
  6. package/aops-assets-release/disciplines/solo-pm-loop/SKILL.md +31 -0
  7. package/aops-assets-release/docs/user-guides/agentspace-user-guide.md +384 -0
  8. package/aops-assets-release/docs/user-guides/aops-cli-user-guide.md +2067 -0
  9. package/aops-assets-release/docs/user-guides/chatv3-user-guide.md +500 -0
  10. package/aops-assets-release/docs/user-guides/docman-user-guide.md +1009 -0
  11. package/aops-assets-release/docs/user-guides/projectman-user-guide.md +763 -0
  12. package/aops-assets-release/docs/user-guides/tasker-user-guide.md +244 -0
  13. package/aops-assets-release/release.json +6 -0
  14. package/aops-assets-release/roles/coordinator/ROLE.md +28 -0
  15. package/aops-assets-release/roles/implementer/ROLE.md +27 -0
  16. package/aops-assets-release/roles/reviewer/ROLE.md +27 -0
  17. package/aops-assets-release/skills/aops/SKILL.md +112 -0
  18. package/aops-assets-release/skills/aops-bootstrapper-authoring/SKILL.md +245 -0
  19. package/aops-assets-release/skills/aops-cli-agentspace/SKILL.md +186 -0
  20. package/aops-assets-release/skills/aops-cli-board-lifecycle/SKILL.md +64 -0
  21. package/aops-assets-release/skills/aops-cli-chat/SKILL.md +204 -0
  22. package/aops-assets-release/skills/aops-cli-collab/SKILL.md +42 -0
  23. package/aops-assets-release/skills/aops-cli-core/SKILL.md +219 -0
  24. package/aops-assets-release/skills/aops-cli-discuss/SKILL.md +172 -0
  25. package/aops-assets-release/skills/aops-cli-docman/SKILL.md +192 -0
  26. package/aops-assets-release/skills/aops-cli-fileman/SKILL.md +169 -0
  27. package/aops-assets-release/skills/aops-cli-mission/SKILL.md +128 -0
  28. package/aops-assets-release/skills/aops-cli-operator-brief/SKILL.md +67 -0
  29. package/aops-assets-release/skills/aops-cli-projectman/SKILL.md +235 -0
  30. package/aops-assets-release/skills/aops-cli-sugar-authoring/SKILL.md +188 -0
  31. package/aops-assets-release/skills/aops-cli-tasker/SKILL.md +108 -0
  32. package/aops-assets-release/skills/aops-cli-tooling-agent/SKILL.md +112 -0
  33. package/aops-assets-release/skills/aops-cli-view/SKILL.md +210 -0
  34. package/aops-assets-release/skills/aops-collaborative-work/SKILL.md +304 -0
  35. package/aops-assets-release/skills/aops-interactive/SKILL.md +70 -0
  36. package/aops-assets-release/skills/aops-loop-interactive/SKILL.md +314 -0
  37. package/aops-assets-release/skills/aops-working-disciplines/SKILL.md +310 -0
  38. package/aops-assets-release/skills/feature-retirement-flow/SKILL.md +126 -0
  39. package/assets/skills/aops-install/SKILL.md +18 -17
  40. package/dist/commands/assets.js +93 -1264
  41. package/dist/commands/community-server.js +27 -8
  42. package/dist/commands/community-setup.js +1 -2
  43. package/dist/commands/discuss.js +1 -1
  44. package/dist/commands/doc.js +88 -27
  45. package/dist/commands/docs.js +68 -0
  46. package/dist/commands/global-update.js +28 -0
  47. package/dist/commands/init.js +3 -1
  48. package/dist/commands/loop.js +6379 -0
  49. package/dist/commands/memory.js +2 -1
  50. package/dist/commands/pm/index.js +11 -9
  51. package/dist/commands/pm/projectman.js +33 -2
  52. package/dist/commands/project.js +6 -6
  53. package/dist/commands/prompt.js +1 -1
  54. package/dist/commands/repo-sync.js +92 -27
  55. package/dist/commands/runner.js +257 -0
  56. package/dist/commands/skill.js +1 -1
  57. package/dist/commands/start.js +1 -1
  58. package/dist/commands/tasker.js +361 -0
  59. package/dist/commands/view.js +53 -9
  60. package/dist/lib/commercial-setup-readiness-adapter.js +0 -1
  61. package/dist/lib/community-migration-snapshot.js +7 -9
  62. package/dist/lib/community-native-database-recovery.js +5 -14
  63. package/dist/lib/community-native-lifecycle.js +13 -0
  64. package/dist/lib/setup-agent-assets-bridge.js +28 -148
  65. package/dist/lib/setup-agent-assets-release.js +16 -44
  66. package/dist/lib/setup-init-orchestrator.js +11 -15
  67. package/dist/lib/simple-agent-assets.js +447 -0
  68. package/dist/lib/user-guide-sections.js +488 -0
  69. package/dist/main.js +10 -2
  70. package/dist/seeds/agents-md.js +3 -3
  71. package/dist/utils/agents-md.js +1 -1
  72. package/dist/utils/guide-paths.js +7 -7
  73. package/dist/utils/hosted-workspace.js +2 -1
  74. package/dist/utils/repo-first-storage.js +26 -1
  75. package/dist/utils/session-state.js +2 -7
  76. package/launchers/aops-cockpit.sh +0 -0
  77. package/launchers/aops-server.sh +0 -0
  78. package/package.json +67 -35
  79. package/THIRD_PARTY_NOTICES +0 -16169
  80. package/agent-assets-release/agent-assets/core/bc42dd7792dbe66040e99a7ef3d80b3bc788c72b369b5a065cf936aef29f53fb/files/SKILL.md +0 -47
  81. package/agent-assets-release/agent-assets/core/bc42dd7792dbe66040e99a7ef3d80b3bc788c72b369b5a065cf936aef29f53fb/files/references/agentspace/SKILL.md +0 -72
  82. package/agent-assets-release/agent-assets/core/bc42dd7792dbe66040e99a7ef3d80b3bc788c72b369b5a065cf936aef29f53fb/files/references/aops-cli-core/SKILL.md +0 -110
  83. package/agent-assets-release/agent-assets/core/bc42dd7792dbe66040e99a7ef3d80b3bc788c72b369b5a065cf936aef29f53fb/files/references/chatv3/SKILL.md +0 -59
  84. package/agent-assets-release/agent-assets/core/bc42dd7792dbe66040e99a7ef3d80b3bc788c72b369b5a065cf936aef29f53fb/files/references/collaborative-work/SKILL.md +0 -81
  85. package/agent-assets-release/agent-assets/core/bc42dd7792dbe66040e99a7ef3d80b3bc788c72b369b5a065cf936aef29f53fb/files/references/discuss/SKILL.md +0 -66
  86. package/agent-assets-release/agent-assets/core/bc42dd7792dbe66040e99a7ef3d80b3bc788c72b369b5a065cf936aef29f53fb/files/references/docman/SKILL.md +0 -75
  87. package/agent-assets-release/agent-assets/core/bc42dd7792dbe66040e99a7ef3d80b3bc788c72b369b5a065cf936aef29f53fb/files/references/projectman/SKILL.md +0 -92
  88. package/agent-assets-release/agent-assets/core/bc42dd7792dbe66040e99a7ef3d80b3bc788c72b369b5a065cf936aef29f53fb/files/references/sys/SKILL.md +0 -36
  89. package/agent-assets-release/agent-assets/core/bc42dd7792dbe66040e99a7ef3d80b3bc788c72b369b5a065cf936aef29f53fb/files/references/view/SKILL.md +0 -58
  90. package/agent-assets-release/agent-assets/core/bc42dd7792dbe66040e99a7ef3d80b3bc788c72b369b5a065cf936aef29f53fb/files/references/working-disciplines/SKILL.md +0 -66
  91. package/agent-assets-release/agent-assets/core/bc42dd7792dbe66040e99a7ef3d80b3bc788c72b369b5a065cf936aef29f53fb/files/user-guides/agent-assets.md +0 -81
  92. package/agent-assets-release/agent-assets/core/bc42dd7792dbe66040e99a7ef3d80b3bc788c72b369b5a065cf936aef29f53fb/files/user-guides/agentspace.md +0 -183
  93. package/agent-assets-release/agent-assets/core/bc42dd7792dbe66040e99a7ef3d80b3bc788c72b369b5a065cf936aef29f53fb/files/user-guides/aops-cli.md +0 -1108
  94. package/agent-assets-release/agent-assets/core/bc42dd7792dbe66040e99a7ef3d80b3bc788c72b369b5a065cf936aef29f53fb/files/user-guides/aops-system.md +0 -102
  95. package/agent-assets-release/agent-assets/core/bc42dd7792dbe66040e99a7ef3d80b3bc788c72b369b5a065cf936aef29f53fb/files/user-guides/chatv3.md +0 -113
  96. package/agent-assets-release/agent-assets/core/bc42dd7792dbe66040e99a7ef3d80b3bc788c72b369b5a065cf936aef29f53fb/files/user-guides/docman.md +0 -223
  97. package/agent-assets-release/agent-assets/core/bc42dd7792dbe66040e99a7ef3d80b3bc788c72b369b5a065cf936aef29f53fb/files/user-guides/projectman.md +0 -233
  98. package/agent-assets-release/agent-assets/core/bc42dd7792dbe66040e99a7ef3d80b3bc788c72b369b5a065cf936aef29f53fb/files/user-guides/sys.md +0 -94
  99. package/agent-assets-release/agent-assets/core/bc42dd7792dbe66040e99a7ef3d80b3bc788c72b369b5a065cf936aef29f53fb/files/user-guides/working-disciplines.md +0 -482
  100. package/agent-assets-release/agent-assets/core/bc42dd7792dbe66040e99a7ef3d80b3bc788c72b369b5a065cf936aef29f53fb/manifest.json +0 -117
  101. package/agent-assets-release/agent-assets/gateway/aops/SKILL.md +0 -14
  102. package/agent-assets-release/agent-assets/inventory.json +0 -29
  103. package/agent-assets-release/agent-assets/projection.json +0 -8
  104. package/agent-assets-release/agent-assets-release.json +0 -171
  105. package/agent-assets-release/agent-assets-release.sigstore.json +0 -67
  106. package/assets/agent-assets/core/SKILL.md +0 -47
  107. package/assets/agent-assets/core/references/agentspace/SKILL.md +0 -72
  108. package/assets/agent-assets/core/references/aops-cli-core/SKILL.md +0 -110
  109. package/assets/agent-assets/core/references/chatv3/SKILL.md +0 -59
  110. package/assets/agent-assets/core/references/collaborative-work/SKILL.md +0 -81
  111. package/assets/agent-assets/core/references/discuss/SKILL.md +0 -66
  112. package/assets/agent-assets/core/references/docman/SKILL.md +0 -75
  113. package/assets/agent-assets/core/references/projectman/SKILL.md +0 -92
  114. package/assets/agent-assets/core/references/sys/SKILL.md +0 -36
  115. package/assets/agent-assets/core/references/view/SKILL.md +0 -58
  116. package/assets/agent-assets/core/references/working-disciplines/SKILL.md +0 -66
  117. package/assets/agent-assets/core/user-guides/agent-assets.md +0 -81
  118. package/assets/agent-assets/core/user-guides/agentspace.md +0 -183
  119. package/assets/agent-assets/core/user-guides/aops-cli.md +0 -1108
  120. package/assets/agent-assets/core/user-guides/aops-system.md +0 -102
  121. package/assets/agent-assets/core/user-guides/chatv3.md +0 -113
  122. package/assets/agent-assets/core/user-guides/docman.md +0 -223
  123. package/assets/agent-assets/core/user-guides/projectman.md +0 -233
  124. package/assets/agent-assets/core/user-guides/sys.md +0 -94
  125. package/assets/agent-assets/core/user-guides/working-disciplines.md +0 -482
  126. package/assets/agent-assets/gateway/aops/SKILL.md +0 -14
  127. package/dist/lib/agent-assets/gateway.js +0 -15
  128. package/dist/lib/agent-assets/guards.js +0 -23
  129. package/dist/lib/agent-assets/hosted-discovery.js +0 -148
  130. package/dist/lib/agent-assets/hosted-package-input.js +0 -154
  131. package/dist/lib/agent-assets/legacy-pointer-migration.js +0 -677
  132. package/dist/lib/agent-assets/native-fs.js +0 -589
  133. package/dist/lib/agent-assets/roots.js +0 -45
  134. package/dist/lib/agent-assets/runtime-binding-reader.js +0 -545
  135. package/dist/lib/agent-assets/runtime-targets.js +0 -50
  136. package/dist/lib/agent-assets/store-reader.js +0 -1212
  137. package/dist/lib/agent-assets/store-writer.js +0 -1484
  138. package/native/bin/darwin-arm64/aops-agent-assets-fs +0 -0
  139. package/native/bin/darwin-x64/aops-agent-assets-fs +0 -0
  140. package/native/bin/linux-arm64/aops-agent-assets-fs +0 -0
  141. package/native/bin/linux-x64/aops-agent-assets-fs +0 -0
  142. package/native/bin/win32-x64/aops-agent-assets-fs.exe +0 -0
  143. package/native/manifest.json +0 -49
  144. package/native/qualifications/win32-x64.json +0 -23
  145. package/native/tui/darwin-arm64/aops-tui +0 -0
  146. package/native/tui/linux-x64/aops-tui +0 -0
  147. package/native/tui/win32-x64/aops-tui.exe +0 -0
@@ -0,0 +1,314 @@
1
+ ---
2
+ name: aops-loop-interactive
3
+ version: 5
4
+ description: "Operator-facing interactive AOPS loop guide. Use when an operator wants to start, inspect, fan out, resume, or close out the aops-cli loop lifecycle with questions first, dry-run readiness, loop-pack preview, supervised-run double gates, parallel/worktree fan-out (v2), resumable agent sessions and short-lived resume-on-trigger (resume-agent / watch / session-reconcile), hosted-runner-v2 contract evaluation, explicit Runner-backed durable orchestration via --hosted-runner-mode=require-hosted, foreground listening, and Projectman review truth."
5
+ metadata:
6
+ short-description: "Interactive AOPS loop lifecycle guide (v1 + v2 fan-out + resume + Runner delegation)"
7
+ tags:
8
+ - aops
9
+ - interactive
10
+ - loop
11
+ - operator-facing
12
+ - projectman
13
+ - chatv3
14
+ - review-request
15
+ - runner
16
+ - worktree
17
+ - fan-out
18
+ - resume
19
+ - watch
20
+ - hosted-runner-v2
21
+ ---
22
+
23
+ # AOPS Loop Interactive
24
+
25
+ Use this skill when the operator wants an interactive, question-first guide for the `aops-cli loop`
26
+ lifecycle. This skill is a playbook only: it does not create a second state store, decision ledger,
27
+ chat ledger, or review system.
28
+
29
+ Canonical command details come from `aops-cli loop --help` and the nested
30
+ `aops-cli loop plan|pack|start|resume-agent|watch|session-reconcile|stop|resume|listen|status|parallel-plan|worktree-init|maker-run|slice-merge|cleanup|runner-eval --help`
31
+ surfaces. If this skill and CLI help disagree, CLI help wins. For a full prose walkthrough, point the
32
+ operator at the hosted Docman guide `aops-guides/aops-loop-user-guide` (read-only mirror at `.aops/docman/aops-guides/aops-loop-user-guide.md`).
33
+
34
+ ## Placement
35
+
36
+ This is the dedicated loop orchestration skill. `aops-interactive` may route here when the operator
37
+ asks for loop engineering, loop orchestration, supervised child-agent runs, parallel/worktree
38
+ fan-out, hosted runner evaluation, Runner-backed durable orchestration, foreground loop listening, or loop closeout.
39
+
40
+ ## First Ask
41
+
42
+ Ask the operator concise questions before running commands. Use the runtime question UI when
43
+ available; otherwise ask plain text and wait only for answers that are required.
44
+
45
+ Required questions:
46
+
47
+ 1. What PM surface anchors this loop? Ask for task id, sprint id, and any existing review-request id.
48
+ 2. What is the scope and DONE-WHEN? Ask for repeatable acceptance criteria and files or domains in scope.
49
+ 3. Who reviews? Ask for reviewer agent/operator and whether a PM review-request already exists.
50
+ 4. What is the budget? Ask for max iterations, timeout minutes, and any cost/usage ceiling.
51
+ 5. What tool/env policy applies? Ask whether this is dry-run only, supervised single child, or explicit real run — and for v2, whether parallel/worktree fan-out is intended.
52
+ 6. What permission policy applies? Ask whether edits, tests, network, and approvals are allowed.
53
+
54
+ Do not auto-assign roles from agent names. Roles are operator-owned.
55
+
56
+ ## Readiness Gate
57
+
58
+ Run `loop plan` first. Keep it dry-run unless the operator explicitly requests otherwise.
59
+
60
+ ```bash
61
+ aops-cli loop plan --task <task-id> --plan <sprint-id> \
62
+ --reviewer <reviewer-id> \
63
+ --max-iterations <n> --timeout-min <minutes> \
64
+ --json
65
+ ```
66
+
67
+ Read the JSON, not prose. If readiness fails, show the failed checks and fixes, then stop or help the
68
+ operator resolve the missing inputs. Do not proceed to `loop pack` or `loop start` while required
69
+ readiness gates are failing.
70
+
71
+ The readiness questions must stay aligned with the loop facade gates:
72
+
73
+ - repeatable task and acceptance criteria
74
+ - reviewer or review-request evidence
75
+ - bounded budget and timeout
76
+ - tool/env capability
77
+ - permission policy
78
+ - adapter maturity and explicit real-run approval state
79
+
80
+ ## Loop Pack Preview
81
+
82
+ After readiness passes, compose the loop pack:
83
+
84
+ ```bash
85
+ aops-cli loop pack --task <task-id> --plan <sprint-id> \
86
+ --reviewer <reviewer-id> \
87
+ --chat-session <chatv3-session> --room <room-slug> \
88
+ --after-seq <seq> \
89
+ --json
90
+ ```
91
+
92
+ Show the operator the important refs and prompts: PM task/sprint/review-request refs; ChatV3
93
+ session/room/cursor refs; discuss topic or mission refs; source hierarchy and source prompt refs;
94
+ maker (implementer) and checker (reviewer) role prompt refs; budget and run mode; the foreground
95
+ listener contract.
96
+
97
+ Do not persist pack output in a new owner store. If a durable handoff is needed, write Projectman
98
+ notes or Agentspace memory with source refs.
99
+
100
+ ## Owner Boundaries
101
+
102
+ Repeat these boundaries before handoff:
103
+
104
+ - Projectman owns planning, implementation truth, review-requests, review results, issues, and closeout records.
105
+ - `aops-cli discuss` owns material decisions and final consensus outputs.
106
+ - ChatV3 owns coordination, wake messages, room refs, and cursors only.
107
+ - Agentspace memory owns durable handoff/checkpoint context.
108
+ - `aops-cli loop` is a facade over those surfaces; it is not their owner.
109
+ - Runner / Tasker owns durable run records, worker leases, heartbeats, expiry/reclaim, retries/backoff, cancel/resume/reconcile state, and ingress when `--hosted-runner-mode=require-hosted` is explicitly used.
110
+ - Hosted skills/prompts are canonical in the server; local hosted mirrors are read-only and must not be hand-edited as truth.
111
+
112
+ ## Start Handoff (single child)
113
+
114
+ Prefer a dry-run handoff first:
115
+
116
+ ```bash
117
+ aops-cli loop start --task <task-id> --plan <sprint-id> \
118
+ --reviewer <reviewer-id> \
119
+ --max-iterations <n> --timeout-min <minutes> \
120
+ --json
121
+ ```
122
+
123
+ For a real supervised run, require the operator to approve both gates in the same explicit instruction:
124
+
125
+ ```bash
126
+ aops-cli loop start --task <task-id> --plan <sprint-id> \
127
+ --reviewer <reviewer-id> \
128
+ --run-agents --supervised-run-approved \
129
+ --max-iterations <n> --timeout-min <minutes> \
130
+ --json
131
+ ```
132
+
133
+ The double gate is mandatory:
134
+
135
+ - `--run-agents` says a real child-agent run is allowed.
136
+ - `--supervised-run-approved` says the operator approved the supervised single-child discipline.
137
+
138
+ Do not infer either gate from enthusiasm, a prior plan approval, or a chat acknowledgement. Permission
139
+ bypass, destructive cleanup, final merge, and review acceptance remain operator/local or Projectman
140
+ controlled.
141
+
142
+ ## Foreground Listening
143
+
144
+ When a run, review, or peer turn is pending, keep a foreground loop:
145
+
146
+ 1. ChatV3 listen/read for operator or peer messages.
147
+ 2. discuss wait/status when a decision topic is active.
148
+ 3. PM review-request get/result status.
149
+ 4. child adapter stream status when a child run exists.
150
+ 5. `aops-cli loop status` for operator-readable cockpit output.
151
+
152
+ Timeouts are not completion:
153
+
154
+ - ChatV3 timeout or no message means re-poll.
155
+ - discuss exit `22` means re-poll.
156
+ - PM review-request `approved` or `changes_requested` is a review event, not a chat decision.
157
+ - Operator-addressed blocks stop the loop and return to the operator.
158
+
159
+ ## Resume and resume-on-trigger (R0-R3)
160
+
161
+ A resumed agent picks up an existing session instead of cold-starting. Use this when re-tasking a
162
+ waiting agent, or when an agent that cannot background-listen (e.g. Codex) must be driven by an
163
+ external orchestrator.
164
+
165
+ Capture a resumable session (default OFF preserves the single-shot ephemeral behavior):
166
+
167
+ ```bash
168
+ aops-cli loop start --plan <sprint-id> --reviewer <agent> \
169
+ --child-agent codex --session-persist \
170
+ --run-agents --supervised-run-approved --json
171
+ ```
172
+
173
+ Read `result.start.childRun.sessionRef.sessionId`, then resume that session with a new directive
174
+ (double-gated, like start):
175
+
176
+ ```bash
177
+ aops-cli loop resume-agent --session-id <id> --session-agent codex \
178
+ --directive "check the room and continue" \
179
+ --run-agents --supervised-run-approved --json
180
+ # or, when the id was not captured, resume the most recent session:
181
+ aops-cli loop resume-agent --resume-last --session-agent codex --directive "..." --run-agents --supervised-run-approved --json
182
+ ```
183
+
184
+ Short-lived resume-on-trigger. `loop watch` does ONE poll of the configured sources and, on a
185
+ qualifying trigger, delegates to `resume-agent`, then EXITS. It is stateless and externally re-armed
186
+ (operator / scheduler / Runner) - never a daemon:
187
+
188
+ ```bash
189
+ aops-cli loop watch --chat-session <session> --chat-room <room> --after-seq <n> \
190
+ --watch-ignore <orchestrator-member-id> --watch-ignore <agent-member-id> \
191
+ --resume-last --session-agent codex \
192
+ --run-agents --supervised-run-approved --json
193
+ ```
194
+
195
+ `--watch-ignore` is REQUIRED to enable ChatV3 auto-trigger: it lists the orchestrator's and the
196
+ resumed agent's own sender ids so the watch never self-triggers on its own output (de-dupe is by
197
+ senderMemberId). Without it the watch skips ChatV3 (safe default). `--directive` is an operator
198
+ override that forces a trigger.
199
+
200
+ Session lifecycle, brakes, and reconcile:
201
+
202
+ ```bash
203
+ aops-cli loop session-reconcile --session-id <id> --session-agent codex --iteration <n> --max-iterations <n> --json
204
+ ```
205
+
206
+ States are active/idle/waiting/stale/closed. Brakes (resume-count vs max-iterations, cost vs budget)
207
+ block a braked resume before it runs. A resumed session never merges, spawns nested agents, or writes
208
+ canonical ledgers. Crash/stale reconcile maps to the runner v2 reconcile-state contract and never
209
+ replays guarded writes.
210
+
211
+ Runner-backed durable orchestration (V2-final): the default mode remains local/stateless
212
+ `--hosted-runner-mode=defer`. When the operator or orchestrator explicitly sets
213
+ `--hosted-runner-mode=require-hosted`, `watch`, `stop`, `resume`, and `session-reconcile` delegate
214
+ durable intent to the hosted loop-runner-v2 surfaces and return `result.runnerDelegation` evidence.
215
+ The current hosted tool ids are `tasker.loop-runner-v2.event.record`,
216
+ `tasker.loop-runner-v2.status.get`, `tasker.loop-runner-v2.control.stop`,
217
+ `tasker.loop-runner-v2.control.resume`, and `tasker.loop-runner-v2.control.reconcile`.
218
+
219
+ Use the opt-in mode only when hosted Runner surfaces are expected to own durable state:
220
+
221
+ ```bash
222
+ aops-cli loop watch --hosted-runner-mode=require-hosted \
223
+ --chat-session <session> --chat-room <room> --after-seq <seq> \
224
+ --watch-ignore <orchestrator-member-id> --watch-ignore <agent-member-id> \
225
+ --resume-last --session-agent codex \
226
+ --run-agents --supervised-run-approved --json
227
+
228
+ aops-cli loop stop --hosted-runner-mode=require-hosted --run-id <run-id> --json
229
+ aops-cli loop resume --hosted-runner-mode=require-hosted --run-id <run-id> --json
230
+ aops-cli loop session-reconcile --hosted-runner-mode=require-hosted --run-id <run-id> --json
231
+ ```
232
+
233
+ Runtime ownership (concluded consensus): the loop facade ships ONLY the short-lived driver. It does
234
+ not own durable worker leases, heartbeats, retry/backoff, expiry/reclaim, ingress, or reconcile state;
235
+ Runner owns those through the hosted-runner-v2 contracts. The facade must never grow a long-running
236
+ stateful watcher or mutate worker leases directly.
237
+
238
+ ## Parallel / Worktree Fan-out (v2)
239
+
240
+ When a sprint is sliced and the operator wants real parallelism, the v2 surfaces fan the work out
241
+ across **isolated git worktrees**, one maker per slice, with operator-gated merges. Each step is
242
+ explicitly gated — never chain them without the gate.
243
+
244
+ ```
245
+ parallel-plan -> worktree-init -> maker-run -> [independent review] -> slice-merge -> cleanup
246
+ ```
247
+
248
+ 1. `loop parallel-plan` — fan-out gate plan only (no worktrees/agents). Requires prior single-child
249
+ acceptance evidence (`--f5-evidence`) and explicit `--slice` boundaries.
250
+ 2. `loop worktree-init --parallel-worktrees-approved` — materialize isolated worktrees on slice
251
+ branches. No agents, no merges.
252
+ 3. Open one **full-UUID** PM review-request per slice **before** the maker runs.
253
+ 4. `loop maker-run --run-agents --supervised-run-approved` — at most one supervised maker in one slice
254
+ worktree. No nested spawn, no merge, no canonical ledger writes.
255
+ 5. An **independent** reviewer (maker != checker) verifies each slice in-code and records the PM
256
+ result. A fallback/local self-review is advisory-only, never acceptance-grade.
257
+ 6. `loop slice-merge --review-accepted --merge-approved` — merge one accepted slice **ff-only**, only
258
+ after the RR is accepted **and** the operator approves the merge. One slice at a time.
259
+ 7. `loop cleanup` — report-only; surfaces stale worker/worktree/artifact candidates and deletes
260
+ nothing. Disposable-worktree deletion stays operator/local.
261
+
262
+ Practical notes:
263
+
264
+ - If the launch parent is dirty with unrelated work, run the fan-out from a **clean disposable
265
+ parent** (clone/worktree from committed HEAD) so clean-parent gates pass without touching the
266
+ operator's changes.
267
+ - Sequential ff-only merges require the next slice to descend from the previous merge result —
268
+ **rebase to linearize**, never fall back to `--no-ff`.
269
+
270
+ ## Hosted Runner v2 Evaluation
271
+
272
+ `aops-cli loop runner-eval` evaluates hosted runner/worker v2 boundaries and gaps without hosted
273
+ mutation. The hosted runner contract (records run/slice/worker-lease/event/artifact/cancel/reconcile,
274
+ plus event/artifact/status surfaces and operator stop/resume/cancel/reconcile controls) is defined in
275
+ `domains/tasker/tasker-kit`. Its invariants are enforced in-schema: operator-only controls,
276
+ `cancel.state=requested`, `replaysCanonicalWrites=false`, `secretMaterialStored=false`,
277
+ `requiresOperatorMerge=true`, idempotency keys, and source-tagged cost.
278
+
279
+ V2-final CLI wiring does not make `runner-eval` a daemon. It adds explicit `--hosted-runner-mode`
280
+ delegation on loop commands: `defer` keeps the facade local/stateless; `require-hosted` calls hosted
281
+ loop-runner-v2 event/status/control surfaces and returns `runnerDelegation` evidence. Hosted Runner,
282
+ not the loop facade, owns durable execution state; merge approval and secrets stay operator/local.
283
+
284
+ ## Review And Closeout
285
+
286
+ Before closeout, ensure:
287
+
288
+ - A PM review-request exists for each implementation or skill/content change.
289
+ - The reviewer records a PM review result (independent of the maker).
290
+ - validation evidence is named: tests, schema/help checks, sync/pointer checks, or smoke commands —
291
+ re-run anywhere a sandbox blocked a check rather than accepting on prose.
292
+ - Agentspace memory gets a concise checkpoint when the result is durable, and a comprehension digest
293
+ records what was and was not proven.
294
+ - ChatV3 gets only a short status/wake with refs, not the full decision ledger.
295
+
296
+ Board, sprint, room, and mission closeout remain operator-controlled. Do not close them autonomously.
297
+
298
+ ## Anti-Patterns
299
+
300
+ - Starting a real run after only one of the two real-run gates is present.
301
+ - Inferring approval from a chat acknowledgement.
302
+ - Treating ChatV3 as PM truth or a decision ledger.
303
+ - Treating `aops-cli loop` as a new owner store.
304
+ - Skipping `loop plan` because the operator already described the task.
305
+ - Proceeding after failed readiness checks without recording the override.
306
+ - Spawning more than one maker per slice, or letting a maker spawn nested agents, merge, or write canonical ledgers.
307
+ - Merging a slice before its PM review-request is accepted and the operator has approved the merge.
308
+ - Accepting a slice on a fallback/local self-review (advisory-only is not acceptance-grade).
309
+ - Falling back to `--no-ff` for sequential merges instead of rebasing to linearize.
310
+ - Enabling `loop watch` ChatV3 auto-trigger without `--watch-ignore` (risks self-triggering on the agent's or orchestrator's own output).
311
+ - Turning `loop watch` into a long-running daemon instead of a short-lived poll-once driver re-armed externally; durable orchestration belongs to Runner.
312
+ - Treating `--hosted-runner-mode=require-hosted` as permission for the facade to own worker leases, heartbeats, retry/backoff, or ingress instead of delegating to Runner.
313
+ - Resuming past the resume-count / budget brakes, or letting a resumed session merge / spawn nested agents / write canonical ledgers.
314
+ - Hand-editing local hosted mirrors instead of publishing hosted skill versions.
@@ -0,0 +1,310 @@
1
+ ---
2
+ name: aops-working-disciplines
3
+ version: 9
4
+ description: "Use when an AOPS operator or agent needs to choose or apply an AOPS working discipline: solo-pm-loop, build-review-chat, design-first-consensus, or coordinator-loop; bridge start mode/method vocabulary to mission.policy, Projectman review requests, issues, memory cadence, discuss consensus, verify-first consensus-to-build, consensus-to-plan binding, ChatV3 coordination, coordinator-delegated sessions, and explicit closeout."
5
+ metadata:
6
+ short-description: "AOPS working discipline selection and execution guide"
7
+ tags:
8
+ - aops
9
+ - discipline
10
+ - mission
11
+ - start
12
+ - projectman
13
+ - review-request
14
+ - chat
15
+ - discuss
16
+ - memory
17
+ - closeout
18
+ - coordinator
19
+ ---
20
+
21
+ # AOPS Working Disciplines
22
+
23
+ Use this skill when the task is about selecting or applying an AOPS working
24
+ discipline, interpreting `aops-cli start` output, seeding `mission.policy`, or
25
+ keeping PM/chat/discuss/memory/closeout behavior aligned with the approved discipline.
26
+
27
+ If this skill conflicts with `aops-cli start --help`, `aops-cli mission --help`,
28
+ or the Docman guide "AOPS Working Disciplines", those sources win.
29
+
30
+ ## Load order
31
+
32
+ 1. Run `aops-cli start --help` for live flags.
33
+ 2. Read the Docman guide:
34
+
35
+ ```bash
36
+ aops-cli doc scope search --project-slug aops --q "AOPS Working Disciplines" --local --json
37
+ ```
38
+
39
+ 3. For implementation details in the aops repo, inspect
40
+ `apps/aops-cli/src/commands/start-disciplines.ts`.
41
+ 4. Use `aops-collaborative-work` for session-level startup and chat-room flow.
42
+ 5. Use `aops-cli-projectman` for review-request/result, issue, sprint, and
43
+ microtask mechanics.
44
+ 6. Use `aops-cli-mission` for hosted mission create/update/resume mechanics.
45
+ 7. Use `aops-cli start --reminder --task "<current task>" --area <area> --json` when a running session needs a bounded rules/playbook/experience refresh.
46
+
47
+ ## Vocabulary
48
+
49
+ - `mode` is transport/session shape: `solo`, `solo+async-review`, `chat-room`.
50
+ - `discipline` is the policy preset plus guardrails.
51
+ - `method` is a compatibility alias for `discipline` in `aops-cli start`.
52
+
53
+ Canonical disciplines:
54
+
55
+ | Discipline | Use when | Review pattern |
56
+ | --- | --- | --- |
57
+ | `solo-pm-loop` | one agent, low or medium uncertainty | optional or async RR |
58
+ | `build-review-chat` | live implementer/reviewer, chat wake | RR per slice, RRR before commit |
59
+ | `design-first-consensus` | high design uncertainty | discuss final stances before implementation |
60
+ | `coordinator-loop` | operator delegates the session to one coordinator agent that directs implementer agents | RR per slice reviewed by the coordinator; commit on coordinator instruction |
61
+
62
+ ## Quick selection
63
+
64
+ Use `design-first-consensus` when design uncertainty is high or the decision is
65
+ expensive to reverse.
66
+
67
+ Use `coordinator-loop` when the operator wants a single agent as their only
68
+ interface and delegates task definition, assignment, and review authority to it
69
+ (free-form multi-task sessions with one or more implementers).
70
+
71
+ Use `build-review-chat` when `--mode chat-room`, `agentCount > 1`, or the
72
+ operator asks for live RRR between peer agents.
73
+
74
+ Use `solo-pm-loop` for single-agent or low-uncertainty work. "fast fix" is not a
75
+ separate discipline; it is a small `solo-pm-loop` profile.
76
+
77
+ Operator override:
78
+
79
+ ```bash
80
+ aops-cli start --mode solo --board <board> --discipline build-review-chat --json
81
+ aops-cli start --mode chat-room --board <board> --discipline coordinator-loop --json
82
+ ```
83
+
84
+ ## Verify-first consensus-to-build
85
+
86
+ `verify-first consensus-to-build` is a composite recipe, not a fifth discipline.
87
+ Use it when an operator reports an AOPS/project improvement issue in a room and
88
+ wants two active roles to verify the problem before deciding whether a formal
89
+ discuss topic is needed.
90
+
91
+ The verify-first stance is short and role-agnostic. Before formal discuss or
92
+ implementation, each active role records:
93
+
94
+ - whether the reported problem appears real
95
+ - which truth source was checked, such as PM, code, docs, logs, or readback
96
+ - whether formal consensus is needed
97
+ - the suspected risk or scope
98
+
99
+ If both stances say the work is low-uncertainty or atomic, the team may skip
100
+ standalone discuss and continue through `solo-pm-loop` or `build-review-chat`
101
+ with Projectman truth. If either stance flags material design uncertainty, a
102
+ cross-owner change, or an expensive-to-reverse decision, open standalone discuss
103
+ and follow the full final-stance/conclude ritual before implementation.
104
+
105
+ ## Role and plan-binding policy
106
+
107
+ Working disciplines are role-agnostic. Use role names such as `implementer`, `reviewer`, `coordinator`, and `operator-approver` in reusable docs and skills. Concrete agent-to-role assignment belongs in mission-specific `mission.policy.roles`; do not hard-code runtime names into the reusable discipline.
108
+
109
+ `coordinator` is the canonical role id for the delegated session manager;
110
+ `master` and `operator-agent` are discouraged aliases (they collide with or
111
+ shadow the human `operator` role).
112
+
113
+ When material consensus exists, use a consensus-to-plan binding gate:
114
+
115
+ 1. Discuss owns final stances and concluded consensus outputs.
116
+ 2. The implementer or reviewer proactively asks whether the consensus should become a Projectman implementation plan.
117
+ 3. After operator approval, carry the consensus ref into a PM task and sprint-backed implementation plan.
118
+ 4. Execution waits until the reviewer accepts the plan approval review request.
119
+ 5. `design-first-consensus` requires this gate before implementation; `build-review-chat` and `coordinator-loop` apply it when a material consensus appears during live build/review work.
120
+
121
+ ## Mission policy
122
+
123
+ `aops-cli start --json` emits `result.mission.policyJson`. Use that string as
124
+ the seed for hosted mission policy:
125
+
126
+ ```bash
127
+ aops-cli mission create --objective "<objective>" --policy-json '<result.mission.policyJson>' --apply --json
128
+ aops-cli mission update --id <mission-id> --policy-json '<result.mission.policyJson>' --apply --json
129
+ ```
130
+
131
+ Mission policy stays free-form. The convention includes:
132
+
133
+ - `discipline{id,version,enforcement,selectedBy,signals}`
134
+ - `signalMapping`
135
+ - `guardrails[]`
136
+ - `guardrailGroups{execution,closeout}`
137
+ - `closeout`
138
+ - `review`
139
+ - `issue`
140
+ - `memory`
141
+ - `plan`
142
+ - `planning`
143
+ - `orchestration`
144
+ - `vocabBridge`
145
+
146
+ `signalMapping`, `planning`, and `orchestration` are emitted by current
147
+ `aops-cli start` seeds to explain why a discipline was chosen and how the
148
+ recommended PM/chat/review surfaces should be wired. Treat the convention as a
149
+ stable advisory shape, not a strict schema.
150
+
151
+ A `coordinator-loop` mission binds `roles.operator`, `roles.coordinator`, and
152
+ one or more `roles.implementer` entries; `roles.reviewer` defaults to the
153
+ coordinator when absent.
154
+
155
+ ## Session guidance and reminders
156
+
157
+ The active discipline should also surface through `result.sessionGuidance`:
158
+
159
+ - runtime/rule pointers stay short: AGENTS.md, ChatV3 room rules, and command refs
160
+ - discipline guardrails are listed as ids, titles, phase, enforcement, and evidence summary
161
+ - accepted playbook briefs and ranked experience briefs are consulted before implementation, phase transitions, RR/RRR, and resume
162
+ - `aops-cli start --reminder --task "<current task>" --area <area> --limit 3 --json` refreshes this pack mid-session without creating tasks, writing memory, or serializing the full starter prompt
163
+
164
+ Do not treat playbooks as another discipline enum. A discipline selects the work rhythm; playbooks and experience are evidence/technique briefs that help the agent execute that rhythm without bulk-loading docs.
165
+
166
+ ## Guardrails
167
+
168
+ Use the published guardrail registry from the Docman guide. Guardrails are grouped by `phase`: `execution` while work is happening, and `closeout` before leaving or handing off. Empty `evidence`
169
+ means reviewer-attested and not auto-checkable by the later `mission check`.
170
+
171
+ Always preserve these boundaries:
172
+
173
+ - PM owns task, sprint, issue, review request, and RRR truth.
174
+ - Discuss owns material consensus and final stances.
175
+ - Consensus-to-plan binding carries approved decisions into PM before implementation.
176
+ - Memory owns durable carry-forward context.
177
+ - ChatV3 is coordination and wake only.
178
+ - Hosted and Docman mirrors are read-only; change canonical truth through
179
+ `aops-cli skill ...` or `aops-cli doc ...` commands.
180
+
181
+ `coordinator-loop` adds four execution guardrails:
182
+
183
+ - `coordinator-independent-research`: the coordinator verifies scope in code/PM/docs before assigning work.
184
+ - `single-operator-interface`: implementers route questions/decisions to the coordinator, never directly to the operator; the coordinator escalates only operator-owned decisions.
185
+ - `assignment-via-canonical-refs`: assignments carry mission/ktask/plan refs; chat prose alone is not an assignment.
186
+ - `idle-window-improvement`: the coordinator uses implementer work windows for doc/skill/tooling improvements and files findings as PM issues/feedback.
187
+
188
+ ## Closeout
189
+
190
+ Closeout is explicit before leaving a mission/session. It is not automatic board
191
+ closeout and it is not leaving a ChatV3 room; those lifecycle actions stay
192
+ operator-only unless explicitly delegated.
193
+
194
+ All disciplines close with the base checklist:
195
+
196
+ - write handoff/resume memory with next action, validation state, and refs
197
+ - triage open review requests as accepted, follow-up issue, or deferred with owner
198
+ - triage open issues as resolved, follow-up work, or deferred with owner
199
+ - leave mission status truthful: active, handoff, completed, blocked, or deferred
200
+ - prove resume readiness from PM, memory, review, issue, and next-action refs
201
+ - record a concise session summary
202
+
203
+ Discipline-specific additions:
204
+
205
+ - `solo-pm-loop`: async review is accepted or deferred with owner before handoff.
206
+ - `build-review-chat`: every slice RR is accounted for, and accepted commits record hash, pathspec, and validation evidence.
207
+ - `design-first-consensus`: final stances/output are finalized, and the decision ref is carried into PM task/sprint-backed implementation plan/issue/feedback before implementation resumes; plan approval review is accepted or explicitly deferred with owner.
208
+ - `coordinator-loop`: `build-review-chat` items plus a truthful assignment queue — every operator request is bound to mission/ktask/plan records, completed, or explicitly deferred with owner; coordinator improvement findings are filed as issues/feedback.
209
+
210
+ Later command hints:
211
+
212
+ ```bash
213
+ aops-cli mission check --closeout --id <mission-id> --json
214
+ aops-cli mission handoff --id <mission-id> [--complete] --apply --json
215
+ ```
216
+
217
+ Until those helpers exist, enforce closeout through PM/RR state, memory,
218
+ review, chat wake refs, and honest handoff notes. Valid closeout states include
219
+ `present`, `missing`, `deferred-with-owner`, `not-applicable`, and
220
+ `waived-by-operator`.
221
+
222
+ ## build-review-chat recipe
223
+
224
+ When a live build/review slice depends on a material consensus, bind that consensus to the PM task/sprint before implementation continues. Keep the reusable recipe role-agnostic: mission policy decides which concrete agent is implementer or reviewer.
225
+
226
+ For verify-first consensus-to-build, the room gets a short initial stance from each active role before formal discuss or implementation. The stance answers whether the issue is real, which truth source was checked, whether consensus is needed, and what risk/scope is suspected. The longer phase-to-command checklist belongs in the accepted playbook and `aops-collaborative-work`; this skill owns the rhythm and guardrail.
227
+
228
+ For every implementation slice:
229
+
230
+ ```bash
231
+ aops-cli pm review-request create --task <task-id> --sprint <sprint-id> \
232
+ --review-scope "sprint:<plan-id>" --requested-by <agent> \
233
+ --target-agent <reviewer> --apply --json
234
+
235
+ aops-cli chatv3 send --session <session> --room general \
236
+ --text "REVIEW READY: PM RR <id> ..." --json
237
+ ```
238
+
239
+ Use `sprint:<plan-id>` as the default review scope for sprint-backed slices,
240
+ matching `aops-cli start` deferred bindings. `aops-cli pm review-request create
241
+ --help` also accepts `files:<glob>` for explicit file-only reviews. For mixed
242
+ slices, keep the sprint scope and list exact files in references/instructions
243
+ unless the reviewer asks for a file-only RR.
244
+
245
+ Do not commit until RRR is accepted. Use explicit pathspec and include only the
246
+ reviewed files.
247
+
248
+ ## coordinator-loop recipe
249
+
250
+ Rhythm: operator request -> coordinator independent research (code, PM, docs)
251
+ -> mission/ktask/plan authoring -> chat assignment with canonical refs ->
252
+ implementer slices with RRs -> coordinator review and fix loop -> instructed
253
+ pathspec commit -> next task or idle-window improvement work.
254
+
255
+ Coordinator setup once per session:
256
+
257
+ ```bash
258
+ aops-cli mission create --objective "<program>" \
259
+ --policy-json '{"discipline":"coordinator-loop","roles":{"operator":"<name>","coordinator":"<agent>","implementer":"<agent>"}}' \
260
+ --apply --json
261
+ ```
262
+
263
+ Per task: `pm ktask create` + `plan create --task` + `mission update
264
+ --active-plan`, then a chat assignment message that carries the mission/ktask/
265
+ plan ids and names any binding policy documents (for example a UI system doc)
266
+ the implementer must re-read as a policy check.
267
+
268
+ Per slice: the implementer opens an RR targeting the coordinator; the
269
+ coordinator reviews with code/runtime verification (never status text alone),
270
+ requests fixes until accepted, then instructs the commit with explicit
271
+ pathspec.
272
+
273
+ Free-form session rules:
274
+
275
+ - multiple independent tasks may be active; each has its own ktask/plan; the
276
+ mission anchors the session
277
+ - atomic fixes may run as a single RR without a plan; multi-slice work gets a
278
+ sprint-backed plan
279
+ - material design uncertainty inside a task: coordinator runs a bounded peer
280
+ deliberation with the implementer (about two turns); converged paths are
281
+ proposed to the operator only when the decision is operator-owned; otherwise
282
+ the coordinator decides and records it
283
+ - implementers never page the operator; the coordinator is the single
284
+ interface
285
+
286
+ ## design-first-consensus recipe
287
+
288
+ Run standalone discuss for material design choices. Do not implement until final
289
+ stances and the required operator approval are recorded.
290
+
291
+ After conclusion, the consensus-to-plan binding gate is required before execution:
292
+
293
+ - finalized consensus outputs must have no `_TBD_` placeholders
294
+ - the approved consensus ref must be carried into a PM task and sprint-backed implementation plan
295
+ - the plan should use operator-readable `NE / NICIN / DONE-WHEN` language
296
+ - a reviewer accepts the plan approval review request before implementation begins
297
+ - concrete agent names stay in `mission.policy.roles`, not in reusable discipline text
298
+
299
+ ```bash
300
+ aops-cli discuss turn --topic <topic> --agent <agent> --kind final-stance --apply --json
301
+ ```
302
+
303
+ No final stances means no conclusion. No `_TBD_` placeholders in concluded
304
+ outputs.
305
+
306
+ ## Later
307
+
308
+ `aops-cli mission check --closeout` is intentionally later. Until it exists,
309
+ guardrails are advisory and enforced by start output, PM/RR discipline, review,
310
+ memory, and explicit closeout notes.