pi-herdsman 0.13.0 → 0.13.2

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 CHANGED
@@ -5,18 +5,18 @@ description: Optional reinforcement and strategy for orchestrating managed agent
5
5
 
6
6
  # Pi Herdsman
7
7
 
8
- Pi Herdsman injects the complete operational contract into active leads and
9
- managed agents at runtime. Loading this skill is optional and is never required
10
- for correct operation.
11
-
12
- This skill intentionally repeats the mandatory runtime operational instructions
13
- so they remain salient in long model contexts, then adds strategy, rationale,
14
- examples, and deeper product guidance.
15
-
16
- The active runtime contract is authoritative. Loading this skill does not grant
17
- tools, change capabilities, alter lifecycle semantics, or introduce requirements
18
- that do not exist at runtime. If this skill and the active runtime contract ever
19
- conflict, follow runtime.
8
+ Pi Herdsman injects the operational contract into active leads and managed
9
+ agents at runtime. Loading this skill is optional and is never required for
10
+ correct operation.
11
+
12
+ This skill reinforces high-salience runtime invariants and adds strategy,
13
+ rationale, examples, and deeper product guidance. The active runtime contract
14
+ remains authoritative. Loading this skill does not grant tools, change
15
+ capabilities, alter lifecycle semantics, or introduce requirements that do not
16
+ exist at runtime. A behavioral invariant may be reinforced at multiple
17
+ model-facing decision points when timing or salience materially affects
18
+ reliability; those projections preserve one meaning rather than defining
19
+ independent rules.
20
20
 
21
21
  ## Runtime controller contract
22
22
 
@@ -24,6 +24,22 @@ conflict, follow runtime.
24
24
 
25
25
  Coordinate managed agents.
26
26
 
27
+ Use these high-salience rules for the model-facing agent boundary:
28
+
29
+ - Use agent for genuinely independent or context-heavy work; keep small,
30
+ tightly coupled work local.
31
+ - Each unresolved unit of work has one executor. Delegating a scope transfers
32
+ its execution ownership to that agent until the assignment resolves; do not
33
+ execute or assign overlapping work while it is delegated.
34
+ - For agent handoffs, `task`/`files` carry assignment evidence and
35
+ `fork`/`continue` carry selected Pi history; do not assume the caller's
36
+ conversation or attachments are inherited.
37
+ - When agent work is unresolved, handle required agent control, then continue
38
+ only necessary work you still own or end the turn without concluding; agent
39
+ results or attention will resume the session automatically. Do not check
40
+ progress with list, inspect, transcript, status requests, steering, sleep, or
41
+ other waiting mechanisms, and do not invent work merely to remain active.
42
+
27
43
  Ordinary Leads use `peer` for other ordinary Lead sessions; managed agents are
28
44
  not peers. `peer list` identifies this Lead as `self` and returns other live
29
45
  Leads as `peers` with exact `lead` IDs. Incoming peer messages are already
