@oh-my-pi/pi-coding-agent 15.9.67 → 15.10.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.
Files changed (266) hide show
  1. package/CHANGELOG.md +136 -0
  2. package/dist/types/cli/args.d.ts +1 -1
  3. package/dist/types/cli/dry-balance-cli.d.ts +15 -1
  4. package/dist/types/cli/gallery-cli.d.ts +43 -0
  5. package/dist/types/cli/gallery-fixtures/agentic.d.ts +2 -0
  6. package/dist/types/cli/gallery-fixtures/codeintel.d.ts +3 -0
  7. package/dist/types/cli/gallery-fixtures/edit.d.ts +3 -0
  8. package/dist/types/cli/gallery-fixtures/fs.d.ts +2 -0
  9. package/dist/types/cli/gallery-fixtures/index.d.ts +4 -0
  10. package/dist/types/cli/gallery-fixtures/interaction.d.ts +3 -0
  11. package/dist/types/cli/gallery-fixtures/memory.d.ts +2 -0
  12. package/dist/types/cli/gallery-fixtures/misc.d.ts +3 -0
  13. package/dist/types/cli/gallery-fixtures/search.d.ts +3 -0
  14. package/dist/types/cli/gallery-fixtures/shell.d.ts +3 -0
  15. package/dist/types/cli/gallery-fixtures/types.d.ts +44 -0
  16. package/dist/types/cli/gallery-fixtures/web.d.ts +2 -0
  17. package/dist/types/cli/gallery-screenshot.d.ts +35 -0
  18. package/dist/types/commands/gallery.d.ts +47 -0
  19. package/dist/types/commit/analysis/conventional.d.ts +2 -2
  20. package/dist/types/commit/analysis/summary.d.ts +2 -2
  21. package/dist/types/commit/changelog/generate.d.ts +2 -2
  22. package/dist/types/commit/changelog/index.d.ts +2 -2
  23. package/dist/types/commit/map-reduce/index.d.ts +3 -3
  24. package/dist/types/commit/map-reduce/map-phase.d.ts +2 -2
  25. package/dist/types/commit/map-reduce/reduce-phase.d.ts +2 -2
  26. package/dist/types/commit/model-selection.d.ts +10 -4
  27. package/dist/types/config/api-key-resolver.d.ts +34 -0
  28. package/dist/types/config/keybindings.d.ts +6 -1
  29. package/dist/types/config/model-id-affixes.d.ts +2 -0
  30. package/dist/types/config/model-registry.d.ts +25 -2
  31. package/dist/types/config/settings-schema.d.ts +41 -6
  32. package/dist/types/dap/config.d.ts +14 -1
  33. package/dist/types/dap/types.d.ts +10 -0
  34. package/dist/types/extensibility/plugins/marketplace-auto-update.d.ts +8 -0
  35. package/dist/types/lsp/types.d.ts +10 -0
  36. package/dist/types/lsp/utils.d.ts +3 -2
  37. package/dist/types/main.d.ts +3 -2
  38. package/dist/types/memory-backend/index.d.ts +2 -1
  39. package/dist/types/memory-backend/resolve.d.ts +1 -1
  40. package/dist/types/memory-backend/types.d.ts +1 -1
  41. package/dist/types/modes/components/chat-block.d.ts +64 -0
  42. package/dist/types/modes/components/custom-editor.d.ts +5 -1
  43. package/dist/types/modes/components/overlay-box.d.ts +17 -0
  44. package/dist/types/modes/components/plan-review-overlay.d.ts +59 -0
  45. package/dist/types/modes/components/plan-toc.d.ts +41 -0
  46. package/dist/types/modes/components/read-tool-group.d.ts +2 -0
  47. package/dist/types/modes/components/tool-execution.d.ts +18 -0
  48. package/dist/types/modes/components/transcript-container.d.ts +11 -0
  49. package/dist/types/modes/controllers/command-controller.d.ts +1 -0
  50. package/dist/types/modes/controllers/event-controller.d.ts +0 -1
  51. package/dist/types/modes/controllers/extension-ui-controller.d.ts +0 -1
  52. package/dist/types/modes/controllers/input-controller.d.ts +1 -1
  53. package/dist/types/modes/controllers/selector-controller.d.ts +1 -1
  54. package/dist/types/modes/controllers/streaming-reveal.d.ts +22 -0
  55. package/dist/types/modes/controllers/tan-command-controller.d.ts +6 -0
  56. package/dist/types/modes/index.d.ts +5 -4
  57. package/dist/types/modes/interactive-mode.d.ts +16 -6
  58. package/dist/types/modes/setup-version.d.ts +11 -0
  59. package/dist/types/modes/setup-wizard/index.d.ts +2 -1
  60. package/dist/types/modes/setup-wizard/scenes/web-search.d.ts +2 -1
  61. package/dist/types/modes/theme/theme.d.ts +1 -1
  62. package/dist/types/modes/types.d.ts +19 -6
  63. package/dist/types/modes/utils/copy-targets.d.ts +21 -1
  64. package/dist/types/plan-mode/approved-plan.d.ts +27 -8
  65. package/dist/types/plan-mode/plan-protection.d.ts +4 -4
  66. package/dist/types/sdk.d.ts +3 -1
  67. package/dist/types/session/agent-session.d.ts +21 -0
  68. package/dist/types/session/messages.d.ts +12 -0
  69. package/dist/types/session/session-manager.d.ts +3 -1
  70. package/dist/types/slash-commands/types.d.ts +4 -6
  71. package/dist/types/task/executor.d.ts +14 -0
  72. package/dist/types/task/index.d.ts +1 -0
  73. package/dist/types/task/render.d.ts +3 -2
  74. package/dist/types/telemetry-export.d.ts +1 -1
  75. package/dist/types/tools/archive-reader.d.ts +5 -0
  76. package/dist/types/tools/ast-edit.d.ts +3 -0
  77. package/dist/types/tools/ast-grep.d.ts +3 -0
  78. package/dist/types/tools/bash.d.ts +1 -0
  79. package/dist/types/tools/eval-render.d.ts +1 -8
  80. package/dist/types/tools/fetch.d.ts +15 -7
  81. package/dist/types/tools/find.d.ts +8 -4
  82. package/dist/types/tools/grouped-file-output.d.ts +95 -12
  83. package/dist/types/tools/memory-render.d.ts +4 -1
  84. package/dist/types/tools/plan-mode-guard.d.ts +8 -9
  85. package/dist/types/tools/render-utils.d.ts +13 -9
  86. package/dist/types/tools/renderers.d.ts +16 -2
  87. package/dist/types/tools/search.d.ts +5 -1
  88. package/dist/types/tools/sqlite-reader.d.ts +1 -0
  89. package/dist/types/tools/todo.d.ts +3 -2
  90. package/dist/types/tools/write.d.ts +5 -0
  91. package/dist/types/tui/output-block.d.ts +16 -4
  92. package/dist/types/tui/status-line.d.ts +3 -0
  93. package/dist/types/utils/enhanced-paste.d.ts +20 -0
  94. package/dist/types/web/scrapers/github.d.ts +22 -0
  95. package/dist/types/web/search/providers/kimi.d.ts +1 -1
  96. package/dist/types/web/search/providers/perplexity.d.ts +8 -1
  97. package/dist/types/web/search/types.d.ts +1 -1
  98. package/package.json +9 -9
  99. package/scripts/dev-launch +42 -0
  100. package/scripts/dev-launch-preload.ts +19 -0
  101. package/src/auto-thinking/classifier.ts +5 -1
  102. package/src/cli/args.ts +2 -2
  103. package/src/cli/dry-balance-cli.ts +52 -17
  104. package/src/cli/gallery-cli.ts +226 -0
  105. package/src/cli/gallery-fixtures/agentic.ts +292 -0
  106. package/src/cli/gallery-fixtures/codeintel.ts +188 -0
  107. package/src/cli/gallery-fixtures/edit.ts +194 -0
  108. package/src/cli/gallery-fixtures/fs.ts +153 -0
  109. package/src/cli/gallery-fixtures/index.ts +40 -0
  110. package/src/cli/gallery-fixtures/interaction.ts +49 -0
  111. package/src/cli/gallery-fixtures/memory.ts +81 -0
  112. package/src/cli/gallery-fixtures/misc.ts +250 -0
  113. package/src/cli/gallery-fixtures/search.ts +213 -0
  114. package/src/cli/gallery-fixtures/shell.ts +167 -0
  115. package/src/cli/gallery-fixtures/types.ts +41 -0
  116. package/src/cli/gallery-fixtures/web.ts +158 -0
  117. package/src/cli/gallery-screenshot.ts +279 -0
  118. package/src/cli-commands.ts +1 -0
  119. package/src/commands/gallery.ts +52 -0
  120. package/src/commands/launch.ts +1 -1
  121. package/src/commit/analysis/conventional.ts +2 -2
  122. package/src/commit/analysis/summary.ts +2 -2
  123. package/src/commit/changelog/generate.ts +2 -2
  124. package/src/commit/changelog/index.ts +2 -2
  125. package/src/commit/map-reduce/index.ts +3 -3
  126. package/src/commit/map-reduce/map-phase.ts +2 -2
  127. package/src/commit/map-reduce/reduce-phase.ts +2 -2
  128. package/src/commit/model-selection.ts +33 -9
  129. package/src/commit/pipeline.ts +4 -4
  130. package/src/config/api-key-resolver.ts +58 -0
  131. package/src/config/keybindings.ts +15 -6
  132. package/src/config/model-equivalence.ts +35 -12
  133. package/src/config/model-id-affixes.ts +39 -22
  134. package/src/config/model-registry.ts +41 -18
  135. package/src/config/settings-schema.ts +28 -5
  136. package/src/config/settings.ts +31 -2
  137. package/src/dap/client.ts +14 -16
  138. package/src/dap/config.ts +41 -2
  139. package/src/dap/defaults.json +1 -0
  140. package/src/dap/session.ts +1 -0
  141. package/src/dap/types.ts +10 -0
  142. package/src/debug/index.ts +40 -54
  143. package/src/edit/renderer.ts +111 -119
  144. package/src/eval/__tests__/agent-bridge.test.ts +75 -32
  145. package/src/eval/__tests__/llm-bridge.test.ts +90 -31
  146. package/src/eval/agent-bridge.ts +34 -7
  147. package/src/eval/llm-bridge.ts +8 -3
  148. package/src/extensibility/extensions/runner.ts +1 -0
  149. package/src/extensibility/plugins/doctor.ts +0 -1
  150. package/src/extensibility/plugins/marketplace-auto-update.ts +49 -0
  151. package/src/goals/tools/goal-tool.ts +37 -27
  152. package/src/internal-urls/docs-index.generated.ts +10 -10
  153. package/src/lsp/client.ts +104 -55
  154. package/src/lsp/types.ts +10 -0
  155. package/src/lsp/utils.ts +3 -2
  156. package/src/main.ts +53 -56
  157. package/src/memories/index.ts +12 -5
  158. package/src/memory-backend/index.ts +13 -1
  159. package/src/memory-backend/resolve.ts +3 -5
  160. package/src/memory-backend/types.ts +1 -1
  161. package/src/mnemopi/backend.ts +5 -1
  162. package/src/modes/acp/acp-agent.ts +33 -26
  163. package/src/modes/components/assistant-message.ts +2 -9
  164. package/src/modes/components/chat-block.ts +111 -0
  165. package/src/modes/components/copy-selector.ts +1 -44
  166. package/src/modes/components/custom-editor.ts +33 -1
  167. package/src/modes/components/custom-message.ts +1 -3
  168. package/src/modes/components/execution-shared.ts +1 -2
  169. package/src/modes/components/hook-message.ts +1 -3
  170. package/src/modes/components/overlay-box.ts +108 -0
  171. package/src/modes/components/plan-review-overlay.ts +799 -0
  172. package/src/modes/components/plan-toc.ts +138 -0
  173. package/src/modes/components/read-tool-group.ts +20 -4
  174. package/src/modes/components/skill-message.ts +0 -1
  175. package/src/modes/components/status-line.ts +3 -5
  176. package/src/modes/components/tips.txt +1 -0
  177. package/src/modes/components/todo-reminder.ts +0 -2
  178. package/src/modes/components/tool-execution.ts +115 -90
  179. package/src/modes/components/transcript-container.ts +84 -24
  180. package/src/modes/components/user-message.ts +1 -2
  181. package/src/modes/controllers/command-controller-shared.ts +7 -6
  182. package/src/modes/controllers/command-controller.ts +70 -57
  183. package/src/modes/controllers/event-controller.ts +41 -40
  184. package/src/modes/controllers/extension-ui-controller.ts +10 -73
  185. package/src/modes/controllers/input-controller.ts +135 -122
  186. package/src/modes/controllers/mcp-command-controller.ts +69 -60
  187. package/src/modes/controllers/selector-controller.ts +25 -27
  188. package/src/modes/controllers/streaming-reveal.ts +212 -0
  189. package/src/modes/controllers/tan-command-controller.ts +173 -0
  190. package/src/modes/index.ts +5 -4
  191. package/src/modes/interactive-mode.ts +171 -82
  192. package/src/modes/setup-version.ts +11 -0
  193. package/src/modes/setup-wizard/index.ts +3 -2
  194. package/src/modes/setup-wizard/scenes/web-search.ts +3 -2
  195. package/src/modes/setup-wizard/wizard-overlay.ts +1 -1
  196. package/src/modes/theme/theme-schema.json +1 -1
  197. package/src/modes/theme/theme.ts +8 -4
  198. package/src/modes/types.ts +19 -8
  199. package/src/modes/utils/context-usage.ts +10 -6
  200. package/src/modes/utils/copy-targets.ts +133 -27
  201. package/src/modes/utils/hotkeys-markdown.ts +1 -0
  202. package/src/modes/utils/ui-helpers.ts +44 -46
  203. package/src/plan-mode/approved-plan.ts +66 -43
  204. package/src/plan-mode/plan-protection.ts +4 -4
  205. package/src/prompts/system/background-tan-dispatch.md +8 -0
  206. package/src/prompts/system/plan-mode-active.md +67 -58
  207. package/src/prompts/system/plan-mode-approved.md +1 -1
  208. package/src/sdk.ts +32 -60
  209. package/src/session/agent-session.ts +89 -13
  210. package/src/session/messages.ts +26 -0
  211. package/src/session/session-manager.ts +13 -5
  212. package/src/slash-commands/builtin-registry.ts +37 -10
  213. package/src/slash-commands/helpers/usage-report.ts +2 -0
  214. package/src/slash-commands/types.ts +4 -6
  215. package/src/task/executor.ts +25 -4
  216. package/src/task/index.ts +4 -0
  217. package/src/task/render.ts +212 -148
  218. package/src/telemetry-export.ts +25 -7
  219. package/src/tools/archive-reader.ts +64 -0
  220. package/src/tools/ask.ts +119 -164
  221. package/src/tools/ast-edit.ts +98 -71
  222. package/src/tools/ast-grep.ts +37 -43
  223. package/src/tools/bash.ts +50 -6
  224. package/src/tools/debug.ts +20 -8
  225. package/src/tools/eval-backends.ts +6 -17
  226. package/src/tools/eval-render.ts +21 -18
  227. package/src/tools/eval.ts +5 -4
  228. package/src/tools/fetch.ts +391 -91
  229. package/src/tools/find.ts +44 -30
  230. package/src/tools/gh-renderer.ts +81 -42
  231. package/src/tools/grouped-file-output.ts +272 -48
  232. package/src/tools/image-gen.ts +150 -103
  233. package/src/tools/inspect-image-renderer.ts +63 -41
  234. package/src/tools/inspect-image.ts +8 -1
  235. package/src/tools/job.ts +3 -4
  236. package/src/tools/memory-render.ts +4 -1
  237. package/src/tools/plan-mode-guard.ts +21 -39
  238. package/src/tools/read.ts +23 -16
  239. package/src/tools/render-utils.ts +38 -40
  240. package/src/tools/renderers.ts +16 -1
  241. package/src/tools/report-tool-issue.ts +1 -1
  242. package/src/tools/resolve.ts +14 -0
  243. package/src/tools/search-tool-bm25.ts +36 -23
  244. package/src/tools/search.ts +189 -95
  245. package/src/tools/sqlite-reader.ts +9 -12
  246. package/src/tools/todo.ts +138 -59
  247. package/src/tools/write.ts +100 -60
  248. package/src/tui/output-block.ts +60 -13
  249. package/src/tui/status-line.ts +5 -1
  250. package/src/utils/commit-message-generator.ts +9 -1
  251. package/src/utils/enhanced-paste.ts +202 -0
  252. package/src/utils/title-generator.ts +2 -1
  253. package/src/web/scrapers/github.ts +255 -3
  254. package/src/web/scrapers/youtube.ts +3 -2
  255. package/src/web/search/providers/anthropic.ts +25 -19
  256. package/src/web/search/providers/exa.ts +11 -3
  257. package/src/web/search/providers/kimi.ts +28 -17
  258. package/src/web/search/providers/parallel.ts +35 -24
  259. package/src/web/search/providers/perplexity.ts +199 -51
  260. package/src/web/search/providers/synthetic.ts +8 -6
  261. package/src/web/search/providers/tavily.ts +9 -8
  262. package/src/web/search/providers/zai.ts +8 -6
  263. package/src/web/search/render.ts +39 -54
  264. package/src/web/search/types.ts +5 -1
  265. package/dist/types/eval/__tests__/shared-executors.test.d.ts +0 -1
  266. package/src/eval/__tests__/shared-executors.test.ts +0 -609
