pi-braid 0.43.2 → 0.43.4
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/CHANGELOG.md +26 -0
- package/README.md +7 -3
- package/build-info.json +4 -4
- package/dist/extensions/core/prompt-builder/external-tool-guidelines.d.ts +1 -1
- package/dist/extensions/core/prompt-builder/external-tool-guidelines.js +1 -1
- package/dist/extensions/core/prompt-builder/tool-description-trim.d.ts +1 -1
- package/dist/extensions/core/prompt-builder/tool-description-trim.js +5 -5
- package/package.json +2 -1
- package/skills/{herdr-topology → pane-topology}/SKILL.md +35 -18
- package/skills/subagent-orchestration/SKILL.md +62 -1
- package/src/extensions/core/prompt-builder/AGENTS.md +1 -1
- package/src/extensions/core/prompt-builder/external-tool-guidelines.ts +1 -1
- package/src/extensions/core/prompt-builder/tool-description-trim.ts +5 -5
package/CHANGELOG.md
CHANGED
|
@@ -43,6 +43,32 @@ reader-facing record; the tag scheme above applies unchanged.
|
|
|
43
43
|
|
|
44
44
|
---
|
|
45
45
|
|
|
46
|
+
## Core — 0.43.4 (2026-10-28: the pane guide is named for the model, and a seat can hand over)
|
|
47
|
+
|
|
48
|
+
- **The skill about panes is named for what it teaches.** Workspaces, tabs, panes, opaque ids, read sources and the
|
|
49
|
+
agent lifecycle are not Herdr's inventions, so a skill named after Herdr read as a product scope rather than a
|
|
50
|
+
model. It is `pane-topology` now: the containment model leads, every fact that is Herdr's stays named as Herdr's,
|
|
51
|
+
and the triggers include the three tool names, so a model that has the tools but not the product word still finds
|
|
52
|
+
it. Three trimmed tool descriptions, the prompt-builder table row and the six fixtures that pin the shipped name
|
|
53
|
+
follow the rename.
|
|
54
|
+
- **`subagent-orchestration` carries the self-transfer procedure**: what opens a handover (a newer build, changed
|
|
55
|
+
settings, an exhausted seat), the ordered steps, which side closes which pane, and the `wait:false` trap with what
|
|
56
|
+
it costs, since a blocked predecessor holds the channel after it has already handed over.
|
|
57
|
+
- **`test-skills-floor` no longer requires a naming coincidence.** Its trigger assertion held only because one skill
|
|
58
|
+
was named after the multiplexer whose tools share its prefix; it now carries a positive control and asserts
|
|
59
|
+
whichever of the two renderings the real inputs produce.
|
|
60
|
+
|
|
61
|
+
## Core — 0.43.3 (2026-10-28: one description, two intros, and a gate that keeps them honest)
|
|
62
|
+
|
|
63
|
+
- **The registry page and the repository page open with the same claim.** The npm README still opened with a summary
|
|
64
|
+
the manifest no longer carried, so the two surfaces described one product in two sets of words. Both files carry the
|
|
65
|
+
manifest description between `<!-- braid:intro:start -->` and `<!-- braid:intro:end -->`, wrapped for reading.
|
|
66
|
+
- **A gate holds them together.** `npm run check:readme-sync` compares the two blocks to each other and to
|
|
67
|
+
`packages/core/package.json` with whitespace normalised, and names the character where a pair diverges. A drift in
|
|
68
|
+
either direction fails the chain, so the next edit to the description has to reach both pages in the same commit.
|
|
69
|
+
- **`braid` is a keyword on every package in the family**, so the five registry entries share one discoverable term
|
|
70
|
+
instead of four different word lists.
|
|
71
|
+
|
|
46
72
|
## Core — 0.43.2 (2026-10-28: the artifact check waits out the publish it is checking)
|
|
47
73
|
|
|
48
74
|
- **A 404 seconds after our own publish is a lag, not absence.** npm acknowledged the `0.43.1` publish, a read forty
|
package/README.md
CHANGED
|
@@ -5,9 +5,13 @@
|
|
|
5
5
|
[](https://opensource.org/licenses/MIT)
|
|
6
6
|
[](https://github.com/earendil-works/pi)
|
|
7
7
|
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
8
|
+
<!-- braid:intro:start -->
|
|
9
|
+
|
|
10
|
+
🥨 Braid - Metacognitive extension suite for pi coding agent: Adds memory, plan tracking, structured
|
|
11
|
+
cognitive signals and completion checks on top of pi core loop, so long sessions keep their context and
|
|
12
|
+
stop claiming unfinished work.
|
|
13
|
+
|
|
14
|
+
<!-- braid:intro:end -->
|
|
11
15
|
|
|
12
16
|
> **Early-stage software.** APIs may change. Not production-hardened.
|
|
13
17
|
|
package/build-info.json
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "pi-braid",
|
|
3
|
-
"version": "0.43.
|
|
4
|
-
"sha": "
|
|
5
|
-
"shaShort": "
|
|
3
|
+
"version": "0.43.4",
|
|
4
|
+
"sha": "27e095fbeebea5dd7bca2c42eb702d5aa45790ef",
|
|
5
|
+
"shaShort": "27e095fb",
|
|
6
6
|
"branch": "detached",
|
|
7
7
|
"dirty": false,
|
|
8
|
-
"packedAt": "2026-10-
|
|
8
|
+
"packedAt": "2026-10-28T14:15:17.325Z"
|
|
9
9
|
}
|
|
@@ -15,7 +15,7 @@
|
|
|
15
15
|
* The registered tool DESCRIPTIONS of herdr_* are trimmed
|
|
16
16
|
* to 1-2 lines at the provider-payload layer (tool-description-trim.ts,
|
|
17
17
|
* before_provider_request) and the deep topology guidance lives in the
|
|
18
|
-
*
|
|
18
|
+
* pane-topology SKILL (progressive disclosure). This map keeps its
|
|
19
19
|
* render-fallback role (priority 3) — still load-bearing if pi-herdr ever
|
|
20
20
|
* stops self-registering promptGuidelines.
|
|
21
21
|
*/
|
|
@@ -15,7 +15,7 @@
|
|
|
15
15
|
* The registered tool DESCRIPTIONS of herdr_* are trimmed
|
|
16
16
|
* to 1-2 lines at the provider-payload layer (tool-description-trim.ts,
|
|
17
17
|
* before_provider_request) and the deep topology guidance lives in the
|
|
18
|
-
*
|
|
18
|
+
* pane-topology SKILL (progressive disclosure). This map keeps its
|
|
19
19
|
* render-fallback role (priority 3) — still load-bearing if pi-herdr ever
|
|
20
20
|
* stops self-registering promptGuidelines.
|
|
21
21
|
*/
|
|
@@ -26,7 +26,7 @@
|
|
|
26
26
|
*
|
|
27
27
|
* Dependency-inversion compatibility: descriptions remain owned by the
|
|
28
28
|
* registering package. The curated strings below only SHORTEN the channel
|
|
29
|
-
* form and point at the
|
|
29
|
+
* form and point at the pane-topology SKILL for the deep form
|
|
30
30
|
* (progressive disclosure). The when-gate ("only when the user explicitly
|
|
31
31
|
* mentions Herdr") is load-bearing and preserved in every rewrite.
|
|
32
32
|
*
|
|
@@ -26,7 +26,7 @@
|
|
|
26
26
|
*
|
|
27
27
|
* Dependency-inversion compatibility: descriptions remain owned by the
|
|
28
28
|
* registering package. The curated strings below only SHORTEN the channel
|
|
29
|
-
* form and point at the
|
|
29
|
+
* form and point at the pane-topology SKILL for the deep form
|
|
30
30
|
* (progressive disclosure). The when-gate ("only when the user explicitly
|
|
31
31
|
* mentions Herdr") is load-bearing and preserved in every rewrite.
|
|
32
32
|
*
|
|
@@ -38,16 +38,16 @@
|
|
|
38
38
|
* name; currently covers @ogulcancelik/pi-herdr (layout/pane/agent).
|
|
39
39
|
*/
|
|
40
40
|
export const TRIM_TOOL_DESCRIPTIONS = {
|
|
41
|
-
herdr_layout: "Create/inspect Herdr terminal topology (workspaces, tabs, panes; layout only, never starts agents or commands). Use only when the user explicitly mentions Herdr. Read pane IDs from results; deep procedures live in the
|
|
42
|
-
herdr_pane: "Raw Herdr terminal pane control: run, read, wait_output, send_text/send_keys, inspect, close. Use only when the user explicitly mentions Herdr; prefer herdr_agent for recognized coding agents. Deep procedures:
|
|
43
|
-
herdr_agent: "Drive a recognized coding agent in an existing Herdr pane: start, prompt, wait, read, send_keys. Use only when the user explicitly mentions Herdr; needs an available shell pane from herdr_layout first. Deep procedures:
|
|
41
|
+
herdr_layout: "Create/inspect Herdr terminal topology (workspaces, tabs, panes; layout only, never starts agents or commands). Use only when the user explicitly mentions Herdr. Read pane IDs from results; deep procedures live in the pane-topology skill.",
|
|
42
|
+
herdr_pane: "Raw Herdr terminal pane control: run, read, wait_output, send_text/send_keys, inspect, close. Use only when the user explicitly mentions Herdr; prefer herdr_agent for recognized coding agents. Deep procedures: pane-topology skill.",
|
|
43
|
+
herdr_agent: "Drive a recognized coding agent in an existing Herdr pane: start, prompt, wait, read, send_keys. Use only when the user explicitly mentions Herdr; needs an available shell pane from herdr_layout first. Deep procedures: pane-topology skill.",
|
|
44
44
|
};
|
|
45
45
|
/** Third-party family the trim applies to (prefix match for the fallback). */
|
|
46
46
|
const TRIMMED_PREFIX = "herdr_";
|
|
47
47
|
/** The when-gate is load-bearing. */
|
|
48
48
|
const HERDR_GATE = "Use only when the user explicitly mentions Herdr";
|
|
49
49
|
/** Skill pointer appended to fallback trims (progressive disclosure home). */
|
|
50
|
-
const SKILL_POINTER = "Deep procedures:
|
|
50
|
+
const SKILL_POINTER = "Deep procedures: pane-topology skill.";
|
|
51
51
|
/** Fallback trim applies only to descriptions longer than this. */
|
|
52
52
|
const FALLBACK_MAX_CHARS = 240;
|
|
53
53
|
/** Cap the description to its leading sentences within maxChars. */
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "pi-braid",
|
|
3
|
-
"version": "0.43.
|
|
3
|
+
"version": "0.43.4",
|
|
4
4
|
"description": "🥨 Braid - Metacognitive extension suite for pi coding agent: Adds memory, plan tracking, structured cognitive signals and completion checks on top of pi core loop, so long sessions keep their context and stop claiming unfinished work.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "./dist/index.js",
|
|
@@ -89,6 +89,7 @@
|
|
|
89
89
|
},
|
|
90
90
|
"keywords": [
|
|
91
91
|
"pi-package",
|
|
92
|
+
"braid",
|
|
92
93
|
"pi-coding-agent",
|
|
93
94
|
"pi-extension",
|
|
94
95
|
"coding-agent",
|
|
@@ -1,25 +1,39 @@
|
|
|
1
1
|
---
|
|
2
|
-
name:
|
|
3
|
-
description: "
|
|
2
|
+
name: pane-topology
|
|
3
|
+
description: "Use when work needs more than one terminal surface, or when a pane, tab or agent has to be read or driven: the containment model (workspaces hold tabs, tabs hold panes, panes hold processes), opaque ID handling, the read sources that recover output, the two control surfaces the herdr_layout, herdr_pane and herdr_agent tools expose (a raw terminal channel and a coding-agent channel), agent lifecycle states, and the orchestrator procedures that keep a multi-pane wave honest about its progress. Load when actually splitting, reading or driving a pane, not on first mention."
|
|
4
4
|
triggers:
|
|
5
|
-
- "
|
|
6
|
-
- "
|
|
7
|
-
- "
|
|
5
|
+
- "pane topology"
|
|
6
|
+
- "split a pane"
|
|
7
|
+
- "terminal panes"
|
|
8
|
+
- "driving panes"
|
|
9
|
+
- "herdr_layout"
|
|
10
|
+
- "herdr_pane"
|
|
11
|
+
- "herdr_agent"
|
|
8
12
|
validated: 2026-09-07
|
|
9
13
|
verdict: KEEP
|
|
10
14
|
---
|
|
11
15
|
|
|
12
|
-
#
|
|
16
|
+
# Pane Topology
|
|
13
17
|
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
+
A containment model and two control surfaces over it. The model is the part a
|
|
19
|
+
model needs before it touches anything: what a terminal multiplexer contains,
|
|
20
|
+
what an identifier points at, and what a read can recover. The surfaces are
|
|
21
|
+
`herdr_layout` (shape and inspect the topology), `herdr_pane` (raw terminal
|
|
22
|
+
control) and `herdr_agent` (drive a recognized coding agent in a pane).
|
|
23
|
+
|
|
24
|
+
This file is the deep form; each tool descriptor carries one line. Where a
|
|
25
|
+
fact is Herdr's - its CLI quirks, its version behavior, its lifecycle states,
|
|
26
|
+
its issue numbers - the fact says Herdr, because that is where it is true. The
|
|
27
|
+
rest is the model, and a different multiplexer keeps the model and replaces
|
|
28
|
+
the facts.
|
|
29
|
+
|
|
30
|
+
Herdr itself is used **only when the user explicitly mentions Herdr**. If you
|
|
31
|
+
are reading this, that gate has already been satisfied.
|
|
18
32
|
|
|
19
33
|
## The containment model
|
|
20
34
|
|
|
21
|
-
|
|
22
|
-
|
|
35
|
+
Three levels, and every operation names one of them. Herdr calls them
|
|
36
|
+
workspaces, tabs and panes; the shape is what matters:
|
|
23
37
|
|
|
24
38
|
- Creating a workspace or tab also creates its root pane; splitting an
|
|
25
39
|
existing pane creates another pane. There is no "create empty container".
|
|
@@ -28,6 +42,8 @@ occupying panes and exposes them by name.
|
|
|
28
42
|
- A pane exists whether or not an agent occupies it. `herdr_agent start`
|
|
29
43
|
requires an existing, available shell pane and never creates, splits, or
|
|
30
44
|
moves layout.
|
|
45
|
+
- Herdr recognizes coding agents occupying panes and exposes them by name, so
|
|
46
|
+
an agent is addressable two ways: by name, or by the pane hosting it.
|
|
31
47
|
|
|
32
48
|
## IDs are opaque: read, never construct
|
|
33
49
|
|
|
@@ -57,7 +73,8 @@ replaced: a process cannot close the pane it runs in, so during a
|
|
|
57
73
|
mastership transfer the incoming seat owns that close and runs
|
|
58
74
|
`herdr_pane close <pane>` on the outgoing seat's pane. The exception covers
|
|
59
75
|
that pane and nothing else - worker panes you did not spawn, tabs, and
|
|
60
|
-
workspaces still wait for the user's word.
|
|
76
|
+
workspaces still wait for the user's word. The transfer procedure, including
|
|
77
|
+
when it is worth its cost, is in the subagent-orchestration skill.
|
|
61
78
|
|
|
62
79
|
## Panes: raw terminal control
|
|
63
80
|
|
|
@@ -120,8 +137,8 @@ prompt, wait, read, and send_keys instead of raw pane input.
|
|
|
120
137
|
whole run - and a timed-out wait does NOT mean the prompt failed; check `get`
|
|
121
138
|
before re-sending. Only prompt with the default when blocking is the intent.
|
|
122
139
|
(Observed 2026-10-09: a helper that had read only the native `herdr` docs
|
|
123
|
-
omitted `wait:false` and hung its dispatcher; the native `herdr` skill
|
|
124
|
-
model-disabled
|
|
140
|
+
omitted `wait:false` and hung its dispatcher; the native `herdr` skill can be
|
|
141
|
+
model-disabled, leaving this skill as the operating surface.)
|
|
125
142
|
- `idle` means ready for input with the tab seen in the focused UI; `done`
|
|
126
143
|
is the same underlying readiness after unseen background work finishes.
|
|
127
144
|
Focusing the tab (or targeting the pane/agent) marks it seen; CLI reads do
|
|
@@ -269,6 +286,6 @@ left running holds a name, a pane, and possibly a bill.
|
|
|
269
286
|
is the always-visible form; this skill is the on-demand deep form.
|
|
270
287
|
- `herdr_layout` results are the single source of topology truth; everything
|
|
271
288
|
else takes IDs from there.
|
|
272
|
-
- Orchestration-level concerns (spawn patterns, worker lifecycles,
|
|
273
|
-
handoff between agents) live in the subagent-orchestration
|
|
274
|
-
file only covers the terminal topology underneath them.
|
|
289
|
+
- Orchestration-level concerns (spawn patterns, worker lifecycles, mastership
|
|
290
|
+
transfer, context handoff between agents) live in the subagent-orchestration
|
|
291
|
+
skill; this file only covers the terminal topology underneath them.
|
|
@@ -323,7 +323,10 @@ herdr action=send pane=<successor> text="[agent:orchestrator→successor] Read /
|
|
|
323
323
|
|
|
324
324
|
Best for a successor that will orchestrate subagents. TUI pi persists, accepts signaling, can spawn its own workers.
|
|
325
325
|
|
|
326
|
-
3. Transfer mastership: the
|
|
326
|
+
3. Transfer mastership: the self-transfer procedure below owns the detail. The short form: the
|
|
327
|
+
successor closes the predecessor's pane with `herdr_pane close <predecessor-pane>` after
|
|
328
|
+
verifying the predecessor's process is gone, because a process cannot close the pane it runs
|
|
329
|
+
in, and the incoming seat owns that one close. The predecessor stands down by ending its turn.
|
|
327
330
|
4. The successor starts clean (no bloat) and reads the handoff.
|
|
328
331
|
|
|
329
332
|
This is a **pipeline, not a loop**: each session is a fresh stage. Never compact above 70% - cascade instead.
|
|
@@ -490,6 +493,64 @@ Master: "I am pane-abc. Your task is X. When done, close pane-abc."
|
|
|
490
493
|
|
|
491
494
|
Without this, the child cannot locate the parent to close it.
|
|
492
495
|
|
|
496
|
+
### Self-transfer: a seat hands mastership to a fresh successor
|
|
497
|
+
|
|
498
|
+
A running process keeps the module it booted with, so a fresh process is the only way to pick
|
|
499
|
+
up a newer build, a changed setting, or a new route order. The seat may hand over whenever that
|
|
500
|
+
is what the work needs; it does not wait for a crisis.
|
|
501
|
+
|
|
502
|
+
Reach for it when:
|
|
503
|
+
|
|
504
|
+
- a newer build exists than the one this process booted with (an adoption wave merged, or the
|
|
505
|
+
owner published),
|
|
506
|
+
- settings or route order changed and the running process cannot see them,
|
|
507
|
+
- the seat is wedged, or its context is exhausted past recovery,
|
|
508
|
+
- the owner asks for it.
|
|
509
|
+
|
|
510
|
+
Not a first resort for a long session: a handover costs a boot, a re-derivation of every claim,
|
|
511
|
+
and a window in which neither seat fully owns the channel.
|
|
512
|
+
|
|
513
|
+
1. **Write the handoff and finish the turn's durable writes first.** Goal, live state (workers
|
|
514
|
+
and their panes, open locks, branches), the queue with paths, and the traps this seat
|
|
515
|
+
learned. After step 2 a prompt may be the last thing this seat does, so anything still only
|
|
516
|
+
in context is lost.
|
|
517
|
+
2. **Spawn the successor in its own pane, on the newest installed build.** Dispatch the handoff
|
|
518
|
+
prompt with `wait: false` and let it boot; the successor reads the handoff, re-derives its
|
|
519
|
+
boot claims from instruments, and writes its boot report in its own pane, because the pane is
|
|
520
|
+
the only channel between seats.
|
|
521
|
+
3. **Verify the boot claims from that pane.** Version and model, the session it opened, the
|
|
522
|
+
skills and settings it loaded: a successor reporting a different build than the one you mean
|
|
523
|
+
to hand over to has not picked up the change, and the transfer stops there.
|
|
524
|
+
4. **Release the channel, then stand down.** `telegram_poller` disable, write "CHANNEL IS FREE"
|
|
525
|
+
into the successor's pane through a herdr call that passes `wait: false`, and end the turn with
|
|
526
|
+
a text-only reply. After that the outgoing seat touches no channel, fleet, queue, repo or
|
|
527
|
+
setting, and arms at most one timer to read the successor's pane.
|
|
528
|
+
|
|
529
|
+
**The trap, and what it costs.** Never end a handover with a `herdr_agent prompt` against the
|
|
530
|
+
successor's pane and the default `wait: true`. The default waits for the successor's lifecycle
|
|
531
|
+
to settle; a booting successor is working and does not settle, so the outgoing seat blocks
|
|
532
|
+
inside the call, never stands down, and the poller lock stays with a seat that has already
|
|
533
|
+
handed over. The successor's `telegram_poller` enable is then refused while a live foreign pid
|
|
534
|
+
holds that lock, and the inbound channel goes to a process that has stopped reading it.
|
|
535
|
+
|
|
536
|
+
The mirror rule, for the incoming side: a handoff message that arrives as a herdr-delivered
|
|
537
|
+
prompt is a blocked predecessor waiting on your lifecycle. Finish the durable writes of that
|
|
538
|
+
turn (lock read, journal, scratchpad) and end the turn with a text-only reply; the turn end is
|
|
539
|
+
what releases it, and holding your own turn open to wait for the predecessor blocks both seats.
|
|
540
|
+
|
|
541
|
+
**Who closes which pane.** The outgoing seat does not close its own pane, because a process
|
|
542
|
+
cannot close the pane it runs in. The successor closes it with `herdr_pane close <pane>` after
|
|
543
|
+
verifying the outgoing process is actually gone (the pid the poller lock named, or `ps`), since
|
|
544
|
+
a close against a live process destroys in-flight state. That one pane close is the whole of the
|
|
545
|
+
exception: the successor still does not close panes it did not inherit.
|
|
546
|
+
|
|
547
|
+
**The journal.** The transfer is two lines in the project journal, not a paragraph in the
|
|
548
|
+
handoff: an intention line before the successor is spawned (`node
|
|
549
|
+
packages/core/scripts/journal-append.mjs`), and an outcome line once the outgoing process is
|
|
550
|
+
gone, with the poller-lock read as its evidence (`node
|
|
551
|
+
packages/core/scripts/check-journal.mjs`). An intention with no outcome entry is an unfinished
|
|
552
|
+
handover, and the next seat treats the channel as contended until it reads otherwise.
|
|
553
|
+
|
|
493
554
|
## Next-Task Selection
|
|
494
555
|
|
|
495
556
|
After every `finalize`, decide what to do next. Do not guess - use this procedure:
|
|
@@ -37,7 +37,7 @@ Every file in this folder either:
|
|
|
37
37
|
| `pi-reference-section.ts` | Pi docs seat: `PI_REFERENCE_POINTER` + `piReferenceSection()` - a static pointer to the `pi-reference` skill (docs index + install paths), rendered after the tools section. Replaced the native `<docs>` re-emission; the parity registry marks the native `docs` key dropped. |
|
|
38
38
|
| `system-info-tool.ts` | `system_info` tool: full Instance data on demand (detail full or compact). The seat for volatile facts (elapsed, last event, turns, tool average) and the core/cwd/settings path triple; a tool result is not a cached prefix. |
|
|
39
39
|
| `inspect.ts` | `prompt_inspect` tool: reads the actual system prompt from runtime. |
|
|
40
|
-
| `tool-description-trim.ts` | Third-party tool-description trim: `before_provider_request` handler that shortens registered descriptions of `herdr_*` tools to 1-2 lines in the API tools channel (curated map + prefix fallback); the deep form moved to the `
|
|
40
|
+
| `tool-description-trim.ts` | Third-party tool-description trim: `before_provider_request` handler that shortens registered descriptions of `herdr_*` tools to 1-2 lines in the API tools channel (curated map + prefix fallback); the deep form moved to the `pane-topology` skill (progressive disclosure). When-gate preserved in every rewrite. |
|
|
41
41
|
|
|
42
42
|
## Local Contracts
|
|
43
43
|
|
|
@@ -15,7 +15,7 @@
|
|
|
15
15
|
* The registered tool DESCRIPTIONS of herdr_* are trimmed
|
|
16
16
|
* to 1-2 lines at the provider-payload layer (tool-description-trim.ts,
|
|
17
17
|
* before_provider_request) and the deep topology guidance lives in the
|
|
18
|
-
*
|
|
18
|
+
* pane-topology SKILL (progressive disclosure). This map keeps its
|
|
19
19
|
* render-fallback role (priority 3) — still load-bearing if pi-herdr ever
|
|
20
20
|
* stops self-registering promptGuidelines.
|
|
21
21
|
*/
|
|
@@ -26,7 +26,7 @@
|
|
|
26
26
|
*
|
|
27
27
|
* Dependency-inversion compatibility: descriptions remain owned by the
|
|
28
28
|
* registering package. The curated strings below only SHORTEN the channel
|
|
29
|
-
* form and point at the
|
|
29
|
+
* form and point at the pane-topology SKILL for the deep form
|
|
30
30
|
* (progressive disclosure). The when-gate ("only when the user explicitly
|
|
31
31
|
* mentions Herdr") is load-bearing and preserved in every rewrite.
|
|
32
32
|
*
|
|
@@ -40,11 +40,11 @@
|
|
|
40
40
|
*/
|
|
41
41
|
export const TRIM_TOOL_DESCRIPTIONS: Record<string, string> = {
|
|
42
42
|
herdr_layout:
|
|
43
|
-
"Create/inspect Herdr terminal topology (workspaces, tabs, panes; layout only, never starts agents or commands). Use only when the user explicitly mentions Herdr. Read pane IDs from results; deep procedures live in the
|
|
43
|
+
"Create/inspect Herdr terminal topology (workspaces, tabs, panes; layout only, never starts agents or commands). Use only when the user explicitly mentions Herdr. Read pane IDs from results; deep procedures live in the pane-topology skill.",
|
|
44
44
|
herdr_pane:
|
|
45
|
-
"Raw Herdr terminal pane control: run, read, wait_output, send_text/send_keys, inspect, close. Use only when the user explicitly mentions Herdr; prefer herdr_agent for recognized coding agents. Deep procedures:
|
|
45
|
+
"Raw Herdr terminal pane control: run, read, wait_output, send_text/send_keys, inspect, close. Use only when the user explicitly mentions Herdr; prefer herdr_agent for recognized coding agents. Deep procedures: pane-topology skill.",
|
|
46
46
|
herdr_agent:
|
|
47
|
-
"Drive a recognized coding agent in an existing Herdr pane: start, prompt, wait, read, send_keys. Use only when the user explicitly mentions Herdr; needs an available shell pane from herdr_layout first. Deep procedures:
|
|
47
|
+
"Drive a recognized coding agent in an existing Herdr pane: start, prompt, wait, read, send_keys. Use only when the user explicitly mentions Herdr; needs an available shell pane from herdr_layout first. Deep procedures: pane-topology skill.",
|
|
48
48
|
};
|
|
49
49
|
|
|
50
50
|
/** Third-party family the trim applies to (prefix match for the fallback). */
|
|
@@ -54,7 +54,7 @@ const TRIMMED_PREFIX = "herdr_";
|
|
|
54
54
|
const HERDR_GATE = "Use only when the user explicitly mentions Herdr";
|
|
55
55
|
|
|
56
56
|
/** Skill pointer appended to fallback trims (progressive disclosure home). */
|
|
57
|
-
const SKILL_POINTER = "Deep procedures:
|
|
57
|
+
const SKILL_POINTER = "Deep procedures: pane-topology skill.";
|
|
58
58
|
|
|
59
59
|
/** Fallback trim applies only to descriptions longer than this. */
|
|
60
60
|
const FALLBACK_MAX_CHARS = 240;
|