@caupulican/pi-adaptative 0.93.19 → 0.94.0

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 (98) hide show
  1. package/CHANGELOG.md +14 -0
  2. package/README.md +3 -2
  3. package/dist/core/extensions/loader.d.ts +0 -1
  4. package/dist/core/extensions/loader.d.ts.map +1 -1
  5. package/dist/core/extensions/loader.js +0 -1
  6. package/dist/core/extensions/loader.js.map +1 -1
  7. package/dist/core/extensions/types.d.ts +0 -4
  8. package/dist/core/extensions/types.d.ts.map +1 -1
  9. package/dist/core/extensions/types.js.map +1 -1
  10. package/dist/core/tools/artifact-retrieve.d.ts.map +1 -1
  11. package/dist/core/tools/artifact-retrieve.js +0 -1
  12. package/dist/core/tools/artifact-retrieve.js.map +1 -1
  13. package/dist/core/tools/edit.d.ts.map +1 -1
  14. package/dist/core/tools/edit.js +0 -7
  15. package/dist/core/tools/edit.js.map +1 -1
  16. package/dist/core/tools/find.d.ts.map +1 -1
  17. package/dist/core/tools/find.js +0 -1
  18. package/dist/core/tools/find.js.map +1 -1
  19. package/dist/core/tools/grep.d.ts.map +1 -1
  20. package/dist/core/tools/grep.js +0 -1
  21. package/dist/core/tools/grep.js.map +1 -1
  22. package/dist/core/tools/ls.d.ts.map +1 -1
  23. package/dist/core/tools/ls.js +0 -1
  24. package/dist/core/tools/ls.js.map +1 -1
  25. package/dist/core/tools/skill-audit.d.ts.map +1 -1
  26. package/dist/core/tools/skill-audit.js +0 -1
  27. package/dist/core/tools/skill-audit.js.map +1 -1
  28. package/dist/core/tools/skill.d.ts.map +1 -1
  29. package/dist/core/tools/skill.js +0 -1
  30. package/dist/core/tools/skill.js.map +1 -1
  31. package/dist/core/tools/skillify.d.ts.map +1 -1
  32. package/dist/core/tools/skillify.js +0 -1
  33. package/dist/core/tools/skillify.js.map +1 -1
  34. package/dist/core/tools/write.d.ts.map +1 -1
  35. package/dist/core/tools/write.js +1 -2
  36. package/dist/core/tools/write.js.map +1 -1
  37. package/dist/modes/interactive/components/action-transcript.d.ts +24 -0
  38. package/dist/modes/interactive/components/action-transcript.d.ts.map +1 -0
  39. package/dist/modes/interactive/components/action-transcript.js +72 -0
  40. package/dist/modes/interactive/components/action-transcript.js.map +1 -0
  41. package/dist/modes/interactive/components/active-tool-call-registry.d.ts +12 -0
  42. package/dist/modes/interactive/components/active-tool-call-registry.d.ts.map +1 -0
  43. package/dist/modes/interactive/components/active-tool-call-registry.js +25 -0
  44. package/dist/modes/interactive/components/active-tool-call-registry.js.map +1 -0
  45. package/dist/modes/interactive/components/activity-lane.d.ts +1 -1
  46. package/dist/modes/interactive/components/activity-lane.d.ts.map +1 -1
  47. package/dist/modes/interactive/components/activity-lane.js.map +1 -1
  48. package/dist/modes/interactive/components/assistant-message.d.ts +2 -0
  49. package/dist/modes/interactive/components/assistant-message.d.ts.map +1 -1
  50. package/dist/modes/interactive/components/assistant-message.js +7 -1
  51. package/dist/modes/interactive/components/assistant-message.js.map +1 -1
  52. package/dist/modes/interactive/components/index.d.ts +0 -2
  53. package/dist/modes/interactive/components/index.d.ts.map +1 -1
  54. package/dist/modes/interactive/components/index.js +0 -2
  55. package/dist/modes/interactive/components/index.js.map +1 -1
  56. package/dist/modes/interactive/components/tool-execution.d.ts +0 -7
  57. package/dist/modes/interactive/components/tool-execution.d.ts.map +1 -1
  58. package/dist/modes/interactive/components/tool-execution.js +2 -76
  59. package/dist/modes/interactive/components/tool-execution.js.map +1 -1
  60. package/dist/modes/interactive/components/transcript-overlay.d.ts +3 -1
  61. package/dist/modes/interactive/components/transcript-overlay.d.ts.map +1 -1
  62. package/dist/modes/interactive/components/transcript-overlay.js +8 -5
  63. package/dist/modes/interactive/components/transcript-overlay.js.map +1 -1
  64. package/dist/modes/interactive/interactive-event-controller.d.ts +2 -3
  65. package/dist/modes/interactive/interactive-event-controller.d.ts.map +1 -1
  66. package/dist/modes/interactive/interactive-event-controller.js +9 -9
  67. package/dist/modes/interactive/interactive-event-controller.js.map +1 -1
  68. package/dist/modes/interactive/interactive-mode.d.ts +6 -6
  69. package/dist/modes/interactive/interactive-mode.d.ts.map +1 -1
  70. package/dist/modes/interactive/interactive-mode.js +50 -100
  71. package/dist/modes/interactive/interactive-mode.js.map +1 -1
  72. package/dist/modes/interactive/settings-selector-flow.d.ts.map +1 -1
  73. package/dist/modes/interactive/settings-selector-flow.js +3 -4
  74. package/dist/modes/interactive/settings-selector-flow.js.map +1 -1
  75. package/docs/UI_POLISH_ORCHESTRATION.md +4 -4
  76. package/docs/extensions.md +4 -12
  77. package/docs/keybindings.md +2 -2
  78. package/docs/settings.md +1 -1
  79. package/docs/task-steps.md +3 -3
  80. package/docs/tool-repair.md +1 -1
  81. package/docs/usage.md +1 -1
  82. package/examples/extensions/custom-provider-anthropic/package-lock.json +2 -2
  83. package/examples/extensions/custom-provider-anthropic/package.json +1 -1
  84. package/examples/extensions/custom-provider-gitlab-duo/package.json +1 -1
  85. package/examples/extensions/sandbox/package-lock.json +2 -2
  86. package/examples/extensions/sandbox/package.json +1 -1
  87. package/examples/extensions/with-deps/package-lock.json +2 -2
  88. package/examples/extensions/with-deps/package.json +1 -1
  89. package/npm-shrinkwrap.json +12 -12
  90. package/package.json +4 -4
  91. package/dist/modes/interactive/components/tool-group.d.ts +0 -28
  92. package/dist/modes/interactive/components/tool-group.d.ts.map +0 -1
  93. package/dist/modes/interactive/components/tool-group.js +0 -200
  94. package/dist/modes/interactive/components/tool-group.js.map +0 -1
  95. package/dist/modes/interactive/components/tool-panel-registry.d.ts +0 -30
  96. package/dist/modes/interactive/components/tool-panel-registry.d.ts.map +0 -1
  97. package/dist/modes/interactive/components/tool-panel-registry.js +0 -145
  98. package/dist/modes/interactive/components/tool-panel-registry.js.map +0 -1
@@ -1 +1 @@
1
- {"version":3,"file":"settings-selector-flow.d.ts","sourceRoot":"","sources":["../../../src/modes/interactive/settings-selector-flow.ts"],"names":[],"mappings":"AAAA;;;;;;;;GAQG;AAGH,OAAO,KAAK,EAA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Y,CAAC,MAAM,EAAE,CAAC,IAAI,EAAE,MAAM,IAAI,KAAK;QAAE,SAAS,EAAE,SAAS,CAAC;QAAC,KAAK,EAAE,SAAS,CAAA;KAAE,GAAG,IAAI,CAAC;IAC7F,UAAU,CAAC,OAAO,EAAE,MAAM,GAAG,IAAI,CAAC;IAClC,WAAW,CAAC,OAAO,EAAE,MAAM,GAAG,IAAI,CAAC;IACnC,SAAS,CAAC,OAAO,EAAE,MAAM,GAAG,IAAI,CAAC;IACjC,wBAAwB,IAAI,UAAU,EAAE,CAAC;IACzC,yBAAyB,IAAI,IAAI,CAAC;IAClC,uBAAuB,IAAI,IAAI,CAAC;IAChC,uBAAuB,IAAI,OAAO,CAAC,IAAI,CAAC,CAAC;IACzC,8BAA8B,CAAC,QAAQ,EAAE,wBAAwB,GAAG,MAAM,GAAG,SAAS,CAAC;IACvF,iBAAiB,CAAC,IAAI,EAAE,YAAY,EAAE,KAAK,CAAC,EAAE,aAAa,GAAG,IAAI,CAAC;IACnE,2BAA2B,CAAC,KAAK,EAAE,MAAM,GAAG,SAAS,GAAG,MAAM,GAAG,SAAS,CAAC;IAC3E,qBAAqB,IAAI,IAAI,CAAC;IAC9B,wBAAwB,CAAC,MAAM,EAAE,MAAM,GAAG,OAAO,CAAC,IAAI,CAAC,CAAC;CACxD;AAED,wBAAgB,oBAAoB,CAAC,IAAI,EAAE,oBAAoB,GAAG,IAAI,CA2SrE"}
@@ -10,10 +10,9 @@
10
10
  import { getSupportedThinkingLevels } from "@caupulican/pi-ai";
11
11
  import { configureHttpDispatcher, formatHttpIdleTimeoutMs } from "../../core/http-dispatcher.js";
12
12
  import { resolveCliModel } from "../../core/model-resolver.js";
13
+ import { ActionTranscriptComponent } from "./components/action-transcript.js";
13
14
  import { AssistantMessageComponent } from "./components/assistant-message.js";
14
15
  import { SettingsSelectorComponent } from "./components/settings-selector.js";
15
- import { ToolExecutionComponent } from "./components/tool-execution.js";
16
- import { ToolGroupComponent } from "./components/tool-group.js";
17
16
  import { getAvailableThemes, setTheme } from "./theme/theme.js";