@@ -0,0 +1,34 @@
1
+ import type { ApiKeyResolver, AuthStorage } from "@oh-my-pi/pi-ai";
2
+ export interface ApiKeyResolverOptions {
3
+ /** Session id for credential stickiness; read at resolve time by the caller. */
4
+ sessionId?: string;
5
+ /** Provider base URL hint forwarded to the auth-storage cascade. */
6
+ baseUrl?: string;
7
+ }
8
+ /**
9
+ * Minimal slice of `ModelRegistry` the resolver needs. Typed structurally so
10
+ * narrower registry shells (e.g. the commit pipeline's `CommitModelRegistry`)
11
+ * can build resolvers without depending on the full class.
12
+ */
13
+ export interface ApiKeyResolverRegistry {
14
+ getApiKeyForProvider(provider: string, sessionId?: string, options?: {
15
+ baseUrl?: string;
16
+ forceRefresh?: boolean;
17
+ signal?: AbortSignal;
18
+ }): Promise<string | undefined>;
19
+ authStorage: Pick<AuthStorage, "rotateSessionCredential">;
20
+ /**
21
+ * Build an {@link ApiKeyResolver} implementing the central a/b/c auth-retry
22
+ * policy: initial → resolve; step (b) → force-refresh same account; step (c)
23
+ * → rotate to a sibling credential, then re-resolve.
24
+ *
25
+ * The resolver is stateless (safe to reuse across requests). Callers that
26
+ * need the initial key for a guard can call `resolveApiKeyOnce(resolver)`.
27
+ */
28
+ resolver(provider: string, options?: ApiKeyResolverOptions): ApiKeyResolver;
29
+ }
30
+ /**
31
+ * Default implementation of {@link ApiKeyResolverRegistry.resolver}.
32
+ * Also usable standalone for structural registries that don't carry the method.
33
+ */
34
+ export declare function createApiKeyResolver(registry: Pick<ApiKeyResolverRegistry, "getApiKeyForProvider" | "authStorage">, provider: string, options?: ApiKeyResolverOptions): ApiKeyResolver;
@@ -8,6 +8,7 @@ interface AppKeybindings {
8
8
  "app.clear": true;
9
9
  "app.exit": true;
10
10
  "app.suspend": true;
11
+ "app.display.reset": true;
11
12
  "app.thinking.cycle": true;
12
13
  "app.thinking.toggle": true;
13
14
  "app.model.cycleForward": true;
@@ -191,6 +192,10 @@ export declare const KEYBINDINGS: {
191
192
  readonly defaultKeys: "ctrl+z";
192
193
  readonly description: "Suspend application";
193
194
  };
195
+ readonly "app.display.reset": {
196
+ readonly defaultKeys: "ctrl+l";
197
+ readonly description: "Reset terminal display";
198
+ };
194
199
  readonly "app.thinking.cycle": {
195
200
  readonly defaultKeys: "shift+tab";
196
201
  readonly description: "Cycle thinking level";
@@ -208,7 +213,7 @@ export declare const KEYBINDINGS: {
208
213
  readonly description: "Cycle to previous model";
209
214
  };
210
215
  readonly "app.model.select": {
211
- readonly defaultKeys: "ctrl+l";
216
+ readonly defaultKeys: "alt+m";
212
217
  readonly description: "Select model";
213
218
  };
214
219
  readonly "app.model.selectTemporary": {
@@ -5,6 +5,8 @@ export declare function getLongestModelLikeIdSegment(modelId: string): string |
5
5
  * upstream model id, e.g.
6
6
  * "[Kiro] claude-opus-4-8" -> "claude-opus-4-8"
7
7
  * "[gcli转] gemini-3.1-pro-preview [假流]" -> "gemini-3.1-pro-preview"
8
+ *
9
+ * Candidates are returned most-stripped first: both ends, then leading-only, then trailing-only.
8
10
  */
9
11
  export declare function getBracketStrippedModelIdCandidates(modelId: string): string[];
10
12
  export declare function stripBracketedModelIdAffixes(modelId: string): string | undefined;
@@ -1,7 +1,11 @@
1
- import { type Api, type AssistantMessageEventStream, type Context, type Model, type ModelRefreshStrategy, type SimpleStreamOptions, type ThinkingConfig } from "@oh-my-pi/pi-ai";
1
+ import { type ModelRefreshStrategy } from "@oh-my-pi/pi-ai/model-manager";
2
+ import type { Api, Context, Model, SimpleStreamOptions, ThinkingConfig } from "@oh-my-pi/pi-ai/types";
3
+ import type { AssistantMessageEventStream } from "@oh-my-pi/pi-ai/utils/event-stream";
4
+ import type { ApiKeyResolver } from "@oh-my-pi/pi-ai";
2
5
  import type { OAuthCredentials, OAuthLoginCallbacks } from "@oh-my-pi/pi-ai/utils/oauth/types";
3
6
  import { type ThemeColor } from "../modes/theme/theme";
4
7
  import type { AuthStorage } from "../session/auth-storage";
8
+ import { type ApiKeyResolverOptions } from "./api-key-resolver";
5
9
  import { type ConfigError, ConfigFile } from "./config-file";
6
10
  import { type CanonicalModelIndex, type CanonicalModelRecord, type CanonicalModelVariant, type ModelEquivalenceConfig } from "./model-equivalence";
7
11
  import { type Settings } from "./settings";
@@ -324,8 +328,22 @@ export declare class ModelRegistry {
324
328
  getApiKey(model: Model<Api>, sessionId?: string): Promise<string | undefined>;
325
329
  /**
326
330
  * Get API key for a provider (e.g., "openai").
331
+ *
332
+ * `options.forceRefresh` powers step (b) of the auth-retry policy — it
333
+ * re-mints the session-sticky OAuth token even when the cached copy still
334
+ * looks valid. `options.signal` is threaded into any broker-bound refresh.
335
+ */
336
+ getApiKeyForProvider(provider: string, sessionId?: string, options?: {
337
+ baseUrl?: string;
338
+ forceRefresh?: boolean;
339
+ signal?: AbortSignal;
340
+ }): Promise<string | undefined>;
341
+ /**
342
+ * Build an {@link ApiKeyResolver} for this provider, implementing the
343
+ * central a/b/c auth-retry policy. Callers that need the initial key for
344
+ * a guard can call `resolveApiKeyOnce(resolver)`.
327
345
  */
328
- getApiKeyForProvider(provider: string, sessionId?: string, baseUrl?: string): Promise<string | undefined>;
346
+ resolver(provider: string, options?: ApiKeyResolverOptions): ApiKeyResolver;
329
347
  /**
330
348
  * Check if a model is using OAuth credentials (subscription).
331
349
  */
@@ -355,6 +373,11 @@ export declare class ModelRegistry {
355
373
  * Check if a model selector is currently suppressed due to rate limits.
356
374
  */
357
375
  isSelectorSuppressed(selector: string): boolean;
376
+ /**
377
+ * Clear all cooldown suppressions recorded via {@link suppressSelector}.
378
+ * Used to reset retry-fallback cooldown state without a full {@link refresh}.
379
+ */
380
+ clearSuppressedSelectors(): void;
358
381
  }
359
382
  /**
360
383
  * Input type for registerProvider API (from extensions).
@@ -689,6 +689,15 @@ export declare const SETTINGS_SCHEMA: {
689
689
  }];
690
690
  };
691
691
  };
692
+ readonly "display.smoothStreaming": {
693
+ readonly type: "boolean";
694
+ readonly default: true;
695
+ readonly ui: {
696
+ readonly tab: "appearance";
697
+ readonly label: "Smooth Streaming";
698
+ readonly description: "Reveal assistant text smoothly while streamed chunks arrive";
699
+ };
700
+ };
692
701
  readonly "display.showTokenUsage": {
693
702
  readonly type: "boolean";
694
703
  readonly default: false;
@@ -3317,7 +3326,7 @@ export declare const SETTINGS_SCHEMA: {
3317
3326
  }, {
3318
3327
  readonly value: "perplexity";
3319
3328
  readonly label: "Perplexity";
3320
- readonly description: "Requires PERPLEXITY_COOKIES or PERPLEXITY_API_KEY";
3329
+ readonly description: "Uses auth when configured; explicit selection falls back to anonymous search";
3321
3330
  }, {
3322
3331
  readonly value: "brave";
3323
3332
  readonly label: "Brave";
@@ -3670,13 +3679,39 @@ export declare const SETTINGS_SCHEMA: {
3670
3679
  }];
3671
3680
  };
3672
3681
  };
3673
- readonly "providers.parallelFetch": {
3674
- readonly type: "boolean";
3675
- readonly default: true;
3682
+ readonly "providers.fetch": {
3683
+ readonly type: "enum";
3684
+ readonly values: readonly ["auto", "native", "trafilatura", "lynx", "parallel", "jina"];
3685
+ readonly default: "auto";
3676
3686
  readonly ui: {
3677
3687
  readonly tab: "providers";
3678
- readonly label: "Parallel Fetch";
3679
- readonly description: "Use Parallel extract API for URL fetching when credentials are available";
3688
+ readonly label: "Fetch Provider";
3689
+ readonly description: "Reader backend priority for the fetch/read URL tool";
3690
+ readonly options: readonly [{
3691
+ readonly value: "auto";
3692
+ readonly label: "Auto";
3693
+ readonly description: "Priority: native > trafilatura > lynx > parallel > jina";
3694
+ }, {
3695
+ readonly value: "native";
3696
+ readonly label: "Native";
3697
+ readonly description: "In-process HTML→Markdown converter (always available)";
3698
+ }, {
3699
+ readonly value: "trafilatura";
3700
+ readonly label: "Trafilatura";
3701
+ readonly description: "Auto-installs via uv/pip";
3702
+ }, {
3703
+ readonly value: "lynx";
3704
+ readonly label: "Lynx";
3705
+ readonly description: "Requires lynx system package";
3706
+ }, {
3707
+ readonly value: "parallel";
3708
+ readonly label: "Parallel";
3709
+ readonly description: "Requires PARALLEL_API_KEY";
3710
+ }, {
3711
+ readonly value: "jina";
3712
+ readonly label: "Jina";
3713
+ readonly description: "Uses r.jina.ai reader (JINA_API_KEY optional)";
3714
+ }];
3680
3715
  };
3681
3716
  };
3682
3717
  readonly "provider.appendOnlyContext": {
@@ -2,5 +2,18 @@ import type { DapAdapterConfig, DapResolvedAdapter } from "./types";
2
2
  export declare function getAdapterConfigs(): Record<string, DapAdapterConfig>;
3
3
  export declare function resolveAdapter(adapterName: string, cwd: string): DapResolvedAdapter | null;
4
4
  export declare function getAvailableAdapters(cwd: string): DapResolvedAdapter[];
5
- export declare function selectLaunchAdapter(program: string, cwd: string, adapterName?: string): DapResolvedAdapter | null;
5
+ export declare function selectLaunchAdapter(program: string, cwd: string, adapterName?: string, programKind?: LaunchProgramKind): DapResolvedAdapter | null;
6
6
  export declare function selectAttachAdapter(cwd: string, adapterName?: string, port?: number): DapResolvedAdapter | null;
7
+ /** How the launch `program` resolves on disk. `"missing"` is reserved for
8
+ * programs the adapter creates on demand (rare); we treat them like files. */
9
+ export type LaunchProgramKind = "file" | "directory" | "missing";
10
+ /** Compute adapter-specific launch arguments that depend on the resolved
11
+ * program. Returned values are spread over `adapter.launchDefaults` so they
12
+ * take precedence over the static defaults but can still be overridden by
13
+ * the fields `DapSessionManager.launch` sets explicitly (program, cwd, args).
14
+ *
15
+ * Currently scoped to dlv, where `mode` selects how the program path is
16
+ * interpreted: directories and `.go` source files debug as a Go package
17
+ * (`mode=debug`), anything else is treated as a compiled binary (`mode=exec`).
18
+ */
19
+ export declare function resolveLaunchOverrides(adapter: DapResolvedAdapter, program: string, programKind: LaunchProgramKind): Record<string, unknown>;
@@ -422,6 +422,10 @@ export interface DapAdapterConfig {
422
422
  * On Linux, connects via a unix domain socket.
423
423
  * On macOS, the adapter dials into a local TCP listener (--client-addr). */
424
424
  connectMode?: "stdio" | "socket";
425
+ /** When true, the adapter accepts a directory as the launch `program`
426
+ * (e.g. dlv treats it as a Go package path). When false/undefined, the
427
+ * debug tool rejects directory programs upfront. */
428
+ acceptsDirectoryProgram?: boolean;
425
429
  }
426
430
  export interface DapResolvedAdapter {
427
431
  name: string;
@@ -434,6 +438,7 @@ export interface DapResolvedAdapter {
434
438
  launchDefaults: Record<string, unknown>;
435
439
  attachDefaults: Record<string, unknown>;
436
440
  connectMode: "stdio" | "socket";
441
+ acceptsDirectoryProgram: boolean;
437
442
  }
438
443
  export interface DapBreakpointRecord {
439
444
  id?: number;
@@ -514,6 +519,11 @@ export interface DapLaunchSessionOptions {
514
519
  program: string;
515
520
  args?: string[];
516
521
  cwd: string;
522
+ /** Per-launch overrides merged over `adapter.launchDefaults`. Used to
523
+ * inject adapter-specific values that depend on the resolved program
524
+ * (e.g. dlv's `mode` switches between `debug` and `exec` based on
525
+ * whether `program` is a Go package path or a compiled binary). */
526
+ extraLaunchArguments?: Record<string, unknown>;
517
527
  }
518
528
  export interface DapAttachSessionOptions {
519
529
  adapter: DapResolvedAdapter;
@@ -0,0 +1,8 @@
1
+ type MarketplaceAutoUpdateMode = "off" | "notify" | "auto";
2
+ interface MarketplaceAutoUpdateOptions {
3
+ autoUpdate: MarketplaceAutoUpdateMode;
4
+ resolveActiveProjectRegistryPath: (cwd: string) => Promise<string | null>;
5
+ clearPluginRootsCache: () => void;
6
+ }
7
+ export declare function scheduleMarketplaceAutoUpdate(options: MarketplaceAutoUpdateOptions): void;
8
+ export {};
@@ -222,6 +222,16 @@ export interface ServerConfig {
222
222
  disabled?: boolean;
223
223
  /** Per-server warmup timeout in milliseconds. Overrides the global WARMUP_TIMEOUT_MS for this server during startup. */
224
224
  warmupTimeoutMs?: number;
225
+ /**
226
+ * Per-server overrides for rust-analyzer workspace-ready polling. When omitted, the module
227
+ * defaults are used. Primarily a tuning/test seam to bound the multi-second settle window.
228
+ */
229
+ workspaceReadyTimings?: {
230
+ timeoutMs?: number;
231
+ pollMs?: number;
232
+ settleMs?: number;
233
+ statusRequestTimeoutMs?: number;
234
+ };
225
235
  capabilities?: ServerCapabilities;
226
236
  /** If true, this is a linter/formatter server (e.g., Biome) - used only for diagnostics/actions, not type intelligence */
227
237
  isLinter?: boolean;
@@ -28,9 +28,10 @@ export declare function severityToIcon(severity?: DiagnosticSeverity): string;
28
28
  */
29
29
  export declare function formatDiagnostic(diagnostic: Diagnostic, filePath: string): string;
30
30
  /**
31
- * Reformat pre-formatted diagnostic messages into grep-style directory/file groups.
31
+ * Reformat pre-formatted diagnostic messages into a multi-level, prefix-folded
32
+ * directory/file grouping (see `formatGroupedFiles`).
32
33
  * Input: ["path:line:col [sev] msg", ...]
33
- * Output: "# dir/\n## file.ts\n line:col [sev] msg"
34
+ * Output: "# pkg/src/\n## file.ts\n line:col [sev] msg"
34
35
  *
35
36
  * Messages that don't match the expected format are appended ungrouped at the end.
36
37
  */
@@ -7,12 +7,13 @@
7
7
  import type { Args } from "./cli/args";
8
8
  import { ModelRegistry } from "./config/model-registry";
9
9
  import { Settings } from "./config/settings";
10
- import { InteractiveMode, runAcpMode } from "./modes";
10
+ import { InteractiveMode } from "./modes/interactive-mode";
11
11
  import type { SubmittedUserInput } from "./modes/types";
12
12
  import { type CreateAgentSessionOptions, type CreateAgentSessionResult, createAgentSession, discoverAuthStorage } from "./sdk";
13
13
  import type { AgentSession } from "./session/agent-session";
14
14
  import type { AuthStorage } from "./session/auth-storage";
15
15
  import { type SessionInfo, SessionManager } from "./session/session-manager";
16
+ type RunAcpMode = (createSession: AcpSessionFactory) => Promise<never>;
16
17
  export interface InteractiveModeNotify {
17
18
  kind: "warn" | "error" | "info";
18
19
  message: string;
@@ -47,7 +48,7 @@ export declare function createSessionManager(parsed: Args, cwd: string, activeSe
47
48
  interface RunRootCommandDependencies {
48
49
  createAgentSession?: typeof createAgentSession;
49
50
  discoverAuthStorage?: typeof discoverAuthStorage;
50
- runAcpMode?: typeof runAcpMode;
51
+ runAcpMode?: RunAcpMode;
51
52
  settings?: Settings;
52
53
  forceSetupWizard?: boolean;
53
54
  }
@@ -1,4 +1,5 @@
1
- export * from "../mnemopi";
1
+ export type { MnemopiBackendConfig, MnemopiLlmMode, MnemopiProviderOptions, MnemopiScoping, } from "../mnemopi/config";
2
+ export type { MnemopiMemoryEditOperation, MnemopiMemoryEditOptions, MnemopiMemoryEditResult, MnemopiSessionState, MnemopiSessionStateOptions, } from "../mnemopi/state";
2
3
  export * from "./local-backend";
3
4
  export * from "./off-backend";
4
5
  export * from "./resolve";
@@ -13,4 +13,4 @@ import type { MemoryBackend } from "./types";
13
13
  * `memories.enabled` remains accepted only as a legacy migration input. Once
14
14
  * a config is loaded, `memory.backend` is the sole runtime selector.
15
15
  */
16
- export declare function resolveMemoryBackend(settings: Settings): MemoryBackend;
16
+ export declare function resolveMemoryBackend(settings: Settings): Promise<MemoryBackend>;
@@ -1,7 +1,7 @@
1
1
  /**
2
2
  * Memory backend abstraction.
3
3
  *
4
- * Backends are mutually exclusive — `resolveMemoryBackend(settings)` returns
4
+ * Backends are mutually exclusive — `await resolveMemoryBackend(settings)` resolves
5
5
  * exactly one. Implementations MUST be self-contained: they own the per-session
6
6
  * state they create in `start()` and tear it down on `clear()`.
7
7
  */
@@ -0,0 +1,64 @@
1
+ import { Container } from "@oh-my-pi/pi-tui";
2
+ /**
3
+ * Capabilities a mounted {@link ChatBlock} may use against its host transcript.
4
+ * Kept minimal so blocks never reach into the full TUI/InteractiveMode surface.
5
+ */
6
+ export interface ChatBlockHost {
7
+ /** Schedule a repaint of the transcript. */
8
+ requestRender(): void;
9
+ }
10
+ /**
11
+ * Lifecycle-aware transcript block — the "return a block, let the host mount it"
12
+ * primitive, modelled on React/Svelte component lifecycles.
13
+ *
14
+ * Producers build and return a `ChatBlock` instead of poking `chatContainer` and
15
+ * `ui.requestRender()` directly. The host (`ctx.present`) appends it and calls
16
+ * {@link mount}, which runs {@link onMount}; effects started there register
17
+ * teardown via {@link onCleanup}. The block repaints through {@link requestRender}
18
+ * — never touching the TUI — and tears down exactly once on {@link finish}
19
+ * (self-complete: stop the animation, keep the final frame in the transcript) or
20
+ * {@link dispose} (host discards it, e.g. a transcript reset).
21
+ *
22
+ * While mounted and unfinished a block reports `isTranscriptBlockFinalized() ===
23
+ * false` so {@link "../components/transcript-container".TranscriptContainer}
24
+ * keeps it in the live, repaintable region on ED3-risk terminals; after
25
+ * `finish()`/`dispose()` it reports `true` and freezes at its final content.
26
+ */
27
+ export declare abstract class ChatBlock extends Container {
28
+ #private;
29
+ /**
30
+ * Run setup after the block is in the transcript: start timers/subscriptions
31
+ * and register their teardown with {@link onCleanup}. Default: no-op (a block
32
+ * whose content is fixed at construction needs no mount work).
33
+ */
34
+ protected onMount(): void;
35
+ /**
36
+ * Register a teardown to run on {@link finish}/{@link dispose}, à la a
37
+ * `useEffect` cleanup. If the block is already disposed the cleanup runs
38
+ * immediately so callers never leak.
39
+ */
40
+ protected onCleanup(cleanup: () => void): void;
41
+ /** Ask the host to repaint. No-op before mount or after dispose. */
42
+ protected requestRender(): void;
43
+ /** True between {@link mount} and {@link finish}/{@link dispose}. */
44
+ protected get active(): boolean;
45
+ /**
46
+ * Host-only: attach the host and run {@link onMount}. Idempotent — a second
47
+ * call (e.g. a transcript rebuild that re-presents the same instance) is a
48
+ * no-op.
49
+ */
50
+ mount(host: ChatBlockHost): void;
51
+ /**
52
+ * Self-complete: stop ongoing effects and freeze the block at its current
53
+ * content, leaving it rendered in the transcript. Use when the operation the
54
+ * block represents finishes (connection resolved, download done).
55
+ */
56
+ finish(): void;
57
+ /**
58
+ * Host-only teardown: release everything and propagate to children. Called
59
+ * when the host permanently discards the block (transcript reset). Idempotent.
60
+ */
61
+ dispose(): void;
62
+ /** Live blocks stay repaintable; finished/disposed ones may freeze. */
63
+ isTranscriptBlockFinalized(): boolean;
64
+ }
@@ -1,6 +1,7 @@
1
1
  import { Editor, type KeyId } from "@oh-my-pi/pi-tui";
2
2
  import type { AppKeybinding } from "../../config/keybindings";
3
- type ConfigurableEditorAction = Extract<AppKeybinding, "app.interrupt" | "app.clear" | "app.exit" | "app.suspend" | "app.thinking.cycle" | "app.model.cycleForward" | "app.model.cycleBackward" | "app.model.select" | "app.model.selectTemporary" | "app.tools.expand" | "app.thinking.toggle" | "app.editor.external" | "app.history.search" | "app.message.dequeue" | "app.clipboard.pasteImage" | "app.clipboard.pasteTextRaw" | "app.clipboard.copyPrompt">;
3
+ type ConfigurableEditorAction = Extract<AppKeybinding, "app.interrupt" | "app.clear" | "app.exit" | "app.suspend" | "app.display.reset" | "app.thinking.cycle" | "app.model.cycleForward" | "app.model.cycleBackward" | "app.model.select" | "app.model.selectTemporary" | "app.tools.expand" | "app.thinking.toggle" | "app.editor.external" | "app.history.search" | "app.message.dequeue" | "app.clipboard.pasteImage" | "app.clipboard.pasteTextRaw" | "app.clipboard.copyPrompt">;
4
+ export declare function extractBracketedImagePastePath(data: string): string | undefined;
4
5
  /**
5
6
  * Custom editor that handles configurable app-level shortcuts for coding-agent.
6
7
  */
@@ -14,6 +15,7 @@ export declare class CustomEditor extends Editor {
14
15
  onEscape?: () => void;
15
16
  onClear?: () => void;
16
17
  onExit?: () => void;
18
+ onDisplayReset?: () => void;
17
19
  onCycleThinkingLevel?: () => void;
18
20
  onCycleModelForward?: () => void;
19
21
  onCycleModelBackward?: () => void;
@@ -28,6 +30,8 @@ export declare class CustomEditor extends Editor {
28
30
  onCopyPrompt?: () => void;
29
31
  /** Called when the configured image-paste shortcut is pressed. */
30
32
  onPasteImage?: () => Promise<boolean>;
33
+ /** Called when a bracketed paste contains exactly one image-file path. */
34
+ onPasteImagePath?: (path: string) => void;
31
35
  /** Called when the configured raw text-paste shortcut is pressed. */
32
36
  onPasteTextRaw?: () => void;
33
37
  /** Called when the configured dequeue shortcut is pressed. */
@@ -0,0 +1,17 @@
1
+ /** Pad or truncate a (possibly ANSI-styled) string to exactly `width` columns. */
2
+ export declare function fit(text: string, width: number): string;
3
+ /** Top border with an optional accent-colored title inset into the rule. */
4
+ export declare function topBorder(width: number, title: string): string;
5
+ /** A horizontal rule with left/right tees, splitting overlay sections. */
6
+ export declare function divider(width: number): string;
7
+ export declare function bottomBorder(width: number): string;
8
+ /** Wrap pre-styled content in vertical borders with single-column insets. */
9
+ export declare function row(content: string, width: number): string;
10
+ /** Body content width for a two-column overlay of total `width`. */
11
+ export declare function splitBodyWidth(width: number, sidebarWidth: number): number;
12
+ /** Top border carrying the title, split by a `┬` over the column divider. */
13
+ export declare function topBorderSplit(width: number, title: string, sidebarWidth: number): string;
14
+ /** Section rule that closes the sidebar column with a `┴` over the divider. */
15
+ export declare function dividerSplit(width: number, sidebarWidth: number): string;
16
+ /** A two-column content row: `│ sidebar │ body │`, each inset by one column. */
17
+ export declare function splitRow(sidebar: string, body: string, width: number, sidebarWidth: number): string;
@@ -0,0 +1,59 @@
1
+ /**
2
+ * Fullscreen plan-review overlay. The overlay owns its entire content: the plan
3
+ * is split into sections (preamble + one per heading), each rendered through its
4
+ * own {@link Markdown} and windowed by a {@link ScrollView}, while the approval
5
+ * options (plus the optional model-tier slider) sit beneath inside the same
6
+ * outlined box — one self-contained surface in the spirit of the `/copy` picker.
7
+ *
8
+ * When the terminal is wide enough and the plan has ≥2 headings, a Contents
9
+ * sidebar appears: it tracks the scrolled section with an accent "glow", and —
10
+ * when focused — lets the operator jump between sections, delete a section
11
+ * (with undo), and annotate sections with feedback that feeds the Refine loop.
12
+ *
13
+ * Focus regions (`toc`/`body`/`actions`) cycle with Tab/Shift+Tab; arrows move
14
+ * within the focused region and step left into the sidebar. The default focus is
15
+ * `actions`, so the muscle memory of the old single-target overlay carries over:
16
+ * ↑/↓ select options, Enter confirms, ←/→ drives the slider when there is no
17
+ * sidebar, g/G + PgUp/PgDn scroll, and the external-editor key opens the plan.
18
+ */
19
+ import { type Component } from "@oh-my-pi/pi-tui";
20
+ import type { HookSelectorSlider } from "./hook-selector";
21
+ export interface PlanReviewOverlayCallbacks {
22
+ /** Invoked with the chosen option label (never a disabled one). */
23
+ onPick: (label: string) => void;
24
+ /** Invoked on Esc / cancel. */
25
+ onCancel: () => void;
26
+ /** Invoked when the external-editor key is pressed (overlay stays open). */
27
+ onExternalEditor?: () => void;
28
+ /** Invoked with the new full plan text after an in-overlay delete/undo. */
29
+ onPlanEdited?: (content: string) => void;
30
+ /** Invoked with the Refine feedback markdown whenever annotations change. */
31
+ onFeedbackChange?: (feedback: string) => void;
32
+ }
33
+ export interface PlanReviewOverlayOptions {
34
+ /** Prompt rendered above the options (e.g. "Plan mode - next step"). */
35
+ promptTitle?: string;
36
+ options: string[];
37
+ /** Indices into `options` that render dimmed and cannot be selected. */
38
+ disabledIndices?: number[];
39
+ /** Trailing footer hint (cancel hint); the overlay prepends dynamic help. */
40
+ helpText?: string;
41
+ /** Initially highlighted option index. */
42
+ initialIndex?: number;
43
+ /** Optional model-tier slider rendered between the plan body and options. */
44
+ slider?: HookSelectorSlider;
45
+ /** Display label for the external-editor key, surfaced in the footer help. */
46
+ externalEditorLabel?: string;
47
+ }
48
+ export declare class PlanReviewOverlay implements Component {
49
+ #private;
50
+ private readonly callbacks;
51
+ constructor(planContent: string, options: PlanReviewOverlayOptions, callbacks: PlanReviewOverlayCallbacks);
52
+ invalidate(): void;
53
+ /** Swap the displayed plan (e.g. after an external-editor round-trip) and
54
+ * reset scroll/focus so the operator starts at the top. Does not emit
55
+ * `onPlanEdited` (the editor round-trip already persisted the file). */
56
+ setPlanContent(planContent: string): void;
57
+ handleInput(keyData: string): void;
58
+ render(width: number): string[];
59
+ }
@@ -0,0 +1,41 @@
1
+ /**
2
+ * Pure heading/section parser for the plan-review overlay. It splits a plan's
3
+ * markdown into a flat list of sections — a leading preamble (text before the
4
+ * first heading) followed by one entry per ATX heading — preserving the exact
5
+ * source bytes of each section so the overlay can render, reorder-free delete,
6
+ * and round-trip the document without a full markdown re-render.
7
+ *
8
+ * No TUI dependencies: this module is unit-tested in isolation.
9
+ */
10
+ export interface PlanSection {
11
+ /** `0` = preamble (no heading, no ToC entry); `1..6` = heading depth. */
12
+ level: number;
13
+ /** Plain-text heading label with inline markdown lightly stripped. */
14
+ title: string;
15
+ /** Exact source slice for this section, including its trailing newline(s). */
16
+ raw: string;
17
+ }
18
+ /**
19
+ * Collapse inline markdown emphasis/link/code syntax to readable text. This is
20
+ * a deliberately light strip (not a full markdown render) just so ToC entries
21
+ * read cleanly — `**Goal** & [docs](x)` becomes `Goal & docs`.
22
+ */
23
+ export declare function stripInlineMarkdown(text: string): string;
24
+ /**
25
+ * Split `text` into preamble + heading sections. `#` characters inside fenced
26
+ * code blocks are never treated as headings. Concatenating every section's
27
+ * `raw` reproduces the original text exactly.
28
+ */
29
+ export declare function parsePlanSections(text: string): PlanSection[];
30
+ /**
31
+ * Concatenate every section's `raw` back into a single document and guarantee a
32
+ * single trailing newline. Inverse of {@link parsePlanSections} for any input
33
+ * that already ends with a newline.
34
+ */
35
+ export declare function joinPlanSections(sections: readonly PlanSection[]): string;
36
+ /**
37
+ * Indices to remove when deleting `sections[index]`: the heading itself plus
38
+ * every following section nested deeper than it (its sub-headings). The
39
+ * preamble (level 0) is never a deletion target and yields an empty span.
40
+ */
41
+ export declare function sectionDeletionSpan(sections: readonly PlanSection[], index: number): number[];
@@ -14,6 +14,8 @@ type ReadToolGroupOptions = {
14
14
  export declare class ReadToolGroupComponent extends Container implements ToolExecutionHandle {
15
15
  #private;
16
16
  constructor(options?: ReadToolGroupOptions);
17
+ isTranscriptBlockFinalized(): boolean;
18
+ finalize(): void;
17
19
  updateArgs(args: ReadRenderArgs, toolCallId?: string): void;
18
20
  updateResult(result: {
19
21
  content: Array<{
@@ -61,6 +61,24 @@ export declare class ToolExecutionComponent extends Container {
61
61
  * past, or an explicit {@link seal} flips it to `true`.
62
62
  */
63
63
  isTranscriptBlockFinalized(): boolean;
64
+ /**
65
+ * While a tool's preview is still streaming, a block whose preview is
66
+ * append-only (rows only grow at the bottom, never re-layout) lets the
67
+ * renderer commit the scrolled-off head of an over-tall preview to native
68
+ * scrollback instead of dropping it — the same anti-yank path a streaming
69
+ * assistant reply uses (see {@link TranscriptContainer} +
70
+ * `NativeScrollbackLiveRegion`). Covers both phases: a pre-result call preview
71
+ * (a `write` whose content streams in) and a partial-result preview that
72
+ * streams output below fixed input (an `eval`/`bash` whose stdout grows under
73
+ * its code cell). Gated on {@link isTranscriptBlockFinalized} so the boundary
74
+ * closes the instant the block reaches a terminal state — a final result that
75
+ * may collapse to a compact view, a backgrounded async tool, or a seal — and
76
+ * the renderer decides whether its current preview shape qualifies via
77
+ * `isStreamingPreviewAppendOnly` (typically: only the expanded full view,
78
+ * which is top-anchored; the collapsed tail window re-layouts but is bounded
79
+ * so it never overflows anyway).
80
+ */
81
+ isTranscriptBlockAppendOnly(): boolean;
64
82
  /**
65
83
  * Mark the tool terminal even though no result arrived (the turn aborted or
66
84
  * abandoned it) and stop animating, so it can freeze and stops pinning the
@@ -36,3 +36,14 @@ export declare class TranscriptContainer extends Container implements NativeScro
36
36
  thaw(): void;
37
37
  render(width: number): string[];
38
38
  }
39
+ /**
40
+ * Groups a run of sibling rows (an IRC card's header + body, a file-mention
41
+ * list, a bordered command/version panel) into a single transcript child so the
42
+ * container spaces it as one block — one blank line above, none injected between
43
+ * its rows. Without this wrapper the rows would be top-level children and the
44
+ * container would put a blank line between each (and inside any border box).
45
+ * It is a plain {@link Container}; the named subclass documents intent and makes
46
+ * every manual block grouping greppable.
47
+ */
48
+ export declare class TranscriptBlock extends Container {
49
+ }
@@ -22,6 +22,7 @@ export declare class CommandController {
22
22
  handleContextCommand(): void;
23
23
  handleMemoryCommand(text: string): Promise<void>;
24
24
  handleClearCommand(): Promise<void>;
25
+ handleFreshCommand(): Promise<void>;
25
26
  handleDropCommand(): Promise<void>;
26
27
  handleForkCommand(): Promise<void>;
27
28
  handleMoveCommand(targetPath: string): Promise<void>;
@@ -8,5 +8,4 @@ export declare class EventController {
8
8
  subscribeToAgent(): void;
9
9
  handleEvent(event: AgentSessionEvent): Promise<void>;
10
10
  sendCompletionNotification(): void;
11
- handleBackgroundEvent(event: AgentSessionEvent): Promise<void>;
12
11
  }
@@ -14,7 +14,6 @@ export declare class ExtensionUiController {
14
14
  initHooksAndCustomTools(): Promise<void>;
15
15
  setHookWidget(key: string, content: ExtensionWidgetContent, options?: ExtensionWidgetOptions): void;
16
16
  initializeHookRunner(uiContext: ExtensionUIContext, _hasUI: boolean): void;
17
- createBackgroundUiContext(): ExtensionUIContext;
18
17
  /**
19
18
  * Emit session event to all extension tools.
20
19
  */
@@ -16,7 +16,7 @@ export declare class InputController {
16
16
  abort?: boolean;
17
17
  currentText?: string;
18
18
  }): number;
19
- handleBackgroundCommand(): void;
19
+ handleImagePathPaste(path: string): Promise<void>;
20
20
  handleImagePaste(): Promise<boolean>;
21
21
  handleClipboardTextRawPaste(): Promise<void>;
22
22
  createAutocompleteProvider(commands: SlashCommand[], basePath: string): AutocompleteProvider;