@narumitw/pi-subagents 3.4.0 → 3.4.1
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/README.md +1 -1
- package/dist/index.ts +1 -1
- package/dist/index.ts.map +2 -2
- package/docs/messaging.md +3 -1
- package/package.json +2 -2
- package/src/runtime.ts +1 -1
package/docs/messaging.md
CHANGED
|
@@ -4,6 +4,8 @@ Main and child processes have separate `subagent_send` definitions. The main age
|
|
|
4
4
|
|
|
5
5
|
## Delivery and waiting
|
|
6
6
|
|
|
7
|
+
Child requests, responses, and terminal completions use Pi steering while the main agent is running. If it is idle, they start a new model turn. A completion does not require a pending `subagent_wait` call.
|
|
8
|
+
|
|
7
9
|
A main-originated request to a queued job waits for the child RPC prompt to be accepted, then uses Pi steering to reach the running child. After RPC accepts steering, the runtime interrupts active child response waits without consuming their original requests. The child may retry `subagent_wait` for a response it still needs.
|
|
8
10
|
|
|
9
11
|
Caller cancellation before RPC delivery starts rolls the request back. Once delivery starts, cancellation stops only the caller's wait: the request may still arrive and remains answerable until delivery fails or the job terminates. A wait timeout likewise stops only that wait, not the job or the underlying message request.
|
|
@@ -16,7 +18,7 @@ Each job may have up to four unresolved or answered-but-not-consumed requests ac
|
|
|
16
18
|
|
|
17
19
|
A job starts `queued`, becomes `running`, and reaches exactly one terminal state: `completed`, `partial`, `failed`, `timed_out`, or `cancelled`. Job execution timeouts start after Pi accepts the RPC prompt. The runtime retains up to 32 recent terminal records for up to 24 hours in the current extension session; inspection reports removed records through `omitted.jobs`.
|
|
18
20
|
|
|
19
|
-
Cancelling or terminalizing a job revokes its communication token and rejects pending child waits before stale output can replace the terminal state. Session replacement and shutdown cancel active work, suppress stale completion delivery, revoke credentials, close sockets, and stop the broker.
|
|
21
|
+
Cancelling or terminalizing a job revokes its communication token and rejects pending child waits before stale output can replace the terminal state. Session replacement and shutdown cancel active work, suppress stale completion delivery, revoke credentials, close sockets, and stop the broker.
|
|
20
22
|
|
|
21
23
|
The session starts one loopback TCP broker on `127.0.0.1` with an ephemeral port. Each job receives a random token bound to its job identity and session generation. The parent passes credentials through a private inherited pipe rather than the child's initial environment or command line. Child broker calls use request-scoped connections; response waits use abortable long polling.
|
|
22
24
|
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@narumitw/pi-subagents",
|
|
3
|
-
"version": "3.4.
|
|
3
|
+
"version": "3.4.1",
|
|
4
4
|
"description": "Subagent jobs with asynchronous main-agent messaging for Pi.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"license": "MIT",
|
|
@@ -54,6 +54,6 @@
|
|
|
54
54
|
},
|
|
55
55
|
"dependencies": {
|
|
56
56
|
"@narumitw/pi-tui-kit": "^0.68.0",
|
|
57
|
-
"ignore": "^7.0.
|
|
57
|
+
"ignore": "^7.0.14"
|
|
58
58
|
}
|
|
59
59
|
}
|
package/src/runtime.ts
CHANGED
|
@@ -437,7 +437,7 @@ export class SubagentRuntime {
|
|
|
437
437
|
display: true,
|
|
438
438
|
details: payload,
|
|
439
439
|
},
|
|
440
|
-
{ deliverAs: "steer" },
|
|
440
|
+
{ deliverAs: "steer", triggerTurn: true },
|
|
441
441
|
);
|
|
442
442
|
} catch {
|
|
443
443
|
// Completion remains available through wait; inspect continues to report status.
|