18
17
  export function showSettingsSelector(host) {
19
18
  host.showSelector((done) => {
@@ -109,7 +108,7 @@ export function showSettingsSelector(host) {
109
108
  onShowImagesChange: (enabled) => {
110
109
  host.settingsManager.setShowImages(enabled);
111
110
  for (const child of host.chatContainer.children) {
112
- if (child instanceof ToolExecutionComponent || child instanceof ToolGroupComponent) {
111
+ if (child instanceof ActionTranscriptComponent) {
113
112
  child.setShowImages(enabled);
114
113
  }
115
114
  }
@@ -118,7 +117,7 @@ export function showSettingsSelector(host) {
118
117
  onImageWidthCellsChange: (width) => {
119
118
  host.settingsManager.setImageWidthCells(width);
120
119
  for (const child of host.chatContainer.children) {
121
- if (child instanceof ToolExecutionComponent || child instanceof ToolGroupComponent) {
120
+ if (child instanceof ActionTranscriptComponent) {
122
121
  child.setImageWidthCells(width);
123
122
  }
124
123
  }
@@ -1 +1 @@
1
- {"version":3,"file":"settings-selector-flow.js","sourceRoot":"","sources":["../../../src/modes/interactive/settings-selector-flow.ts"],"names":[],"mappings":"AAAA;;;;;;;;GAQG;AAEH,OAAO,EAAE,0BAA0B,EAAE,MAAM,mBAAmB,CAAC;AAG/D,OAAO,EAAE,uBAAuB,EAAE,uBAAuB,EAAE,MAAM,+BAA+B,CAAC;AACjG,OAAO,EAAE,eAAe,EAAE,MAAM,8BAA8B,CAAC;AAO/D,OAAO,EAAE,yBAAyB,EAAE,MAAM,mCAAmC,CAAC;AAG9E,OAAO,EAAE,yBAAyB,EAAE,MAAM,mCAAmC,CAAC;AAC9E,OAAO,EAAE,sBAAsB,EAAE,MAAM,gCAAgC,CAAC;AACxE,OAAO,EAAE,kBAAkB,EAAE,MAAM,4BAA4B,CAAC;AAChE,OAAO,EAAE,kBAAkB,EAAE,QAAQ,EAAE,MAAM,kBAAkB,CAAC;AA0BhE,MAAM,UAAU,oBAAoB,CAAC,IAA0B;IAC9D,IAAI,CAAC,YAAY,CAAC,CAAC,IAAI,EAAE,EAAE;QAC1B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AE,KAAK,CAAC,CAAC;gBACjE,IAAI,CAAC,UAAU,CAAC,8CAA8C,KAAK,GAAG,CAAC,CAAC;YACzE,CAAC;YACD,oBAAoB,EAAE,CAAC,MAAM,EAAE,EAAE;gBAChC,IAAI,EAAE,CAAC;gBACP,KAAK,IAAI,CAAC,wBAAwB,CAAC,MAAM,CAAC,CAAC;YAC5C,CAAC;YACD,QAAQ,EAAE,GAAG,EAAE;gBACd,IAAI,EAAE,CAAC;gBACP,IAAI,CAAC,EAAE,CAAC,aAAa,EAAE,CAAC;YACzB,CAAC;SACD,CACD,CAAC;QACF,OAAO,EAAE,SAAS,EAAE,QAAQ,EAAE,KAAK,EAAE,QAAQ,CAAC,eAAe,EAAE,EAAE,CAAC;IACnE,CAAC,CAAC,CAAC;AACJ,CAAC","sourcesContent":["/**\n * `/settings` selector flow extracted from interactive-mode.\n *\n * Builds the SettingsSelectorComponent model from the current settings/session\n * state and wires its change callbacks back through a `SettingsSelectorHost`\n * seam. Self-mod/auto-learn validation, autonomy-preset application, autocomplete\n * rebuild, and the resources-hub hand-off stay host-side (shared with other\n * flows); interactive-mode keeps a thin wrapper building the host once.\n */\n\nimport { getSupportedThinkingLevels } from \"@caupulican/pi-ai\";\nimport type { Component, Container, EditorComponent, SelectItem, TUI } from \"@caupulican/pi-tui\";\nimport type { AgentSession } from \"../../core/agent-session.ts\";\nimport { configureHttpDispatcher, formatHttpIdleTimeoutMs } from \"../../core/http-dispatcher.ts\";\nimport { resolveCliModel } from \"../../core/model-resolver.ts\";\nimport type {\n\tAutonomyMode,\n\tSelfModificationSettings,\n\tSettingsManager,\n\tSettingsScope,\n} from \"../../core/settings-manager.ts\";\nimport { AssistantMessageComponent } from \"./components/assistant-message.ts\";\nimport type { CustomEditor } from \"./components/custom-editor.ts\";\nimport type { FooterComponent } from \"./components/footer.ts\";\nimport { SettingsSelectorComponent } from \"./components/settings-selector.ts\";\nimport { ToolExecutionComponent } from \"./components/tool-execution.ts\";\nimport { ToolGroupComponent } from \"./components/tool-group.ts\";\nimport { getAvailableThemes, setTheme } from \"./theme/theme.ts\";\n\nexport interface SettingsSelectorHost {\n\treadonly session: AgentSession;\n\treadonly settingsManager: SettingsManager;\n\treadonly footer: FooterComponent;\n\treadonly chatContainer: Container;\n\treadonly ui: TUI;\n\treadonly defaultEditor: CustomEditor;\n\treadonly editor: EditorComponent;\n\thideThinkingBlock: boolean;\n\tshowSelector(create: (done: () => void) => { component: Component; focus: Component }): void;\n\tshowStatus(message: string): void;\n\tshowWarning(message: string): void;\n\tshowError(message: string): void;\n\tgetAutoLearnModelOptions(): SelectItem[];\n\tsetupAutocompleteProvider(): void;\n\tupdateEditorBorderColor(): void;\n\trebuildChatFromMessages(): Promise<void>;\n\tvalidateSelfModificationSource(settings: SelfModificationSettings): string | undefined;\n\tapplyAutonomyMode(mode: AutonomyMode, scope?: SettingsScope): void;\n\tvalidateAutoLearnModelValue(value: string | undefined): string | undefined;\n\tupdateAutoLearnFooter(): void;\n\thandleResourcesHubAction(action: string): Promise<void>;\n}\n\nexport function showSettingsSelector(host: SettingsSelectorHost): void {\n\thost.showSelector((done) => {\n\t\tconst projectSettings = host.settingsManager.getProjectSettings();\n\t\tconst profileOptions = [\n\t\t\t{\n\t\t\t\tvalue: \"(none)\",\n\t\t\t\tlabel: \"(none)\",\n\t\t\t\tdescription: \"Use configured profile selection (session default)\",\n\t\t\t},\n\t\t\t...host.settingsManager\n\t\t\t\t.getProfileRegistry()\n\t\t\t\t.listProfiles()\n\t\t\t\t.map((profile) => ({\n\t\t\t\t\tvalue: profile.name,\n\t\t\t\t\tlabel: profile.name,\n\t\t\t\t\tdescription: profile.description ?? profile.source,\n\t\t\t\t})),\n\t\t];\n\t\tconst selector = new SettingsSelectorComponent(\n\t\t\t{\n\t\t\t\tautoCompact: host.session.autoCompactionEnabled,\n\t\t\t\tshowImages: host.settingsManager.getShowImages(),\n\t\t\t\timageWidthCells: host.settingsManager.getImageWidthCells(),\n\t\t\t\tautoResizeImages: host.settingsManager.getImageAutoResize(),\n\t\t\t\tblockImages: host.settingsManager.getBlockImages(),\n\t\t\t\tenableSkillCommands: host.settingsManager.getEnableSkillCommands(),\n\t\t\t\tsteeringMode: host.session.steeringMode,\n\t\t\t\tfollowUpMode: host.session.followUpMode,\n\t\t\t\ttransport: host.settingsManager.getTransport(),\n\t\t\t\thttpIdleTimeoutMs: host.settingsManager.getHttpIdleTimeoutMs(),\n\t\t\t\tthinkingLevel: host.session.thinkingLevel,\n\t\t\t\tavailableThinkingLevels: host.session.getAvailableThinkingLevels(),\n\t\t\t\tcurrentTheme: host.settingsManager.getTheme() || \"dark\",\n\t\t\t\t// The picker offers only themes the active profile permits (no-bypass). The theme\n\t\t\t\t// registry/renderer keeps the full set, so an already-applied theme still renders\n\t\t\t\t// even if the profile would block re-selecting it.\n\t\t\t\tavailableThemes: getAvailableThemes().filter((name) =>\n\t\t\t\t\thost.settingsManager.isResourceAllowedByProfile(\"themes\", name),\n\t\t\t\t),\n\t\t\t\thideThinkingBlock: host.hideThinkingBlock,\n\t\t\t\tprojectContextFiles: host.settingsManager.getProjectContextFiles(),\n\t\t\t\tprojectContextFilesScope: host.settingsManager.getProjectContextFilesScope(),\n\t\t\t\tcollapseChangelog: host.settingsManager.getCollapseChangelog(),\n\t\t\t\tenableInstallTelemetry: host.settingsManager.getEnableInstallTelemetry(),\n\t\t\t\tdoubleEscapeAction: host.settingsManager.getDoubleEscapeAction(),\n\t\t\t\ttreeFilterMode: host.settingsManager.getTreeFilterMode(),\n\t\t\t\tshowHardwareCursor: host.settingsManager.getShowHardwareCursor(),\n\t\t\t\teditorPaddingX: host.settingsManager.getEditorPaddingX(),\n\t\t\t\tautocompleteMaxVisible: host.settingsManager.getAutocompleteMaxVisible(),\n\t\t\t\tquietStartup: host.settingsManager.getQuietStartup(),\n\t\t\t\tclearOnShrink: host.settingsManager.getClearOnShrink(),\n\t\t\t\tshowTerminalProgress: host.settingsManager.getShowTerminalProgress(),\n\t\t\t\twarnings: host.settingsManager.getWarnings(),\n\t\t\t\tselfModification: host.settingsManager.getSelfModificationSettings(),\n\t\t\t\tselfModificationScope: projectSettings.selfModification ? \"project\" : \"global\",\n\t\t\t\tautonomy: host.settingsManager.getAutonomySettings(),\n\t\t\t\tautonomyScope: projectSettings.autonomy ? \"project\" : \"global\",\n\t\t\t\tresearchLane: host.settingsManager.getResearchLaneSettings(),\n\t\t\t\tresearchLaneScope: projectSettings.researchLane ? \"project\" : \"global\",\n\t\t\t\tworkerDelegation: host.settingsManager.getWorkerDelegationSettings(),\n\t\t\t\tworkerDelegationScope: projectSettings.workerDelegation ? \"project\" : \"global\",\n\t\t\t\tcontextCuration: host.settingsManager.getContextCurationSettings(),\n\t\t\t\tcontextCurationScope: projectSettings.contextPolicy?.curation ? \"project\" : \"global\",\n\t\t\t\tlearningPolicy: host.settingsManager.getLearningPolicySettings(),\n\t\t\t\tlearningPolicyScope: projectSettings.learningPolicy ? \"project\" : \"global\",\n\t\t\t\tmodelCapability: host.settingsManager.getModelCapabilitySettings(),\n\t\t\t\tmodelCapabilityScope: projectSettings.modelCapability ? \"project\" : \"global\",\n\t\t\t\tmodelRouter: host.settingsManager.getModelRouterSettings(),\n\t\t\t\tmodelRouterScope: projectSettings.modelRouter ? \"project\" : \"global\",\n\t\t\t\tautoLearn: host.settingsManager.getAutoLearnSettings(),\n\t\t\t\tautoLearnScope: projectSettings.autoLearn ? \"project\" : \"global\",\n\t\t\t\tautoLearnModelOptions: host.getAutoLearnModelOptions(),\n\t\t\t\tresolveModelThinkingLevels: (modelPattern) => {\n\t\t\t\t\tif (!modelPattern) return host.session.getAvailableThinkingLevels();\n\t\t\t\t\tconst resolved = resolveCliModel({ cliModel: modelPattern, modelRegistry: host.session.modelRegistry });\n\t\t\t\t\treturn resolved.model ? getSupportedThinkingLevels(resolved.model) : undefined;\n\t\t\t\t},\n\t\t\t\tcontextPolicyEnforcement: host.settingsManager.getContextPromptEnforcementSettings(),\n\t\t\t\tcontextPolicyEnforcementScope: projectSettings.contextPolicy?.enforcement ? \"project\" : \"global\",\n\t\t\t\tcontextMemoryRetrieval: host.settingsManager.getMemoryRetrievalSettings(),\n\t\t\t\tcontextMemoryRetrievalScope: projectSettings.contextPolicy?.memory ? \"project\" : \"global\",\n\t\t\t\tcurrentModelPattern: host.session.model\n\t\t\t\t\t? `${host.session.model.provider}/${host.session.model.id}`\n\t\t\t\t\t: undefined,\n\t\t\t\tactiveProfileName: host.settingsManager.getActiveResourceProfileNames()[0],\n\t\t\t\tprofileOptions,\n\t\t\t\texternalResourceRoots: host.settingsManager.getExternalResourceRoots(),\n\t\t\t\ttrustedResourceRoots: host.settingsManager.getTrustedResourceRoots(),\n\t\t\t},\n\t\t\t{\n\t\t\t\tonAutoCompactChange: (enabled) => {\n\t\t\t\t\thost.session.setAutoCompactionEnabled(enabled);\n\t\t\t\t\thost.footer.setAutoCompactEnabled(enabled);\n\t\t\t\t},\n\t\t\t\tonShowImagesChange: (enabled) => {\n\t\t\t\t\thost.settingsManager.setShowImages(enabled);\n\t\t\t\t\tfor (const child of host.chatContainer.children) {\n\t\t\t\t\t\tif (child instanceof ToolExecutionComponent || child instanceof ToolGroupComponent) {\n\t\t\t\t\t\t\tchild.setShowImages(enabled);\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\thost.ui.requestRender();\n\t\t\t\t},\n\t\t\t\tonImageWidthCellsChange: (width) => {\n\t\t\t\t\thost.settingsManager.setImageWidthCells(width);\n\t\t\t\t\tfor (const child of host.chatContainer.children) {\n\t\t\t\t\t\tif (child instanceof ToolExecutionComponent || child instanceof ToolGroupComponent) {\n\t\t\t\t\t\t\tchild.setImageWidthCells(width);\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\thost.ui.requestRender();\n\t\t\t\t},\n\t\t\t\tonAutoResizeImagesChange: (enabled) => {\n\t\t\t\t\thost.settingsManager.setImageAutoResize(enabled);\n\t\t\t\t},\n\t\t\t\tonBlockImagesChange: (blocked) => {\n\t\t\t\t\thost.settingsManager.setBlockImages(blocked);\n\t\t\t\t},\n\t\t\t\tonEnableSkillCommandsChange: (enabled) => {\n\t\t\t\t\thost.settingsManager.setEnableSkillCommands(enabled);\n\t\t\t\t\thost.setupAutocompleteProvider();\n\t\t\t\t},\n\t\t\t\tonSteeringModeChange: (mode) => {\n\t\t\t\t\thost.session.setSteeringMode(mode);\n\t\t\t\t},\n\t\t\t\tonFollowUpModeChange: (mode) => {\n\t\t\t\t\thost.session.setFollowUpMode(mode);\n\t\t\t\t},\n\t\t\t\tonTransportChange: (transport) => {\n\t\t\t\t\thost.settingsManager.setTransport(transport);\n\t\t\t\t\thost.session.agent.transport = transport;\n\t\t\t\t},\n\t\t\t\tonHttpIdleTimeoutMsChange: (timeoutMs) => {\n\t\t\t\t\thost.settingsManager.setHttpIdleTimeoutMs(timeoutMs);\n\t\t\t\t\tconfigureHttpDispatcher(timeoutMs);\n\t\t\t\t\thost.showStatus(`HTTP idle timeout: ${formatHttpIdleTimeoutMs(timeoutMs)}`);\n\t\t\t\t},\n\t\t\t\tonThinkingLevelChange: (level) => {\n\t\t\t\t\thost.session.setThinkingLevel(level);\n\t\t\t\t\thost.footer.invalidate();\n\t\t\t\t\thost.updateEditorBorderColor();\n\t\t\t\t},\n\t\t\t\tonThemeChange: (themeName) => {\n\t\t\t\t\tconst result = setTheme(themeName, true);\n\t\t\t\t\thost.settingsManager.setTheme(themeName);\n\t\t\t\t\thost.ui.invalidate();\n\t\t\t\t\tif (!result.success) {\n\t\t\t\t\t\thost.showError(`Failed to load theme \"${themeName}\": ${result.error}\\nFell back to dark theme.`);\n\t\t\t\t\t}\n\t\t\t\t},\n\t\t\t\tonThemePreview: (themeName) => {\n\t\t\t\t\tconst result = setTheme(themeName, true);\n\t\t\t\t\tif (result.success) {\n\t\t\t\t\t\thost.ui.invalidate();\n\t\t\t\t\t\thost.ui.requestRender();\n\t\t\t\t\t}\n\t\t\t\t},\n\t\t\t\tonProjectContextFilesChange: (mode, scope) => {\n\t\t\t\t\thost.settingsManager.setProjectContextFiles(mode, scope);\n\t\t\t\t\tconst where =\n\t\t\t\t\t\tscope === \"directoryProfile\"\n\t\t\t\t\t\t\t? \"this directory\"\n\t\t\t\t\t\t\t: scope === \"project\"\n\t\t\t\t\t\t\t\t? \"this project\"\n\t\t\t\t\t\t\t\t: \"all projects\";\n\t\t\t\t\tconst load = mode === \"on-demand\" ? \"lists this project's AGENTS.md\" : \"global AGENTS.md only\";\n\t\t\t\t\thost.showStatus(`Project context files: ${load} (${where}). Run /reload to apply.`);\n\t\t\t\t},\n\t\t\t\tonHideThinkingBlockChange: (hidden) => {\n\t\t\t\t\thost.hideThinkingBlock = hidden;\n\t\t\t\t\thost.settingsManager.setHideThinkingBlock(hidden);\n\t\t\t\t\tfor (const child of host.chatContainer.children) {\n\t\t\t\t\t\tif (child instanceof AssistantMessageComponent) {\n\t\t\t\t\t\t\tchild.setHideThinkingBlock(hidden);\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\tvoid host.rebuildChatFromMessages();\n\t\t\t\t},\n\t\t\t\tonCollapseChangelogChange: (collapsed) => {\n\t\t\t\t\thost.settingsManager.setCollapseChangelog(collapsed);\n\t\t\t\t},\n\t\t\t\tonEnableInstallTelemetryChange: (enabled) => {\n\t\t\t\t\thost.settingsManager.setEnableInstallTelemetry(enabled);\n\t\t\t\t},\n\t\t\t\tonQuietStartupChange: (enabled) => {\n\t\t\t\t\thost.settingsManager.setQuietStartup(enabled);\n\t\t\t\t},\n\t\t\t\tonDoubleEscapeActionChange: (action) => {\n\t\t\t\t\thost.settingsManager.setDoubleEscapeAction(action);\n\t\t\t\t},\n\t\t\t\tonTreeFilterModeChange: (mode) => {\n\t\t\t\t\thost.settingsManager.setTreeFilterMode(mode);\n\t\t\t\t},\n\t\t\t\tonShowHardwareCursorChange: (enabled) => {\n\t\t\t\t\thost.settingsManager.setShowHardwareCursor(enabled);\n\t\t\t\t\thost.ui.setShowHardwareCursor(enabled);\n\t\t\t\t},\n\t\t\t\tonEditorPaddingXChange: (padding) => {\n\t\t\t\t\thost.settingsManager.setEditorPaddingX(padding);\n\t\t\t\t\thost.defaultEditor.setPaddingX(padding);\n\t\t\t\t\tif (host.editor !== host.defaultEditor && host.editor.setPaddingX !== undefined) {\n\t\t\t\t\t\thost.editor.setPaddingX(padding);\n\t\t\t\t\t}\n\t\t\t\t},\n\t\t\t\tonAutocompleteMaxVisibleChange: (maxVisible) => {\n\t\t\t\t\thost.settingsManager.setAutocompleteMaxVisible(maxVisible);\n\t\t\t\t\thost.defaultEditor.setAutocompleteMaxVisible(maxVisible);\n\t\t\t\t\tif (host.editor !== host.defaultEditor && host.editor.setAutocompleteMaxVisible !== undefined) {\n\t\t\t\t\t\thost.editor.setAutocompleteMaxVisible(maxVisible);\n\t\t\t\t\t}\n\t\t\t\t},\n\t\t\t\tonClearOnShrinkChange: (enabled) => {\n\t\t\t\t\thost.settingsManager.setClearOnShrink(enabled);\n\t\t\t\t\thost.ui.setClearOnShrink(enabled);\n\t\t\t\t},\n\t\t\t\tonShowTerminalProgressChange: (enabled) => {\n\t\t\t\t\thost.settingsManager.setShowTerminalProgress(enabled);\n\t\t\t\t},\n\t\t\t\tonWarningsChange: (warnings) => {\n\t\t\t\t\thost.settingsManager.setWarnings(warnings);\n\t\t\t\t},\n\t\t\t\tonSelfModificationChange: (settings, scope) => {\n\t\t\t\t\thost.settingsManager.setSelfModificationSettings(settings, scope);\n\t\t\t\t\tconst validationMessage = host.validateSelfModificationSource(settings);\n\t\t\t\t\tif (validationMessage) {\n\t\t\t\t\t\thost.showWarning(validationMessage);\n\t\t\t\t\t}\n\t\t\t\t\thost.showStatus(\n\t\t\t\t\t\t`Self modification settings saved to ${scope}. Start a new session or /reload for system-prompt guardrails to fully refresh.`,\n\t\t\t\t\t);\n\t\t\t\t},\n\t\t\t\tonAutonomyChange: (settings, scope) => {\n\t\t\t\t\thost.applyAutonomyMode(settings.mode ?? \"off\", scope);\n\t\t\t\t\thost.showStatus(`Autonomy mode ${settings.mode ?? \"off\"} saved to ${scope}. Use /autonomy status.`);\n\t\t\t\t},\n\t\t\t\tonResearchLaneChange: (settings, scope) => {\n\t\t\t\t\thost.settingsManager.setResearchLaneSettings(settings, scope);\n\t\t\t\t\thost.showStatus(\n\t\t\t\t\t\t`Research lane settings saved to ${scope}. Use /autonomy research or /autonomy diagnostics.`,\n\t\t\t\t\t);\n\t\t\t\t},\n\t\t\t\tonWorkerDelegationChange: (settings, scope) => {\n\t\t\t\t\thost.settingsManager.setWorkerDelegationSettings(settings, scope);\n\t\t\t\t\thost.showStatus(`Worker delegation settings saved to ${scope}. The delegate tool uses them.`);\n\t\t\t\t},\n\t\t\t\tonLearningPolicyChange: (settings, scope) => {\n\t\t\t\t\thost.settingsManager.setLearningPolicySettings(settings, scope);\n\t\t\t\t\thost.showStatus(`Learning policy saved to ${scope}.`);\n\t\t\t\t},\n\t\t\t\tonModelCapabilityChange: (settings, scope) => {\n\t\t\t\t\thost.settingsManager.setModelCapabilitySettings(settings, scope);\n\t\t\t\t\thost.showStatus(`Model capability mode saved to ${scope}. Applies on the next model switch or /reload.`);\n\t\t\t\t},\n\t\t\t\tonContextCurationChange: (settings, scope) => {\n\t\t\t\t\thost.settingsManager.setContextCurationSettings(settings, scope);\n\t\t\t\t\thost.showStatus(\n\t\t\t\t\t\t`Context curation settings saved to ${scope}. Run /fitness <model> first if the model is unprobed.`,\n\t\t\t\t\t);\n\t\t\t\t},\n\t\t\t\tonModelRouterChange: (settings, scope) => {\n\t\t\t\t\thost.settingsManager.setModelRouterSettings(settings, scope);\n\t\t\t\t\tfor (const value of [settings.cheapModel, settings.expensiveModel, settings.learningModel]) {\n\t\t\t\t\t\tconst validationMessage = host.validateAutoLearnModelValue(value);\n\t\t\t\t\t\tif (validationMessage) {\n\t\t\t\t\t\t\thost.showWarning(validationMessage.replace(\"Auto Learn model\", \"Model router model\"));\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\thost.updateAutoLearnFooter();\n\t\t\t\t\thost.showStatus(`Model Router settings saved to ${scope}. Use /session or /usage to inspect routing.`);\n\t\t\t\t},\n\t\t\t\tonAutoLearnChange: (settings, scope) => {\n\t\t\t\t\thost.settingsManager.setAutoLearnSettings(settings, scope);\n\t\t\t\t\tconst validationMessage = host.validateAutoLearnModelValue(settings.model);\n\t\t\t\t\tif (validationMessage) {\n\t\t\t\t\t\thost.showWarning(validationMessage);\n\t\t\t\t\t}\n\t\t\t\t\thost.updateAutoLearnFooter();\n\t\t\t\t\thost.showStatus(`Auto Learn settings saved to ${scope}. Use /auto-learn status or /auto-learn run.`);\n\t\t\t\t},\n\t\t\t\tonContextPolicyEnforcementChange: (settings, scope) => {\n\t\t\t\t\thost.settingsManager.setContextPromptEnforcementSettings(settings, scope);\n\t\t\t\t\thost.showStatus(`Context/prompt-policy settings saved to ${scope}.`);\n\t\t\t\t},\n\t\t\t\tonContextMemoryRetrievalChange: (settings, scope) => {\n\t\t\t\t\thost.settingsManager.setMemoryRetrievalSettings(settings, scope);\n\t\t\t\t\thost.showStatus(`Context/memory-retrieval settings saved to ${scope}.`);\n\t\t\t\t},\n\t\t\t\tonResourcesHubAction: (action) => {\n\t\t\t\t\tdone();\n\t\t\t\t\tvoid host.handleResourcesHubAction(action);\n\t\t\t\t},\n\t\t\t\tonCancel: () => {\n\t\t\t\t\tdone();\n\t\t\t\t\thost.ui.requestRender();\n\t\t\t\t},\n\t\t\t},\n\t\t);\n\t\treturn { component: selector, focus: selector.getSettingsList() };\n\t});\n}\n"]}
1
+ {"version":3,"file":"settings-selector-flow.js","sourceRoot":"","sources":["../../../src/modes/interactive/settings-selector-flow.ts"],"names":[],"mappings":"AAAA;;;;;;;;GAQG;AAEH,OAAO,EAAE,0BAA0B,EAAE,MAAM,mBAAmB,CAAC;AAG/D,OAAO,EAAE,uBAAuB,EAAE,uBAAuB,EAAE,MAAM,+BAA+B,CAAC;AACjG,OAAO,EAAE,eAAe,EAAE,MAAM,8BAA8B,CAAC;A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,EAAE,EAAE;gBACrD,IAAI,CAAC,eAAe,CAAC,mCAAmC,CAAC,QAAQ,EAAE,KAAK,CAAC,CAAC;gBAC1E,IAAI,CAAC,UAAU,CAAC,2CAA2C,KAAK,GAAG,CAAC,CAAC;YACtE,CAAC;YACD,8BAA8B,EAAE,CAAC,QAAQ,EAAE,KAAK,EAAE,EAAE;gBACnD,IAAI,CAAC,eAAe,CAAC,0BAA0B,CAAC,QAAQ,EAAE,KAAK,CAAC,CAAC;gBACjE,IAAI,CAAC,UAAU,CAAC,8CAA8C,KAAK,GAAG,CAAC,CAAC;YACzE,CAAC;YACD,oBAAoB,EAAE,CAAC,MAAM,EAAE,EAAE;gBAChC,IAAI,EAAE,CAAC;gBACP,KAAK,IAAI,CAAC,wBAAwB,CAAC,MAAM,CAAC,CAAC;YAC5C,CAAC;YACD,QAAQ,EAAE,GAAG,EAAE;gBACd,IAAI,EAAE,CAAC;gBACP,IAAI,CAAC,EAAE,CAAC,aAAa,EAAE,CAAC;YACzB,CAAC;SACD,CACD,CAAC;QACF,OAAO,EAAE,SAAS,EAAE,QAAQ,EAAE,KAAK,EAAE,QAAQ,CAAC,eAAe,EAAE,EAAE,CAAC;IACnE,CAAC,CAAC,CAAC;AACJ,CAAC","sourcesContent":["/**\n * `/settings` selector flow extracted from interactive-mode.\n *\n * Builds the SettingsSelectorComponent model from the current settings/session\n * state and wires its change callbacks back through a `SettingsSelectorHost`\n * seam. Self-mod/auto-learn validation, autonomy-preset application, autocomplete\n * rebuild, and the resources-hub hand-off stay host-side (shared with other\n * flows); interactive-mode keeps a thin wrapper building the host once.\n */\n\nimport { getSupportedThinkingLevels } from \"@caupulican/pi-ai\";\nimport type { Component, Container, EditorComponent, SelectItem, TUI } from \"@caupulican/pi-tui\";\nimport type { AgentSession } from \"../../core/agent-session.ts\";\nimport { configureHttpDispatcher, formatHttpIdleTimeoutMs } from \"../../core/http-dispatcher.ts\";\nimport { resolveCliModel } from \"../../core/model-resolver.ts\";\nimport type {\n\tAutonomyMode,\n\tSelfModificationSettings,\n\tSettingsManager,\n\tSettingsScope,\n} from \"../../core/settings-manager.ts\";\nimport { ActionTranscriptComponent } from \"./components/action-transcript.ts\";\nimport { AssistantMessageComponent } from \"./components/assistant-message.ts\";\nimport type { CustomEditor } from \"./components/custom-editor.ts\";\nimport type { FooterComponent } from \"./components/footer.ts\";\nimport { SettingsSelectorComponent } from \"./components/settings-selector.ts\";\nimport { getAvailableThemes, setTheme } from \"./theme/theme.ts\";\n\nexport interface SettingsSelectorHost {\n\treadonly session: AgentSession;\n\treadonly settingsManager: SettingsManager;\n\treadonly footer: FooterComponent;\n\treadonly chatContainer: Container;\n\treadonly ui: TUI;\n\treadonly defaultEditor: CustomEditor;\n\treadonly editor: EditorComponent;\n\thideThinkingBlock: boolean;\n\tshowSelector(create: (done: () => void) => { component: Component; focus: Component }): void;\n\tshowStatus(message: string): void;\n\tshowWarning(message: string): void;\n\tshowError(message: string): void;\n\tgetAutoLearnModelOptions(): SelectItem[];\n\tsetupAutocompleteProvider(): void;\n\tupdateEditorBorderColor(): void;\n\trebuildChatFromMessages(): Promise<void>;\n\tvalidateSelfModificationSource(settings: SelfModificationSettings): string | undefined;\n\tapplyAutonomyMode(mode: AutonomyMode, scope?: SettingsScope): void;\n\tvalidateAutoLearnModelValue(value: string | undefined): string | undefined;\n\tupdateAutoLearnFooter(): void;\n\thandleResourcesHubAction(action: string): Promise<void>;\n}\n\nexport function showSettingsSelector(host: SettingsSelectorHost): void {\n\thost.showSelector((done) => {\n\t\tconst projectSettings = host.settingsManager.getProjectSettings();\n\t\tconst profileOptions = [\n\t\t\t{\n\t\t\t\tvalue: \"(none)\",\n\t\t\t\tlabel: \"(none)\",\n\t\t\t\tdescription: \"Use configured profile selection (session default)\",\n\t\t\t},\n\t\t\t...host.settingsManager\n\t\t\t\t.getProfileRegistry()\n\t\t\t\t.listProfiles()\n\t\t\t\t.map((profile) => ({\n\t\t\t\t\tvalue: profile.name,\n\t\t\t\t\tlabel: profile.name,\n\t\t\t\t\tdescription: profile.description ?? profile.source,\n\t\t\t\t})),\n\t\t];\n\t\tconst selector = new SettingsSelectorComponent(\n\t\t\t{\n\t\t\t\tautoCompact: host.session.autoCompactionEnabled,\n\t\t\t\tshowImages: host.settingsManager.getShowImages(),\n\t\t\t\timageWidthCells: host.settingsManager.getImageWidthCells(),\n\t\t\t\tautoResizeImages: host.settingsManager.getImageAutoResize(),\n\t\t\t\tblockImages: host.settingsManager.getBlockImages(),\n\t\t\t\tenableSkillCommands: host.settingsManager.getEnableSkillCommands(),\n\t\t\t\tsteeringMode: host.session.steeringMode,\n\t\t\t\tfollowUpMode: host.session.followUpMode,\n\t\t\t\ttransport: host.settingsManager.getTransport(),\n\t\t\t\thttpIdleTimeoutMs: host.settingsManager.getHttpIdleTimeoutMs(),\n\t\t\t\tthinkingLevel: host.session.thinkingLevel,\n\t\t\t\tavailableThinkingLevels: host.session.getAvailableThinkingLevels(),\n\t\t\t\tcurrentTheme: host.settingsManager.getTheme() || \"dark\",\n\t\t\t\t// The picker offers only themes the active profile permits (no-bypass). The theme\n\t\t\t\t// registry/renderer keeps the full set, so an already-applied theme still renders\n\t\t\t\t// even if the profile would block re-selecting it.\n\t\t\t\tavailableThemes: getAvailableThemes().filter((name) =>\n\t\t\t\t\thost.settingsManager.isResourceAllowedByProfile(\"themes\", name),\n\t\t\t\t),\n\t\t\t\thideThinkingBlock: host.hideThinkingBlock,\n\t\t\t\tprojectContextFiles: host.settingsManager.getProjectContextFiles(),\n\t\t\t\tprojectContextFilesScope: host.settingsManager.getProjectContextFilesScope(),\n\t\t\t\tcollapseChangelog: host.settingsManager.getCollapseChangelog(),\n\t\t\t\tenableInstallTelemetry: host.settingsManager.getEnableInstallTelemetry(),\n\t\t\t\tdoubleEscapeAction: host.settingsManager.getDoubleEscapeAction(),\n\t\t\t\ttreeFilterMode: host.settingsManager.getTreeFilterMode(),\n\t\t\t\tshowHardwareCursor: host.settingsManager.getShowHardwareCursor(),\n\t\t\t\teditorPaddingX: host.settingsManager.getEditorPaddingX(),\n\t\t\t\tautocompleteMaxVisible: host.settingsManager.getAutocompleteMaxVisible(),\n\t\t\t\tquietStartup: host.settingsManager.getQuietStartup(),\n\t\t\t\tclearOnShrink: host.settingsManager.getClearOnShrink(),\n\t\t\t\tshowTerminalProgress: host.settingsManager.getShowTerminalProgress(),\n\t\t\t\twarnings: host.settingsManager.getWarnings(),\n\t\t\t\tselfModification: host.settingsManager.getSelfModificationSettings(),\n\t\t\t\tselfModificationScope: projectSettings.selfModification ? \"project\" : \"global\",\n\t\t\t\tautonomy: host.settingsManager.getAutonomySettings(),\n\t\t\t\tautonomyScope: projectSettings.autonomy ? \"project\" : \"global\",\n\t\t\t\tresearchLane: host.settingsManager.getResearchLaneSettings(),\n\t\t\t\tresearchLaneScope: projectSettings.researchLane ? \"project\" : \"global\",\n\t\t\t\tworkerDelegation: host.settingsManager.getWorkerDelegationSettings(),\n\t\t\t\tworkerDelegationScope: projectSettings.workerDelegation ? \"project\" : \"global\",\n\t\t\t\tcontextCuration: host.settingsManager.getContextCurationSettings(),\n\t\t\t\tcontextCurationScope: projectSettings.contextPolicy?.curation ? \"project\" : \"global\",\n\t\t\t\tlearningPolicy: host.settingsManager.getLearningPolicySettings(),\n\t\t\t\tlearningPolicyScope: projectSettings.learningPolicy ? \"project\" : \"global\",\n\t\t\t\tmodelCapability: host.settingsManager.getModelCapabilitySettings(),\n\t\t\t\tmodelCapabilityScope: projectSettings.modelCapability ? \"project\" : \"global\",\n\t\t\t\tmodelRouter: host.settingsManager.getModelRouterSettings(),\n\t\t\t\tmodelRouterScope: projectSettings.modelRouter ? \"project\" : \"global\",\n\t\t\t\tautoLearn: host.settingsManager.getAutoLearnSettings(),\n\t\t\t\tautoLearnScope: projectSettings.autoLearn ? \"project\" : \"global\",\n\t\t\t\tautoLearnModelOptions: host.getAutoLearnModelOptions(),\n\t\t\t\tresolveModelThinkingLevels: (modelPattern) => {\n\t\t\t\t\tif (!modelPattern) return host.session.getAvailableThinkingLevels();\n\t\t\t\t\tconst resolved = resolveCliModel({ cliModel: modelPattern, modelRegistry: host.session.modelRegistry });\n\t\t\t\t\treturn resolved.model ? getSupportedThinkingLevels(resolved.model) : undefined;\n\t\t\t\t},\n\t\t\t\tcontextPolicyEnforcement: host.settingsManager.getContextPromptEnforcementSettings(),\n\t\t\t\tcontextPolicyEnforcementScope: projectSettings.contextPolicy?.enforcement ? \"project\" : \"global\",\n\t\t\t\tcontextMemoryRetrieval: host.settingsManager.getMemoryRetrievalSettings(),\n\t\t\t\tcontextMemoryRetrievalScope: projectSettings.contextPolicy?.memory ? \"project\" : \"global\",\n\t\t\t\tcurrentModelPattern: host.session.model\n\t\t\t\t\t? `${host.session.model.provider}/${host.session.model.id}`\n\t\t\t\t\t: undefined,\n\t\t\t\tactiveProfileName: host.settingsManager.getActiveResourceProfileNames()[0],\n\t\t\t\tprofileOptions,\n\t\t\t\texternalResourceRoots: host.settingsManager.getExternalResourceRoots(),\n\t\t\t\ttrustedResourceRoots: host.settingsManager.getTrustedResourceRoots(),\n\t\t\t},\n\t\t\t{\n\t\t\t\tonAutoCompactChange: (enabled) => {\n\t\t\t\t\thost.session.setAutoCompactionEnabled(enabled);\n\t\t\t\t\thost.footer.setAutoCompactEnabled(enabled);\n\t\t\t\t},\n\t\t\t\tonShowImagesChange: (enabled) => {\n\t\t\t\t\thost.settingsManager.setShowImages(enabled);\n\t\t\t\t\tfor (const child of host.chatContainer.children) {\n\t\t\t\t\t\tif (child instanceof ActionTranscriptComponent) {\n\t\t\t\t\t\t\tchild.setShowImages(enabled);\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\thost.ui.requestRender();\n\t\t\t\t},\n\t\t\t\tonImageWidthCellsChange: (width) => {\n\t\t\t\t\thost.settingsManager.setImageWidthCells(width);\n\t\t\t\t\tfor (const child of host.chatContainer.children) {\n\t\t\t\t\t\tif (child instanceof ActionTranscriptComponent) {\n\t\t\t\t\t\t\tchild.setImageWidthCells(width);\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\thost.ui.requestRender();\n\t\t\t\t},\n\t\t\t\tonAutoResizeImagesChange: (enabled) => {\n\t\t\t\t\thost.settingsManager.setImageAutoResize(enabled);\n\t\t\t\t},\n\t\t\t\tonBlockImagesChange: (blocked) => {\n\t\t\t\t\thost.settingsManager.setBlockImages(blocked);\n\t\t\t\t},\n\t\t\t\tonEnableSkillCommandsChange: (enabled) => {\n\t\t\t\t\thost.settingsManager.setEnableSkillCommands(enabled);\n\t\t\t\t\thost.setupAutocompleteProvider();\n\t\t\t\t},\n\t\t\t\tonSteeringModeChange: (mode) => {\n\t\t\t\t\thost.session.setSteeringMode(mode);\n\t\t\t\t},\n\t\t\t\tonFollowUpModeChange: (mode) => {\n\t\t\t\t\thost.session.setFollowUpMode(mode);\n\t\t\t\t},\n\t\t\t\tonTransportChange: (transport) => {\n\t\t\t\t\thost.settingsManager.setTransport(transport);\n\t\t\t\t\thost.session.agent.transport = transport;\n\t\t\t\t},\n\t\t\t\tonHttpIdleTimeoutMsChange: (timeoutMs) => {\n\t\t\t\t\thost.settingsManager.setHttpIdleTimeoutMs(timeoutMs);\n\t\t\t\t\tconfigureHttpDispatcher(timeoutMs);\n\t\t\t\t\thost.showStatus(`HTTP idle timeout: ${formatHttpIdleTimeoutMs(timeoutMs)}`);\n\t\t\t\t},\n\t\t\t\tonThinkingLevelChange: (level) => {\n\t\t\t\t\thost.session.setThinkingLevel(level);\n\t\t\t\t\thost.footer.invalidate();\n\t\t\t\t\thost.updateEditorBorderColor();\n\t\t\t\t},\n\t\t\t\tonThemeChange: (themeName) => {\n\t\t\t\t\tconst result = setTheme(themeName, true);\n\t\t\t\t\thost.settingsManager.setTheme(themeName);\n\t\t\t\t\thost.ui.invalidate();\n\t\t\t\t\tif (!result.success) {\n\t\t\t\t\t\thost.showError(`Failed to load theme \"${themeName}\": ${result.error}\\nFell back to dark theme.`);\n\t\t\t\t\t}\n\t\t\t\t},\n\t\t\t\tonThemePreview: (themeName) => {\n\t\t\t\t\tconst result = setTheme(themeName, true);\n\t\t\t\t\tif (result.success) {\n\t\t\t\t\t\thost.ui.invalidate();\n\t\t\t\t\t\thost.ui.requestRender();\n\t\t\t\t\t}\n\t\t\t\t},\n\t\t\t\tonProjectContextFilesChange: (mode, scope) => {\n\t\t\t\t\thost.settingsManager.setProjectContextFiles(mode, scope);\n\t\t\t\t\tconst where =\n\t\t\t\t\t\tscope === \"directoryProfile\"\n\t\t\t\t\t\t\t? \"this directory\"\n\t\t\t\t\t\t\t: scope === \"project\"\n\t\t\t\t\t\t\t\t? \"this project\"\n\t\t\t\t\t\t\t\t: \"all projects\";\n\t\t\t\t\tconst load = mode === \"on-demand\" ? \"lists this project's AGENTS.md\" : \"global AGENTS.md only\";\n\t\t\t\t\thost.showStatus(`Project context files: ${load} (${where}). Run /reload to apply.`);\n\t\t\t\t},\n\t\t\t\tonHideThinkingBlockChange: (hidden) => {\n\t\t\t\t\thost.hideThinkingBlock = hidden;\n\t\t\t\t\thost.settingsManager.setHideThinkingBlock(hidden);\n\t\t\t\t\tfor (const child of host.chatContainer.children) {\n\t\t\t\t\t\tif (child instanceof AssistantMessageComponent) {\n\t\t\t\t\t\t\tchild.setHideThinkingBlock(hidden);\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\tvoid host.rebuildChatFromMessages();\n\t\t\t\t},\n\t\t\t\tonCollapseChangelogChange: (collapsed) => {\n\t\t\t\t\thost.settingsManager.setCollapseChangelog(collapsed);\n\t\t\t\t},\n\t\t\t\tonEnableInstallTelemetryChange: (enabled) => {\n\t\t\t\t\thost.settingsManager.setEnableInstallTelemetry(enabled);\n\t\t\t\t},\n\t\t\t\tonQuietStartupChange: (enabled) => {\n\t\t\t\t\thost.settingsManager.setQuietStartup(enabled);\n\t\t\t\t},\n\t\t\t\tonDoubleEscapeActionChange: (action) => {\n\t\t\t\t\thost.settingsManager.setDoubleEscapeAction(action);\n\t\t\t\t},\n\t\t\t\tonTreeFilterModeChange: (mode) => {\n\t\t\t\t\thost.settingsManager.setTreeFilterMode(mode);\n\t\t\t\t},\n\t\t\t\tonShowHardwareCursorChange: (enabled) => {\n\t\t\t\t\thost.settingsManager.setShowHardwareCursor(enabled);\n\t\t\t\t\thost.ui.setShowHardwareCursor(enabled);\n\t\t\t\t},\n\t\t\t\tonEditorPaddingXChange: (padding) => {\n\t\t\t\t\thost.settingsManager.setEditorPaddingX(padding);\n\t\t\t\t\thost.defaultEditor.setPaddingX(padding);\n\t\t\t\t\tif (host.editor !== host.defaultEditor && host.editor.setPaddingX !== undefined) {\n\t\t\t\t\t\thost.editor.setPaddingX(padding);\n\t\t\t\t\t}\n\t\t\t\t},\n\t\t\t\tonAutocompleteMaxVisibleChange: (maxVisible) => {\n\t\t\t\t\thost.settingsManager.setAutocompleteMaxVisible(maxVisible);\n\t\t\t\t\thost.defaultEditor.setAutocompleteMaxVisible(maxVisible);\n\t\t\t\t\tif (host.editor !== host.defaultEditor && host.editor.setAutocompleteMaxVisible !== undefined) {\n\t\t\t\t\t\thost.editor.setAutocompleteMaxVisible(maxVisible);\n\t\t\t\t\t}\n\t\t\t\t},\n\t\t\t\tonClearOnShrinkChange: (enabled) => {\n\t\t\t\t\thost.settingsManager.setClearOnShrink(enabled);\n\t\t\t\t\thost.ui.setClearOnShrink(enabled);\n\t\t\t\t},\n\t\t\t\tonShowTerminalProgressChange: (enabled) => {\n\t\t\t\t\thost.settingsManager.setShowTerminalProgress(enabled);\n\t\t\t\t},\n\t\t\t\tonWarningsChange: (warnings) => {\n\t\t\t\t\thost.settingsManager.setWarnings(warnings);\n\t\t\t\t},\n\t\t\t\tonSelfModificationChange: (settings, scope) => {\n\t\t\t\t\thost.settingsManager.setSelfModificationSettings(settings, scope);\n\t\t\t\t\tconst validationMessage = host.validateSelfModificationSource(settings);\n\t\t\t\t\tif (validationMessage) {\n\t\t\t\t\t\thost.showWarning(validationMessage);\n\t\t\t\t\t}\n\t\t\t\t\thost.showStatus(\n\t\t\t\t\t\t`Self modification settings saved to ${scope}. Start a new session or /reload for system-prompt guardrails to fully refresh.`,\n\t\t\t\t\t);\n\t\t\t\t},\n\t\t\t\tonAutonomyChange: (settings, scope) => {\n\t\t\t\t\thost.applyAutonomyMode(settings.mode ?? \"off\", scope);\n\t\t\t\t\thost.showStatus(`Autonomy mode ${settings.mode ?? \"off\"} saved to ${scope}. Use /autonomy status.`);\n\t\t\t\t},\n\t\t\t\tonResearchLaneChange: (settings, scope) => {\n\t\t\t\t\thost.settingsManager.setResearchLaneSettings(settings, scope);\n\t\t\t\t\thost.showStatus(\n\t\t\t\t\t\t`Research lane settings saved to ${scope}. Use /autonomy research or /autonomy diagnostics.`,\n\t\t\t\t\t);\n\t\t\t\t},\n\t\t\t\tonWorkerDelegationChange: (settings, scope) => {\n\t\t\t\t\thost.settingsManager.setWorkerDelegationSettings(settings, scope);\n\t\t\t\t\thost.showStatus(`Worker delegation settings saved to ${scope}. The delegate tool uses them.`);\n\t\t\t\t},\n\t\t\t\tonLearningPolicyChange: (settings, scope) => {\n\t\t\t\t\thost.settingsManager.setLearningPolicySettings(settings, scope);\n\t\t\t\t\thost.showStatus(`Learning policy saved to ${scope}.`);\n\t\t\t\t},\n\t\t\t\tonModelCapabilityChange: (settings, scope) => {\n\t\t\t\t\thost.settingsManager.setModelCapabilitySettings(settings, scope);\n\t\t\t\t\thost.showStatus(`Model capability mode saved to ${scope}. Applies on the next model switch or /reload.`);\n\t\t\t\t},\n\t\t\t\tonContextCurationChange: (settings, scope) => {\n\t\t\t\t\thost.settingsManager.setContextCurationSettings(settings, scope);\n\t\t\t\t\thost.showStatus(\n\t\t\t\t\t\t`Context curation settings saved to ${scope}. Run /fitness <model> first if the model is unprobed.`,\n\t\t\t\t\t);\n\t\t\t\t},\n\t\t\t\tonModelRouterChange: (settings, scope) => {\n\t\t\t\t\thost.settingsManager.setModelRouterSettings(settings, scope);\n\t\t\t\t\tfor (const value of [settings.cheapModel, settings.expensiveModel, settings.learningModel]) {\n\t\t\t\t\t\tconst validationMessage = host.validateAutoLearnModelValue(value);\n\t\t\t\t\t\tif (validationMessage) {\n\t\t\t\t\t\t\thost.showWarning(validationMessage.replace(\"Auto Learn model\", \"Model router model\"));\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\thost.updateAutoLearnFooter();\n\t\t\t\t\thost.showStatus(`Model Router settings saved to ${scope}. Use /session or /usage to inspect routing.`);\n\t\t\t\t},\n\t\t\t\tonAutoLearnChange: (settings, scope) => {\n\t\t\t\t\thost.settingsManager.setAutoLearnSettings(settings, scope);\n\t\t\t\t\tconst validationMessage = host.validateAutoLearnModelValue(settings.model);\n\t\t\t\t\tif (validationMessage) {\n\t\t\t\t\t\thost.showWarning(validationMessage);\n\t\t\t\t\t}\n\t\t\t\t\thost.updateAutoLearnFooter();\n\t\t\t\t\thost.showStatus(`Auto Learn settings saved to ${scope}. Use /auto-learn status or /auto-learn run.`);\n\t\t\t\t},\n\t\t\t\tonContextPolicyEnforcementChange: (settings, scope) => {\n\t\t\t\t\thost.settingsManager.setContextPromptEnforcementSettings(settings, scope);\n\t\t\t\t\thost.showStatus(`Context/prompt-policy settings saved to ${scope}.`);\n\t\t\t\t},\n\t\t\t\tonContextMemoryRetrievalChange: (settings, scope) => {\n\t\t\t\t\thost.settingsManager.setMemoryRetrievalSettings(settings, scope);\n\t\t\t\t\thost.showStatus(`Context/memory-retrieval settings saved to ${scope}.`);\n\t\t\t\t},\n\t\t\t\tonResourcesHubAction: (action) => {\n\t\t\t\t\tdone();\n\t\t\t\t\tvoid host.handleResourcesHubAction(action);\n\t\t\t\t},\n\t\t\t\tonCancel: () => {\n\t\t\t\t\tdone();\n\t\t\t\t\thost.ui.requestRender();\n\t\t\t\t},\n\t\t\t},\n\t\t);\n\t\treturn { component: selector, focus: selector.getSettingsList() };\n\t});\n}\n"]}
@@ -7,9 +7,9 @@ UI type: dense keyboard-first terminal tool. Phase: transient-status consolidati
7
7
  1. Task, goal, worker, routing, retry, compaction, queue, and tool progress used separate transcript, footer, widget, and loader paths. This duplicated truth and polluted scrollback. They now project into one event-driven horizontal line immediately above the editor.
8
8
  2. Completed work needed feedback without becoming permanent history. The lane uses a muted active dot, holds green/red terminal feedback for two seconds, then removes it by timer event.
9
9
  3. Resumed state could replay old terminal work as new. Session replacement primes terminal identities without displaying them; only later transitions flash.
10
- 4. Successful orchestration bookkeeping still produced empty or multiline tool cards. Collapsed successful task, goal, and worker tools now render nothing; explicit tool expansion retains the structured detail.
10
+ 4. Tool history still used separate Bash, file, skill, task, goal, worker, and extension summaries. Every model tool invocation now contributes once to one append-only `Performing N actions` / `Performed N actions` transcript row; Ctrl+T retains the structured detail.
11
11
  5. A terminal process did not prove a human was watching. `--session-mode user|worker` feeds the authoritative session-role contract; unattended workers do not receive approval UI, extension TUI context, widgets, footer, loaders, or activity-lane routing.
12
- 6. Loading session history still invoked collapsed tool-result renderers and image conversion. Retained results now stay behind their existing payload accessor until expansion; one expansion materializes once, and collapse releases the display cache.
12
+ 6. Loading session history still invoked collapsed tool-result renderers and image conversion. The collapsed action transcript does not invoke per-tool renderers; retained results stay behind their payload accessor until expansion, and collapse releases the display cache.
13
13
 
14
14
  ## Acceptance battery
15
15
 
@@ -20,8 +20,8 @@ UI type: dense keyboard-first terminal tool. Phase: transient-status consolidati
20
20
  | State clarity | PASS | Glyph plus text plus semantic theme color; status is never color-only. |
21
21
  | Completion lifecycle | PASS | Event/timer driven; success/failure disappears after a bounded hold. |
22
22
  | Resume correctness | PASS | Existing terminal identities are primed and do not replay. |
23
- | History cleanliness | PASS | Successful orchestration calls are absent while collapsed; retained tool-result payloads are not read or rendered until the existing expansion key is used. |
24
- | Failure honesty | PASS | Tool errors, compaction failures, and final retry failures remain textual and actionable. |
23
+ | History cleanliness | PASS | One action counter replaces category-specific cards; retained tool-result payloads are not read or rendered until Ctrl+T expands the transcript. |
24
+ | Failure honesty | PASS | Failed calls remain counted and marked on the action row; details stay in the transcript, while operational warnings use the transient activity lane. |
25
25
  | Audience isolation | PASS | Worker role disables human UI capability and does not mount transient visual surfaces. |
26
26
  | Focus and interruption | PASS | The lane never captures focus; cancellation remains on the existing interrupt binding. |
27
27
 
@@ -2149,7 +2149,7 @@ By default, tool output is wrapped in a `Box` that handles padding and backgroun
2149
2149
 
2150
2150
  Set `renderShell: "self"` when the tool should render its own shell instead of using the default `Box`. This is useful for tools that need complete control over framing or background behavior, for example large previews that must stay visually stable after the tool settles.
2151
2151
 
2152
- Adjacent tool calls collapse into grouped panels by default using the tool name as the group id. Set `toolGroup` to a stable freeform group id when related tools should share one grouped panel in the TUI, or set it to an empty string to opt out for a specific tool. Grouping is display-only: renderer state remains per tool call, and reusable panels are still scoped to the active session/cwd so different sessions cannot share display state.
2152
+ Adjacent model-invoked tool calls use one append-only transcript row. While calls are active it shows `Performing N actions`; after they settle it shows `Performed N actions`. Each call contributes exactly once, including pending and failed calls; later calls append and never reuse or replace earlier action history. The collapsed row hides tool details, including custom renderers; press Ctrl+T to expand the transcript and view each call's details.
2153
2153
 
2154
2154
  ```typescript
2155
2155
  pi.registerTool({
@@ -2173,8 +2173,6 @@ pi.registerTool({
2173
2173
  - `lastComponent` - the previously returned component for that slot, if any
2174
2174
  - `invalidate()` - request a rerender of this tool row
2175
2175
  - `toolCallId`, `cwd`, `executionStarted`, `argsComplete`, `isPartial`, `expanded`, `showImages`, `isError`
2176
- - `toolGroupSummary` - true when `renderCall` is rendering a collapsed grouped-panel summary; avoid adding per-row expand hints in this mode
2177
-
2178
2176
  Use `context.state` for cross-slot shared state. Keep slot-local caches on the returned component instance when you want to reuse and mutate the same component across renders.
2179
2177
 
2180
2178
  #### renderCall
@@ -2224,18 +2222,12 @@ If a slot intentionally has no visible content, return an empty `Component` such
2224
2222
 
2225
2223
  #### Keybinding Hints
2226
2224
 
2227
- Use `keyHint()` to display keybinding hints that respect the active keybinding configuration:
2225
+ Use `keyHint()` to display keybinding hints that respect the active keybinding configuration. Tool renderers must not add their own expansion hint: the collapsed action transcript owns the Ctrl+T hint and does not invoke per-tool renderers.
2228
2226
 
2229
2227
  ```typescript
2230
2228
  import { keyHint } from "@caupulican/pi-adaptative";
2231
2229
 
2232
- renderResult(result, { expanded }, theme, context) {
2233
- let text = theme.fg("success", "✓ Done");
2234
- if (!expanded) {
2235
- text += ` (${keyHint("app.tools.expand", "to expand")})`;
2236
- }
2237
- return new Text(text, 0, 0);
2238
- }
2230
+ const confirmHint = keyHint("tui.select.confirm", "to confirm");
2239
2231
  ```
2240
2232
 
2241
2233
  Available functions:
@@ -2244,7 +2236,7 @@ Available functions:
2244
2236
  - `rawKeyHint(key, description)` - Format a raw key string
2245
2237
 
2246
2238
  Use namespaced keybinding ids:
2247
- - Coding-agent ids use the `app.*` namespace, for example `app.tools.expand`, `app.editor.external`, `app.session.rename`
2239
+ - Coding-agent ids use the `app.*` namespace, for example `app.transcript.open`, `app.editor.external`, `app.session.rename`
2248
2240
  - Shared TUI ids use the `tui.*` namespace, for example `tui.select.confirm`, `tui.select.cancel`, `tui.input.tab`
2249
2241
 
2250
2242
  For the exhaustive list of keybinding ids and defaults, see [keybindings.md](keybindings.md). `keybindings.json` uses those same namespaced ids.
@@ -128,8 +128,8 @@ These actions apply while the built-in `ask_question` interaction has focus. The
128
128
 
129
129
  | Keybinding id | Default | Description |
130
130
  |--------|---------|-------------|
131
- | `app.tools.expand` | `ctrl+o` | Expand or collapse tool output (file groups stay as a count + short list until then) |
132
- | `app.transcript.open` | `ctrl+t` | Open expanded transcript scrollback |
131
+ | `app.tools.expand` | `ctrl+o` | Expand or collapse non-action inline details |
132
+ | `app.transcript.open` | `ctrl+t` | Open transcript scrollback with action details expanded |
133
133
  | `app.history.load` | `ctrl+shift+h` | Load deferred session history into the chat |
134
134
  | `app.message.followUp` | `alt+enter` | Queue follow-up message |
135
135
  | `app.message.dequeue` | `alt+up` | Restore queued messages to editor |
package/docs/settings.md CHANGED
@@ -20,7 +20,7 @@ Edit directly or use `/settings` for common options.
20
20
  | `defaultProvider` | string | - | Default provider (e.g., `"anthropic"`, `"openai"`) |
21
21
  | `defaultModel` | string | - | Default model ID |
22
22
  | `defaultThinkingLevel` | string | model default | `"off"`, `"minimal"`, `"low"`, `"medium"`, `"high"`, `"xhigh"`, `"max"`, or `"ultra"` |
23
- | `hideThinkingBlock` | boolean | `true` | Hide thinking blocks in output. Press the thinking toggle (default Ctrl+T) to show them. |
23
+ | `hideThinkingBlock` | boolean | `true` | Hide thinking blocks in output. Press the thinking toggle (default Shift+PageUp) to show them. |
24
24
  | `thinkingBudgets` | object | - | Custom token budgets per thinking level |
25
25
 
26
26
  #### thinkingBudgets
@@ -86,11 +86,11 @@ Native worker lanes emit terminal handoff notifications and retain bounded resul
86
86
 
87
87
  ## Native orchestration UI
88
88
 
89
- Interactive sessions render task steps, worker dispatch, and worker status through one shared orchestration panel. The compact tool result shows status and counts first; expanding tool output reveals bounded notes, evidence, changed files, blockers, and untrusted worker claims. Checklist IDs stay out of the collapsed task view.
89
+ Interactive history uses the same action transcript as every other model tool: task, goal, delegation, skill, file, shell, and extension calls contribute once to the adjacent `Performing N actions` / `Performed N actions` row. Tool-specific cards never compete in collapsed history. Ctrl+T opens the transcript with bounded notes, evidence, changed files, blockers, and untrusted worker claims.
90
90
 
91
- While work is open, a host-owned panel below the editor combines the active checklist with queued or running `worker` and `tmux-worker` lanes. It updates from session and terminal-lane events, never by polling output. It disappears when no checklist item or worker is active and survives extension reloads without becoming extension-owned state.
91
+ While work is open, the host-owned activity lane below the editor combines the active checklist with queued or running `worker` and `tmux-worker` lanes. It updates from session and terminal-lane events, never by polling output. It disappears when no checklist item or worker is active and survives extension reloads without becoming extension-owned state.
92
92
 
93
- The visual contract is deliberately restrained for a keyboard-first terminal: semantic theme colors, status glyphs that remain meaningful without color, no animation, no hard frame, bounded rows, and width-safe truncation. Extension widgets still render independently; reloading or clearing them does not remove the native orchestration panel.
93
+ The visual contract is deliberately restrained for a keyboard-first terminal: semantic theme colors, status glyphs that remain meaningful without color, no animation, no hard frame, bounded rows, and width-safe truncation. Extension widgets still render independently; reloading or clearing them does not remove the native activity lane.
94
94
 
95
95
  ## Persistence and isolation
96
96
 
@@ -43,7 +43,7 @@ Example project settings:
43
43
 
44
44
  ## Visible signals
45
45
 
46
- - Interactive tool panels show `[repaired arguments]` when execution used repaired arguments.
46
+ - Expanded Ctrl+T action details show `[repaired arguments]` when execution used repaired arguments.
47
47
  - RPC `tool_execution_start`, `tool_execution_update`, and `tool_execution_end` events include a `repair` object when arguments were repaired.
48
48
  - `/toolhealth` prints model adaptation records for this host: tool-probe verdicts, calibrated or failed text protocol, learned standing rules, teach statistics, recovery-log worker counters, and execution-failure counts by phase.
49
49
  - `/toolrule-remove <provider/model> <mode>` removes one learned standing rule from the host-local adaptation store.
package/docs/usage.md CHANGED
@@ -43,7 +43,7 @@ Pasted images are stored under `~/.pi/agent/state/attachments` by default and at
43
43
 
44
44
  When an owner choice materially changes the result, the built-in `ask_question` interaction presents up to four questions together. It supports single choice, multi-select, an unrestricted multi-line custom **Other** answer, clipboard text or image paste, explicit **Skip**, configurable keyboard navigation, cancellation, and a final review before a multi-question answer is submitted. The request is checkpointed before display; `/resume` restores the original tool call, and large answers remain exact in a retrievable artifact while only a bounded projection enters prompt context. TUI and RPC hosts use the same fail-closed typed request. Image paste is refused with a visible explanation when the routed model cannot accept images instead of silently replacing it with a placeholder. Non-interactive sessions fail closed instead of inventing an answer, and worker sessions do not construct the question tool.
45
45
 
46
- Native task steps and worker agents share the same compact work panel. Steps and agents are grouped separately; durable task labels and admitted preset or adaptive grant IDs remain visible after `/resume`. Completed worker output remains untrusted until the parent verifies it through the existing result and review contracts.
46
+ Every model-invoked skill, goal, task, worker, file, shell, and extension call contributes once to the same collapsed `Performing N actions` / `Performed N actions` transcript row. Ctrl+T opens the detailed transcript. Live task and worker state uses the single activity lane; durable labels and admitted preset or adaptive grant IDs remain visible after `/resume`. Completed worker output remains untrusted until the parent verifies it through the existing result and review contracts.
47
47
 
48
48
  ### Secret Store
49
49
 
@@ -1,12 +1,12 @@
1
1
  {
2
2
  "name": "pi-extension-custom-provider",
3
- "version": "0.93.19",
3
+ "version": "0.94.0",
4
4
  "lockfileVersion": 3,
5
5
  "requires": true,
6
6
  "packages": {
7
7
  "": {
8
8
  "name": "pi-extension-custom-provider",
9
- "version": "0.93.19",
9
+ "version": "0.94.0",
10
10
  "dependencies": {
11
11
  "@anthropic-ai/sdk": "^0.52.0"
12
12
  }
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "pi-extension-custom-provider-anthropic",
3
3
  "private": true,
4
- "version": "0.93.19",
4
+ "version": "0.94.0",
5
5
  "type": "module",
6
6
  "scripts": {
7
7
  "clean": "echo 'nothing to clean'",
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "pi-extension-custom-provider-gitlab-duo",
3
3
  "private": true,
4
- "version": "0.93.19",
4
+ "version": "0.94.0",
5
5
  "type": "module",
6
6
  "scripts": {
7
7
  "clean": "echo 'nothing to clean'",
@@ -1,12 +1,12 @@
1
1
  {
2
2
  "name": "pi-extension-sandbox",
3
- "version": "0.93.19",
3
+ "version": "0.94.0",
4
4
  "lockfileVersion": 3,
5
5
  "requires": true,
6
6
  "packages": {
7
7
  "": {
8
8
  "name": "pi-extension-sandbox",
9
- "version": "0.93.19",
9
+ "version": "0.94.0",
10
10
  "dependencies": {
11
11
  "@anthropic-ai/sandbox-runtime": "^0.0.26"
12
12
  }
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "pi-extension-sandbox",
3
3
  "private": true,
4
- "version": "0.93.19",
4
+ "version": "0.94.0",
5
5
  "type": "module",
6
6
  "scripts": {
7
7
  "clean": "echo 'nothing to clean'",
@@ -1,12 +1,12 @@
1
1
  {
2
2
  "name": "pi-extension-with-deps",
3
- "version": "0.93.19",
3
+ "version": "0.94.0",
4
4
  "lockfileVersion": 3,
5
5
  "requires": true,
6
6
  "packages": {
7
7
  "": {
8
8
  "name": "pi-extension-with-deps",
9
- "version": "0.93.19",
9
+ "version": "0.94.0",
10
10
  "dependencies": {
11
11
  "ms": "^2.1.3"
12
12
  },
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "pi-extension-with-deps",
3
3
  "private": true,
4
- "version": "0.93.19",
4
+ "version": "0.94.0",
5
5
  "type": "module",
6
6
  "scripts": {
7
7
  "clean": "echo 'nothing to clean'",
@@ -1,17 +1,17 @@
1
1
  {
2
2
  "name": "@caupulican/pi-adaptative",
3
- "version": "0.93.19",
3
+ "version": "0.94.0",
4
4
  "lockfileVersion": 3,
5
5
  "requires": true,
6
6
  "packages": {
7
7
  "": {
8
8
  "name": "@caupulican/pi-adaptative",
9
- "version": "0.93.19",
9
+ "version": "0.94.0",
10
10
  "license": "MIT",
11
11
  "dependencies": {
12
- "@caupulican/pi-agent-core": "^0.93.19",
13
- "@caupulican/pi-ai": "^0.93.19",
14
- "@caupulican/pi-tui": "^0.93.19",
12
+ "@caupulican/pi-agent-core": "^0.94.0",
13
+ "@caupulican/pi-ai": "^0.94.0",
14
+ "@caupulican/pi-tui": "^0.94.0",
15
15
  "@silvia-odwyer/photon-node": "0.3.4",
16
16
  "chalk": "5.6.2",
17
17
  "cross-spawn": "7.0.6",
@@ -506,11 +506,11 @@
506
506
  }
507
507
  },
508
508
  "node_modules/@caupulican/pi-agent-core": {
509
- "version": "0.93.19",
510
- "resolved": "https://registry.npmjs.org/@caupulican/pi-agent-core/-/pi-agent-core-0.93.19.tgz",
509
+ "version": "0.94.0",
510
+ "resolved": "https://registry.npmjs.org/@caupulican/pi-agent-core/-/pi-agent-core-0.94.0.tgz",
511
511
  "license": "MIT",
512
512
  "dependencies": {
513
- "@caupulican/pi-ai": "^0.93.19",
513
+ "@caupulican/pi-ai": "^0.94.0",
514
514
  "ignore": "7.0.5",
515
515
  "typebox": "1.1.38",
516
516
  "yaml": "2.9.0"
@@ -520,8 +520,8 @@
520
520
  }
521
521
  },
522
522
  "node_modules/@caupulican/pi-ai": {
523
- "version": "0.93.19",
524
- "resolved": "https://registry.npmjs.org/@caupulican/pi-ai/-/pi-ai-0.93.19.tgz",
523
+ "version": "0.94.0",
524
+ "resolved": "https://registry.npmjs.org/@caupulican/pi-ai/-/pi-ai-0.94.0.tgz",
525
525
  "license": "MIT",
526
526
  "dependencies": {
527
527
  "@anthropic-ai/sdk": "0.117.1",
@@ -546,8 +546,8 @@
546
546
  }
547
547
  },
548
548
  "node_modules/@caupulican/pi-tui": {
549
- "version": "0.93.19",
550
- "resolved": "https://registry.npmjs.org/@caupulican/pi-tui/-/pi-tui-0.93.19.tgz",
549
+ "version": "0.94.0",
550
+ "resolved": "https://registry.npmjs.org/@caupulican/pi-tui/-/pi-tui-0.94.0.tgz",
551
551
  "license": "MIT",
552
552
  "dependencies": {
553
553
  "get-east-asian-width": "1.6.0",
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@caupulican/pi-adaptative",
3
- "version": "0.93.19",
3
+ "version": "0.94.0",
4
4
  "description": "Adaptive fork of Pi coding agent for self-evolving agent harness experiments",
5
5
  "type": "module",
6
6
  "piConfig": {
@@ -89,9 +89,9 @@
89
89
  "postinstall": "node scripts/postinstall-python-runtime.mjs"
90
90
  },
91
91
  "dependencies": {
92
- "@caupulican/pi-agent-core": "^0.93.19",
93
- "@caupulican/pi-ai": "^0.93.19",
94
- "@caupulican/pi-tui": "^0.93.19",
92
+ "@caupulican/pi-agent-core": "^0.94.0",
93
+ "@caupulican/pi-ai": "^0.94.0",
94
+ "@caupulican/pi-tui": "^0.94.0",
95
95
  "@silvia-odwyer/photon-node": "0.3.4",
96
96
  "chalk": "5.6.2",
97
97
  "cross-spawn": "7.0.6",
@@ -1,28 +0,0 @@
1
- import { type Component } from "@caupulican/pi-tui";
2
- import type { ToolExecutionComponent } from "./tool-execution.ts";
3
- export declare class ToolGroupComponent implements Component {
4
- readonly toolGroup: string;
5
- private readonly tools;
6
- private expanded;
7
- constructor(toolGroup: string, tools?: ToolExecutionComponent[]);
8
- addTool(tool: ToolExecutionComponent): void;
9
- canAccept(tool: ToolExecutionComponent): boolean;
10
- removeTool(tool: ToolExecutionComponent): boolean;
11
- getToolCount(): number;
12
- getOnlyTool(): ToolExecutionComponent | undefined;
13
- setExpanded(expanded: boolean): void;
14
- setShowImages(show: boolean): void;
15
- setImageWidthCells(width: number): void;
16
- invalidate(): void;
17
- render(width: number): string[];
18
- private isCommandGroup;
19
- private renderCommandGroup;
20
- private renderCollapsed;
21
- private formatCountLine;
22
- private formatFileSnippet;
23
- private formatLastAction;
24
- private uniqueFiles;
25
- private appendExpandHint;
26
- private getBackgroundColor;
27
- }
28
- //# sourceMappingURL=tool-group.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"tool-group.d.ts","sourceRoot":"","sources":["../../../../src/modes/interactive/components/tool-group.ts"],"names":[],"mappings":"AAAA,OAAO,EAAO,KAAK,SAAS,EAAiC,MAAM,oBAAoB,CAAC;AAIxF,OAAO,KAAK,EAAE,sBAAsB,EAAE,MAAM,qBAAqB,CAAC;AA2ClE,qBAAa,kBAAmB,YAAW,SAAS;IACnD,QAAQ,CAAC,SAAS,EAAE,MAAM,CAAC;IAC3B,OAAO,CAAC,QAAQ,CAAC,KAAK,CAAgC;IACtD,OAAO,CAAC,QAAQ,CAAS;IAEzB,YAAY,SAAS,EAAE,MAAM,EAAE,KAAK,GAAE,sBAAsB,EAAO,EAGlE;IAED,OAAO,CAAC,IAAI,EAAE,sBAAsB,GAAG,IAAI,CAG1C;IAED,SAAS,CAAC,IAAI,EAAE,sBAAsB,GAAG,OAAO,CAI/C;IAED,UAAU,CAAC,IAAI,EAAE,sBAAsB,GAAG,OAAO,CAKhD;IAED,YAAY,IAAI,MAAM,CAErB;IAED,WAAW,IAAI,sBAAsB,GAAG,SAAS,CAEhD;IAED,WAAW,CAAC,QAAQ,EAAE,OAAO,GAAG,IAAI,CAGnC;IAED,aAAa,CAAC,IAAI,EAAE,OAAO,GAAG,IAAI,CAEjC;IAED,kBAAkB,CAAC,KAAK,EAAE,MAAM,GAAG,IAAI,CAEtC;IAED,UAAU,IAAI,IAAI,CAEjB;IAED,MAAM,CAAC,KAAK,EAAE,MAAM,GAAG,MAAM,EAAE,CAW9B;IAED,OAAO,CAAC,cAAc;IAQtB,OAAO,CAAC,kBAAkB;IAW1B,OAAO,CAAC,eAAe;IAUvB,OAAO,CAAC,eAAe;IAiBvB,OAAO,CAAC,iBAAiB;IASzB,OAAO,CAAC,gBAAgB;IASxB,OAAO,CAAC,WAAW;IAcnB,OAAO,CAAC,gBAAgB;IAOxB,OAAO,CAAC,kBAAkB;CAM1B"}