pi-subagents 0.62.0 → 0.64.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/CHANGELOG.md +52 -1
- package/docs/agents.md +5 -4
- package/docs/configuration.md +28 -2
- package/docs/models.md +5 -5
- package/docs/observability.md +4 -1
- package/docs/tool-reference.md +2 -2
- package/docs/watchdog.md +92 -114
- package/package.json +1 -1
- package/skills/pi-subagents/references/execution-controls.md +4 -3
- package/skills/pi-subagents/references/management-authoring-rpc.md +1 -1
- package/skills/pi-subagents/references/prompting-and-roles.md +3 -3
- package/src/agents/agent-management.ts +22 -4
- package/src/agents/agents.ts +107 -125
- package/src/api/shared-types.ts +3 -0
- package/src/extension/config.ts +20 -0
- package/src/inspectors/herdr/inspector-runner.ts +19 -13
- package/src/runs/background/active-async-capacity.ts +0 -1
- package/src/runs/background/async-execution.ts +56 -7
- package/src/runs/background/async-resume.ts +3 -0
- package/src/runs/background/async-status.ts +18 -2
- package/src/runs/background/notify.ts +54 -3
- package/src/runs/background/run-status.ts +22 -2
- package/src/runs/background/subagent-runner.ts +53 -3
- package/src/runs/background/wait-completions.ts +13 -0
- package/src/runs/foreground/execution.ts +7 -1
- package/src/runs/foreground/subagent-executor.ts +56 -4
- package/src/runs/shared/acceptance.ts +25 -9
- package/src/runs/shared/async-status-projection.ts +11 -43
- package/src/runs/shared/lane-metadata.ts +24 -3
- package/src/runs/shared/parallel-handoff.ts +4 -0
- package/src/runs/shared/pi-args.ts +9 -6
- package/src/runs/shared/subagent-control.ts +4 -2
- package/src/runs/shared/task-intent.ts +5 -2
- package/src/runs/shared/worktree.ts +467 -63
- package/src/shared/types.ts +38 -2
- package/src/shared/utils.ts +18 -7
- package/src/slash/subagents-admin.ts +24 -12
- package/src/tui/fleet-status.ts +61 -2
- package/src/tui/fleet.ts +12 -7
- package/src/tui/render.ts +227 -14
- package/src/watchdog/child-status.ts +54 -33
- package/src/watchdog/diff-tool.ts +77 -0
- package/src/watchdog/emission-guard.ts +5 -3
- package/src/watchdog/guidance.ts +20 -0
- package/src/watchdog/register-child.ts +16 -13
- package/src/watchdog/register-main.ts +10 -9
- package/src/watchdog/render.ts +4 -5
- package/src/watchdog/review.ts +15 -4
- package/src/watchdog/rules.ts +70 -0
- package/src/watchdog/runtime.ts +75 -92
- package/src/watchdog/scope.ts +0 -11
- package/src/watchdog/settings.ts +48 -104
- package/src/watchdog/types.ts +18 -32
- package/src/watchdog/warning-format.ts +0 -1
- package/src/workflows/chat-progress.ts +3 -2
- package/src/workflows/workflow-checklist.ts +439 -0
- package/src/workflows/workflow-preflight.ts +28 -1
package/CHANGELOG.md
CHANGED
|
@@ -1,8 +1,59 @@
|
|
|
1
1
|
# Changelog
|
|
2
2
|
|
|
3
|
-
|
|
4
3
|
## [Unreleased]
|
|
5
4
|
|
|
5
|
+
## [0.64.0] - 2026-09-02
|
|
6
|
+
|
|
7
|
+
### Highlights
|
|
8
|
+
- Watchdog can now warn or block child launches before they start, based on role and model rules.
|
|
9
|
+
- Watchdog reviews are easier to guide with safe diff access, reusable `WATCHDOG.md` instructions, and configurable child review cadence.
|
|
10
|
+
- Watchdog findings are easier to see in parent results, completion notices, acceptance evidence, and Fleet.
|
|
11
|
+
- Workflow status and async results are less noisy and more accurate.
|
|
12
|
+
|
|
13
|
+
### Added
|
|
14
|
+
- Add watchdog launch rules under `subagents.watchdog.rules`, with per-role model allow and deny globs that warn or block before a child starts.
|
|
15
|
+
- Give watchdog reviewers a read-only `watchdog_diff` tool for session-start diffs, untracked paths, path narrowing, and stat summaries.
|
|
16
|
+
- Run child watchdog reviews on a configurable cadence with `children.cadence` and `children.overrides.<agent>.cadence`.
|
|
17
|
+
- Show child watchdog warnings in parent results, acceptance evidence, completion notices, and Fleet `wd:<n>` chips.
|
|
18
|
+
- Load watchdog reviewer instructions from project and agent `WATCHDOG.md` files.
|
|
19
|
+
|
|
20
|
+
### Changed
|
|
21
|
+
- Reject unsupported watchdog settings that never took effect: `delivery`, `showDuringRun`, `syncBacklog`, `lateWarningPolicy`, `compactAtPercent`, `reviewRetryDelayMs`, `maxReviewFailures`, `asyncCompletion`, and `guidance.systemPromptPath`.
|
|
22
|
+
- Remove watchdog auto-follow. Pi 0.84+ already continues after displayed boundary warnings, and repeated identical warnings now stop after `subagents.watchdog.stalemateRepeats`. The `autoFollow` settings block is now unknown.
|
|
23
|
+
|
|
24
|
+
### Fixed
|
|
25
|
+
- Keep advisory preflight checks out of runtime workflow rows and queued checklist counts (#1821). Thanks [@stekman08](https://github.com/stekman08).
|
|
26
|
+
- Preserve effective thinking in completed async step results. Thanks to [@Nickonomic](https://github.com/Nickonomic) for #1823.
|
|
27
|
+
- Forward workflow child control overrides through new and retained launches, and suppress idle needs-attention notices before the first assistant turn (#1817). Thanks [@rrocxela](https://github.com/rrocxela).
|
|
28
|
+
|
|
29
|
+
## [0.63.0] - 2026-09-01
|
|
30
|
+
|
|
31
|
+
### Highlights
|
|
32
|
+
- Workflow progress is easier to scan in status, Fleet, and live widgets.
|
|
33
|
+
- Additional agent folders can now be configured without copying definitions into one directory.
|
|
34
|
+
- Worktrunk users get managed worktrees automatically, with native Git available as the fallback.
|
|
35
|
+
- Fleet can jump straight into the selected child run's Herdr inspector.
|
|
36
|
+
- Async runs clean up and report edge cases more reliably.
|
|
37
|
+
|
|
38
|
+
### Added
|
|
39
|
+
- Show workflow progress as stacked checklist summaries in status, Fleet, and live widget views (#1806).
|
|
40
|
+
- Add configurable extra agent scan directories with one-segment wildcard expansion. Thanks to [@mystery4f](https://github.com/mystery4f) for #1801.
|
|
41
|
+
- Make Worktrunk a first-class managed worktree provider, selected automatically when available with native Git as the fallback (#1800).
|
|
42
|
+
- Let Fleet open the selected async child in its child-specific Herdr inspector. Thanks to [@stekman08](https://github.com/stekman08) for #1790.
|
|
43
|
+
|
|
44
|
+
### Changed
|
|
45
|
+
- Show workflow checklist phases first in collapsed views, while keeping child details available when expanded (#1810).
|
|
46
|
+
|
|
47
|
+
### Fixed
|
|
48
|
+
- Keep isolated test runs from writing agent definitions into an inherited `PI_CODING_AGENT_DIR`. Thanks to [@mapleluvr](https://github.com/mapleluvr) for #1809.
|
|
49
|
+
- Prevent nested tool-availability diagnostics from failing an otherwise valid parent result. Thanks to [@robertvangor](https://github.com/robertvangor) for #1802.
|
|
50
|
+
- Free async capacity correctly after workflows finish, even when saved step status is stale. Thanks to [@boggylp](https://github.com/boggylp) for #1804.
|
|
51
|
+
- Make `subagents.agentOverrides.<name>` replace matching custom-agent frontmatter fields, consistently with builtin agents. Thanks to [@expoli](https://github.com/expoli) for #1796.
|
|
52
|
+
- Strip the trailing Pi turn-timing footer from child output. Thanks to [@fkhawajagh](https://github.com/fkhawajagh) for #1792.
|
|
53
|
+
- Keep inferred acceptance reports out of reviewer and read-only child prompts. Thanks to [@expoli](https://github.com/expoli) for #1797.
|
|
54
|
+
- Preserve coordinated read-only intent when direct async children resume, and show captured structured output in completion and status evidence. Thanks to [@fkhawajagh](https://github.com/fkhawajagh) for #1788.
|
|
55
|
+
- Keep macOS subagent tasks out of argv by delivering them through temporary files. Thanks to [@josephkallas](https://github.com/josephkallas) for #1793.
|
|
56
|
+
|
|
6
57
|
## [0.62.0] - 2026-08-31
|
|
7
58
|
|
|
8
59
|
### Highlights
|
package/docs/agents.md
CHANGED
|
@@ -27,6 +27,7 @@ Discovery notes:
|
|
|
27
27
|
|
|
28
28
|
- Project discovery also reads legacy `.agents/**/*.md` files. If both `.agents/` and the project config agents directory define the same parsed runtime agent name, the project config directory wins.
|
|
29
29
|
- Nested subdirectories are discovered recursively. `.chain.md` files do not define agents.
|
|
30
|
+
- User and project settings can add extra recursive scan roots with `subagents.agentScanDirs`; fixed user/project agent directories keep higher priority than same-name agents from scan roots.
|
|
30
31
|
- Installed Pi packages can expose agent directories from either `{"pi-subagents":{"agents":["./agents"]}}` or `{"pi":{"subagents":{"agents":["./agents"]}}}` in their package manifest. Package agents load above builtins and below user/project agents.
|
|
31
32
|
- Use `agentScope: "user" | "project" | "both"` to control discovery. `both` is the default, and project definitions win runtime-name collisions.
|
|
32
33
|
|
|
@@ -189,9 +190,9 @@ The `researcher` builtin uses `web_search`, `fetch_content`, and `get_search_con
|
|
|
189
190
|
pi install npm:pi-web-access
|
|
190
191
|
```
|
|
191
192
|
|
|
192
|
-
## Overriding builtins
|
|
193
|
+
## Overriding builtins and custom agents
|
|
193
194
|
|
|
194
|
-
You can override selected
|
|
195
|
+
You can override selected agent fields without copying the whole agent. Overrides live in settings:
|
|
195
196
|
|
|
196
197
|
- User: `~/.pi/agent/settings.json`
|
|
197
198
|
- Project: project config settings file (`.pi/settings.json` in standard Pi)
|
|
@@ -213,9 +214,9 @@ Supported override fields: `description`, `output`, `outputMode`, `defaultReads`
|
|
|
213
214
|
|
|
214
215
|
- `description` replaces the discovered description for builtin and custom agents, which lets list output show deployment-specific routing or model metadata.
|
|
215
216
|
- Use `output: false`, `defaultReads: false`, `defaultContext: false`, or `acceptanceRole: false` to clear an inherited value.
|
|
216
|
-
- Use `tools: "inherit"`
|
|
217
|
+
- Use `tools: "inherit"` when that one role should omit its bundled or frontmatter tool allowlist and receive Pi's normal builtins and ambient extensions.
|
|
217
218
|
- Project overrides beat user overrides.
|
|
218
|
-
- Matching user and project agents also receive override fields
|
|
219
|
+
- Matching package, user, and project agents also receive override fields, which replace the same fields declared in their frontmatter. This lets a shared agent keep its persona while local settings choose the effective model, context, tools, or other supported options.
|
|
219
220
|
|
|
220
221
|
Disable and restore:
|
|
221
222
|
|
package/docs/configuration.md
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
`pi-subagents` reads optional JSON config from `~/.pi/agent/extensions/subagent/config.json`. This page lists every key, plus the environment variables and the settings-file keys that affect config resolution.
|
|
4
4
|
|
|
5
|
-
Settings-level keys (`subagents.defaultModel`, `defaultProvider`, `defaultThinking`, `defaultExtensions`, `agentOverrides`, `modelScope`, `disableThinking`, `disableBuiltins`, watchdog settings) live in Pi settings files, not this config file. `modelScope.agents.<name>` adds per-agent restrictions, and `allow: ["inherit"]` permits the current parent model. See [models.md](models.md), [agents.md](agents.md), and [watchdog.md](watchdog.md).
|
|
5
|
+
Settings-level keys (`subagents.defaultModel`, `defaultProvider`, `defaultThinking`, `defaultExtensions`, `agentOverrides`, `agentScanDirs`, `modelScope`, `disableThinking`, `disableBuiltins`, watchdog settings) live in Pi settings files, not this config file. `modelScope.agents.<name>` adds per-agent restrictions, and `allow: ["inherit"]` permits the current parent model. See [models.md](models.md), [agents.md](agents.md), and [watchdog.md](watchdog.md).
|
|
6
6
|
|
|
7
7
|
## Project root resolution (settings)
|
|
8
8
|
|
|
@@ -18,6 +18,20 @@ By default, project settings resolve from the nearest parent directory that cont
|
|
|
18
18
|
|
|
19
19
|
`"git-root"` keeps package discovery, project agents, chains, and `agentOverrides` anchored to the git worktree root when that root also has Pi project config. A nested project can still opt back into nearest-root behavior by setting `"projectRootResolution": "nearest"` in its own `.pi/settings.json`.
|
|
20
20
|
|
|
21
|
+
## Extra agent scan directories (settings)
|
|
22
|
+
|
|
23
|
+
Add recursive user or project agent roots with `subagents.agentScanDirs` in Pi settings:
|
|
24
|
+
|
|
25
|
+
```json
|
|
26
|
+
{
|
|
27
|
+
"subagents": {
|
|
28
|
+
"agentScanDirs": ["~/.pi/flows/*/agents"]
|
|
29
|
+
}
|
|
30
|
+
}
|
|
31
|
+
```
|
|
32
|
+
|
|
33
|
+
Entries support `~` expansion. A single `*` path segment expands one directory level, so package-like folders can each expose an `agents/` directory. Missing directories are ignored. Fixed user/project agent directories still win over same-name agents from scan roots.
|
|
34
|
+
|
|
21
35
|
## `modelExclusions`
|
|
22
36
|
|
|
23
37
|
```json
|
|
@@ -356,7 +370,7 @@ Overrides the command used to launch child Pi processes. Package wrappers can se
|
|
|
356
370
|
export PI_SUBAGENT_TASK_DELIVERY=file # auto | file (default: auto)
|
|
357
371
|
```
|
|
358
372
|
|
|
359
|
-
Controls how the task text reaches the child Pi process. `auto` (default) passes short tasks as an inline argv token and writes tasks longer than 8000 characters to a temp `task.md` referenced as `@<path>`. `file` always uses a temp file, keeping the task out of argv entirely.
|
|
373
|
+
Controls how the task text reaches the child Pi process. `auto` (default) passes short non-macOS tasks as an inline argv token, and writes macOS tasks plus tasks longer than 8000 characters to a temp `task.md` referenced as `@<path>`. `file` always uses a temp file, keeping the task out of argv entirely.
|
|
360
374
|
|
|
361
375
|
Use `file` on hosts where endpoint protection (EDR) pre-execution scanning denies child processes whose command line embeds a long natural-language task — that denial surfaces as an immediate zero-activity `SIGKILL`. Independently of this setting, startup retries automatically escalate to file delivery after an unexplained zero-activity `SIGKILL`. Empty, whitespace-only, or unrecognized values fall back to `auto`.
|
|
362
376
|
|
|
@@ -392,6 +406,18 @@ The default injected guidance tells children to use `contact_supervisor` with `r
|
|
|
392
406
|
|
|
393
407
|
Sets the base directory for `worktree: true` runs. Relative paths resolve from the repository root, `~/...` expands to your home directory, and `PI_SUBAGENTS_WORKTREE_DIR` is used when config is unset. The default remains the system temp directory.
|
|
394
408
|
|
|
409
|
+
## `worktreeProvider`
|
|
410
|
+
|
|
411
|
+
```json
|
|
412
|
+
{ "worktreeProvider": "auto", "worktreeBranchPrefix": "pi-subagents/" }
|
|
413
|
+
```
|
|
414
|
+
|
|
415
|
+
Selects the managed worktree allocator: `auto` (the default) uses Worktrunk when its machine-readable interface is available and otherwise falls back to Pi's native Git worktrees; `native` always uses Pi's Git implementation; and `worktrunk` fails closed when Worktrunk is unavailable or incompatible. A configured `worktreeBaseDir` (or `PI_SUBAGENTS_WORKTREE_DIR`) selects native allocation and cannot be combined with explicit `worktrunk`.
|
|
416
|
+
|
|
417
|
+
`worktreeBranchPrefix` is normalized as a Git ref namespace and defaults to `pi-subagents/`. Branch names include readable task/lane identity plus run and fan-out indexes. Pi continues to own setup hooks, launch, handoff/diff evidence, resume, and cleanup; Worktrunk is used only to allocate and report the worktree path.
|
|
418
|
+
|
|
419
|
+
Set `worktree` to `true` to make managed worktree isolation the default for launches that omit the per-call `worktree` flag. A per-call value still takes precedence.
|
|
420
|
+
|
|
395
421
|
## `worktreeSetupHook`
|
|
396
422
|
|
|
397
423
|
```json
|
package/docs/models.md
CHANGED
|
@@ -11,7 +11,7 @@ Builtin agents inherit your current Pi default model. This keeps new installs fr
|
|
|
11
11
|
- `subagents.agentOverridesByProvider.<provider>.<name>` — layer role fields for the active parent provider.
|
|
12
12
|
- Per-run overrides — for one launch only.
|
|
13
13
|
|
|
14
|
-
Precedence, strongest first: per-run override →
|
|
14
|
+
Precedence, strongest first: per-run override → provider-scoped role override → `agentOverrides.<name>.model` → agent frontmatter `model` → `subagents.defaultModel` → the parent session model. A provider preference does not replace this order; it only resolves bare model ids when the active registry has more than one match. Fully qualified `provider/model` strings still win exactly.
|
|
15
15
|
|
|
16
16
|
Use `model: "inherit"` in agent frontmatter or `agentOverrides.<name>.model` to select the current parent session model explicitly.
|
|
17
17
|
|
|
@@ -81,7 +81,7 @@ For a persistent role override with a backup model for provider failures:
|
|
|
81
81
|
}
|
|
82
82
|
```
|
|
83
83
|
|
|
84
|
-
`subagents.defaultModel` and `subagents.defaultProvider` apply to builtin, package, user, and project agents. `defaultModel` fills only agents that do not set `model` in frontmatter. `defaultProvider` is also applied to frontmatter and override models so bare ids resolve against the intended provider. Per-run model overrides and `agentOverrides.<name>.model`
|
|
84
|
+
`subagents.defaultModel` and `subagents.defaultProvider` apply to builtin, package, user, and project agents. `defaultModel` fills only agents that do not set `model` in frontmatter. `defaultProvider` is also applied to frontmatter and override models so bare ids resolve against the intended provider. Per-run model overrides and `agentOverrides.<name>.model` win over frontmatter and the global default. The same `agentOverrides` block can change `tools`, `skills`, inherited context, prompt text, or disable an agent (see [agents.md](agents.md)); matching custom-agent frontmatter is replaced for any field set by the override.
|
|
85
85
|
|
|
86
86
|
## Fast mode
|
|
87
87
|
|
|
@@ -116,7 +116,7 @@ One interaction worth knowing for tier 4: forked context over an Anthropic paren
|
|
|
116
116
|
|
|
117
117
|
## Thinking level defaults
|
|
118
118
|
|
|
119
|
-
Set `subagents.defaultThinking` to give builtin, package, user, and project agents without a `thinking` value a shared thinking level, independent of the parent session's default. Project settings win over user settings.
|
|
119
|
+
Set `subagents.defaultThinking` to give builtin, package, user, and project agents without a `thinking` value a shared thinking level, independent of the parent session's default. Project settings win over user settings. Matching `agentOverrides.<name>.thinking` and per-run thinking overrides replace frontmatter; otherwise explicit frontmatter remains in effect. `thinking: false` remains an explicit opt-out:
|
|
120
120
|
|
|
121
121
|
```json
|
|
122
122
|
{
|
|
@@ -129,7 +129,7 @@ Set `subagents.defaultThinking` to give builtin, package, user, and project agen
|
|
|
129
129
|
}
|
|
130
130
|
```
|
|
131
131
|
|
|
132
|
-
If your provider rejects model IDs with thinking suffixes, set `subagents.disableThinking: true` in user or project settings. That clears bundled builtin thinking defaults in one place. An explicit higher-precedence `agentOverrides.<name>.thinking` value can opt a role back in
|
|
132
|
+
If your provider rejects model IDs with thinking suffixes, set `subagents.disableThinking: true` in user or project settings. That clears bundled builtin thinking defaults in one place. An explicit higher-precedence `agentOverrides.<name>.thinking` value can opt a role back in or replace custom-agent frontmatter thinking.
|
|
133
133
|
|
|
134
134
|
### Thinking ceiling
|
|
135
135
|
|
|
@@ -154,7 +154,7 @@ Set `subagents.defaultExtensions` to give builtin, package, user, and project ag
|
|
|
154
154
|
- Empty array: sets `extensions: []` for agents that do not explicitly define it, disabling ambient extension loading.
|
|
155
155
|
- Non-empty array: supplies that allowlist to agents that do not explicitly define one.
|
|
156
156
|
|
|
157
|
-
Project settings win over user settings. Use `agentOverrides.<name>.extensions` for per-agent settings;
|
|
157
|
+
Project settings win over user settings. Use `agentOverrides.<name>.extensions` for per-agent settings; a matching override replaces custom-agent frontmatter for that field.
|
|
158
158
|
|
|
159
159
|
```json
|
|
160
160
|
{
|
package/docs/observability.md
CHANGED
|
@@ -54,7 +54,7 @@ After you expand it:
|
|
|
54
54
|
reviewer · running 38s · ↓ 1.1k window · 1.4k spent
|
|
55
55
|
```
|
|
56
56
|
|
|
57
|
-
When the focused editor is empty, press `↓` or `←` to expand the summary into `main` plus active children with agent name, state, elapsed time, and token usage. When providers report usage, `window` is the latest assistant turn's input plus cache-read tokens, while `spent` keeps the cumulative input-plus-output total. Old run artifacts without window data keep the existing token-total label. The compact line counts active current-session work and Herdr project panes. Then use `↑`/`↓` or `j`/`k` to select a child and `Enter` to
|
|
57
|
+
When the focused editor is empty, press `↓` or `←` to expand the summary into `main` plus active children with agent name, state, elapsed time, and token usage. When providers report usage, `window` is the latest assistant turn's input plus cache-read tokens, while `spent` keeps the cumulative input-plus-output total. Old run artifacts without window data keep the existing token-total label. The compact line counts active current-session work and Herdr project panes. Then use `↑`/`↓` or `j`/`k` to select a child and `Enter` to open the Fleet lobby; press `Enter` or `H` there to open its child-specific Herdr inspector. Printable navigation keys are never intercepted before activation.
|
|
58
58
|
|
|
59
59
|
FleetView replaces the legacy above-editor async widget by default. Successful background completions stay quiet so inactive Pi tabs are not marked unread, while failed or paused completions still notify the originating session. Parallel runs show every active child independently. Chains with parallel groups keep their grouped shape in progress and results, so failed or paused agents stay visible next to completed ones. When a child is explicitly allowed to fan out with `tools: subagent` or `allowNestedSubagents: true`, its nested runs appear under that parent child in the main status tree instead of being hidden inside the child process.
|
|
60
60
|
|
|
@@ -70,6 +70,7 @@ Default keys:
|
|
|
70
70
|
- `x`/`Ctrl+O` — toggle tool details
|
|
71
71
|
- `r` — refresh
|
|
72
72
|
- `Esc` — close
|
|
73
|
+
- `Enter` — open the selected inspectable async child in its child-specific Herdr inspector
|
|
73
74
|
- `s` — compose an acknowledged message to a selected live async child; Tab cycles `steer`, `follow_up`, and `auto`
|
|
74
75
|
- `D` — stop a selected child's top-level async run after confirmation
|
|
75
76
|
- `H` — open the selected active async child in a Herdr inspector pane (Herdr 0.7.5+)
|
|
@@ -78,6 +79,8 @@ Set `fleetKeybindings` in the extension config to replace inspector-level keys w
|
|
|
78
79
|
|
|
79
80
|
`Ctrl+Alt+F` opens the same inspector even while a foreground turn is active and slash input is queued.
|
|
80
81
|
|
|
82
|
+
Enter and `H` use the existing Herdr pane path. In a child-specific Herdr inspector, type ordinary guidance and press Enter to send it through the acknowledged steer channel; `steer <message>`, `status`, and `stop` remain available as explicit controls.
|
|
83
|
+
|
|
81
84
|
Without a TUI, `/subagents-fleet` retains the textual `subagent({ action: "status", view: "fleet" })` fallback, and mutations use explicit commands: run `/subagents-stop` and pick from the selector, or use `/subagents-stop <run-id>` / `subagent({ action: "stop", id: "..." })` when you already know the id.
|
|
82
85
|
|
|
83
86
|
Use `/subagents-detach [run-id]` only for an active foreground single-subagent run you want to leave running without terminating; the eventual result remains available through status/wait.
|
package/docs/tool-reference.md
CHANGED
|
@@ -393,7 +393,7 @@ Acceptance evidence levels are `auto`, `none`, `attested`, `checked`, and `verif
|
|
|
393
393
|
Review is a separate gate configured with `acceptance.review`:
|
|
394
394
|
|
|
395
395
|
- Async, risky, and dynamic writer contexts infer checked evidence plus `review: { agent: "reviewer", required: true }`.
|
|
396
|
-
-
|
|
396
|
+
- Reviewer/read-only calls infer no acceptance by default; explicit acceptance requests still apply.
|
|
397
397
|
- Normal writer tasks infer checked evidence without review.
|
|
398
398
|
|
|
399
399
|
Agent frontmatter or `subagents.agentOverrides` may set `acceptanceRole: "read-only" | "writer"` for ambiguous tasks. Explicit task mutation or no-edit intent wins over that role, while omitted metadata preserves the existing reviewer/scout/worker name heuristics. The role affects acceptance inference only and does not change tool access.
|
|
@@ -420,7 +420,7 @@ Acceptance provenance is stored separately from child prose. `evidenceStatus` pr
|
|
|
420
420
|
|
|
421
421
|
### The acceptance report
|
|
422
422
|
|
|
423
|
-
For `attested` or stricter levels, the child prompt includes a standardized acceptance section and asks for a fenced `acceptance-report` JSON block. With `outputSchema`, set `acceptance.report: "on"` to require the same report in the final `structured_output` call, or `"off"` to keep the fenced-report path. Omitting `report` preserves the default behavior. Runs without `outputSchema` never gain a standalone structured-output tool from this option.
|
|
423
|
+
For `attested` or stricter levels, the child prompt includes a standardized acceptance section and asks for a fenced `acceptance-report` JSON block. Reviewer/read-only inference resolves to `none`, so it does not add this section; explicit acceptance still does. With `outputSchema`, set `acceptance.report: "on"` to require the same report in the final `structured_output` call, or `"off"` to keep the fenced-report path. Omitting `report` preserves the default behavior. Runs without `outputSchema` never gain a standalone structured-output tool from this option.
|
|
424
424
|
|
|
425
425
|
The parser canonicalizes known enum synonyms, snake_case report keys and wrappers, underscore fence tags, unambiguous scalar arrays, string booleans, and criterion-id separators. Unknown or ambiguous keys and enum values fail with field-level diagnostics. Explicit empty `changedFiles` and `testsAddedOrUpdated` arrays are recorded as not applicable; missing fields and empty required command or validation evidence still fail.
|
|
426
426
|
|
package/docs/watchdog.md
CHANGED
|
@@ -1,145 +1,142 @@
|
|
|
1
1
|
# Watchdog and child permissions
|
|
2
2
|
|
|
3
|
-
The watchdog is an opt-in
|
|
3
|
+
The watchdog is an opt-in second model that reviews what the agent just did and pushes findings back into the transcript. It looks for missed constraints, correctness risks, test gaps, unsafe changes, loop risks, and scope drift, and says nothing when the turn is clean. It is not the `reviewer` subagent; `subagents.defaultModel` and `agentOverrides.reviewer` do not configure it.
|
|
4
4
|
|
|
5
|
-
##
|
|
5
|
+
## When it runs
|
|
6
6
|
|
|
7
|
-
|
|
7
|
+
| Timing | Trigger | Gate | Delivery |
|
|
8
|
+
|---|---|---|---|
|
|
9
|
+
| Boundary review | `agent_end` of every main or child turn | Repo changed | Steered into the transcript; the agent gets one continuation, then that turn is reviewed again |
|
|
10
|
+
| Cadence review | Every `cadence.everyNTools` tool results, minimum 5 | Opt-in | Steered after the current tool, before the next step |
|
|
11
|
+
| LSP pre-pass | Before boundary review | Changed TypeScript/JavaScript files | Diagnostics become watchdog findings without a model call |
|
|
8
12
|
|
|
9
|
-
|
|
13
|
+
Boundary reviews coalesce a turn's edits into one final-state review. Unchanged or reverted diffs are skipped, as are `.pi/subagents/` and `tmp/` artifacts. In orchestrated runs, each writing child reviews its own worktree and the parent reviews the aggregate diff after child changes land. There is no timer or "every turn regardless of edits" mode; the closest is a low cadence such as `everyNTools: 5`. Cadence monitoring is inspired by [Scopey](https://github.com/ArchAstro/scopey).
|
|
10
14
|
|
|
11
|
-
|
|
12
|
-
- Multiple edits in one turn are coalesced into one review of the final changed state.
|
|
13
|
-
- Unchanged/reverted diffs are skipped.
|
|
14
|
-
- Generated `.pi/subagents/` or `tmp/` artifacts do not trigger review.
|
|
15
|
-
- In orchestrated runs, each writing child can review its own edited worktree, and the parent can still review the aggregate repo diff after child changes are applied.
|
|
15
|
+
Children get the same boundary, cadence, and LSP behavior. Child cadence resolves from `children.overrides.<agent>.cadence`, then `children.cadence`, then top-level `cadence`:
|
|
16
16
|
|
|
17
|
-
|
|
17
|
+
```json
|
|
18
|
+
{
|
|
19
|
+
"subagents": {
|
|
20
|
+
"watchdog": {
|
|
21
|
+
"enabled": true,
|
|
22
|
+
"cadence": { "everyNTools": 10 },
|
|
23
|
+
"children": {
|
|
24
|
+
"enabled": true,
|
|
25
|
+
"cadence": { "everyNTools": 20 },
|
|
26
|
+
"overrides": {
|
|
27
|
+
"worker": { "cadence": { "everyNTools": 5 } },
|
|
28
|
+
"reviewer": { "enabled": false }
|
|
29
|
+
}
|
|
30
|
+
}
|
|
31
|
+
}
|
|
32
|
+
}
|
|
33
|
+
}
|
|
34
|
+
```
|
|
18
35
|
|
|
19
|
-
|
|
36
|
+
That means: main every 10 tools, worker every 5, other children every 20, reviewer never.
|
|
20
37
|
|
|
21
|
-
|
|
38
|
+
## What you see
|
|
22
39
|
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
40
|
+
Every finding is an ordinary transcript message: expandable, scrollable, and persisted in session JSONL. A clean review shows nothing.
|
|
41
|
+
|
|
42
|
+
```
|
|
43
|
+
you ─▶ agent turn ─▶ edits repo ─▶ agent_end ─▶ watchdog review
|
|
44
|
+
├─ clean: turn ends
|
|
45
|
+
└─ warning: steered in; agent continues once
|
|
27
46
|
```
|
|
28
47
|
|
|
29
|
-
|
|
48
|
+
Collapsed warnings show the title and evidence line. Expanded warnings show evidence, recommended action, category, and source:
|
|
30
49
|
|
|
31
|
-
|
|
32
|
-
|
|
50
|
+
```
|
|
51
|
+
● Subagent watchdog Blocker (displayed): Claims tests passed without running them
|
|
52
|
+
Evidence: The transcript claims `npm test` passed but no test command appears in the tool log.
|
|
53
|
+
Recommended action: Run the focused test before finishing.
|
|
54
|
+
Category: Test Gap · Source: main
|
|
55
|
+
```
|
|
33
56
|
|
|
34
|
-
|
|
57
|
+
When consecutive boundary reviews raise the same warning, the agent is not making progress. After `stalemateRepeats` identical warnings in a row (default 3), the warning is shown as `stalemate`, no continuation is triggered, and the turn ends. Your next prompt resets the count.
|
|
35
58
|
|
|
36
|
-
|
|
37
|
-
/subagents-watchdog model anthropic/claude-opus-4-8:high
|
|
38
|
-
/subagents-watchdog model openai-codex/gpt-5.5:high
|
|
39
|
-
/subagents-watchdog model inherit
|
|
40
|
-
/subagents-watchdog check
|
|
41
|
-
```
|
|
59
|
+
Child watchdog findings are lifted into the parent in three ways:
|
|
42
60
|
|
|
43
|
-
|
|
61
|
+
- The result envelope contains `watchdog.warnings` with severity, category, summary, evidence, recommended action, `addressed`, and `stalemate`, bounded to the last 20.
|
|
62
|
+
- The acceptance runtime check `watchdog-blocker` fails on blockers that are unaddressed or stalemate.
|
|
63
|
+
- Completion notices include `Watchdog blockers:` lines, and Fleet/status views show `wd:<n>` plus `resolve watchdog blockers`.
|
|
44
64
|
|
|
45
|
-
-
|
|
46
|
-
- If `main.model` is set without a thinking suffix or `main.thinking`, it runs with thinking off. Prefer `:high` or `"thinking": "high"` for the strong-watchdog pairing.
|
|
65
|
+
`/subagents-watchdog status` shows setting sources, enabled state, runtime state, review trigger, scope, cadence, LSP status, selected model/thinking, child overrides, timeout, stalemate count, launch-rule count, review backend, last warning, changed paths, and config errors when present.
|
|
47
66
|
|
|
48
|
-
|
|
67
|
+
## What the reviewer is given
|
|
49
68
|
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
"main": {
|
|
56
|
-
"model": "anthropic/claude-opus-4-8",
|
|
57
|
-
"thinking": "high"
|
|
58
|
-
}
|
|
59
|
-
}
|
|
60
|
-
}
|
|
61
|
-
}
|
|
62
|
-
```
|
|
69
|
+
- **Turn delta** with changed repo paths. Over-long input keeps the first 6,000 characters and the tail.
|
|
70
|
+
- **Current scope** (`scope.enabled`, default on): bounded real user prompts, with newer prompts superseding older ones.
|
|
71
|
+
- **`watchdog_diff`** when inside git: diff since the session-start commit, including later commits, plus untracked paths to inspect with `read`; accepts `path` and `stat:true`.
|
|
72
|
+
- **`WATCHDOG.md`** standing instructions, read fresh on every review: `<project>/.pi/WATCHDOG.md` first, then `~/.pi/agent/WATCHDOG.md`, capped at 8,000 characters. Set `guidance.watchdogMd: false` to ignore them.
|
|
73
|
+
- **LSP diagnostics** from `typescript-language-server`, auto-detected in `node_modules/.bin` or `PATH`; it is never installed and never run over the whole workspace. Errors become blockers, warnings concerns, and info/hints stay in status.
|
|
63
74
|
|
|
64
|
-
##
|
|
75
|
+
## Choosing a model
|
|
65
76
|
|
|
66
|
-
|
|
77
|
+
One model setting serves both boundary and cadence reviews per endpoint. Use a strong complementary model for rare adversarial boundary reviews, or a cheap one for frequent cadence monitoring.
|
|
67
78
|
|
|
68
|
-
|
|
79
|
+
```text
|
|
80
|
+
/subagents-watchdog recommend-model
|
|
81
|
+
/subagents-watchdog session model recommended
|
|
82
|
+
/subagents-watchdog model recommended
|
|
83
|
+
/subagents-watchdog model anthropic/claude-opus-4-8:high
|
|
84
|
+
/subagents-watchdog model openai-codex/gpt-5.5:high
|
|
85
|
+
/subagents-watchdog model inherit
|
|
86
|
+
/subagents-watchdog check
|
|
87
|
+
/subagents-watchdog on
|
|
88
|
+
```
|
|
69
89
|
|
|
70
|
-
|
|
90
|
+
The recommendation is Opus 4.8 or GPT 5.5 at thinking high, whichever your main session is not using and is authenticated. Saving a model does not enable the watchdog; use `on` separately.
|
|
71
91
|
|
|
72
92
|
```json
|
|
73
93
|
{
|
|
74
94
|
"subagents": {
|
|
75
95
|
"watchdog": {
|
|
76
96
|
"enabled": true,
|
|
77
|
-
"main": {
|
|
78
|
-
"model": "anthropic/claude-haiku-4-5",
|
|
79
|
-
"thinking": "medium"
|
|
80
|
-
},
|
|
97
|
+
"main": { "model": "anthropic/claude-opus-4-8", "thinking": "high" },
|
|
81
98
|
"scope": { "enabled": true },
|
|
82
99
|
"cadence": { "everyNTools": 10 },
|
|
83
|
-
"
|
|
84
|
-
"blockers": true,
|
|
85
|
-
"maxAttempts": 3,
|
|
86
|
-
"stalemateRepeats": 3
|
|
87
|
-
}
|
|
100
|
+
"stalemateRepeats": 3
|
|
88
101
|
}
|
|
89
102
|
}
|
|
90
103
|
}
|
|
91
104
|
```
|
|
92
105
|
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
When the watchdog displays a blocker at `agent_end`, the `subagents.watchdog.autoFollow` policy can queue a visible follow-up user message asking the agent to address it. Auto-follow only runs while the watchdog is enabled, respects `maxAttempts`, and stops on repeated identical blockers using `stalemateRepeats`.
|
|
96
|
-
|
|
97
|
-
## LSP diagnostics
|
|
98
|
-
|
|
99
|
-
When the watchdog is enabled, it also checks changed TypeScript and JavaScript files for fresh language-server diagnostics before the model review.
|
|
106
|
+
Omit `main.model` to inherit the session model and thinking level. A `main.model` without a thinking suffix or `main.thinking` runs with thinking off, so prefer `:high` for the strong pairing.
|
|
100
107
|
|
|
101
|
-
|
|
102
|
-
- LSP errors surface as watchdog blockers, warnings as concerns, and info/hints stay in status details.
|
|
103
|
-
- Slow or missing servers are reported in `/subagents-watchdog status` without blocking the turn or emitting late mid-turn warnings.
|
|
104
|
-
- Configure the bounds with `subagents.watchdog.lsp.enabled`, `timeoutMs`, `maxFiles`, and `maxDiagnostics`.
|
|
108
|
+
Agents can call `subagent({ action: "watchdog.recommend-model" })` and `subagent({ action: "watchdog.configure", model: "recommended", scope: "session" | "user" | "project" })`. They should use `scope: "session"` unless you ask for a lasting default.
|
|
105
109
|
|
|
106
110
|
## Child watchdogs
|
|
107
111
|
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
Child watchdogs are opt-in and follow the same edit-gated rule: read-only children do not trigger watchdog reviews, while writer children are reviewed at their own `agent_end` if their worktree changed.
|
|
111
|
-
|
|
112
|
-
## Agent-driven configuration
|
|
113
|
-
|
|
114
|
-
Agents can configure the same values through the tool when you ask them to set up the watchdog:
|
|
115
|
-
|
|
116
|
-
```ts
|
|
117
|
-
subagent({ action: "watchdog.recommend-model" })
|
|
118
|
-
subagent({ action: "watchdog.configure", model: "recommended", scope: "session" })
|
|
119
|
-
subagent({ action: "watchdog.configure", model: "recommended", scope: "project" })
|
|
120
|
-
```
|
|
121
|
-
|
|
122
|
-
Persistent scopes (`user` or `project`) should only be used when you ask for a lasting default. Otherwise the agent should use `scope: "session"`.
|
|
112
|
+
Opt in under `subagents.watchdog.children`. `model` and `thinking` set the default child watchdog; `overrides.<agent>` can set `model`, `thinking`, `enabled`, or `cadence` per role.
|
|
123
113
|
|
|
124
|
-
##
|
|
114
|
+
## Launch rules
|
|
125
115
|
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
Configure explicit non-bash rules globally in `~/.pi/agent/extensions/subagent/config.json`:
|
|
116
|
+
`subagents.watchdog.rules` pins which models each role may run on. It runs before a child starts, needs no model call, and applies even when model review is off.
|
|
129
117
|
|
|
130
118
|
```json
|
|
131
119
|
{
|
|
132
|
-
"
|
|
133
|
-
"
|
|
134
|
-
"
|
|
135
|
-
|
|
136
|
-
|
|
120
|
+
"subagents": {
|
|
121
|
+
"watchdog": {
|
|
122
|
+
"rules": {
|
|
123
|
+
"action": "warn",
|
|
124
|
+
"roleModels": {
|
|
125
|
+
"scout": { "allow": ["openai-codex/gpt-5.6-luna:max"] },
|
|
126
|
+
"oracle": { "deny": ["*"], "note": "oracle is for hard questions only; ask before launching" },
|
|
127
|
+
"worker": { "deny": ["openai-codex/gpt-5.6-sol:high"] }
|
|
128
|
+
}
|
|
129
|
+
}
|
|
137
130
|
}
|
|
138
131
|
}
|
|
139
132
|
}
|
|
140
133
|
```
|
|
141
134
|
|
|
142
|
-
|
|
135
|
+
`action: "warn"` steers a concern into the orchestrator transcript and lets the launch proceed. `action: "block"` returns a tool error and starts nothing. `allow` and `deny` are anchored, case-sensitive globs (`*`, `?`) matched against `provider/id[:thinking]` and bare `provider/id`; `deny` wins. Rules apply to direct launches, workflow children, and chain/parallel steps using settings visible at the launch cwd.
|
|
136
|
+
|
|
137
|
+
## Native child tool permissions
|
|
138
|
+
|
|
139
|
+
Opt-in, Pi child runtimes only. With no rules, every tool call passes through. Global non-bash rules live in `~/.pi/agent/extensions/subagent/config.json`; agents override matching rules in `permission:` or `permissions:` frontmatter:
|
|
143
140
|
|
|
144
141
|
```yaml
|
|
145
142
|
---
|
|
@@ -150,27 +147,8 @@ permission:
|
|
|
150
147
|
---
|
|
151
148
|
```
|
|
152
149
|
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
- Agent rules override matching global rules.
|
|
156
|
-
- Omitted and unknown tools default to `allow`.
|
|
157
|
-
- Explicit `allow` removes an inherited restriction.
|
|
158
|
-
- The gate is not registered when the resolved policy has no `ask` or `deny` rules.
|
|
159
|
-
|
|
160
|
-
### How `ask` works
|
|
161
|
-
|
|
162
|
-
An explicit `ask` pauses that exact tool call and sends a bounded, redacted preview to a one-call permission arbiter owned by the built-in child watchdog. The arbiter uses the configured child-watchdog model and returns only `approve` or `deny`; it does not notify the parent agent.
|
|
163
|
-
|
|
164
|
-
Enable and configure `subagents.watchdog.children` before using `ask` rules. A disabled watchdog, missing model/auth, timeout, malformed response, or runtime error denies the call with a clear error.
|
|
165
|
-
|
|
166
|
-
Asked requests and decisions are written to bounded audit JSONL, including `decisionSource: "watchdog"` and bounded failure reasons. Ordinary direction and clarification through `contact_supervisor` or the optional `pi-intercom` extension remain separate and are never permission-gated.
|
|
167
|
-
|
|
168
|
-
### Bash is out of scope
|
|
169
|
-
|
|
170
|
-
`bash` is always passed through by pi-subagents. Bash rules are rejected rather than parsed, gated, denied, or audited. Install and configure `pi-guard` when command-level bash policy is needed.
|
|
171
|
-
|
|
172
|
-
A pi-subagents child is headless, so a pi-guard rule that resolves to `ask` cannot request approval from the parent Pi UI. Native permissions do not forward pi-guard decisions; they only apply to the separate non-bash child permission gate. For child-specific policy, use `PI_GUARD` through a `PI_SUBAGENT_PI_BINARY` wrapper or an equivalent launch wrapper, and configure explicit `allow` or `deny` rules. An `allow` rule grants execution; it is not approval forwarding, so retain explicit denies for commands the child must not run.
|
|
150
|
+
Values are `allow`, `ask`, and `deny`. Agent rules override global ones, omitted and unknown tools default to `allow`, an explicit `allow` removes an inherited restriction, and the gate is not registered when the resolved policy has no `ask` or `deny`.
|
|
173
151
|
|
|
174
|
-
|
|
152
|
+
`ask` pauses that exact tool call and sends a bounded, redacted preview to a one-call arbiter owned by the child watchdog, using the configured child-watchdog model. The arbiter returns only `approve` or `deny` and does not notify the parent. A disabled watchdog, missing model/auth, timeout, malformed response, or runtime error denies the call with a clear error. Requests and decisions are written to bounded audit JSONL. `contact_supervisor` and the optional `pi-intercom` extension are never permission-gated.
|
|
175
153
|
|
|
176
|
-
External CLI profiles are opaque processes, so native permissions cannot intercept their tools
|
|
154
|
+
Bash is always passed through; bash rules are rejected. Use `pi-guard` for command-level policy. For child-specific command policy, run `PI_GUARD` through a `PI_SUBAGENT_PI_BINARY` wrapper with explicit `allow` or `deny` rules. External CLI profiles are opaque processes, so native permissions cannot intercept their tools; launches with effective `ask` or `deny` rules are rejected for external CLI agents.
|
package/package.json
CHANGED
|
@@ -337,9 +337,10 @@ child changes land. Enabled watchdogs also run changed-file TypeScript/JavaScrip
|
|
|
337
337
|
LSP diagnostics before the model pass when `typescript-language-server` is available.
|
|
338
338
|
They keep bounded current-scope context from real user prompts (`watchdog.scope.enabled`)
|
|
339
339
|
and can optionally run non-blocking Scopey-style cadence reviews every N tool results
|
|
340
|
-
(`watchdog.cadence.everyNTools`). Cadence corrections and
|
|
341
|
-
|
|
342
|
-
|
|
340
|
+
(`watchdog.cadence.everyNTools`). Cadence corrections and boundary warnings are always
|
|
341
|
+
transcript-visible; a boundary warning continues the run so the agent can act on it, and
|
|
342
|
+
repeated identical warnings stop after `watchdog.stalemateRepeats`. Choose the watchdog
|
|
343
|
+
model that matches the desired cheap-monitor vs strong-reviewer policy.
|
|
343
344
|
|
|
344
345
|
Prefer a strong complementary model (for example Opus 4.8 high paired against a
|
|
345
346
|
GPT 5.5 main session, or the reverse). Recommendation and configuration:
|
|
@@ -85,7 +85,7 @@ subagent({ action: "reset", agent: "reviewer" })
|
|
|
85
85
|
Use management actions when the system needs to create or edit subagents on
|
|
86
86
|
demand without dropping into raw file editing.
|
|
87
87
|
|
|
88
|
-
Management actions create or update user/project agent files. `config.name` is the local frontmatter name; optional `config.package` registers and looks up the runtime name as `{package}.{name}`. Use the dotted runtime name for `get`, `update`, `delete`, slash commands, and scripted workflow steps. For small
|
|
88
|
+
Management actions create or update user/project agent files. `config.name` is the local frontmatter name; optional `config.package` registers and looks up the runtime name as `{package}.{name}`. Use the dotted runtime name for `get`, `update`, `delete`, slash commands, and scripted workflow steps. For small agent changes such as a model swap, prefer `subagents.agentOverrides` in settings. Durable `.chain.md` definitions are legacy records, not a current authoring target; use `workflowScript` or `/prompt-workflow` for repeatable orchestration.
|
|
89
89
|
|
|
90
90
|
## Creating and Editing Agents by File
|
|
91
91
|
|
|
@@ -185,7 +185,7 @@ Builtin `worker` and `delegate` use strict tool allowlists and do not inherit am
|
|
|
185
185
|
|
|
186
186
|
Builtin agents inherit the current Pi default model unless a run, user setting, project setting, or `subagents.defaultModel` overrides `model`. The table records recommended tier routing, not shipped hard defaults; explicit run, user, or project settings still win. Keep the parent/orchestrator on the ordinary strong default model unless parent/user policy says otherwise. Override builtin defaults before copying full agent files when a small tweak is enough.
|
|
187
187
|
|
|
188
|
-
Set `subagents.defaultThinking` to apply a shared thinking level to builtin, package, user, and project agents whose frontmatter leaves `thinking` unset. Project settings win over user settings;
|
|
188
|
+
Set `subagents.defaultThinking` to apply a shared thinking level to builtin, package, user, and project agents whose frontmatter leaves `thinking` unset. Project settings win over user settings; matching `agentOverrides.<name>.thinking` and per-run overrides replace frontmatter, while an explicit frontmatter value remains in effect when no matching override is set. This setting affects child agents only and does not change the parent session's default thinking level.
|
|
189
189
|
|
|
190
190
|
```json
|
|
191
191
|
{
|
|
@@ -288,8 +288,8 @@ Use `fallbackModels` when a tier has provider quota or availability risk. Prefer
|
|
|
288
288
|
If a provider rejects model IDs with thinking suffixes, use
|
|
289
289
|
`subagents.disableThinking: true` in user or project settings to clear bundled
|
|
290
290
|
builtin thinking defaults globally. A higher-precedence per-agent `thinking`
|
|
291
|
-
override can opt one builtin back in
|
|
291
|
+
override can opt one builtin back in or replace custom-agent frontmatter thinking.
|
|
292
292
|
|
|
293
|
-
Set `subagents.defaultExtensions` to give agents without an `extensions` field a shared child extension allowlist. Omit it to preserve ambient extension discovery, set it to `[]` to disable ambient extensions by default, or use `agentOverrides.<name>.extensions` for one agent.
|
|
293
|
+
Set `subagents.defaultExtensions` to give agents without an `extensions` field a shared child extension allowlist. Omit it to preserve ambient extension discovery, set it to `[]` to disable ambient extensions by default, or use `agentOverrides.<name>.extensions` for one agent. A matching override replaces custom-agent frontmatter for that field.
|
|
294
294
|
|
|
295
295
|
Tool description modes live in `~/.pi/agent/extensions/subagent/config.json`, not `subagents` settings. The default uses split prompt metadata: a short tool description plus active `promptSnippet` and `promptGuidelines`. Set `toolDescriptionMode` to `full` or `compact` to force one description string, or `custom` to read `subagent-tool-description.md` from the project config dir or agent dir; invalid custom files fall back to full mode and the safety guidance is still appended.
|