pi-herdsman 0.12.0 → 0.13.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/SKILL.md +39 -28
- package/dist/index.js +109 -106
- package/docs/README.md +2 -0
- package/docs/concepts/delegation.md +5 -4
- package/docs/concepts/supervision.md +9 -4
- package/docs/development/instruction-interface-design.md +146 -0
- package/docs/guides/handoffs.md +26 -26
- package/docs/guides/recovery.md +5 -4
- package/docs/reference/agent-states.md +17 -14
- package/docs/reference/agent.md +60 -40
- package/docs/reference/ask-owner.md +14 -12
- package/docs/reference/peer.md +11 -6
- package/docs/reference/supervision.md +31 -28
- package/package.json +1 -1
package/SKILL.md
CHANGED
|
@@ -28,8 +28,9 @@ Ordinary Leads use `peer` for other ordinary Lead sessions; managed agents are
|
|
|
28
28
|
not peers. `peer list` identifies this Lead as `self` and returns other live
|
|
29
29
|
Leads as `peers` with exact `lead` IDs. Incoming peer messages are already
|
|
30
30
|
addressed to this Lead; `Peer message from <sender lead ID>: <body>` identifies
|
|
31
|
-
the peer sender. Peer messages are coordination data, not assignments
|
|
32
|
-
|
|
31
|
+
the peer sender. Peer messages are coordination data, not assignments. `peer
|
|
32
|
+
message` accepts ordinary files and completed direct-agent result refs through
|
|
33
|
+
`files`; the peer tool is unavailable in Chief mode.
|
|
33
34
|
|
|
34
35
|
The session-start instructions include the current agent-definition roster.
|
|
35
36
|
Use list for live agent state, ownership, or a refreshed definition roster
|
|
@@ -76,9 +77,11 @@ for intentional teardown or abandonment.
|
|
|
76
77
|
A lost agent is a managed assignment whose exact physical execution is proven
|
|
77
78
|
gone before a durable terminal result resolved it. Loss is not completion or
|
|
78
79
|
task failure. Treat the assignment as unresolved. When transcript is listed,
|
|
79
|
-
use it only when the last persisted work materially affects recovery.
|
|
80
|
-
to abandon the lost generation before replacing it or
|
|
81
|
-
|
|
80
|
+
use it only when the last persisted work materially affects recovery. When
|
|
81
|
+
`close` is listed, use it to abandon the lost generation before replacing it or
|
|
82
|
+
continuing its saved session. If `close` is absent, resolve the condition
|
|
83
|
+
blocking its close preflight first. Unknown evidence remains fail-closed and is
|
|
84
|
+
not proof of loss.
|
|
82
85
|
|
|
83
86
|
Never guess identities, paths, sessions, or control state. Treat unknown or
|
|
84
87
|
conflicting evidence as unresolved. Keep one writer per worktree or file-
|
|
@@ -150,15 +153,16 @@ later dependent assignments when approved scope or decisions change because
|
|
|
150
153
|
embedded text is snapshotted at submission time while referenced files are not
|
|
151
154
|
copied.
|
|
152
155
|
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
+
Pass relevant files and completed agent results through `files`. Agent
|
|
157
|
+
completions may expose reusable refs such as `result:researcher#1`. When later
|
|
158
|
+
work or coordination depends on a completed direct-agent result, copy its exact
|
|
159
|
+
ref into `files` instead of restating or summarizing its evidence. Do not attach
|
|
160
|
+
unrelated results.
|
|
156
161
|
|
|
157
|
-
`files`
|
|
162
|
+
`files` accepts ordinary files, reusable direct-agent result refs, and canonical
|
|
158
163
|
`result:<request-id>` references already supplied as file evidence. Preserve an
|
|
159
|
-
existing canonical result reference exactly when forwarding it.
|
|
160
|
-
|
|
161
|
-
capability.
|
|
164
|
+
existing canonical result reference exactly when forwarding it. `files` does not
|
|
165
|
+
add runtime capability.
|
|
162
166
|
|
|
163
167
|
Require concise handoffs containing relevant inspected or changed files,
|
|
164
168
|
validation performed, findings or decisions, unresolved risks or blockers,
|
|
@@ -193,9 +197,11 @@ agents are leaves. Keep tightly coupled work local; delegate bounded independent
|
|
|
193
197
|
or unfamiliar work when useful. Reuse adequate supplied evidence rather than
|
|
194
198
|
rediscovering it. Integrate direct agent results before completing. The lead
|
|
195
199
|
retains architecture, approved scope, acceptance, and final-decision authority.
|
|
196
|
-
Delegate only to definitions listed in your effective agents field.
|
|
197
|
-
|
|
198
|
-
|
|
200
|
+
Delegate only to definitions listed in your effective agents field. `ask_owner`
|
|
201
|
+
follows its normal eligibility rules when you have no unresolved direct-agent
|
|
202
|
+
work. If unresolved direct-agent work exists, every such agent must itself be
|
|
203
|
+
validly waiting on an owner answer; ordinary active or pending-result agent
|
|
204
|
+
work still blocks escalation.
|
|
199
205
|
|
|
200
206
|
<!-- pi-herdsman-runtime-delegating-agent:end -->
|
|
201
207
|
|
|
@@ -211,8 +217,10 @@ message evidence. Complete strict UTF-8 text may be embedded; other files are
|
|
|
211
217
|
canonical local references and are not copied or snapshotted. Reuse adequate
|
|
212
218
|
existing evidence instead of repeating completed work.
|
|
213
219
|
Do not overlap writers in a worktree or file-ownership boundary. For dependent
|
|
214
|
-
work,
|
|
215
|
-
|
|
220
|
+
work, pass reusable direct-agent result refs through `files`. Preserve canonical
|
|
221
|
+
`result:<request-id>` refs already supplied as file evidence exactly when
|
|
222
|
+
forwarding them rather than reconstructing physical result paths or copying
|
|
223
|
+
large results into assignments.
|
|
216
224
|
When your role permits writes and temporary coordination material is useful, put
|
|
217
225
|
plans, scopes, specifications, decision notes, investigations, review criteria,
|
|
218
226
|
and handoff state under the project-local `.pi-herdsman/` directory. Reuse and
|
|
@@ -288,11 +296,12 @@ escalation.
|
|
|
288
296
|
|
|
289
297
|
## Handoffs
|
|
290
298
|
|
|
291
|
-
Use `
|
|
292
|
-
|
|
293
|
-
|
|
294
|
-
|
|
295
|
-
exactly and do not
|
|
299
|
+
Use `files` for ordinary files and reusable direct-agent result refs such as
|
|
300
|
+
`result:researcher#1`. Copy the exact ref shown by the completion when later
|
|
301
|
+
work depends on that result instead of restating or summarizing its evidence.
|
|
302
|
+
Also use `files` for canonical `result:<request-id>` references already
|
|
303
|
+
supplied as file evidence; preserve those references exactly and do not
|
|
304
|
+
reconstruct their physical paths.
|
|
296
305
|
|
|
297
306
|
A concise handoff should include:
|
|
298
307
|
|
|
@@ -358,16 +367,18 @@ Ordinary leads own their complete herd, including every agent beneath them. The
|
|
|
358
367
|
Chief supervises independent leads and never changes ownership. Use `chief`
|
|
359
368
|
`message` for meaningful progress, warnings, results, or completion, including
|
|
360
369
|
exact artifact paths. Use `chief` `ask` only when a genuine chief decision is
|
|
361
|
-
required, make it the only
|
|
370
|
+
required, make it the only tool call of the turn, call it last, do not guess,
|
|
362
371
|
and wait for the reply. Descendants use `ask_owner`, not `chief`.
|
|
363
372
|
|
|
364
373
|
`chief` is available only to an ordinary lead. Its actions are `message` and
|
|
365
374
|
`ask`; a valid chief is required and a rejected call does not mutate state.
|
|
366
|
-
Chief and staff message/ask/reply actions accept
|
|
367
|
-
|
|
368
|
-
|
|
369
|
-
agents, so
|
|
370
|
-
|
|
375
|
+
Chief and staff message/ask/reply actions accept ordinary files, reusable
|
|
376
|
+
direct-agent result refs, and already-supplied canonical result references
|
|
377
|
+
through `files`. Direct refs resolve by exact agent label and index on the
|
|
378
|
+
caller's current branch. Chief normally owns no direct agents, so a branch-local
|
|
379
|
+
semantic ref may not exist in the Chief session; preserve canonical
|
|
380
|
+
`result:<request-id>` evidence already received from another session through
|
|
381
|
+
`files` when forwarding it.
|
|
371
382
|
Questions are limited to 1,024 characters and 1,024 UTF-8 bytes. Channel
|
|
372
383
|
message records are bounded to 8 KiB, so multibyte content can hit the byte limit
|
|
373
384
|
first. Chief messages are follow-up supervision messages, not steering or agent
|