@oh-my-pi/pi-coding-agent 10.2.1 → 10.2.3

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 (67) hide show
  1. package/CHANGELOG.md +45 -0
  2. package/package.json +7 -7
  3. package/src/commit/agentic/prompts/analyze-file.md +7 -7
  4. package/src/commit/agentic/prompts/session-user.md +4 -4
  5. package/src/commit/agentic/prompts/system.md +14 -16
  6. package/src/commit/prompts/analysis-system.md +7 -9
  7. package/src/commit/prompts/analysis-user.md +0 -3
  8. package/src/commit/prompts/changelog-system.md +14 -19
  9. package/src/commit/prompts/file-observer-system.md +2 -2
  10. package/src/commit/prompts/reduce-system.md +13 -23
  11. package/src/commit/prompts/summary-system.md +7 -21
  12. package/src/config/settings-schema.ts +135 -38
  13. package/src/cursor.ts +2 -1
  14. package/src/debug/index.ts +1 -1
  15. package/src/debug/report-bundle.ts +1 -1
  16. package/src/extensibility/extensions/index.ts +0 -11
  17. package/src/extensibility/extensions/types.ts +1 -30
  18. package/src/extensibility/hooks/types.ts +1 -31
  19. package/src/index.ts +0 -11
  20. package/src/ipy/prelude.py +1 -113
  21. package/src/lsp/index.ts +66 -515
  22. package/src/lsp/render.ts +0 -11
  23. package/src/lsp/types.ts +3 -87
  24. package/src/modes/components/settings-defs.ts +3 -2
  25. package/src/modes/components/settings-selector.ts +14 -14
  26. package/src/modes/interactive-mode.ts +5 -5
  27. package/src/modes/theme/theme.ts +45 -1
  28. package/src/prompts/agents/designer.md +23 -27
  29. package/src/prompts/agents/explore.md +28 -38
  30. package/src/prompts/agents/init.md +17 -17
  31. package/src/prompts/agents/plan.md +21 -27
  32. package/src/prompts/agents/reviewer.md +37 -37
  33. package/src/prompts/compaction/branch-summary.md +9 -9
  34. package/src/prompts/compaction/compaction-summary.md +8 -12
  35. package/src/prompts/compaction/compaction-update-summary.md +17 -19
  36. package/src/prompts/review-request.md +12 -13
  37. package/src/prompts/system/custom-system-prompt.md +6 -26
  38. package/src/prompts/system/plan-mode-active.md +23 -35
  39. package/src/prompts/system/plan-mode-subagent.md +7 -7
  40. package/src/prompts/system/subagent-system-prompt.md +7 -7
  41. package/src/prompts/system/system-prompt.md +84 -125
  42. package/src/prompts/system/web-search.md +10 -10
  43. package/src/prompts/tools/ask.md +12 -15
  44. package/src/prompts/tools/bash.md +7 -7
  45. package/src/prompts/tools/exit-plan-mode.md +6 -6
  46. package/src/prompts/tools/gemini-image.md +4 -4
  47. package/src/prompts/tools/grep.md +4 -4
  48. package/src/prompts/tools/lsp.md +12 -19
  49. package/src/prompts/tools/patch.md +26 -30
  50. package/src/prompts/tools/python.md +14 -57
  51. package/src/prompts/tools/read.md +4 -4
  52. package/src/prompts/tools/replace.md +8 -8
  53. package/src/prompts/tools/ssh.md +14 -27
  54. package/src/prompts/tools/task.md +23 -35
  55. package/src/prompts/tools/todo-write.md +29 -38
  56. package/src/prompts/tools/write.md +3 -3
  57. package/src/sdk.ts +0 -2
  58. package/src/session/agent-session.ts +27 -6
  59. package/src/system-prompt.ts +1 -219
  60. package/src/task/agents.ts +2 -1
  61. package/src/tools/bash-interceptor.ts +0 -24
  62. package/src/tools/bash.ts +1 -7
  63. package/src/tools/index.ts +8 -3
  64. package/src/tools/read.ts +74 -17
  65. package/src/tools/renderers.ts +0 -2
  66. package/src/lsp/rust-analyzer.ts +0 -184
  67. package/src/tools/ls.ts +0 -307
