@yandy0725/pi-subagents 0.11.4 → 0.11.5
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 +12 -0
- package/README.zh.md +12 -0
- package/package.json +4 -1
- package/src/ui/session-navigator.ts +3 -3
- package/src/ui/transcript-body.ts +1 -1
package/README.md
CHANGED
|
@@ -219,6 +219,18 @@ npm test # vitest run
|
|
|
219
219
|
|
|
220
220
|
This project is a friendly fork of [@gotgenes/pi-subagents](https://github.com/gotgenes/pi-packages/tree/main/packages/pi-subagents) by [Chris Lasher](https://github.com/gotgenes), which began as a fork of [tintinweb/pi-subagents](https://github.com/tintinweb/pi-subagents). Thank you to all original authors for their work that made this package possible.
|
|
221
221
|
|
|
222
|
+
## UI surface
|
|
223
|
+
|
|
224
|
+
Both slash commands and the running-agents widget call host UI primitives directly. The widget registers a **component factory**, which only TUI mode accepts; the commands use dialogs, which RPC forwards but the client may ignore:
|
|
225
|
+
|
|
226
|
+
| Method | Guard | Outside TUI (RPC / headless) |
|
|
227
|
+
|---|---|---|
|
|
228
|
+
| `setWidget(factory)` (running / finished agents widget) | none | RPC drops component factories silently, so the widget never appears. print / json have no UI at all |
|
|
229
|
+
| `setStatus` (agents summary line) | none | Forwarded fire-and-forget; may be dropped |
|
|
230
|
+
| `select` / `input` / `notify` (`/subagents:settings`) | none | Forwarded; no `timeout` is passed, so an unresponsive client keeps the command pending. print / json get no-op dialogs, so the menu exits silently |
|
|
231
|
+
| `select` (`/subagents:sessions`) | none | Forwarded; no timeout |
|
|
232
|
+
| `custom` (transcript overlay) | none | RPC returns `undefined` immediately: picking a session shows nothing. Same in print / json |
|
|
233
|
+
|
|
222
234
|
## License
|
|
223
235
|
|
|
224
236
|
MIT
|
package/README.zh.md
CHANGED
|
@@ -211,6 +211,18 @@ npm test # vitest run
|
|
|
211
211
|
|
|
212
212
|
本项目是 [@gotgenes/pi-subagents](https://github.com/gotgenes/pi-packages/tree/main/packages/pi-subagents)(作者 [Chris Lasher](https://github.com/gotgenes))的友好分支,后者源自 [tintinweb/pi-subagents](https://github.com/tintinweb/pi-subagents)。感谢所有原作者的工作使本包成为可能。
|
|
213
213
|
|
|
214
|
+
## UI 能力
|
|
215
|
+
|
|
216
|
+
两个斜杠命令和「运行中 agent」widget 都直接调用宿主的 UI 原语。widget 注册的是**组件工厂**,只有 TUI 接受这种形式;命令用的是对话框,RPC 会转发,但客户端可能不应答或直接丢弃:
|
|
217
|
+
|
|
218
|
+
| 方法 | 守卫 | 非 TUI(RPC / headless) |
|
|
219
|
+
|---|---|---|
|
|
220
|
+
| `setWidget(factory)`(运行中 / 已完成 agent 的 widget) | 无 | RPC 静默丢弃组件工厂,widget 不会出现;print / json 根本没有 UI |
|
|
221
|
+
| `setStatus`(agent 汇总行) | 无 | fire-and-forget,可能被丢弃 |
|
|
222
|
+
| `select` / `input` / `notify`(`/subagents:settings`) | 无 | 会转发;没有传 `timeout`,客户端不响应时命令一直挂着。print / json 下对话皆为空实现,菜单直接退出 |
|
|
223
|
+
| `select`(`/subagents:sessions`) | 无 | 会转发;没有超时 |
|
|
224
|
+
| `custom`(会话记录浮层) | 无 | RPC 直接返回 `undefined`:选中一个会话后什么都不显示;print / json 同理 |
|
|
225
|
+
|
|
214
226
|
## 许可证
|
|
215
227
|
|
|
216
228
|
MIT
|
package/package.json
CHANGED
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
"publishConfig": {
|
|
4
4
|
"access": "public"
|
|
5
5
|
},
|
|
6
|
-
"version": "0.11.
|
|
6
|
+
"version": "0.11.5",
|
|
7
7
|
"description": "Focused, in-process sub-agent core for pi — autonomous agents plus a typed API and lifecycle events",
|
|
8
8
|
"license": "MIT",
|
|
9
9
|
"repository": {
|
|
@@ -41,6 +41,9 @@
|
|
|
41
41
|
},
|
|
42
42
|
"devDependencies": {
|
|
43
43
|
"@biomejs/biome": "^2.6.6",
|
|
44
|
+
"@earendil-works/pi-ai": "1.5.0",
|
|
45
|
+
"@earendil-works/pi-coding-agent": "1.5.0",
|
|
46
|
+
"@earendil-works/pi-tui": "1.5.0",
|
|
44
47
|
"@types/node": "^26.6.6",
|
|
45
48
|
"typebox": "^1.4.6",
|
|
46
49
|
"typescript": "~7.0.2",
|
|
@@ -447,12 +447,12 @@ export class TranscriptOverlay implements Component {
|
|
|
447
447
|
*/
|
|
448
448
|
private buildContentLines(innerW: number): string[] {
|
|
449
449
|
if (innerW <= 0) return [];
|
|
450
|
-
const
|
|
450
|
+
const bodyLines = this.body.render(innerW);
|
|
451
451
|
this.renderedIndicator = this.indicatorLine();
|
|
452
452
|
if (this.renderedIndicator) {
|
|
453
|
-
|
|
453
|
+
return [...bodyLines, "", this.renderedIndicator];
|
|
454
454
|
}
|
|
455
|
-
return
|
|
455
|
+
return [...bodyLines];
|
|
456
456
|
}
|
|
457
457
|
|
|
458
458
|
/** Running-agent indicator line, or "" when the source is not streaming. */
|