@caupulican/pi-adaptative 0.93.17 → 0.93.19
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +23 -0
- package/dist/core/agent-session.d.ts +1 -0
- package/dist/core/agent-session.d.ts.map +1 -1
- package/dist/core/agent-session.js +22 -12
- package/dist/core/agent-session.js.map +1 -1
- package/dist/core/compaction-controller.d.ts +22 -0
- package/dist/core/compaction-controller.d.ts.map +1 -1
- package/dist/core/compaction-controller.js +191 -30
- package/dist/core/compaction-controller.js.map +1 -1
- package/dist/core/compaction-support.d.ts.map +1 -1
- package/dist/core/compaction-support.js +21 -1
- package/dist/core/compaction-support.js.map +1 -1
- package/dist/core/delegation/worker-agent-control-coordinator.d.ts.map +1 -1
- package/dist/core/delegation/worker-agent-control-coordinator.js +1 -0
- package/dist/core/delegation/worker-agent-control-coordinator.js.map +1 -1
- package/dist/core/delegation/worker-agent-control.d.ts +2 -0
- package/dist/core/delegation/worker-agent-control.d.ts.map +1 -1
- package/dist/core/delegation/worker-agent-control.js.map +1 -1
- package/dist/core/foreground-lifecycle-adapter.d.ts +27 -0
- package/dist/core/foreground-lifecycle-adapter.d.ts.map +1 -0
- package/dist/core/foreground-lifecycle-adapter.js +61 -0
- package/dist/core/foreground-lifecycle-adapter.js.map +1 -0
- package/dist/core/foreground-lifecycle-controller.d.ts +48 -0
- package/dist/core/foreground-lifecycle-controller.d.ts.map +1 -0
- package/dist/core/foreground-lifecycle-controller.js +404 -0
- package/dist/core/foreground-lifecycle-controller.js.map +1 -0
- package/dist/core/foreground-recovery-controller.d.ts +3 -0
- package/dist/core/foreground-recovery-controller.d.ts.map +1 -1
- package/dist/core/foreground-recovery-controller.js +15 -1
- package/dist/core/foreground-recovery-controller.js.map +1 -1
- package/dist/core/goals/goal-state.d.ts.map +1 -1
- package/dist/core/goals/goal-state.js +9 -2
- package/dist/core/goals/goal-state.js.map +1 -1
- package/dist/core/keybindings.d.ts +2 -2
- package/dist/core/keybindings.d.ts.map +1 -1
- package/dist/core/keybindings.js +2 -2
- package/dist/core/keybindings.js.map +1 -1
- package/dist/core/memory/memory-manager.d.ts +22 -0
- package/dist/core/memory/memory-manager.d.ts.map +1 -1
- package/dist/core/memory/memory-manager.js +108 -49
- package/dist/core/memory/memory-manager.js.map +1 -1
- package/dist/core/model-router/session-buffer.d.ts +10 -2
- package/dist/core/model-router/session-buffer.d.ts.map +1 -1
- package/dist/core/model-router/session-buffer.js +35 -9
- package/dist/core/model-router/session-buffer.js.map +1 -1
- package/dist/core/model-router-controller.d.ts +20 -2
- package/dist/core/model-router-controller.d.ts.map +1 -1
- package/dist/core/model-router-controller.js +70 -17
- package/dist/core/model-router-controller.js.map +1 -1
- package/dist/core/provider-request-runtime-controller.d.ts +12 -1
- package/dist/core/provider-request-runtime-controller.d.ts.map +1 -1
- package/dist/core/provider-request-runtime-controller.js +45 -2
- package/dist/core/provider-request-runtime-controller.js.map +1 -1
- package/dist/core/settings-manager.d.ts +1 -0
- package/dist/core/settings-manager.d.ts.map +1 -1
- package/dist/core/settings-manager.js +3 -0
- package/dist/core/settings-manager.js.map +1 -1
- package/dist/core/tools/delegate.d.ts.map +1 -1
- package/dist/core/tools/delegate.js +4 -2
- package/dist/core/tools/delegate.js.map +1 -1
- package/dist/modes/interactive/components/assistant-message.d.ts +1 -3
- package/dist/modes/interactive/components/assistant-message.d.ts.map +1 -1
- package/dist/modes/interactive/components/assistant-message.js +10 -20
- package/dist/modes/interactive/components/assistant-message.js.map +1 -1
- package/dist/modes/interactive/components/tool-group.d.ts +3 -0
- package/dist/modes/interactive/components/tool-group.d.ts.map +1 -1
- package/dist/modes/interactive/components/tool-group.js +25 -0
- package/dist/modes/interactive/components/tool-group.js.map +1 -1
- package/dist/modes/interactive/components/transcript-overlay.d.ts +13 -0
- package/dist/modes/interactive/components/transcript-overlay.d.ts.map +1 -0
- package/dist/modes/interactive/components/transcript-overlay.js +35 -0
- package/dist/modes/interactive/components/transcript-overlay.js.map +1 -0
- package/dist/modes/interactive/components/tree-selector.d.ts +1 -1
- package/dist/modes/interactive/components/tree-selector.d.ts.map +1 -1
- package/dist/modes/interactive/components/tree-selector.js +7 -4
- package/dist/modes/interactive/components/tree-selector.js.map +1 -1
- package/dist/modes/interactive/interactive-event-controller.d.ts +1 -1
- package/dist/modes/interactive/interactive-event-controller.d.ts.map +1 -1
- package/dist/modes/interactive/interactive-event-controller.js +2 -1
- package/dist/modes/interactive/interactive-event-controller.js.map +1 -1
- package/dist/modes/interactive/interactive-mode.d.ts +9 -7
- package/dist/modes/interactive/interactive-mode.d.ts.map +1 -1
- package/dist/modes/interactive/interactive-mode.js +70 -99
- package/dist/modes/interactive/interactive-mode.js.map +1 -1
- package/dist/modes/interactive/runtime-status-controller.d.ts +40 -0
- package/dist/modes/interactive/runtime-status-controller.d.ts.map +1 -0
- package/dist/modes/interactive/runtime-status-controller.js +147 -0
- package/dist/modes/interactive/runtime-status-controller.js.map +1 -0
- package/dist/modes/interactive/runtime-status.d.ts +15 -0
- package/dist/modes/interactive/runtime-status.d.ts.map +1 -0
- package/dist/modes/interactive/runtime-status.js +18 -0
- package/dist/modes/interactive/runtime-status.js.map +1 -0
- package/docs/json.md +1 -1
- package/docs/keybindings.md +2 -1
- package/docs/session-format.md +59 -4
- package/examples/extensions/custom-provider-anthropic/package-lock.json +2 -2
- package/examples/extensions/custom-provider-anthropic/package.json +1 -1
- package/examples/extensions/custom-provider-gitlab-duo/package.json +1 -1
- package/examples/extensions/sandbox/package-lock.json +2 -2
- package/examples/extensions/sandbox/package.json +1 -1
- package/examples/extensions/with-deps/package-lock.json +2 -2
- package/examples/extensions/with-deps/package.json +1 -1
- package/npm-shrinkwrap.json +12 -12
- package/package.json +4 -4
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"interactive-mode.d.ts","sourceRoot":"","sources":["../../../src/modes/interactive/interactive-mode.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAKH,OAAO,KAAK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C,OAAO,CAAC,kBAAkB;IAQ1B,OAAO,CAAC,iBAAiB;IAIzB,OAAO,CAAC,oBAAoB;IAI5B,OAAO,CAAC,qBAAqB;IAI7B,OAAO,CAAC,iBAAiB;IAuBzB,OAAO,CAAC,oBAAoB;IAW5B,IAAI,IAAI,IAAI,CA2BX;CACD"}
|
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
import * as fs from "node:fs";
|
|
6
6
|
import * as path from "node:path";
|
|
7
7
|
import { getToolCallRepairInfo } from "@caupulican/pi-agent-core/agent-loop";
|
|
8
|
-
import { Container,
|
|
8
|
+
import { Container, ProcessTerminal, Spacer, setKeybindings, Text, TUI, } from "@caupulican/pi-tui";
|
|
9
9
|
import { APP_NAME, APP_TITLE, getAgentDir, VERSION } from "../../config.js";
|
|
10
10
|
import { parseSkillBlock } from "../../core/agent-session.js";
|
|
11
11
|
import { FooterDataProvider } from "../../core/footer-data-provider.js";
|
|
@@ -41,7 +41,7 @@ import { SkillInvocationMessageComponent } from "./components/skill-invocation-m
|
|
|
41
41
|
import { ToolExecutionComponent } from "./components/tool-execution.js";
|
|
42
42
|
import { ToolGroupComponent } from "./components/tool-group.js";
|
|
43
43
|
import { getToolPanelActionKey, shouldReuseToolPanelInPlace, ToolPanelRegistry, } from "./components/tool-panel-registry.js";
|
|
44
|
-
import {
|
|
44
|
+
import { openTranscriptOverlay } from "./components/transcript-overlay.js";
|
|
45
45
|
import { UserMessageComponent } from "./components/user-message.js";
|
|
46
46
|
import * as configBackup from "./config-backup.js";
|
|
47
47
|
import { EditorOverlayHost } from "./editor-overlay-host.js";
|
|
@@ -56,6 +56,7 @@ import * as localModelCommands from "./local-model-commands.js";
|
|
|
56
56
|
import { ProfileMenuController } from "./profile-menu-controller.js";
|
|
57
57
|
import * as reportCommands from "./report-commands.js";
|
|
58
58
|
import * as resourceShellCommands from "./resource-shell-commands.js";
|
|
59
|
+
import { RuntimeStatusController } from "./runtime-status-controller.js";
|
|
59
60
|
import { SecretMenuController } from "./secret-menu-controller.js";
|
|
60
61
|
import * as sessionFlows from "./session-flow-commands.js";
|
|
61
62
|
import * as sessionIoCommands from "./session-io-commands.js";
|
|
@@ -108,6 +109,24 @@ export class InteractiveMode {
|
|
|
108
109
|
get settingsManager() {
|
|
109
110
|
return this.session.settingsManager;
|
|
110
111
|
}
|
|
112
|
+
get loadingAnimation() {
|
|
113
|
+
return this.runtimeStatus.loadingAnimation;
|
|
114
|
+
}
|
|
115
|
+
set loadingAnimation(value) {
|
|
116
|
+
this.runtimeStatus.loadingAnimation = value;
|
|
117
|
+
}
|
|
118
|
+
get workingVisible() {
|
|
119
|
+
return this.runtimeStatus.isWorkingVisible;
|
|
120
|
+
}
|
|
121
|
+
set workingVisible(value) {
|
|
122
|
+
this.runtimeStatus.isWorkingVisible = value;
|
|
123
|
+
}
|
|
124
|
+
get workingIndicatorOptions() {
|
|
125
|
+
return this.runtimeStatus.indicatorOptions;
|
|
126
|
+
}
|
|
127
|
+
set workingIndicatorOptions(value) {
|
|
128
|
+
this.runtimeStatus.indicatorOptions = value;
|
|
129
|
+
}
|
|
111
130
|
constructor(runtimeHost, options = {}) {
|
|
112
131
|
this.autocompleteProviderWrappers = [];
|
|
113
132
|
this.isInitialized = false;
|
|
@@ -116,13 +135,6 @@ export class InteractiveMode {
|
|
|
116
135
|
pendingClipboardImages: [],
|
|
117
136
|
clipboardImageCounter: 0,
|
|
118
137
|
};
|
|
119
|
-
this.loadingAnimation = undefined;
|
|
120
|
-
this.workingMessage = undefined;
|
|
121
|
-
this.workingVisible = true;
|
|
122
|
-
this.workingIndicatorOptions = undefined;
|
|
123
|
-
this.defaultWorkingMessage = "Working...";
|
|
124
|
-
this.defaultHiddenThinkingLabel = "Thinking...";
|
|
125
|
-
this.hiddenThinkingLabel = this.defaultHiddenThinkingLabel;
|
|
126
138
|
this.lastSigintTime = 0;
|
|
127
139
|
this.lastEscapeTime = 0;
|
|
128
140
|
this.changelogMarkdown = undefined;
|
|
@@ -180,7 +192,6 @@ export class InteractiveMode {
|
|
|
180
192
|
this.runtimeHost = runtimeHost;
|
|
181
193
|
this.options = options;
|
|
182
194
|
this.hasHumanAudience = options.hasHumanAudience ?? true;
|
|
183
|
-
this.workingVisible = this.hasHumanAudience;
|
|
184
195
|
this.runtimeHost.setBeforeSessionInvalidate(() => {
|
|
185
196
|
this.extensionUiHost.resetExtensionUI();
|
|
186
197
|
});
|
|
@@ -199,6 +210,14 @@ export class InteractiveMode {
|
|
|
199
210
|
this.activityLane = this.hasHumanAudience
|
|
200
211
|
? new ActivityLaneComponent(theme, () => this.ui.requestRender())
|
|
201
212
|
: undefined;
|
|
213
|
+
this.runtimeStatus = new RuntimeStatusController({
|
|
214
|
+
ui: this.ui,
|
|
215
|
+
statusContainer: this.statusContainer,
|
|
216
|
+
activityLane: this.activityLane,
|
|
217
|
+
hasHumanAudience: this.hasHumanAudience,
|
|
218
|
+
isStreaming: () => this.session.isStreaming,
|
|
219
|
+
isThinkingHidden: () => this.hideThinkingBlock,
|
|
220
|
+
});
|
|
202
221
|
this.keybindings = KeybindingsManager.create();
|
|
203
222
|
setKeybindings(this.keybindings);
|
|
204
223
|
const editorPaddingX = this.settingsManager.getEditorPaddingX();
|
|
@@ -414,6 +433,7 @@ export class InteractiveMode {
|
|
|
414
433
|
hint("app.tools.expand", "to expand tools"),
|
|
415
434
|
hint("app.history.load", "to load session history"),
|
|
416
435
|
hint("app.agents.open", "to show live agents"),
|
|
436
|
+
hint("app.transcript.open", "to view transcript"),
|
|
417
437
|
hint("app.thinking.toggle", "to expand thinking"),
|
|
418
438
|
hint("app.editor.external", "for external editor"),
|
|
419
439
|
rawKeyHint("/", "for commands"),
|
|
@@ -889,15 +909,25 @@ export class InteractiveMode {
|
|
|
889
909
|
}
|
|
890
910
|
const children = this.chatContainer.children;
|
|
891
911
|
const lastChild = children[children.length - 1];
|
|
892
|
-
if (lastChild instanceof ToolGroupComponent && lastChild.
|
|
912
|
+
if (lastChild instanceof ToolGroupComponent && lastChild.canAccept(component)) {
|
|
893
913
|
lastChild.addTool(component);
|
|
894
914
|
this.trimLiveTuiHistory();
|
|
895
915
|
return;
|
|
896
916
|
}
|
|
897
917
|
if (lastChild instanceof ToolExecutionComponent && lastChild.toolGroup?.trim() === toolGroup) {
|
|
898
|
-
const group = new ToolGroupComponent(toolGroup, [lastChild
|
|
918
|
+
const group = new ToolGroupComponent(toolGroup, [lastChild]);
|
|
919
|
+
if (group.canAccept(component)) {
|
|
920
|
+
group.addTool(component);
|
|
921
|
+
group.setExpanded(this.toolOutputExpanded);
|
|
922
|
+
children[children.length - 1] = group;
|
|
923
|
+
this.trimLiveTuiHistory();
|
|
924
|
+
return;
|
|
925
|
+
}
|
|
926
|
+
}
|
|
927
|
+
if (toolGroup === "bash") {
|
|
928
|
+
const group = new ToolGroupComponent(toolGroup, [component]);
|
|
899
929
|
group.setExpanded(this.toolOutputExpanded);
|
|
900
|
-
|
|
930
|
+
this.chatContainer.addChild(group);
|
|
901
931
|
this.trimLiveTuiHistory();
|
|
902
932
|
return;
|
|
903
933
|
}
|
|
@@ -919,7 +949,7 @@ export class InteractiveMode {
|
|
|
919
949
|
if (remaining === 0) {
|
|
920
950
|
children.splice(i, 1);
|
|
921
951
|
}
|
|
922
|
-
else if (remaining === 1) {
|
|
952
|
+
else if (remaining === 1 && child.toolGroup !== "bash") {
|
|
923
953
|
const onlyTool = child.getOnlyTool();
|
|
924
954
|
if (onlyTool)
|
|
925
955
|
children[i] = onlyTool;
|
|
@@ -965,101 +995,41 @@ export class InteractiveMode {
|
|
|
965
995
|
this.toolPanels.clearAll();
|
|
966
996
|
}
|
|
967
997
|
getWorkingLoaderMessage() {
|
|
968
|
-
return this.
|
|
998
|
+
return this.runtimeStatus.getWorkingLoaderMessage();
|
|
969
999
|
}
|
|
970
1000
|
createWorkingLoader() {
|
|
971
|
-
return
|
|
1001
|
+
return this.runtimeStatus.createWorkingLoader();
|
|
972
1002
|
}
|
|
973
1003
|
stopWorkingLoader() {
|
|
974
|
-
|
|
975
|
-
this.loadingAnimation.stop();
|
|
976
|
-
this.loadingAnimation = undefined;
|
|
977
|
-
}
|
|
978
|
-
this.statusContainer.clear();
|
|
979
|
-
this.activityLane?.remove("runtime:routing");
|
|
980
|
-
this.activityLane?.remove("runtime:turn");
|
|
1004
|
+
this.runtimeStatus.stopWorkingLoader();
|
|
981
1005
|
}
|
|
982
1006
|
setWorkingVisible(visible) {
|
|
983
|
-
|
|
984
|
-
this.workingVisible = false;
|
|
985
|
-
this.stopWorkingLoader();
|
|
986
|
-
return;
|
|
987
|
-
}
|
|
988
|
-
this.workingVisible = visible;
|
|
989
|
-
if (!visible) {
|
|
990
|
-
this.stopWorkingLoader();
|
|
991
|
-
this.ui.requestRender();
|
|
992
|
-
return;
|
|
993
|
-
}
|
|
994
|
-
if (this.session.isStreaming && !this.loadingAnimation) {
|
|
995
|
-
if (this.workingIndicatorOptions) {
|
|
996
|
-
this.statusContainer.clear();
|
|
997
|
-
this.loadingAnimation = this.createWorkingLoader();
|
|
998
|
-
this.statusContainer.addChild(this.loadingAnimation);
|
|
999
|
-
}
|
|
1000
|
-
else {
|
|
1001
|
-
this.activityLane?.start({ id: "runtime:turn", kind: "runtime", label: this.getWorkingLoaderMessage() });
|
|
1002
|
-
}
|
|
1003
|
-
}
|
|
1004
|
-
this.ui.requestRender();
|
|
1007
|
+
this.runtimeStatus.setWorkingVisible(visible);
|
|
1005
1008
|
}
|
|
1006
1009
|
setWorkingIndicator(options) {
|
|
1007
|
-
this.
|
|
1008
|
-
if (!this.hasHumanAudience) {
|
|
1009
|
-
this.stopWorkingLoader();
|
|
1010
|
-
return;
|
|
1011
|
-
}
|
|
1012
|
-
if (options) {
|
|
1013
|
-
this.activityLane?.remove("runtime:turn");
|
|
1014
|
-
if (this.session.isStreaming && this.workingVisible) {
|
|
1015
|
-
this.stopWorkingLoader();
|
|
1016
|
-
this.loadingAnimation = this.createWorkingLoader();
|
|
1017
|
-
this.statusContainer.addChild(this.loadingAnimation);
|
|
1018
|
-
}
|
|
1019
|
-
}
|
|
1020
|
-
else {
|
|
1021
|
-
this.loadingAnimation?.stop();
|
|
1022
|
-
this.loadingAnimation = undefined;
|
|
1023
|
-
this.statusContainer.clear();
|
|
1024
|
-
if (this.session.isStreaming && this.workingVisible) {
|
|
1025
|
-
this.activityLane?.start({ id: "runtime:turn", kind: "runtime", label: this.getWorkingLoaderMessage() });
|
|
1026
|
-
}
|
|
1027
|
-
}
|
|
1028
|
-
this.ui.requestRender();
|
|
1010
|
+
this.runtimeStatus.setWorkingIndicator(options);
|
|
1029
1011
|
}
|
|
1030
1012
|
setHiddenThinkingLabel(label) {
|
|
1031
|
-
this.
|
|
1032
|
-
|
|
1033
|
-
|
|
1034
|
-
|
|
1035
|
-
|
|
1036
|
-
|
|
1037
|
-
if (this.streamingComponent) {
|
|
1038
|
-
this.streamingComponent.setHiddenThinkingLabel(this.hiddenThinkingLabel);
|
|
1039
|
-
}
|
|
1040
|
-
this.ui.requestRender();
|
|
1013
|
+
this.runtimeStatus.setHiddenThinkingLabel(label);
|
|
1014
|
+
if (this.streamingMessage)
|
|
1015
|
+
this.updateRuntimeStatus(this.streamingMessage);
|
|
1016
|
+
}
|
|
1017
|
+
updateRuntimeStatus(message) {
|
|
1018
|
+
this.runtimeStatus.updateRuntimeStatus(message);
|
|
1041
1019
|
}
|
|
1042
1020
|
/**
|
|
1043
1021
|
* Set the extension-provided working-loader message (undefined restores the default).
|
|
1044
1022
|
*/
|
|
1045
1023
|
setWorkingMessage(message) {
|
|
1046
|
-
this.
|
|
1047
|
-
if (this.loadingAnimation) {
|
|
1048
|
-
this.loadingAnimation.setMessage(message ?? this.defaultWorkingMessage);
|
|
1049
|
-
}
|
|
1050
|
-
this.activityLane?.update("runtime:turn", message ?? this.defaultWorkingMessage);
|
|
1024
|
+
this.runtimeStatus.setWorkingMessage(message, this.streamingMessage);
|
|
1051
1025
|
}
|
|
1052
1026
|
/**
|
|
1053
1027
|
* Reset the working indicator and hidden-thinking label to their built-in defaults.
|
|
1054
1028
|
*/
|
|
1055
1029
|
resetWorkingIndicators() {
|
|
1056
|
-
this.
|
|
1057
|
-
|
|
1058
|
-
|
|
1059
|
-
if (this.loadingAnimation) {
|
|
1060
|
-
this.loadingAnimation.setMessage(`${this.defaultWorkingMessage} (${keyText("app.interrupt")} to interrupt)`);
|
|
1061
|
-
}
|
|
1062
|
-
this.setHiddenThinkingLabel();
|
|
1030
|
+
this.runtimeStatus.resetWorkingIndicators();
|
|
1031
|
+
if (this.streamingMessage)
|
|
1032
|
+
this.updateRuntimeStatus(this.streamingMessage);
|
|
1063
1033
|
}
|
|
1064
1034
|
async promptForMissingSessionCwd(error) {
|
|
1065
1035
|
const confirmed = await this.extensionUiHost.showExtensionConfirm("Session cwd not found", formatMissingSessionCwdPrompt(error.issue));
|
|
@@ -1609,18 +1579,13 @@ export class InteractiveMode {
|
|
|
1609
1579
|
overlay.mount();
|
|
1610
1580
|
}
|
|
1611
1581
|
showTranscriptPager() {
|
|
1612
|
-
|
|
1613
|
-
const pager = new TranscriptPager({
|
|
1582
|
+
openTranscriptOverlay({
|
|
1614
1583
|
source: this.chatContainer,
|
|
1615
1584
|
viewportRows: () => this.ui.terminal.rows,
|
|
1616
1585
|
keybindings: this.keybindings,
|
|
1617
|
-
|
|
1618
|
-
|
|
1619
|
-
|
|
1620
|
-
width: "100%",
|
|
1621
|
-
maxHeight: "100%",
|
|
1622
|
-
row: 0,
|
|
1623
|
-
col: 0,
|
|
1586
|
+
getToolsExpanded: () => this.toolOutputExpanded,
|
|
1587
|
+
setToolsExpanded: (expanded) => this.setToolsExpanded(expanded),
|
|
1588
|
+
showOverlay: (component, options) => this.ui.showOverlay(component, options),
|
|
1624
1589
|
});
|
|
1625
1590
|
}
|
|
1626
1591
|
attachStreamingToolPanels(message) {
|
|
@@ -1641,6 +1606,7 @@ export class InteractiveMode {
|
|
|
1641
1606
|
}
|
|
1642
1607
|
applyStreamingMessageUpdate(message, options = {}) {
|
|
1643
1608
|
this.streamingMessage = message;
|
|
1609
|
+
this.updateRuntimeStatus(message);
|
|
1644
1610
|
if (!this.streamingComponent)
|
|
1645
1611
|
return;
|
|
1646
1612
|
const now = performance.now();
|
|
@@ -1798,7 +1764,7 @@ export class InteractiveMode {
|
|
|
1798
1764
|
break;
|
|
1799
1765
|
}
|
|
1800
1766
|
case "assistant": {
|
|
1801
|
-
const assistantComponent = new AssistantMessageComponent(message, this.hideThinkingBlock, this.getMarkdownThemeWithSettings()
|
|
1767
|
+
const assistantComponent = new AssistantMessageComponent(message, this.hideThinkingBlock, this.getMarkdownThemeWithSettings());
|
|
1802
1768
|
this.chatContainer.addChild(assistantComponent);
|
|
1803
1769
|
break;
|
|
1804
1770
|
}
|
|
@@ -2152,7 +2118,12 @@ export class InteractiveMode {
|
|
|
2152
2118
|
if (this.streamingComponent && this.streamingMessage) {
|
|
2153
2119
|
this.streamingComponent.setHideThinkingBlock(this.hideThinkingBlock);
|
|
2154
2120
|
this.streamingComponent.updateContent(this.streamingMessage);
|
|
2121
|
+
this.updateRuntimeStatus(this.streamingMessage);
|
|
2155
2122
|
this.chatContainer.addChild(this.streamingComponent);
|
|
2123
|
+
// Rebuilding the chat clears the rendered tool-panel registry. Reattach
|
|
2124
|
+
// any tool calls that are still arriving so toggling thinking visibility
|
|
2125
|
+
// cannot make an in-flight tool disappear from the TUI.
|
|
2126
|
+
this.attachStreamingToolPanels(this.streamingMessage);
|
|
2156
2127
|
}
|
|
2157
2128
|
this.showStatus(`Thinking blocks: ${this.hideThinkingBlock ? "hidden" : "visible"}`);
|
|
2158
2129
|
}
|