@@ -33,8 +49,9 @@ message` accepts ordinary files and completed direct-agent result refs through
33
49
  `files`; the peer tool is unavailable in Chief mode.
34
50
 
35
51
  The session-start instructions include the current agent-definition roster.
36
- Use list for live agent state, ownership, or a refreshed definition roster
37
- after configuration changes.
52
+ Use list when fresh agent state or ownership is materially needed for a concrete
53
+ control or recovery decision, or to refresh the definition roster after
54
+ configuration changes. Do not use list merely to check progress.
38
55
 
39
56
  Use delegate to start one bounded assignment from an agent definition.
40
57
  Use continue to start one bounded assignment from an exact historical Pi session.
@@ -88,38 +105,10 @@ conflicting evidence as unresolved. Keep one writer per worktree or file-
88
105
  ownership boundary. Use a capable definition or report blocked when a required
89
106
  runtime capability is unavailable.
90
107
 
91
- Delegate genuinely independent or context-heavy work. Prefer agents for broad
92
- file inspection, large logs or command output, and dataset analysis. Keep small,
93
- tightly coupled work local.
94
- If several tightly coupled phases are already known, put them in one bounded
95
- assignment when practical. If genuinely new follow-up work emerges after
96
- completion and previous context is valuable, continue the exact returned session
97
- only when the completion is not marked retired. A retired session requires a
98
- fresh delegation; pass this result/handoff plus the relevant files instead.
99
- Each active delegated assignment has one executor: that agent. Do not repeat
100
- its assigned work locally or delegate substantially overlapping work elsewhere.
101
-
102
- After starting an agent assignment or receiving an agent result or attention
103
- event, reassess the remaining work. Handle required agent control when needed.
104
- If another concrete, necessary objective is independent of active agent
105
- assignments and an authorized agent is the right owner, delegate it. If a
106
- concrete, necessary independent objective is best handled locally and doing it
107
- now materially advances the task, do that work, then reassess.
108
-
109
- If further useful progress depends on active agents, or no other concrete,
110
- necessary independent work remains, end your turn without concluding the task.
111
- Agent results or attention will resume this session automatically. Do not
112
- conclude or produce the final synthesis while unresolved agent work remains.
113
- Do not invent side work, broaden scope, perform speculative or precautionary
114
- exploration, list, inspect, or transcript merely for progress, steer merely for status, sleep,
115
- poll, or otherwise keep the turn alive while agent results are pending.
116
-
117
108
  If list reports result_error, do not start a new delegation over unresolved
118
109
  work. Resolve mailbox persistence first, then close the exact agent before
119
110
  starting another assignment; follow the stored recovery nextAction.
120
111
 
121
- Before delegate, continue, steer, interrupt, or reply, make the message self-contained.
122
-
123
112
  Do not attach or mention agent instruction files such as AGENTS.md, CLAUDE.md,
124
113
  GEMINI.md, or equivalents merely because they exist. Rely on normal project or
125
114
  runtime discovery when it supplies those instructions.
@@ -133,16 +122,17 @@ Skills are separate. Attach a required SKILL.md only when the task needs it and
133
122
  the selected definition does not already provide that skill. Ordinary relevant
134
123
  source, documentation, configuration, and evidence files remain attachable.
135
124
 
136
- Complete strict UTF-8 text is embedded when it fits;
137
- other files are canonical local references with byte size. Embedded text is
138
- snapshotted; referenced files are not copied or snapshotted. files transfers
139
- inline content or canonical references, not tools or runtime capabilities.
140
- Assume the recipient has no prior knowledge of this conversation, task history,
141
- live environment, current state, sibling work, or unstated assumptions. Include
142
- the objective and deliverable, relevant facts and evidence, exact identities and
143
- paths, scope and non-goals, constraints and authority, dependencies, acceptance
144
- and validation, expected handoff, and what to do if blocked. For delegated work,
145
- use files for large evidence and explain what each file contains.
125
+ Complete strict UTF-8 text is embedded when it fits; other files are canonical
126
+ local references with byte size. Embedded text is snapshotted; referenced files
127
+ are not copied or snapshotted. files transfers inline content or canonical
128
+ references, not tools or runtime capabilities.
129
+
130
+ For agent handoffs, task text and `files` carry assignment-specific evidence.
131
+ `fork` and `continue` are the public mechanisms that deliberately select saved
132
+ Pi history. Do not assume the caller's conversation or caller-side attachments
133
+ are inherited by another agent session.
134
+
135
+ Pass relevant evidence explicitly through `files`; omit unrelated evidence.
146
136
 
147
137
  Use the project-local `.pi-herdsman/` directory as the default workspace for
148
138
  temporary coordination artifacts such as plans, scopes, specifications,
@@ -192,6 +182,10 @@ of duplicating work.
192
182
 
193
183
  <!-- pi-herdsman-runtime-delegating-agent:start -->
194
184
 
185
+ Each unresolved unit of work has one executor. Delegating a scope transfers its
186
+ execution ownership to that agent until the assignment resolves; do not execute
187
+ or assign overlapping work while it is delegated.
188
+ Integrate direct agent results after resolution.
195
189
  Own only the assigned objective and your direct permitted agents. Agent-started
196
190
  agents are leaves. Keep tightly coupled work local; delegate bounded independent
197
191
  or unfamiliar work when useful. Reuse adequate supplied evidence rather than
@@ -330,9 +324,12 @@ See [Recovery](docs/guides/recovery.md) for operator procedures and the
330
324
  End a turn with unresolved agent work only when that work can still make
331
325
  progress without the owner, or Herdsman is reconciling a durable transition
332
326
  that can produce a future result or attention event. If an attention event
333
- requires owner action, handle it before returning to passive waiting. If an
334
- inactivity advisory appears healthy or legitimately long-running, leave it
335
- alone and end the turn; Herdsman will reconcile it again.
327
+ requires owner action, handle it before returning to passive waiting. For stale
328
+ inactivity, use evidence attached to the first attention event before judging
329
+ health. If that evidence is absent or insufficient, perform at most one bounded
330
+ diagnostic read before returning to passive waiting. Repeated reminders for the
331
+ same stale episode do not by themselves justify another read. If the evidence
332
+ shows healthy or legitimately long-running work, leave it alone.
336
333
 
337
334
  Health reconciliation is event-driven with a 30-second fallback scan. Actionable
338
335
  health attention is sent only to the exact direct owner and is based on freshly