@astralyn/pi 0.84.1 → 0.84.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/CHANGELOG.md +8 -1
- package/dist/extensions/index.d.ts.map +1 -1
- package/dist/extensions/index.js +0 -4
- package/dist/extensions/index.js.map +1 -1
- package/dist/extensions/todo/schema.d.ts +1 -1
- package/dist/extensions/todo/state.js +5 -5
- package/dist/extensions/todo/state.js.map +1 -1
- package/docs/bundled/README.md +0 -2
- package/docs/docs.json +0 -8
- package/docs/usage.md +0 -1
- package/examples/extensions/README.md +2 -0
- package/examples/extensions/plan-mode/README.md +66 -0
- package/examples/extensions/plan-mode/index.ts +390 -0
- package/examples/extensions/plan-mode/utils.ts +168 -0
- package/examples/extensions/subagent/README.md +175 -0
- package/examples/extensions/subagent/agents/planner.md +37 -0
- package/examples/extensions/subagent/agents/reviewer.md +35 -0
- package/examples/extensions/subagent/agents/scout.md +50 -0
- package/examples/extensions/subagent/agents/worker.md +24 -0
- package/examples/extensions/subagent/agents.ts +126 -0
- package/examples/extensions/subagent/index.ts +1009 -0
- package/examples/extensions/subagent/prompts/implement-and-review.md +10 -0
- package/examples/extensions/subagent/prompts/implement.md +10 -0
- package/examples/extensions/subagent/prompts/scout-and-plan.md +9 -0
- package/npm-shrinkwrap.json +2 -2
- package/package.json +1 -1
- package/dist/extensions/biu/index.d.ts +0 -19
- package/dist/extensions/biu/index.d.ts.map +0 -1
- package/dist/extensions/biu/index.js +0 -350
- package/dist/extensions/biu/index.js.map +0 -1
- package/dist/extensions/biu/prompts.d.ts +0 -26
- package/dist/extensions/biu/prompts.d.ts.map +0 -1
- package/dist/extensions/biu/prompts.js +0 -260
- package/dist/extensions/biu/prompts.js.map +0 -1
- package/dist/extensions/biu/workspace.d.ts +0 -122
- package/dist/extensions/biu/workspace.d.ts.map +0 -1
- package/dist/extensions/biu/workspace.js +0 -404
- package/dist/extensions/biu/workspace.js.map +0 -1
- package/dist/extensions/rewind/anchor.d.ts +0 -29
- package/dist/extensions/rewind/anchor.d.ts.map +0 -1
- package/dist/extensions/rewind/anchor.js +0 -35
- package/dist/extensions/rewind/anchor.js.map +0 -1
- package/dist/extensions/rewind/config.d.ts +0 -16
- package/dist/extensions/rewind/config.d.ts.map +0 -1
- package/dist/extensions/rewind/config.js +0 -69
- package/dist/extensions/rewind/config.js.map +0 -1
- package/dist/extensions/rewind/engine.d.ts +0 -93
- package/dist/extensions/rewind/engine.d.ts.map +0 -1
- package/dist/extensions/rewind/engine.js +0 -778
- package/dist/extensions/rewind/engine.js.map +0 -1
- package/dist/extensions/rewind/gc.d.ts +0 -35
- package/dist/extensions/rewind/gc.d.ts.map +0 -1
- package/dist/extensions/rewind/gc.js +0 -169
- package/dist/extensions/rewind/gc.js.map +0 -1
- package/dist/extensions/rewind/index.d.ts +0 -3
- package/dist/extensions/rewind/index.d.ts.map +0 -1
- package/dist/extensions/rewind/index.js +0 -287
- package/dist/extensions/rewind/index.js.map +0 -1
- package/dist/extensions/rewind/menu.d.ts +0 -13
- package/dist/extensions/rewind/menu.d.ts.map +0 -1
- package/dist/extensions/rewind/menu.js +0 -123
- package/dist/extensions/rewind/menu.js.map +0 -1
- package/dist/extensions/rewind/paths.d.ts +0 -4
- package/dist/extensions/rewind/paths.d.ts.map +0 -1
- package/dist/extensions/rewind/paths.js +0 -15
- package/dist/extensions/rewind/paths.js.map +0 -1
- package/dist/extensions/rewind/restore.d.ts +0 -54
- package/dist/extensions/rewind/restore.d.ts.map +0 -1
- package/dist/extensions/rewind/restore.js +0 -94
- package/dist/extensions/rewind/restore.js.map +0 -1
- package/dist/extensions/rewind/snapshot.d.ts +0 -45
- package/dist/extensions/rewind/snapshot.d.ts.map +0 -1
- package/dist/extensions/rewind/snapshot.js +0 -21
- package/dist/extensions/rewind/snapshot.js.map +0 -1
- package/dist/extensions/rewind/storage.d.ts +0 -12
- package/dist/extensions/rewind/storage.d.ts.map +0 -1
- package/dist/extensions/rewind/storage.js +0 -33
- package/dist/extensions/rewind/storage.js.map +0 -1
- package/dist/extensions/rewind/text.d.ts +0 -7
- package/dist/extensions/rewind/text.d.ts.map +0 -1
- package/dist/extensions/rewind/text.js +0 -19
- package/dist/extensions/rewind/text.js.map +0 -1
- package/dist/extensions/rewind/tool-path.d.ts +0 -3
- package/dist/extensions/rewind/tool-path.d.ts.map +0 -1
- package/dist/extensions/rewind/tool-path.js +0 -9
- package/dist/extensions/rewind/tool-path.js.map +0 -1
- package/docs/bundled/extensions/biu.md +0 -63
- package/docs/bundled/extensions/rewind.md +0 -86
package/CHANGELOG.md
CHANGED
|
@@ -4,6 +4,13 @@ This file records `@astralyn/pi` releases beginning with the first Fork-owned re
|
|
|
4
4
|
|
|
5
5
|
## [Unreleased]
|
|
6
6
|
|
|
7
|
+
## [0.84.2] - 2026-08-09
|
|
8
|
+
|
|
9
|
+
### Removed
|
|
10
|
+
|
|
11
|
+
- Removed the bundled rewind extension, including per-edit backups, the `/rewind` settings command, and `/tree` work-tree restoration. Existing `~/.pi/agent/rewind/` data is no longer read and can be removed manually; historical `pi-rewind-snapshot` session entries remain inert.
|
|
12
|
+
- Removed the bundled Biu extension, including the `/biu` workflow command, `biu://` path resolution for the core file tools, and the SPEC approval gate. Existing `~/.pi/agent/biu/` workspace data is no longer read and can be removed manually; historical `biu-mode` session entries stay inert and `biu-kickoff` messages fall back to the default custom-message rendering.
|
|
13
|
+
|
|
7
14
|
## [0.84.1] - 2026-08-07
|
|
8
15
|
|
|
9
16
|
### Added
|
|
@@ -197,7 +204,7 @@ This file records `@astralyn/pi` releases beginning with the first Fork-owned re
|
|
|
197
204
|
- Fixed auto-compaction to also check the context before continuing a run with queued steering or follow-up messages; previously a turn without tool results skipped the mid-turn check and long follow-up chains could only recover via overflow.
|
|
198
205
|
- Fixed the IME candidate window jumping between the caret and the end of the input line while typing with a CJK input method in Windows Terminal and other terminals that anchor the candidate window to the hardware cursor. Each TUI render pass is now flushed to stdout as one atomic write instead of separate frame, cursor-reposition, and cursor-visibility writes, so the terminal never observes the intermediate cursor position (upstream [#6289](https://github.com/earendil-works/pi/issues/6289), [#5200](https://github.com/earendil-works/pi/issues/5200)).
|
|
199
206
|
- Fixed the terminal viewport jumping to the top of the buffer when scrolling up through history while a response is streaming, most visibly in Windows Terminal. Content-driven full redraws (triggered whenever a line above the viewport changes during streaming markdown reflow) previously cleared the terminal scrollback with `ESC[3J` and replayed the entire transcript; such frames are now rewritten to overwrite the visible screen in place (avoiding `ESC[2J`, which conhost implements by pushing the screen into scrollback), preserving scrollback, the reading position, and pre-session shell history without accumulating duplicate screen copies. Width-change redraws still clear scrollback since re-wrapped content invalidates it (upstream [#6502](https://github.com/earendil-works/pi/issues/6502), [#5576](https://github.com/earendil-works/pi/issues/5576), [#6050](https://github.com/earendil-works/pi/issues/6050)).
|
|
200
|
-
- Fixed the rewind extension's `/tree` restore semantics. Snapshots now anchor to the first user entry of a run (steering/follow-up messages no longer shift the anchor onto a mid-run message), and the restore target mirrors `/tree`'s leaf rules: user-message targets restore to the state before that turn, other targets to the state after it, and navigation is silent instead of rolling back the target turn's own edits when nothing was recorded afterwards. Also fixed resume/fork backup migration to link only retained frames (removing a race with over-cap blob pruning), made restore-side change detection immune to mtime-preserving content swaps, deduplicated case-insensitive tracking keys on Windows, and taught the storage menu's "remove all" to keep backups recently written by other running sessions.
|
|
207
|
+
- Fixed the rewind extension's `/tree` restore semantics. Snapshots now anchor to the first user entry of a run (steering/follow-up messages no longer shift the anchor onto a mid-run message), and the restore target mirrors `/tree`'s leaf rules: user-message targets restore to the state before that turn, other targets to the state after it, and navigation is silent instead of rolling back the target turn's own edits when nothing was recorded afterwards. Also fixed resume/fork backup migration to link only retained frames (removing a race with over-cap blob pruning), made restore-side change detection immune to mtime-preserving content swaps, deduplicated case-insensitive tracking keys on Windows, and taught the storage menu's "remove all" to keep backups recently written by other running sessions.
|
|
201
208
|
- Fixed subagent working-directory resolution under a symlinked parent directory (macOS `/tmp`, Windows junctions): the containment check compared the real parent path against the unresolved candidate, so every call — including the default inherit-cwd case — was rejected as an escape. Traversal and symlink escapes are still blocked.
|
|
202
209
|
- Fixed the subagent tool staying broken for the rest of the session after a transient `ModelRuntime` creation failure; the rejected promise is no longer cached, so the next invocation retries.
|
|
203
210
|
- Fixed subagent progress updates firing after the tool result had settled (a throttled emitter leaked its timer), and skipped redundant progress serialization when consecutive events change nothing user-visible.
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/extensions/index.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,6BAA6B,CAAC;
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/extensions/index.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,6BAA6B,CAAC;AASnE,eAAO,MAAM,iBAAiB,EAAE,eAAe,EAQ9C,CAAC"}
|
package/dist/extensions/index.js
CHANGED
|
@@ -1,18 +1,14 @@
|
|
|
1
|
-
import biuExtension from "./biu/index.js";
|
|
2
1
|
import deepwikiExtension from "./deepwiki/index.js";
|
|
3
2
|
import llamaExtension from "./llama/index.js";
|
|
4
3
|
import questionExtension from "./question/index.js";
|
|
5
|
-
import rewindExtension from "./rewind/index.js";
|
|
6
4
|
import routerExtension from "./router/index.js";
|
|
7
5
|
import statuslineExtension from "./statusline/index.js";
|
|
8
6
|
import subagentExtension from "./subagent/index.js";
|
|
9
7
|
import todoExtension from "./todo/index.js";
|
|
10
8
|
export const builtInExtensions = [
|
|
11
|
-
{ name: "biu", factory: biuExtension, hidden: true },
|
|
12
9
|
{ name: "llama.cpp", factory: llamaExtension, hidden: true },
|
|
13
10
|
{ name: "deepwiki", factory: deepwikiExtension, hidden: true },
|
|
14
11
|
{ name: "question", factory: questionExtension, hidden: true },
|
|
15
|
-
{ name: "rewind", factory: rewindExtension, hidden: true },
|
|
16
12
|
{ name: "router", factory: routerExtension, hidden: true },
|
|
17
13
|
{ name: "statusline", factory: statuslineExtension, hidden: true },
|
|
18
14
|
{ name: "subagent", factory: subagentExtension, hidden: true },
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/extensions/index.ts"],"names":[],"mappings":"AACA,OAAO,
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/extensions/index.ts"],"names":[],"mappings":"AACA,OAAO,iBAAiB,MAAM,qBAAqB,CAAC;AACpD,OAAO,cAAc,MAAM,kBAAkB,CAAC;AAC9C,OAAO,iBAAiB,MAAM,qBAAqB,CAAC;AACpD,OAAO,eAAe,MAAM,mBAAmB,CAAC;AAChD,OAAO,mBAAmB,MAAM,uBAAuB,CAAC;AACxD,OAAO,iBAAiB,MAAM,qBAAqB,CAAC;AACpD,OAAO,aAAa,MAAM,iBAAiB,CAAC;AAE5C,MAAM,CAAC,MAAM,iBAAiB,GAAsB;IACnD,EAAE,IAAI,EAAE,WAAW,EAAE,OAAO,EAAE,cAAc,EAAE,MAAM,EAAE,IAAI,EAAE;IAC5D,EAAE,IAAI,EAAE,UAAU,EAAE,OAAO,EAAE,iBAAiB,EAAE,MAAM,EAAE,IAAI,EAAE;IAC9D,EAAE,IAAI,EAAE,UAAU,EAAE,OAAO,EAAE,iBAAiB,EAAE,MAAM,EAAE,IAAI,EAAE;IAC9D,EAAE,IAAI,EAAE,QAAQ,EAAE,OAAO,EAAE,eAAe,EAAE,MAAM,EAAE,IAAI,EAAE;IAC1D,EAAE,IAAI,EAAE,YAAY,EAAE,OAAO,EAAE,mBAAmB,EAAE,MAAM,EAAE,IAAI,EAAE;IAClE,EAAE,IAAI,EAAE,UAAU,EAAE,OAAO,EAAE,iBAAiB,EAAE,MAAM,EAAE,IAAI,EAAE;IAC9D,EAAE,IAAI,EAAE,MAAM,EAAE,OAAO,EAAE,aAAa,EAAE,MAAM,EAAE,IAAI,EAAE;CACtD,CAAC","sourcesContent":["import type { InlineExtension } from \"../core/extensions/types.ts\";\nimport deepwikiExtension from \"./deepwiki/index.ts\";\nimport llamaExtension from \"./llama/index.ts\";\nimport questionExtension from \"./question/index.ts\";\nimport routerExtension from \"./router/index.ts\";\nimport statuslineExtension from \"./statusline/index.ts\";\nimport subagentExtension from \"./subagent/index.ts\";\nimport todoExtension from \"./todo/index.ts\";\n\nexport const builtInExtensions: InlineExtension[] = [\n\t{ name: \"llama.cpp\", factory: llamaExtension, hidden: true },\n\t{ name: \"deepwiki\", factory: deepwikiExtension, hidden: true },\n\t{ name: \"question\", factory: questionExtension, hidden: true },\n\t{ name: \"router\", factory: routerExtension, hidden: true },\n\t{ name: \"statusline\", factory: statuslineExtension, hidden: true },\n\t{ name: \"subagent\", factory: subagentExtension, hidden: true },\n\t{ name: \"todo\", factory: todoExtension, hidden: true },\n];\n"]}
|
|
@@ -61,7 +61,7 @@ export declare const TodoParamsSchema: Type.TObject<{
|
|
|
61
61
|
subject: Type.TOptional<Type.TString>;
|
|
62
62
|
description: Type.TOptional<Type.TString>;
|
|
63
63
|
activeForm: Type.TOptional<Type.TString>;
|
|
64
|
-
status: Type.TOptional<Type.TUnsafe<"pending" | "
|
|
64
|
+
status: Type.TOptional<Type.TUnsafe<"pending" | "completed" | "in_progress" | "deleted">>;
|
|
65
65
|
blockedBy: Type.TOptional<Type.TArray<Type.TInteger>>;
|
|
66
66
|
items: Type.TOptional<Type.TArray<Type.TObject<{
|
|
67
67
|
key: Type.TOptional<Type.TString>;
|
|
@@ -18,11 +18,11 @@ const LEGACY_METADATA_LIMITS = {
|
|
|
18
18
|
maxBytes: 16 * 1024 * 1024,
|
|
19
19
|
};
|
|
20
20
|
// ---- per-session state ------------------------------------------------------
|
|
21
|
-
// Keyed by session id
|
|
22
|
-
//
|
|
23
|
-
//
|
|
24
|
-
//
|
|
25
|
-
//
|
|
21
|
+
// Keyed by session id: one Pi process can host more than one session over its
|
|
22
|
+
// lifetime (resume, /tree branch switches), and a module-level singleton would
|
|
23
|
+
// leak one session's list into another. Tool renderers get no ctx, so the
|
|
24
|
+
// active session is a module-level pointer kept current by execute and the
|
|
25
|
+
// lifecycle handlers (which do have ctx).
|
|
26
26
|
const states = new Map();
|
|
27
27
|
let activeSid = "";
|
|
28
28
|
/** Point the module at a session's state bucket. Call wherever ctx is in hand. */
|