@@ -14,7 +14,47 @@
14
14
  // Schema Definition Types
15
15
  // ═══════════════════════════════════════════════════════════════════════════
16
16
 
17
- export type SettingTab = "behavior" | "tools" | "bash" | "display" | "ttsr" | "status" | "lsp" | "exa";
17
+ export type SettingTab =
18
+ | "display"
19
+ | "agent"
20
+ | "input"
21
+ | "tools"
22
+ | "config"
23
+ | "services"
24
+ | "bash"
25
+ | "lsp"
26
+ | "ttsr"
27
+ | "status";
28
+
29
+ /** Tab display metadata - icon is resolved via theme.symbol() */
30
+ export type TabMetadata = { label: string; icon: `tab.${string}` };
31
+
32
+ /** Ordered list of tabs for UI rendering (status excluded - custom menu) */
33
+ export const SETTING_TABS: SettingTab[] = [
34
+ "display",
35
+ "agent",
36
+ "input",
37
+ "tools",
38
+ "config",
39
+ "services",
40
+ "bash",
41
+ "lsp",
42
+ "ttsr",
43
+ ];
44
+
45
+ /** Tab display metadata - icon is a symbol key from theme.ts (tab.*) */
46
+ export const TAB_METADATA: Record<SettingTab, { label: string; icon: `tab.${string}` }> = {
47
+ display: { label: "Display", icon: "tab.display" },
48
+ agent: { label: "Agent", icon: "tab.agent" },
49
+ input: { label: "Input", icon: "tab.input" },
50
+ tools: { label: "Tools", icon: "tab.tools" },
51
+ config: { label: "Config", icon: "tab.config" },
52
+ services: { label: "Services", icon: "tab.services" },
53
+ bash: { label: "Bash", icon: "tab.bash" },
54
+ lsp: { label: "LSP", icon: "tab.lsp" },
55
+ ttsr: { label: "TTSR", icon: "tab.ttsr" },
56
+ status: { label: "Status", icon: "tab.status" },
57
+ };
18
58
 
19
59
  /** Status line segment identifiers */
20
60
  export type StatusLineSegmentId =
@@ -126,7 +166,7 @@ export const SETTINGS_SCHEMA = {
126
166
  values: ["off", "minimal", "low", "medium", "high", "xhigh"] as const,
127
167
  default: "off",
128
168
  ui: {
129
- tab: "display",
169
+ tab: "agent",
130
170
  label: "Thinking level",
131
171
  description: "Reasoning depth for thinking-capable models",
132
172
  submenu: true,
@@ -135,14 +175,14 @@ export const SETTINGS_SCHEMA = {
135
175
  hideThinkingBlock: {
136
176
  type: "boolean",
137
177
  default: false,
138
- ui: { tab: "display", label: "Hide thinking", description: "Hide thinking blocks in assistant responses" },
178
+ ui: { tab: "agent", label: "Hide thinking", description: "Hide thinking blocks in assistant responses" },
139
179
  },
140
180
  steeringMode: {
141
181
  type: "enum",
142
182
  values: ["all", "one-at-a-time"] as const,
143
183
  default: "one-at-a-time",
144
184
  ui: {
145
- tab: "behavior",
185
+ tab: "agent",
146
186
  label: "Steering mode",
147
187
  description: "How to process queued messages while agent is working",
148
188
  },
@@ -152,7 +192,7 @@ export const SETTINGS_SCHEMA = {
152
192
  values: ["all", "one-at-a-time"] as const,
153
193
  default: "one-at-a-time",
154
194
  ui: {
155
- tab: "behavior",
195
+ tab: "agent",
156
196
  label: "Follow-up mode",
157
197
  description: "How to drain follow-up messages after a turn completes",
158
198
  },
@@ -161,14 +201,14 @@ export const SETTINGS_SCHEMA = {
161
201
  type: "enum",
162
202
  values: ["immediate", "wait"] as const,
163
203
  default: "immediate",
164
- ui: { tab: "behavior", label: "Interrupt mode", description: "When steering messages interrupt tool execution" },
204
+ ui: { tab: "agent", label: "Interrupt mode", description: "When steering messages interrupt tool execution" },
165
205
  },
166
206
  doubleEscapeAction: {
167
207
  type: "enum",
168
208
  values: ["branch", "tree", "none"] as const,
169
209
  default: "tree",
170
210
  ui: {
171
- tab: "behavior",
211
+ tab: "input",
172
212
  label: "Double-escape action",
173
213
  description: "Action when pressing Escape twice with empty editor",
174
214
  },
@@ -186,13 +226,13 @@ export const SETTINGS_SCHEMA = {
186
226
  collapseChangelog: {
187
227
  type: "boolean",
188
228
  default: false,
189
- ui: { tab: "behavior", label: "Collapse changelog", description: "Show condensed changelog after updates" },
229
+ ui: { tab: "input", label: "Collapse changelog", description: "Show condensed changelog after updates" },
190
230
  },
191
231
  normativeRewrite: {
192
232
  type: "boolean",
193
233
  default: false,
194
234
  ui: {
195
- tab: "behavior",
235
+ tab: "agent",
196
236
  label: "Normative rewrite",
197
237
  description: "Rewrite tool call arguments to normalized format in session history",
198
238
  },
@@ -201,7 +241,7 @@ export const SETTINGS_SCHEMA = {
201
241
  type: "boolean",
202
242
  default: false,
203
243
  ui: {
204
- tab: "tools",
244
+ tab: "config",
205
245
  label: "Read line numbers",
206
246
  description: "Prepend line numbers to read tool output by default",
207
247
  },
@@ -225,7 +265,7 @@ export const SETTINGS_SCHEMA = {
225
265
  type: "boolean",
226
266
  default: true,
227
267
  ui: {
228
- tab: "behavior",
268
+ tab: "agent",
229
269
  label: "Auto-compact",
230
270
  description: "Automatically compact context when it gets too large",
231
271
  },
@@ -241,7 +281,7 @@ export const SETTINGS_SCHEMA = {
241
281
  "branchSummary.enabled": {
242
282
  type: "boolean",
243
283
  default: false,
244
- ui: { tab: "behavior", label: "Branch summaries", description: "Prompt to summarize when leaving a branch" },
284
+ ui: { tab: "agent", label: "Branch summaries", description: "Prompt to summarize when leaving a branch" },
245
285
  },
246
286
  "branchSummary.reserveTokens": { type: "number", default: 16384 },
247
287
 
@@ -253,7 +293,7 @@ export const SETTINGS_SCHEMA = {
253
293
  type: "number",
254
294
  default: 3,
255
295
  ui: {
256
- tab: "behavior",
296
+ tab: "agent",
257
297
  label: "Retry max attempts",
258
298
  description: "Maximum retry attempts on API errors",
259
299
  submenu: true,
@@ -264,29 +304,77 @@ export const SETTINGS_SCHEMA = {
264
304
  // ─────────────────────────────────────────────────────────────────────────
265
305
  // Todo completion settings
266
306
  // ─────────────────────────────────────────────────────────────────────────
267
- "todoCompletion.enabled": {
307
+ "todo.reminders": {
268
308
  type: "boolean",
269
309
  default: false,
270
- ui: { tab: "behavior", label: "Todo completion", description: "Remind agent to complete todos before stopping" },
310
+ ui: { tab: "agent", label: "Todo reminders", description: "Remind agent to complete todos before stopping" },
271
311
  },
272
- "todoCompletion.maxReminders": {
312
+ "todo.reminders.max": {
273
313
  type: "number",
274
314
  default: 3,
275
315
  ui: {
276
- tab: "behavior",
316
+ tab: "agent",
277
317
  label: "Todo max reminders",
278
318
  description: "Maximum reminders to complete todos before giving up",
279
319
  submenu: true,
280
320
  },
281
321
  },
282
322
 
323
+ // ─────────────────────────────────────────────────────────────────────────
324
+ // Optional tools
325
+ // ─────────────────────────────────────────────────────────────────────────
326
+ "todo.enabled": {
327
+ type: "boolean",
328
+ default: true,
329
+ ui: { tab: "tools", label: "Enable Todos", description: "Enable the todo_write tool for task tracking" },
330
+ },
331
+ "find.enabled": {
332
+ type: "boolean",
333
+ default: true,
334
+ ui: { tab: "tools", label: "Enable Find", description: "Enable the find tool for file searching" },
335
+ },
336
+ "grep.enabled": {
337
+ type: "boolean",
338
+ default: true,
339
+ ui: { tab: "tools", label: "Enable Grep", description: "Enable the grep tool for content searching" },
340
+ },
341
+ "notebook.enabled": {
342
+ type: "boolean",
343
+ default: true,
344
+ ui: { tab: "tools", label: "Enable Notebook", description: "Enable the notebook tool for notebook editing" },
345
+ },
346
+ "fetch.enabled": {
347
+ type: "boolean",
348
+ default: true,
349
+ ui: { tab: "tools", label: "Enable Fetch", description: "Enable the fetch tool for URL fetching" },
350
+ },
351
+ "web_search.enabled": {
352
+ type: "boolean",
353
+ default: true,
354
+ ui: { tab: "tools", label: "Enable Web Search", description: "Enable the web_search tool for web searching" },
355
+ },
356
+ "lsp.enabled": {
357
+ type: "boolean",
358
+ default: true,
359
+ ui: { tab: "tools", label: "Enable LSP", description: "Enable the lsp tool for language server protocol" },
360
+ },
361
+ "calc.enabled": {
362
+ type: "boolean",
363
+ default: false,
364
+ ui: {
365
+ tab: "tools",
366
+ label: "Enable Calculator",
367
+ description: "Enable the calculator tool for basic calculations",
368
+ },
369
+ },
370
+
283
371
  // ─────────────────────────────────────────────────────────────────────────
284
372
  // Startup settings
285
373
  // ─────────────────────────────────────────────────────────────────────────
286
374
  "startup.quiet": {
287
375
  type: "boolean",
288
376
  default: false,
289
- ui: { tab: "behavior", label: "Startup quiet", description: "Skip welcome screen and startup status messages" },
377
+ ui: { tab: "input", label: "Startup quiet", description: "Skip welcome screen and startup status messages" },
290
378
  },
291
379
 
292
380
  // ─────────────────────────────────────────────────────────────────────────
@@ -296,7 +384,7 @@ export const SETTINGS_SCHEMA = {
296
384
  type: "enum",
297
385
  values: ["auto", "bell", "osc99", "osc9", "off"] as const,
298
386
  default: "auto",
299
- ui: { tab: "behavior", label: "Completion notification", description: "Notify when the agent completes" },
387
+ ui: { tab: "input", label: "Completion notification", description: "Notify when the agent completes" },
300
388
  },
301
389
 
302
390
  // ─────────────────────────────────────────────────────────────────────────
@@ -306,7 +394,7 @@ export const SETTINGS_SCHEMA = {
306
394
  type: "number",
307
395
  default: 30,
308
396
  ui: {
309
- tab: "behavior",
397
+ tab: "input",
310
398
  label: "Ask tool timeout",
311
399
  description: "Auto-select recommended option after timeout (0 to disable)",
312
400
  submenu: true,
@@ -316,7 +404,7 @@ export const SETTINGS_SCHEMA = {
316
404
  type: "enum",
317
405
  values: ["auto", "bell", "osc99", "osc9", "off"] as const,
318
406
  default: "auto",
319
- ui: { tab: "behavior", label: "Ask notification", description: "Notify when ask tool is waiting for input" },
407
+ ui: { tab: "input", label: "Ask notification", description: "Notify when ask tool is waiting for input" },
320
408
  },
321
409
 
322
410
  // ─────────────────────────────────────────────────────────────────────────
@@ -390,19 +478,29 @@ export const SETTINGS_SCHEMA = {
390
478
  type: "enum",
391
479
  values: ["auto", "exa", "perplexity", "anthropic"] as const,
392
480
  default: "auto",
393
- ui: { tab: "tools", label: "Web search provider", description: "Provider for web search tool", submenu: true },
481
+ ui: { tab: "services", label: "Web search provider", description: "Provider for web search tool", submenu: true },
394
482
  },
395
483
  "providers.image": {
396
484
  type: "enum",
397
485
  values: ["auto", "gemini", "openrouter"] as const,
398
486
  default: "auto",
399
- ui: { tab: "tools", label: "Image provider", description: "Provider for image generation tool", submenu: true },
487
+ ui: {
488
+ tab: "services",
489
+ label: "Image provider",
490
+ description: "Provider for image generation tool",
491
+ submenu: true,
492
+ },
400
493
  },
401
494
  "providers.kimiApiFormat": {
402
495
  type: "enum",
403
496
  values: ["openai", "anthropic"] as const,
404
497
  default: "anthropic",
405
- ui: { tab: "tools", label: "Kimi API format", description: "API format for Kimi Code provider", submenu: true },
498
+ ui: {
499
+ tab: "services",
500
+ label: "Kimi API format",
501
+ description: "API format for Kimi Code provider",
502
+ submenu: true,
503
+ },
406
504
  },
407
505
 
408
506
  // ─────────────────────────────────────────────────────────────────────────
@@ -411,32 +509,32 @@ export const SETTINGS_SCHEMA = {
411
509
  "exa.enabled": {
412
510
  type: "boolean",
413
511
  default: true,
414
- ui: { tab: "exa", label: "Exa enabled", description: "Master toggle for all Exa search tools" },
512
+ ui: { tab: "services", label: "Exa enabled", description: "Master toggle for all Exa search tools" },
415
513
  },
416
514
  "exa.enableSearch": {
417
515
  type: "boolean",
418
516
  default: true,
419
- ui: { tab: "exa", label: "Exa search", description: "Basic search, deep search, code search, crawl" },
517
+ ui: { tab: "services", label: "Exa search", description: "Basic search, deep search, code search, crawl" },
420
518
  },
421
519
  "exa.enableLinkedin": {
422
520
  type: "boolean",
423
521
  default: false,
424
- ui: { tab: "exa", label: "Exa LinkedIn", description: "Search LinkedIn for people and companies" },
522
+ ui: { tab: "services", label: "Exa LinkedIn", description: "Search LinkedIn for people and companies" },
425
523
  },
426
524
  "exa.enableCompany": {
427
525
  type: "boolean",
428
526
  default: false,
429
- ui: { tab: "exa", label: "Exa company", description: "Comprehensive company research tool" },
527
+ ui: { tab: "services", label: "Exa company", description: "Comprehensive company research tool" },
430
528
  },
431
529
  "exa.enableResearcher": {
432
530
  type: "boolean",
433
531
  default: false,
434
- ui: { tab: "exa", label: "Exa researcher", description: "AI-powered deep research tasks" },
532
+ ui: { tab: "services", label: "Exa researcher", description: "AI-powered deep research tasks" },
435
533
  },
436
534
  "exa.enableWebsets": {
437
535
  type: "boolean",
438
536
  default: false,
439
- ui: { tab: "exa", label: "Exa websets", description: "Webset management and enrichment tools" },
537
+ ui: { tab: "services", label: "Exa websets", description: "Webset management and enrichment tools" },
440
538
  },
441
539
 
442
540
  // ─────────────────────────────────────────────────────────────────────────
@@ -506,14 +604,14 @@ export const SETTINGS_SCHEMA = {
506
604
  type: "enum",
507
605
  values: ["ipy-only", "bash-only", "both"] as const,
508
606
  default: "both",
509
- ui: { tab: "tools", label: "Python tool mode", description: "How Python code is executed" },
607
+ ui: { tab: "config", label: "Python tool mode", description: "How Python code is executed" },
510
608
  },
511
609
  "python.kernelMode": {
512
610
  type: "enum",
513
611
  values: ["session", "per-call"] as const,
514
612
  default: "session",
515
613
  ui: {
516
- tab: "tools",
614
+ tab: "config",
517
615
  label: "Python kernel mode",
518
616
  description: "Whether to keep IPython kernel alive across calls",
519
617
  },
@@ -522,7 +620,7 @@ export const SETTINGS_SCHEMA = {
522
620
  type: "boolean",
523
621
  default: true,
524
622
  ui: {
525
- tab: "tools",
623
+ tab: "config",
526
624
  label: "Python shared gateway",
527
625
  description: "Share IPython kernel gateway across pi instances",
528
626
  },
@@ -535,7 +633,7 @@ export const SETTINGS_SCHEMA = {
535
633
  type: "boolean",
536
634
  default: true,
537
635
  ui: {
538
- tab: "tools",
636
+ tab: "config",
539
637
  label: "Edit fuzzy match",
540
638
  description: "Accept high-confidence fuzzy matches for whitespace differences",
541
639
  },
@@ -544,7 +642,7 @@ export const SETTINGS_SCHEMA = {
544
642
  type: "number",
545
643
  default: 0.95,
546
644
  ui: {
547
- tab: "tools",
645
+ tab: "config",
548
646
  label: "Edit fuzzy threshold",
549
647
  description: "Similarity threshold for fuzzy matches",
550
648
  submenu: true,
@@ -553,13 +651,13 @@ export const SETTINGS_SCHEMA = {
553
651
  "edit.patchMode": {
554
652
  type: "boolean",
555
653
  default: true,
556
- ui: { tab: "tools", label: "Edit patch mode", description: "Use codex-style apply-patch format for edits" },
654
+ ui: { tab: "config", label: "Edit patch mode", description: "Use codex-style apply-patch format for edits" },
557
655
  },
558
656
  "edit.streamingAbort": {
559
657
  type: "boolean",
560
658
  default: false,
561
659
  ui: {
562
- tab: "tools",
660
+ tab: "config",
563
661
  label: "Edit streaming abort",
564
662
  description: "Abort streaming edit tool calls when patch preview fails",
565
663
  },
@@ -822,7 +920,6 @@ export interface BashInterceptorRule {
822
920
  export interface GroupTypeMap {
823
921
  compaction: CompactionSettings;
824
922
  retry: RetrySettings;
825
- todoCompletion: TodoCompletionSettings;
826
923
  branchSummary: BranchSummarySettings;
827
924
  skills: SkillsSettings;
828
925
  commit: CommitSettings;
package/src/cursor.ts CHANGED
@@ -156,7 +156,8 @@ export class CursorExecHandlers implements ICursorExecHandlers {
156
156
 
157
157
  async ls(args: Parameters<NonNullable<ICursorExecHandlers["ls"]>>[0]) {
158
158
  const toolCallId = decodeToolCallId(args.toolCallId);
159
- const toolResultMessage = await executeTool(this.options, "ls", toolCallId, { path: args.path });
159
+ // Redirect ls to read tool, which handles directories
160
+ const toolResultMessage = await executeTool(this.options, "read", toolCallId, { path: args.path });
160
161
  return toolResultMessage;
161
162
  }
162
163
 
@@ -4,7 +4,7 @@
4
4
  * Provides tools for debugging, bug report generation, and system diagnostics.
5
5
  */
6
6
  import * as fs from "node:fs/promises";
7
- import { getWorkProfile } from "@oh-my-pi/pi-natives/work";
7
+ import { getWorkProfile } from "@oh-my-pi/pi-natives";
8
8
  import { Container, Loader, type SelectItem, SelectList, Spacer, Text } from "@oh-my-pi/pi-tui";
9
9
  import { getSessionsDir } from "../config";
10
10
  import { DynamicBorder } from "../modes/components/dynamic-border";
@@ -6,7 +6,7 @@
6
6
  import * as fs from "node:fs/promises";
7
7
  import * as os from "node:os";
8
8
  import * as path from "node:path";
9
- import type { WorkProfile } from "@oh-my-pi/pi-natives/work";
9
+ import type { WorkProfile } from "@oh-my-pi/pi-natives";
10
10
  import { isEnoent } from "@oh-my-pi/pi-utils";
11
11
  import type { CpuProfile, HeapSnapshot } from "./profiler";
12
12
  import { collectSystemInfo, sanitizeEnv } from "./system-info";
@@ -56,7 +56,6 @@ export type {
56
56
  InputEventResult,
57
57
  KeybindingsManager,
58
58
  LoadExtensionsResult,
59
- LsToolResultEvent,
60
59
  // Message Rendering
61
60
  MessageRenderer,
62
61
  MessageRenderOptions,
@@ -104,14 +103,4 @@ export type {
104
103
  UserPythonEventResult,
105
104
  WriteToolResultEvent,
106
105
  } from "./types";
107
- // Type guards
108
- export {
109
- isBashToolResult,
110
- isEditToolResult,
111
- isFindToolResult,
112
- isGrepToolResult,
113
- isLsToolResult,
114
- isReadToolResult,
115
- isWriteToolResult,
116
- } from "./types";
117
106
  export { ExtensionToolWrapper, RegisteredToolAdapter, wrapRegisteredTool, wrapRegisteredTools } from "./wrapper";
@@ -28,7 +28,7 @@ import type {
28
28
  SessionEntry,
29
29
  SessionManager,
30
30
  } from "../../session/session-manager";
31
- import type { BashToolDetails, FindToolDetails, GrepToolDetails, LsToolDetails, ReadToolDetails } from "../../tools";
31
+ import type { BashToolDetails, FindToolDetails, GrepToolDetails, ReadToolDetails } from "../../tools";
32
32
  import type { EventBus } from "../../utils/event-bus";
33
33
 
34
34
  export type { AppAction, KeybindingsManager } from "../../config/keybindings";
@@ -495,11 +495,6 @@ export interface FindToolResultEvent extends ToolResultEventBase {
495
495
  details: FindToolDetails | undefined;
496
496
  }
497
497
 
498
- export interface LsToolResultEvent extends ToolResultEventBase {
499
- toolName: "ls";
500
- details: LsToolDetails | undefined;
501
- }
502
-
503
498
  export interface CustomToolResultEvent extends ToolResultEventBase {
504
499
  toolName: string;
505
500
  details: unknown;
@@ -513,32 +508,8 @@ export type ToolResultEvent =
513
508
  | WriteToolResultEvent
514
509
  | GrepToolResultEvent
515
510
  | FindToolResultEvent
516
- | LsToolResultEvent
517
511
  | CustomToolResultEvent;
518
512
 
519
- // Type guards
520
- export function isBashToolResult(e: ToolResultEvent): e is BashToolResultEvent {
521
- return e.toolName === "bash";
522
- }
523
- export function isReadToolResult(e: ToolResultEvent): e is ReadToolResultEvent {
524
- return e.toolName === "read";
525
- }
526
- export function isEditToolResult(e: ToolResultEvent): e is EditToolResultEvent {
527
- return e.toolName === "edit";
528
- }
529
- export function isWriteToolResult(e: ToolResultEvent): e is WriteToolResultEvent {
530
- return e.toolName === "write";
531
- }
532
- export function isGrepToolResult(e: ToolResultEvent): e is GrepToolResultEvent {
533
- return e.toolName === "grep";
534
- }
535
- export function isFindToolResult(e: ToolResultEvent): e is FindToolResultEvent {
536
- return e.toolName === "find";
537
- }
538
- export function isLsToolResult(e: ToolResultEvent): e is LsToolResultEvent {
539
- return e.toolName === "ls";
540
- }
541
-
542
513
  /** Union of all event types */
543
514
  export type ExtensionEvent =
544
515
  | SessionEvent
@@ -20,7 +20,7 @@ import type {
20
20
  SessionEntry,
21
21
  SessionManager,
22
22
  } from "../../session/session-manager";
23
- import type { BashToolDetails, FindToolDetails, GrepToolDetails, LsToolDetails, ReadToolDetails } from "../../tools";
23
+ import type { BashToolDetails, FindToolDetails, GrepToolDetails, ReadToolDetails } from "../../tools";
24
24
 
25
25
  // Re-export for backward compatibility
26
26
  export type { ExecOptions, ExecResult } from "../../exec/exec";
@@ -454,12 +454,6 @@ export interface FindToolResultEvent extends ToolResultEventBase {
454
454
  details: FindToolDetails | undefined;
455
455
  }
456
456
 
457
- /** Tool result event for ls tool */
458
- export interface LsToolResultEvent extends ToolResultEventBase {
459
- toolName: "ls";
460
- details: LsToolDetails | undefined;
461
- }
462
-
463
457
  /** Tool result event for custom/unknown tools */
464
458
  export interface CustomToolResultEvent extends ToolResultEventBase {
465
459
  toolName: string;
@@ -478,32 +472,8 @@ export type ToolResultEvent =
478
472
  | WriteToolResultEvent
479
473
  | GrepToolResultEvent
480
474
  | FindToolResultEvent
481
- | LsToolResultEvent
482
475
  | CustomToolResultEvent;
483
476
 
484
- // Type guards for narrowing ToolResultEvent to specific tool types
485
- export function isBashToolResult(e: ToolResultEvent): e is BashToolResultEvent {
486
- return e.toolName === "bash";
487
- }
488
- export function isReadToolResult(e: ToolResultEvent): e is ReadToolResultEvent {
489
- return e.toolName === "read";
490
- }
491
- export function isEditToolResult(e: ToolResultEvent): e is EditToolResultEvent {
492
- return e.toolName === "edit";
493
- }
494
- export function isWriteToolResult(e: ToolResultEvent): e is WriteToolResultEvent {
495
- return e.toolName === "write";
496
- }
497
- export function isGrepToolResult(e: ToolResultEvent): e is GrepToolResultEvent {
498
- return e.toolName === "grep";
499
- }
500
- export function isFindToolResult(e: ToolResultEvent): e is FindToolResultEvent {
501
- return e.toolName === "find";
502
- }
503
- export function isLsToolResult(e: ToolResultEvent): e is LsToolResultEvent {
504
- return e.toolName === "ls";
505
- }
506
-
507
477
  /**
508
478
  * Union of all hook event types.
509
479
  */
package/src/index.ts CHANGED
@@ -75,13 +75,6 @@ export {
75
75
  discoverAndLoadExtensions,
76
76
  ExtensionRunner,
77
77
  ExtensionRuntime,
78
- isBashToolResult,
79
- isEditToolResult,
80
- isFindToolResult,
81
- isGrepToolResult,
82
- isLsToolResult,
83
- isReadToolResult,
84
- isWriteToolResult,
85
78
  } from "./extensibility/extensions";
86
79
  // Hook system types (legacy re-export)
87
80
  export type * from "./extensibility/hooks";
@@ -180,7 +173,6 @@ export {
180
173
  EditTool,
181
174
  FindTool,
182
175
  GrepTool,
183
- LsTool,
184
176
  loadSshTool,
185
177
  PythonTool,
186
178
  ReadTool,
@@ -256,9 +248,6 @@ export {
256
248
  type GrepOperations,
257
249
  type GrepToolDetails,
258
250
  type GrepToolOptions,
259
- type LsOperations,
260
- type LsToolDetails,
261
- type LsToolOptions,
262
251
  type PythonToolDetails,
263
252
  type ReadToolDetails,
264
253
  type TruncationOptions,