nolo-cli 0.29.2 → 0.30.0-alpha.10
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/{_executeModel-BFVTGZXE.js → _executeModel-5ARVVUIK.js} +64 -69
- package/{action-LG32A6DJ.js → action-HI3VRQLP.js} +15 -16
- package/{addContentAction-MPGMBJTQ.js → addContentAction-NCURJ6PK.js} +13 -13
- package/{addDialogAgentAction-ZH23WDID.js → addDialogAgentAction-RCY4ECF4.js} +12 -12
- package/{agentDeleteCommand-4S4STG42.js → agentDeleteCommand-5Q6TDCJU.js} +62 -40
- package/{agentEmailCommands-3F4IP4DI.js → agentEmailCommands-DSX4BJ2I.js} +77 -81
- package/{agentGrantCommands-JNDE4RWR.js → agentGrantCommands-E7ZZFRHK.js} +2 -1
- package/{agentListCommands-JCRV2XF6.js → agentListCommands-S66HL5RO.js} +59 -41
- package/{agentMachineCommands-KYXPYSFP.js → agentMachineCommands-ULCQ5ZNN.js} +55 -36
- package/{agentPullCommand-ZZGU5KOY.js → agentPullCommand-4V36XNGV.js} +4 -3
- package/{agentRecordCommands-UADUPIXO.js → agentRecordCommands-2AA3GEGO.js} +75 -79
- package/{agentRunCommand-MJWSR53W.js → agentRunCommand-3KOT77XY.js} +79 -83
- package/{agentRunControl-SNUKXN6J.js → agentRunControl-AKBN2366.js} +13 -1
- package/{agentRuntimeLocal-PC5RRRPT.js → agentRuntimeLocal-7TMDJD4S.js} +50 -31
- package/{agentSlice-C5OYLNBT.js → agentSlice-6IQRQZX3.js} +13 -14
- package/{appDeleteCommands-ZXODZ5AD.js → appDeleteCommands-UUDIWLNE.js} +55 -36
- package/{appDeployCommands-AWC6JPZH.js → appDeployCommands-CO6SZ7YP.js} +55 -36
- package/{appDeployStatusCommands-74NXMDAI.js → appDeployStatusCommands-QEVKVECJ.js} +55 -36
- package/{appGetCommands-6YGIAP5L.js → appGetCommands-3YSCCLK4.js} +55 -36
- package/{appListCommands-DZWBHMNK.js → appListCommands-FBJAFZKK.js} +55 -36
- package/{authCommand-XMQHBK5L.js → authCommand-3ADNCFKD.js} +16 -16
- package/{authCommands-JSOG2H4E.js → authCommands-CXJ6PI2O.js} +7 -7
- package/{chunk-TOGGHWHI.js → chunk-2CYGIPJH.js} +3 -3
- package/{chunk-HRJEPMZY.js → chunk-2HQ4OG6N.js} +2 -2
- package/{chunk-XMLRJUU5.js → chunk-2IJAKBK2.js} +12 -10
- package/{chunk-OLWMGSW2.js → chunk-2SOQY5L6.js} +41 -39
- package/{chunk-7H3UTGPM.js → chunk-3AUWC6EM.js} +82 -3
- package/{chunk-6HTWA77J.js → chunk-43EPBPZ2.js} +1 -1
- package/{chunk-RJBTU7AS.js → chunk-4F77PJBR.js} +302 -14
- package/{chunk-RZNYL4LW.js → chunk-4SAV7BD7.js} +65 -1
- package/{chunk-R5V5G73M.js → chunk-5RDLGLAP.js} +0 -1
- package/{chunk-VKBTAQWT.js → chunk-6JH2DF7J.js} +6 -6
- package/{chunk-DZ3XJVET.js → chunk-AOS5IN2I.js} +1 -1
- package/{chunk-5ZXNLOAG.js → chunk-ARPAHODF.js} +17 -10
- package/{chunk-IC7W63RM.js → chunk-ATK5WJOA.js} +4 -4
- package/{chunk-OEWEE4VW.js → chunk-BIPRFBC2.js} +4 -2
- package/{chunk-YTA2QOEE.js → chunk-CAENRKNJ.js} +15 -0
- package/chunk-CYRMUTGB.js +1707 -0
- package/chunk-DCDL3GC4.js +171 -0
- package/{chunk-WX3ZOSTL.js → chunk-EBNSAABL.js} +24 -26
- package/{chunk-2TYLTEAH.js → chunk-EDWM6D6L.js} +1 -1
- package/{chunk-GT3GG2H7.js → chunk-EIQDGAAE.js} +148 -2
- package/chunk-F3MP7CP6.js +73 -0
- package/{chunk-R7LOFGRE.js → chunk-G5GVZAXF.js} +19 -15
- package/{chunk-KEF5OBOZ.js → chunk-GKXS4F2I.js} +33 -27
- package/{chunk-R3JSTDQO.js → chunk-GVPMJPCT.js} +1 -1
- package/{chunk-WMB7GVPN.js → chunk-IPSPETAL.js} +152 -1177
- package/{chunk-MQRZ5QUH.js → chunk-IXZX5CJK.js} +1 -1
- package/{chunk-2FX23RGA.js → chunk-J3LHGBNO.js} +5 -5
- package/{chunk-VHBWHNVT.js → chunk-K6QEHQZ3.js} +8 -4
- package/{chunk-HRPWRVBI.js → chunk-KGEVMUMI.js} +11 -11
- package/{chunk-L65QKSVJ.js → chunk-L3GCUVOH.js} +1 -1
- package/{chunk-G2BZ43DV.js → chunk-LAXMH7JY.js} +14 -14
- package/chunk-LEVCXTDN.js +5558 -0
- package/{chunk-HEXXIS77.js → chunk-N2IX3ZYK.js} +1 -1
- package/{chunk-32ZM6HVI.js → chunk-NZBH7FTB.js} +95 -95
- package/{chunk-XOIF2TNF.js → chunk-OB6FBSH3.js} +13 -0
- package/{chunk-PSK2RUHV.js → chunk-OIW2RJ74.js} +360 -2
- package/{chunk-FRN5QOKN.js → chunk-PACNSC37.js} +19 -4
- package/{chunk-QC6ZWDSV.js → chunk-PIC6Z7VI.js} +3 -3
- package/{chunk-H5S4XUGI.js → chunk-Q243PXRU.js} +185 -158
- package/{chunk-BBGRJB5E.js → chunk-QBOW6RZN.js} +4 -4
- package/{chunk-FVOSIYXM.js → chunk-R5Y4XELF.js} +43 -394
- package/{chunk-DF7SMWEV.js → chunk-RWJPDKPB.js} +1 -1
- package/{chunk-NXMJ55RU.js → chunk-S2BMRBR2.js} +3 -3
- package/{chunk-GC34RRTQ.js → chunk-SWYMCHM7.js} +1 -69
- package/chunk-T27IEBNQ.js +149 -0
- package/{chunk-GMJS5AYP.js → chunk-T4X4GCYT.js} +19 -179
- package/{chunk-4BDPDTJU.js → chunk-TXVSNFHC.js} +8 -8
- package/{chunk-JSB4N6NU.js → chunk-V54H24CQ.js} +3 -3
- package/chunk-VQ4QPCKE.js +3226 -0
- package/{chunk-Q5RXHXKU.js → chunk-W3UDJJMA.js} +189 -122
- package/{chunk-L3QFIBZG.js → chunk-WTGCTVJG.js} +1 -1
- package/{chunk-XS7UPVR7.js → chunk-WTPC3XD4.js} +5 -5
- package/{chunk-WSQLK2KR.js → chunk-XFGM5PJP.js} +6 -6
- package/{chunk-HALKDXKP.js → chunk-XORE26Z4.js} +8 -4
- package/chunk-YLC42PIE.js +7889 -0
- package/{chunk-SKDNBYZK.js → chunk-ZJ2WITOO.js} +2 -2
- package/{chunk-L6RBX4L4.js → chunk-ZJH3LKEW.js} +21 -9
- package/{codingSkills-EN6Z6G6U.js → codingSkills-V35TRR4Y.js} +1 -2
- package/{createAgentAutomationAction-BK4UZJKU.js → createAgentAutomationAction-EYNYY2LB.js} +31 -37
- package/{createDialogAction-MJJUI2MK.js → createDialogAction-OUIRWYZP.js} +34 -39
- package/{createPageAction-YMZ7K363.js → createPageAction-2I5PHJFF.js} +45 -51
- package/{dbSlice-6QJYQUBV.js → dbSlice-BBL3PEVW.js} +12 -12
- package/{deleteFile-WDZ3VM7B.js → deleteFile-RJTEPOT4.js} +6 -6
- package/{dialogCommands-OKH45ASS.js → dialogCommands-5CL4QYQ7.js} +55 -38
- package/{dialogSlice-UDOKNDHB.js → dialogSlice-EKKVFKBJ.js} +28 -35
- package/{docCreateCommands-MCLMR4TE.js → docCreateCommands-QHCLYGNW.js} +54 -37
- package/{docDeleteCommands-ONDHI7JV.js → docDeleteCommands-DS6KOU6N.js} +56 -39
- package/{docReadCommands-FCXBMISW.js → docReadCommands-FRI5DAKH.js} +54 -37
- package/{docStore-N66O4CGH.js → docStore-V7EJS4PX.js} +30 -36
- package/{docUpdateCommands-T3XN6XOX.js → docUpdateCommands-RQO5ZTXT.js} +57 -40
- package/{fetchMessages-W4IKHPCS.js → fetchMessages-VPPQDDZ4.js} +3 -3
- package/{getPricing-X6I23RN6.js → getPricing-67TQVKFV.js} +6 -7
- package/{handleSendMessageAction-KC4AYUZP.js → handleSendMessageAction-KCF7KII4.js} +30 -37
- package/index.js +72 -72
- package/{localDialogRead-UFLBS6OT.js → localDialogRead-P72W2U2R.js} +1 -1
- package/{machineCommands-DIMRFA3Y.js → machineCommands-IAGAKTHV.js} +78 -82
- package/{machineWsRunDispatch-2DYJZI6Z.js → machineWsRunDispatch-JGKC2HEK.js} +73 -77
- package/{models-YT32CTT5.js → models-WDUTTYFS.js} +2 -2
- package/{offlineMarxistsAgentCommand-5OOWZLJI.js → offlineMarxistsAgentCommand-E6LUG63A.js} +6 -2
- package/package.json +1 -1
- package/{read-C7Y6LSBM.js → read-64OQDO3I.js} +7 -7
- package/{readDocTool-TOHRYJHP.js → readDocTool-MXM3T6PE.js} +2 -1
- package/{readlineWorkspace-HUPHMLDG.js → readlineWorkspace-5AQHHIBK.js} +209 -183
- package/{removeDialogAgentAction-WZXPOH5S.js → removeDialogAgentAction-NEKVAMSH.js} +16 -17
- package/{runAgentClientLoop-5TGSUKHV.js → runAgentClientLoop-6OGPS6SI.js} +63 -67
- package/{setDialogExtraReferencesAction-INZY2ENI.js → setDialogExtraReferencesAction-WTOHQDIV.js} +13 -13
- package/{setPrimaryDialogAgentAction-WCVLPYCF.js → setPrimaryDialogAgentAction-LDJOYC4F.js} +16 -17
- package/{settingSlice-IDUM4LWU.js → settingSlice-4M37TN7V.js} +14 -15
- package/{skillDiscovery-ITA7BI7A.js → skillDiscovery-I3QRA7NE.js} +2 -2
- package/{spaceCommands-XSSDB3YK.js → spaceCommands-VTDNKTSF.js} +240 -41
- package/{spaceSlice-BXDCO6PT.js → spaceSlice-LGUZMB7Y.js} +29 -35
- package/{streamAgentChatTurn-HRFMVSVC.js → streamAgentChatTurn-TIGCZUNZ.js} +133 -1301
- package/{switchDialogAgentAction-YBFFCBOD.js → switchDialogAgentAction-XVWGKR2Z.js} +12 -12
- package/{tableCommands-QSZILI7I.js → tableCommands-RJZ3V4TF.js} +7 -7
- package/{toolApiClient-WVTUYOFM.js → toolApiClient-ARGFDJAG.js} +2 -2
- package/{tools-5V6FHWQU.js → tools-BQAOPYMR.js} +51 -56
- package/{tuiSummaryLlmCaller-GCUPULOV.js → tuiSummaryLlmCaller-YQBN5IMG.js} +12 -12
- package/{updateDialogTitleAction-W62C4W4K.js → updateDialogTitleAction-E6HMEDPH.js} +39 -45
- package/chunk-5CS33IBL.js +0 -301
- package/chunk-5MMAK75Q.js +0 -15
- package/chunk-HYSJHRWD.js +0 -669
- package/chunk-MRC4Q34M.js +0 -188
- package/chunk-SIZQB7BD.js +0 -91
- package/chunk-UEOPA6MV.js +0 -641
- package/chunk-UFL6WHHJ.js +0 -15419
- package/chunk-VIDPVFP3.js +0 -20
- package/chunk-W2LZV5GE.js +0 -231
- package/chunk-Y5GCAMGP.js +0 -9
- package/chunk-YYLHWIW6.js +0 -48
- package/chunk-Z54ZAZZC.js +0 -1791
- package/chunk-ZZ2MH7LE.js +0 -84
- package/{chunk-OMP5L5NF.js → chunk-44HACRCK.js} +3 -3
- package/{chunk-ZVZMT3EA.js → chunk-KWCLUYGQ.js} +3 -3
- package/{chunk-NRY4GCKJ.js → chunk-WHLVPK32.js} +3 -3
- package/{chunk-RQSOAMPJ.js → chunk-Z5MXSEOJ.js} +2 -2
- package/{runtimeDoctorCommands-HSU632DY.js → runtimeDoctorCommands-E2OUORHK.js} +3 -3
|
@@ -3,11 +3,9 @@ import {
|
|
|
3
3
|
normalizeDialogRecord,
|
|
4
4
|
readDialogSnapshot,
|
|
5
5
|
sortDialogs
|
|
6
|
-
} from "./chunk-
|
|
6
|
+
} from "./chunk-TXVSNFHC.js";
|
|
7
7
|
import {
|
|
8
8
|
ANSI_ESCAPE_REGEX,
|
|
9
|
-
CLI_AUTO_TIER_AGENT_KEY_TABLE,
|
|
10
|
-
CLI_IMAGE_AGENT_KEY,
|
|
11
9
|
COLLAPSED_PASTE_PLACEHOLDER_RE,
|
|
12
10
|
THEME_PALETTES,
|
|
13
11
|
allocateCollapsedPaste,
|
|
@@ -59,8 +57,8 @@ import {
|
|
|
59
57
|
visibleWidth,
|
|
60
58
|
wrapTextToLines,
|
|
61
59
|
wrapTranscriptLine
|
|
62
|
-
} from "./chunk-
|
|
63
|
-
import "./chunk-
|
|
60
|
+
} from "./chunk-W3UDJJMA.js";
|
|
61
|
+
import "./chunk-AOS5IN2I.js";
|
|
64
62
|
import "./chunk-6HYVJV7B.js";
|
|
65
63
|
import {
|
|
66
64
|
listFavoriteAgentIdsAcrossServers,
|
|
@@ -68,12 +66,12 @@ import {
|
|
|
68
66
|
listRemoteAgents,
|
|
69
67
|
listRemoteAgentsAcrossServers,
|
|
70
68
|
normalizeListedAgent
|
|
71
|
-
} from "./chunk-
|
|
69
|
+
} from "./chunk-S2BMRBR2.js";
|
|
72
70
|
import "./chunk-ID4G2MAR.js";
|
|
73
71
|
import {
|
|
74
72
|
listUserRecordsFromServers,
|
|
75
73
|
readLiveDbRecordAfterTombstoneMerge
|
|
76
|
-
} from "./chunk-
|
|
74
|
+
} from "./chunk-RWJPDKPB.js";
|
|
77
75
|
import {
|
|
78
76
|
createCliLocalRuntimeAdapter,
|
|
79
77
|
initCliLocale,
|
|
@@ -81,8 +79,17 @@ import {
|
|
|
81
79
|
readTimestamp,
|
|
82
80
|
setCliLocale,
|
|
83
81
|
t
|
|
84
|
-
} from "./chunk-
|
|
85
|
-
import "./chunk-
|
|
82
|
+
} from "./chunk-Q243PXRU.js";
|
|
83
|
+
import "./chunk-EBNSAABL.js";
|
|
84
|
+
import {
|
|
85
|
+
checkStaleRun,
|
|
86
|
+
isRunRecordClaimed,
|
|
87
|
+
readRunRecord
|
|
88
|
+
} from "./chunk-4SAV7BD7.js";
|
|
89
|
+
import "./chunk-JDSUTNYY.js";
|
|
90
|
+
import "./chunk-WJRJDX2W.js";
|
|
91
|
+
import "./chunk-LM6IYQ3F.js";
|
|
92
|
+
import "./chunk-JBTJAPUF.js";
|
|
86
93
|
import {
|
|
87
94
|
getReadableCliDb
|
|
88
95
|
} from "./chunk-WFHXMLHZ.js";
|
|
@@ -90,114 +97,55 @@ import {
|
|
|
90
97
|
deleteDbRecord,
|
|
91
98
|
queryUserRecords,
|
|
92
99
|
readDbRecord
|
|
93
|
-
} from "./chunk-
|
|
94
|
-
import "./chunk-
|
|
100
|
+
} from "./chunk-PIC6Z7VI.js";
|
|
101
|
+
import "./chunk-GVPMJPCT.js";
|
|
95
102
|
import {
|
|
96
103
|
NOLO_DEFAULT_AGENT_KEY,
|
|
97
104
|
resolveCliAgentKeyInput
|
|
98
|
-
} from "./chunk-
|
|
99
|
-
import "./chunk-LTRXGFMS.js";
|
|
100
|
-
import "./chunk-W2LZV5GE.js";
|
|
101
|
-
import "./chunk-JEXVIMYZ.js";
|
|
102
|
-
import {
|
|
103
|
-
prepareTools
|
|
104
|
-
} from "./chunk-32ZM6HVI.js";
|
|
105
|
-
import "./chunk-2FX23RGA.js";
|
|
106
|
-
import "./chunk-WMB7GVPN.js";
|
|
107
|
-
import "./chunk-RQSOAMPJ.js";
|
|
108
|
-
import "./chunk-GC34RRTQ.js";
|
|
109
|
-
import "./chunk-HRJEPMZY.js";
|
|
110
|
-
import "./chunk-KQHGZWSV.js";
|
|
111
|
-
import "./chunk-3LY4F7SV.js";
|
|
112
|
-
import "./chunk-VF4K2QE6.js";
|
|
113
|
-
import "./chunk-VKBTAQWT.js";
|
|
114
|
-
import "./chunk-6HTWA77J.js";
|
|
115
|
-
import "./chunk-VP4WJWKW.js";
|
|
116
|
-
import "./chunk-63W5N6P3.js";
|
|
117
|
-
import "./chunk-WJRJDX2W.js";
|
|
118
|
-
import "./chunk-GMJS5AYP.js";
|
|
119
|
-
import {
|
|
120
|
-
extractReferenceKeysFromMessage
|
|
121
|
-
} from "./chunk-UFL6WHHJ.js";
|
|
122
|
-
import {
|
|
123
|
-
buildBuiltinSummaryContent
|
|
124
|
-
} from "./chunk-XOIF2TNF.js";
|
|
125
|
-
import "./chunk-MRC4Q34M.js";
|
|
126
|
-
import "./chunk-SIZQB7BD.js";
|
|
127
|
-
import "./chunk-RJBTU7AS.js";
|
|
128
|
-
import "./chunk-YYLHWIW6.js";
|
|
129
|
-
import "./chunk-CWMSB67P.js";
|
|
130
|
-
import "./chunk-IC7W63RM.js";
|
|
131
|
-
import "./chunk-5RGU3J7P.js";
|
|
132
|
-
import "./chunk-M76ECQRD.js";
|
|
133
|
-
import "./chunk-L65QKSVJ.js";
|
|
105
|
+
} from "./chunk-K6QEHQZ3.js";
|
|
134
106
|
import {
|
|
135
107
|
buildSkillDiscoveryContextBlock,
|
|
136
108
|
buildSkillDiscoveryContextLayer
|
|
137
|
-
} from "./chunk-
|
|
138
|
-
import "./chunk-7H3UTGPM.js";
|
|
139
|
-
import {
|
|
140
|
-
expandEnabledPacks
|
|
141
|
-
} from "./chunk-CF7S2RYZ.js";
|
|
142
|
-
import "./chunk-ZWJOGMKH.js";
|
|
143
|
-
import "./chunk-WZSRQNQG.js";
|
|
109
|
+
} from "./chunk-KWCLUYGQ.js";
|
|
144
110
|
import {
|
|
145
111
|
buildLocalWorkspaceOpenAiTools,
|
|
146
112
|
buildLocalWorkspaceToolset,
|
|
147
113
|
getProcessRegistry
|
|
148
|
-
} from "./chunk-
|
|
114
|
+
} from "./chunk-GKXS4F2I.js";
|
|
149
115
|
import "./chunk-ZNFJWEN4.js";
|
|
150
|
-
import "./chunk-
|
|
116
|
+
import "./chunk-XORE26Z4.js";
|
|
117
|
+
import "./chunk-LTRXGFMS.js";
|
|
118
|
+
import "./chunk-ATNTHIZI.js";
|
|
151
119
|
import "./chunk-OIQPORYI.js";
|
|
120
|
+
import "./chunk-T27IEBNQ.js";
|
|
121
|
+
import "./chunk-JEXVIMYZ.js";
|
|
152
122
|
import {
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
123
|
+
prepareTools
|
|
124
|
+
} from "./chunk-NZBH7FTB.js";
|
|
125
|
+
import {
|
|
126
|
+
readCommandActionGatePayload
|
|
127
|
+
} from "./chunk-VQ4QPCKE.js";
|
|
156
128
|
import "./chunk-N7J63Q6C.js";
|
|
129
|
+
import {
|
|
130
|
+
buildAgentsMdLayer,
|
|
131
|
+
partitionScopedBlocks,
|
|
132
|
+
renderTurnContextBlocksWithScope
|
|
133
|
+
} from "./chunk-PJY5AH5A.js";
|
|
134
|
+
import "./chunk-J3LHGBNO.js";
|
|
157
135
|
import {
|
|
158
136
|
buildCurrentTimeBlock,
|
|
159
137
|
buildIdentityBlock,
|
|
160
138
|
buildRuntimeGuidanceBlocks,
|
|
161
139
|
resolveToolGuidedSections
|
|
162
|
-
} from "./chunk-
|
|
140
|
+
} from "./chunk-OIW2RJ74.js";
|
|
163
141
|
import "./chunk-D34RI6NI.js";
|
|
164
142
|
import {
|
|
165
143
|
resolvePlatformAuthToken
|
|
166
|
-
} from "./chunk-
|
|
167
|
-
import "./chunk-UEOPA6MV.js";
|
|
168
|
-
import "./chunk-2MBTWINN.js";
|
|
169
|
-
import {
|
|
170
|
-
DEFAULT_CONTEXT_WINDOW,
|
|
171
|
-
estimateTokenCount,
|
|
172
|
-
getModelContextWindow,
|
|
173
|
-
planCompression,
|
|
174
|
-
serializeMessageContent
|
|
175
|
-
} from "./chunk-HYSJHRWD.js";
|
|
176
|
-
import {
|
|
177
|
-
clipCompactText
|
|
178
|
-
} from "./chunk-5MMAK75Q.js";
|
|
179
|
-
import "./chunk-5CS33IBL.js";
|
|
180
|
-
import "./chunk-JZPBVBIY.js";
|
|
181
|
-
import "./chunk-GT3GG2H7.js";
|
|
182
|
-
import "./chunk-ZHXJ6M7T.js";
|
|
183
|
-
import {
|
|
184
|
-
buildAgentsMdLayer,
|
|
185
|
-
partitionScopedBlocks,
|
|
186
|
-
renderTurnContextBlocksWithScope
|
|
187
|
-
} from "./chunk-PJY5AH5A.js";
|
|
144
|
+
} from "./chunk-WTPC3XD4.js";
|
|
188
145
|
import "./chunk-4PWB7JRR.js";
|
|
189
|
-
import
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
import "./chunk-OMP5L5NF.js";
|
|
193
|
-
import "./chunk-3ASDTTEI.js";
|
|
194
|
-
import {
|
|
195
|
-
compactWhitespace
|
|
196
|
-
} from "./chunk-DWLEOOGR.js";
|
|
197
|
-
import {
|
|
198
|
-
checkStaleRun,
|
|
199
|
-
readRunRecord
|
|
200
|
-
} from "./chunk-RZNYL4LW.js";
|
|
146
|
+
import "./chunk-2MBTWINN.js";
|
|
147
|
+
import "./chunk-IPSPETAL.js";
|
|
148
|
+
import "./chunk-Z5MXSEOJ.js";
|
|
201
149
|
import {
|
|
202
150
|
clipText,
|
|
203
151
|
formatDuration,
|
|
@@ -209,13 +157,51 @@ import {
|
|
|
209
157
|
runShowsLogTail,
|
|
210
158
|
shortRunId
|
|
211
159
|
} from "./chunk-KXKQO4Q6.js";
|
|
212
|
-
import "./chunk-
|
|
213
|
-
import "./chunk-
|
|
214
|
-
import "./chunk-
|
|
215
|
-
import "./chunk-
|
|
160
|
+
import "./chunk-2HQ4OG6N.js";
|
|
161
|
+
import "./chunk-KQHGZWSV.js";
|
|
162
|
+
import "./chunk-CYRMUTGB.js";
|
|
163
|
+
import "./chunk-6JH2DF7J.js";
|
|
164
|
+
import "./chunk-43EPBPZ2.js";
|
|
165
|
+
import "./chunk-F3MP7CP6.js";
|
|
166
|
+
import "./chunk-SWYMCHM7.js";
|
|
167
|
+
import "./chunk-44HACRCK.js";
|
|
168
|
+
import "./chunk-T4X4GCYT.js";
|
|
169
|
+
import "./chunk-DCDL3GC4.js";
|
|
170
|
+
import "./chunk-PACNSC37.js";
|
|
171
|
+
import "./chunk-3LY4F7SV.js";
|
|
172
|
+
import "./chunk-YLC42PIE.js";
|
|
173
|
+
import {
|
|
174
|
+
DEFAULT_CONTEXT_WINDOW,
|
|
175
|
+
estimateTokenCount,
|
|
176
|
+
extractReferenceKeysFromMessage,
|
|
177
|
+
getModelContextWindow,
|
|
178
|
+
planCompression,
|
|
179
|
+
serializeMessageContent
|
|
180
|
+
} from "./chunk-LEVCXTDN.js";
|
|
181
|
+
import {
|
|
182
|
+
buildBuiltinSummaryContent,
|
|
183
|
+
clipCompactText
|
|
184
|
+
} from "./chunk-OB6FBSH3.js";
|
|
185
|
+
import "./chunk-ATK5WJOA.js";
|
|
186
|
+
import "./chunk-4F77PJBR.js";
|
|
187
|
+
import "./chunk-JZPBVBIY.js";
|
|
188
|
+
import "./chunk-5RGU3J7P.js";
|
|
189
|
+
import "./chunk-M76ECQRD.js";
|
|
216
190
|
import {
|
|
217
191
|
toErrorMessage
|
|
218
192
|
} from "./chunk-HNMXYYJR.js";
|
|
193
|
+
import {
|
|
194
|
+
compactWhitespace
|
|
195
|
+
} from "./chunk-DWLEOOGR.js";
|
|
196
|
+
import "./chunk-3ASDTTEI.js";
|
|
197
|
+
import "./chunk-V54H24CQ.js";
|
|
198
|
+
import "./chunk-WTGCTVJG.js";
|
|
199
|
+
import "./chunk-CWMSB67P.js";
|
|
200
|
+
import "./chunk-EIQDGAAE.js";
|
|
201
|
+
import "./chunk-ZHXJ6M7T.js";
|
|
202
|
+
import "./chunk-CAENRKNJ.js";
|
|
203
|
+
import "./chunk-63W5N6P3.js";
|
|
204
|
+
import "./chunk-VF4K2QE6.js";
|
|
219
205
|
import {
|
|
220
206
|
checkForCliUpdate,
|
|
221
207
|
runSelfUpdate
|
|
@@ -237,35 +223,41 @@ import {
|
|
|
237
223
|
import {
|
|
238
224
|
DEFAULT_NOLO_SERVER_URL
|
|
239
225
|
} from "./chunk-OLZBQWZU.js";
|
|
240
|
-
import "./chunk-
|
|
241
|
-
import "./chunk-
|
|
242
|
-
import "./chunk-HRPWRVBI.js";
|
|
243
|
-
import "./chunk-R7LOFGRE.js";
|
|
244
|
-
import "./chunk-Y5GCAMGP.js";
|
|
245
|
-
import "./chunk-UZ6XXCVR.js";
|
|
226
|
+
import "./chunk-KGEVMUMI.js";
|
|
227
|
+
import "./chunk-G5GVZAXF.js";
|
|
246
228
|
import "./chunk-KX6YBIHG.js";
|
|
247
|
-
import "./chunk-
|
|
248
|
-
import "./chunk-
|
|
249
|
-
import "./chunk-NRY4GCKJ.js";
|
|
250
|
-
import "./chunk-WWC7I6TA.js";
|
|
251
|
-
import "./chunk-SKDNBYZK.js";
|
|
252
|
-
import "./chunk-I42VC5KR.js";
|
|
229
|
+
import "./chunk-LAXMH7JY.js";
|
|
230
|
+
import "./chunk-ZJ2WITOO.js";
|
|
253
231
|
import {
|
|
254
232
|
asTrimmedLowercaseString
|
|
255
233
|
} from "./chunk-QSJ3HFEF.js";
|
|
256
|
-
import "./chunk-
|
|
257
|
-
import "./chunk-XMLRJUU5.js";
|
|
258
|
-
import "./chunk-R5V5G73M.js";
|
|
259
|
-
import "./chunk-GBRG75BQ.js";
|
|
260
|
-
import "./chunk-3EUW3WEO.js";
|
|
261
|
-
import "./chunk-U6VC4MU4.js";
|
|
234
|
+
import "./chunk-ZJH3LKEW.js";
|
|
262
235
|
import {
|
|
263
236
|
extractCustomId
|
|
264
237
|
} from "./chunk-TOW4E763.js";
|
|
265
|
-
import "./chunk-
|
|
238
|
+
import "./chunk-2IJAKBK2.js";
|
|
239
|
+
import "./chunk-5RDLGLAP.js";
|
|
266
240
|
import "./chunk-LCBAMY2M.js";
|
|
267
241
|
import "./chunk-4SN6J65J.js";
|
|
268
242
|
import "./chunk-CF7PE763.js";
|
|
243
|
+
import "./chunk-VP4WJWKW.js";
|
|
244
|
+
import "./chunk-L3GCUVOH.js";
|
|
245
|
+
import "./chunk-WHLVPK32.js";
|
|
246
|
+
import "./chunk-WWC7I6TA.js";
|
|
247
|
+
import "./chunk-GBRG75BQ.js";
|
|
248
|
+
import "./chunk-3EUW3WEO.js";
|
|
249
|
+
import "./chunk-U6VC4MU4.js";
|
|
250
|
+
import "./chunk-KUG52IAP.js";
|
|
251
|
+
import {
|
|
252
|
+
canonicalizeToolNames
|
|
253
|
+
} from "./chunk-3AUWC6EM.js";
|
|
254
|
+
import {
|
|
255
|
+
expandEnabledPacks
|
|
256
|
+
} from "./chunk-CF7S2RYZ.js";
|
|
257
|
+
import "./chunk-ZWJOGMKH.js";
|
|
258
|
+
import "./chunk-WZSRQNQG.js";
|
|
259
|
+
import "./chunk-UZ6XXCVR.js";
|
|
260
|
+
import "./chunk-I42VC5KR.js";
|
|
269
261
|
import {
|
|
270
262
|
asOptionalTrimmedString
|
|
271
263
|
} from "./chunk-G3SUCT4W.js";
|
|
@@ -2271,13 +2263,22 @@ function createRunCompletionWatcher(deps) {
|
|
|
2271
2263
|
const createdAt = now();
|
|
2272
2264
|
const lastStatusByRunId = /* @__PURE__ */ new Map();
|
|
2273
2265
|
const notifiedRunIds = /* @__PURE__ */ new Set();
|
|
2266
|
+
const runDuration = (record) => formatRunAge(
|
|
2267
|
+
{
|
|
2268
|
+
startedAt: readTimestamp(record.startedAt),
|
|
2269
|
+
finishedAt: readTimestamp(record.endedAt ?? record.finishedAt)
|
|
2270
|
+
},
|
|
2271
|
+
now()
|
|
2272
|
+
) ?? "";
|
|
2273
|
+
const isFailureStatus = (status) => typeof status === "string" && status !== "done";
|
|
2274
2274
|
const describeRun = (record) => {
|
|
2275
2275
|
const lines = [
|
|
2276
2276
|
`runId: ${record.runId}`,
|
|
2277
2277
|
`agent: ${resolveRunLabel(record)}`,
|
|
2278
2278
|
`status: ${record.status}`
|
|
2279
2279
|
];
|
|
2280
|
-
|
|
2280
|
+
const verbose = isFailureStatus(record.status);
|
|
2281
|
+
if (verbose && typeof record.exitCode === "number") {
|
|
2281
2282
|
lines.push(`exitCode: ${record.exitCode}`);
|
|
2282
2283
|
}
|
|
2283
2284
|
if (record.dialogId) {
|
|
@@ -2287,18 +2288,12 @@ function createRunCompletionWatcher(deps) {
|
|
|
2287
2288
|
} else {
|
|
2288
2289
|
lines.push(`childDialogId: missing (result unpersisted or ephemeral)`);
|
|
2289
2290
|
}
|
|
2290
|
-
const duration =
|
|
2291
|
-
{
|
|
2292
|
-
startedAt: readTimestamp(record.startedAt),
|
|
2293
|
-
finishedAt: readTimestamp(record.endedAt ?? record.finishedAt)
|
|
2294
|
-
},
|
|
2295
|
-
now()
|
|
2296
|
-
);
|
|
2291
|
+
const duration = runDuration(record);
|
|
2297
2292
|
if (duration) lines.push(`duration: ${duration}`);
|
|
2298
2293
|
const recordError = "error" in record && typeof record.error === "string" ? record.error : void 0;
|
|
2299
2294
|
const note = typeof record.note === "string" ? clipText(record.note, WAKE_NOTE_MAX_CHARS) : typeof recordError === "string" ? clipText(recordError, WAKE_NOTE_MAX_CHARS) : "";
|
|
2300
2295
|
if (note) lines.push(`note: ${note}`);
|
|
2301
|
-
const counters = record.activity?.counters;
|
|
2296
|
+
const counters = verbose ? record.activity?.counters : void 0;
|
|
2302
2297
|
if (counters && typeof counters.toolCalls === "number" && typeof counters.llmCalls === "number" && typeof counters.fileEdits === "number") {
|
|
2303
2298
|
lines.push(
|
|
2304
2299
|
`activity: ${counters.toolCalls} tool calls \xB7 ${counters.llmCalls} llm calls \xB7 ${counters.fileEdits} edits`
|
|
@@ -2319,6 +2314,16 @@ function createRunCompletionWatcher(deps) {
|
|
|
2319
2314
|
);
|
|
2320
2315
|
return lines.join("\n");
|
|
2321
2316
|
};
|
|
2317
|
+
const buildWakeDisplayText = (finished) => {
|
|
2318
|
+
const parts = finished.map((record) => {
|
|
2319
|
+
const mark = isFailureStatus(record.status) ? "\u2717" : "\u2713";
|
|
2320
|
+
const duration = runDuration(record);
|
|
2321
|
+
const label = resolveRunLabel(record);
|
|
2322
|
+
const status = isFailureStatus(record.status) ? ` ${record.status}` : "";
|
|
2323
|
+
return `${mark} ${label}${status}${duration ? ` \xB7 ${duration}` : ""}`;
|
|
2324
|
+
});
|
|
2325
|
+
return `${finished.length} \u6761\u540E\u53F0 run \u5DF2\u5B8C\u6210 \xB7 ${parts.join(" \xB7 ")}`;
|
|
2326
|
+
};
|
|
2322
2327
|
return {
|
|
2323
2328
|
observe(records) {
|
|
2324
2329
|
const finished = [];
|
|
@@ -2328,13 +2333,15 @@ function createRunCompletionWatcher(deps) {
|
|
|
2328
2333
|
if (!rawRecord || typeof rawRecord.runId !== "string" || !rawRecord.runId) continue;
|
|
2329
2334
|
const record = rawRecord;
|
|
2330
2335
|
if (notifiedRunIds.has(record.runId)) continue;
|
|
2331
|
-
if (record.ack === true) {
|
|
2332
|
-
notifiedRunIds.add(record.runId);
|
|
2333
|
-
continue;
|
|
2334
|
-
}
|
|
2335
2336
|
const status = record.status;
|
|
2336
2337
|
if (typeof status !== "string") continue;
|
|
2337
2338
|
if (record.parentDialogId !== currentDialogId) continue;
|
|
2339
|
+
if (isRunRecordClaimed(record, now())) {
|
|
2340
|
+
if (!isAgentRunTerminalStatus(status)) {
|
|
2341
|
+
lastStatusByRunId.set(record.runId, status);
|
|
2342
|
+
}
|
|
2343
|
+
continue;
|
|
2344
|
+
}
|
|
2338
2345
|
const previous = lastStatusByRunId.get(record.runId);
|
|
2339
2346
|
lastStatusByRunId.set(record.runId, status);
|
|
2340
2347
|
if (!isAgentRunTerminalStatus(status)) continue;
|
|
@@ -2356,7 +2363,8 @@ function createRunCompletionWatcher(deps) {
|
|
|
2356
2363
|
const event = {
|
|
2357
2364
|
kind: "child-run-completed",
|
|
2358
2365
|
runs: shapes,
|
|
2359
|
-
text: summaryText
|
|
2366
|
+
text: summaryText,
|
|
2367
|
+
displayText: buildWakeDisplayText(finished)
|
|
2360
2368
|
};
|
|
2361
2369
|
deps.onWake(event);
|
|
2362
2370
|
},
|
|
@@ -3630,7 +3638,6 @@ var SLASH_COMMANDS = [
|
|
|
3630
3638
|
"/ctx",
|
|
3631
3639
|
"/runtime",
|
|
3632
3640
|
"/tools",
|
|
3633
|
-
"/thinking",
|
|
3634
3641
|
"/switch",
|
|
3635
3642
|
"/agent",
|
|
3636
3643
|
"/agents",
|
|
@@ -4507,6 +4514,10 @@ function resolveChatSendDecision(input) {
|
|
|
4507
4514
|
}
|
|
4508
4515
|
|
|
4509
4516
|
// packages/core/chat/chatQueueStatus.ts
|
|
4517
|
+
function resolveQueuePreviewText(item) {
|
|
4518
|
+
if (typeof item === "string") return item;
|
|
4519
|
+
return item?.event?.displayText ?? item?.text ?? "";
|
|
4520
|
+
}
|
|
4510
4521
|
function projectChatQueueStatus({
|
|
4511
4522
|
state,
|
|
4512
4523
|
maxPreview = 3,
|
|
@@ -4515,7 +4526,7 @@ function projectChatQueueStatus({
|
|
|
4515
4526
|
const preview = [];
|
|
4516
4527
|
for (let i = 0; i < Math.min(maxPreview, state.queue.length); i++) {
|
|
4517
4528
|
const item = state.queue[i];
|
|
4518
|
-
const text =
|
|
4529
|
+
const text = resolveQueuePreviewText(item);
|
|
4519
4530
|
preview.push(text.length > previewCharLimit ? text.slice(0, previewCharLimit) + "\u2026" : text);
|
|
4520
4531
|
}
|
|
4521
4532
|
let composerPlaceholderKey = "default";
|
|
@@ -4715,6 +4726,18 @@ function finalizeCurrentTurn(history) {
|
|
|
4715
4726
|
}
|
|
4716
4727
|
}
|
|
4717
4728
|
}
|
|
4729
|
+
function appendLocalTurn(history, command, output) {
|
|
4730
|
+
finalizeCurrentTurn(history);
|
|
4731
|
+
history.turns.push({
|
|
4732
|
+
role: "local",
|
|
4733
|
+
command,
|
|
4734
|
+
content: output
|
|
4735
|
+
});
|
|
4736
|
+
if (history.turns.length > MAX_TUI_HISTORY_TURNS) {
|
|
4737
|
+
history.turns = history.turns.slice(history.turns.length - MAX_TUI_HISTORY_TURNS);
|
|
4738
|
+
}
|
|
4739
|
+
resetStreamingTurnCache();
|
|
4740
|
+
}
|
|
4718
4741
|
function applyOutputChunkToCurrentTurn(history, chunk) {
|
|
4719
4742
|
const next = applyTerminalOutputToText(history.currentContent, chunk);
|
|
4720
4743
|
if (next === history.currentContent) return false;
|
|
@@ -4742,7 +4765,7 @@ function fillUserBubbleRow(row, surfaceSeq, contentWidth) {
|
|
|
4742
4765
|
}
|
|
4743
4766
|
return renderSurfaceLine({ text: row, surface: surfaceSeq, padTo: contentWidth });
|
|
4744
4767
|
}
|
|
4745
|
-
function renderTurnBlock(role, content, contentWidth, colorEnabled) {
|
|
4768
|
+
function renderTurnBlock(role, content, contentWidth, colorEnabled, command) {
|
|
4746
4769
|
content = content.replace(/\r\n/g, "\n").replace(/\r/g, "\n");
|
|
4747
4770
|
const lines = [];
|
|
4748
4771
|
if (role === "user") {
|
|
@@ -4761,6 +4784,21 @@ function renderTurnBlock(role, content, contentWidth, colorEnabled) {
|
|
|
4761
4784
|
...surfaceSeq ? rows.map((row) => fillUserBubbleRow(row, surfaceSeq, contentWidth)) : rows
|
|
4762
4785
|
);
|
|
4763
4786
|
}
|
|
4787
|
+
} else if (role === "local") {
|
|
4788
|
+
const dimSeq = colorEnabled ? "\x1B[2m" : "";
|
|
4789
|
+
const resetSeq = colorEnabled ? "\x1B[0m" : "";
|
|
4790
|
+
if (command) {
|
|
4791
|
+
lines.push(
|
|
4792
|
+
...wrapTranscriptLine(`${dimSeq}\u203A ${command}${resetSeq}`, contentWidth)
|
|
4793
|
+
);
|
|
4794
|
+
}
|
|
4795
|
+
if (content) {
|
|
4796
|
+
for (const line of content.split("\n")) {
|
|
4797
|
+
lines.push(
|
|
4798
|
+
...wrapTranscriptLine(`${dimSeq} ${line}${resetSeq}`, contentWidth)
|
|
4799
|
+
);
|
|
4800
|
+
}
|
|
4801
|
+
}
|
|
4764
4802
|
} else {
|
|
4765
4803
|
const styledEntry = styleAssistantTurn(content, colorEnabled);
|
|
4766
4804
|
for (const logicalLine of styledEntry.split("\n")) {
|
|
@@ -4894,13 +4932,22 @@ function getAssistantPlainLines(content) {
|
|
|
4894
4932
|
assistantPlainLinesCache.set(content, plainLines);
|
|
4895
4933
|
return plainLines;
|
|
4896
4934
|
}
|
|
4897
|
-
function countTurnLines(role, content, contentWidth) {
|
|
4935
|
+
function countTurnLines(role, content, contentWidth, command) {
|
|
4898
4936
|
content = content.replace(/\r\n/g, "\n").replace(/\r/g, "\n");
|
|
4899
4937
|
let count = 0;
|
|
4900
4938
|
if (role === "user") {
|
|
4901
4939
|
for (const line of content.split("\n")) {
|
|
4902
4940
|
count += wrapTranscriptLine(`\u2503 ${line}`, contentWidth, "\u2503 ").length;
|
|
4903
4941
|
}
|
|
4942
|
+
} else if (role === "local") {
|
|
4943
|
+
if (command) {
|
|
4944
|
+
count += wrapTranscriptLine(`\u203A ${command}`, contentWidth).length;
|
|
4945
|
+
}
|
|
4946
|
+
if (content) {
|
|
4947
|
+
for (const line of content.split("\n")) {
|
|
4948
|
+
count += wrapTranscriptLine(` ${line}`, contentWidth).length;
|
|
4949
|
+
}
|
|
4950
|
+
}
|
|
4904
4951
|
} else {
|
|
4905
4952
|
const plainLines = getAssistantPlainLines(content);
|
|
4906
4953
|
for (let i = 0; i < plainLines.length; i++) {
|
|
@@ -4924,7 +4971,7 @@ function buildTurnOffsets(history, contentWidth) {
|
|
|
4924
4971
|
if (cached && cached.width === contentWidth) {
|
|
4925
4972
|
lineCount = cached.count;
|
|
4926
4973
|
} else {
|
|
4927
|
-
lineCount = countTurnLines(turn.role, turn.content, contentWidth);
|
|
4974
|
+
lineCount = countTurnLines(turn.role, turn.content, contentWidth, turn.command);
|
|
4928
4975
|
turnLineCountCache.set(turn, { width: contentWidth, count: lineCount });
|
|
4929
4976
|
}
|
|
4930
4977
|
entries.push({ startRow: offset, lineCount, separatorAbove });
|
|
@@ -4944,7 +4991,14 @@ function buildCopyViewLines(history) {
|
|
|
4944
4991
|
for (const [index, turn] of turns.entries()) {
|
|
4945
4992
|
if (index > 0) lines.push("");
|
|
4946
4993
|
const normalized = stripAnsi(turn.content).replace(/\r\n/g, "\n").replace(/\r/g, "\n");
|
|
4947
|
-
|
|
4994
|
+
if (turn.role === "local") {
|
|
4995
|
+
if (turn.command) {
|
|
4996
|
+
lines.push(`\u203A ${stripAnsi(turn.command)}`);
|
|
4997
|
+
}
|
|
4998
|
+
lines.push(...normalized.split("\n"));
|
|
4999
|
+
} else {
|
|
5000
|
+
lines.push(...normalized.split("\n"));
|
|
5001
|
+
}
|
|
4948
5002
|
}
|
|
4949
5003
|
return lines;
|
|
4950
5004
|
}
|
|
@@ -5008,7 +5062,7 @@ function renderHistory(output, history, inputLines) {
|
|
|
5008
5062
|
lines = cached.lines;
|
|
5009
5063
|
} else {
|
|
5010
5064
|
renderCacheMissCount += 1;
|
|
5011
|
-
lines = renderTurnBlock(turn.role, turn.content, contentWidth, colorEnabled);
|
|
5065
|
+
lines = renderTurnBlock(turn.role, turn.content, contentWidth, colorEnabled, turn.command);
|
|
5012
5066
|
turnLineCache.set(turn, {
|
|
5013
5067
|
width: contentWidth,
|
|
5014
5068
|
color: colorEnabled,
|
|
@@ -5714,34 +5768,6 @@ async function runAgentChat(scriptDir, state, message, env, output, agentRunner
|
|
|
5714
5768
|
);
|
|
5715
5769
|
}
|
|
5716
5770
|
}
|
|
5717
|
-
const userSelectedAgent = state.agentKey !== DEFAULT_TUI_AGENT_KEY;
|
|
5718
|
-
const visionProbeKey = hasImages && userSelectedAgent ? state.agentKey : effectiveAgentKey;
|
|
5719
|
-
if (hasImages && effectiveAgentKey !== CLI_IMAGE_AGENT_KEY) {
|
|
5720
|
-
let needsVisionSwitch = false;
|
|
5721
|
-
if (CLI_AUTO_TIER_AGENT_KEY_TABLE[visionProbeKey]) {
|
|
5722
|
-
needsVisionSwitch = true;
|
|
5723
|
-
} else {
|
|
5724
|
-
const authToken = resolvePlatformAuthToken(env);
|
|
5725
|
-
const record = await readDbRecord({
|
|
5726
|
-
dbKey: visionProbeKey,
|
|
5727
|
-
authToken,
|
|
5728
|
-
serverUrl: state.serverUrl,
|
|
5729
|
-
fetchImpl: fetch
|
|
5730
|
-
}).catch(() => null);
|
|
5731
|
-
if (record && !resolveAgentImageInputSupport(record)) {
|
|
5732
|
-
needsVisionSwitch = true;
|
|
5733
|
-
}
|
|
5734
|
-
}
|
|
5735
|
-
if (needsVisionSwitch) {
|
|
5736
|
-
output.write(
|
|
5737
|
-
`
|
|
5738
|
-
[nolo] \u5F53\u524D agent \u4E0D\u652F\u6301\u56FE\u7247\u8F93\u5165\uFF0C\u5DF2\u81EA\u52A8\u5207\u6362\u5230 Kimi K2.6
|
|
5739
|
-
`
|
|
5740
|
-
);
|
|
5741
|
-
effectiveAgentKey = CLI_IMAGE_AGENT_KEY;
|
|
5742
|
-
effectiveAgentName = "Kimi K2.6";
|
|
5743
|
-
}
|
|
5744
|
-
}
|
|
5745
5771
|
let effectiveMessage = message;
|
|
5746
5772
|
let skillAllowedTools;
|
|
5747
5773
|
let skillContextBlocks;
|
|
@@ -6352,8 +6378,13 @@ async function startTuiWorkspace(options) {
|
|
|
6352
6378
|
turnEpoch += 1;
|
|
6353
6379
|
const myEpoch = turnEpoch;
|
|
6354
6380
|
history.followBottom = true;
|
|
6355
|
-
|
|
6356
|
-
|
|
6381
|
+
const isInternalEvent = req.event.kind !== "user";
|
|
6382
|
+
const transcriptText = req.event.kind === "child-run-completed" ? req.event.displayText ?? req.event.text : message;
|
|
6383
|
+
startTurn(history, isInternalEvent ? "assistant" : "user");
|
|
6384
|
+
appendToCurrentTurn(
|
|
6385
|
+
history,
|
|
6386
|
+
isInternalEvent ? dimCliText(transcriptText, resolveCliColorEnabled()) : transcriptText
|
|
6387
|
+
);
|
|
6357
6388
|
finalizeCurrentTurn(history);
|
|
6358
6389
|
renderHistoryToOutput();
|
|
6359
6390
|
if (fixedInput.active) fixedInput.repaint(buffer, cursorPos);
|
|
@@ -6497,7 +6528,7 @@ async function startTuiWorkspace(options) {
|
|
|
6497
6528
|
activeTurnAbort.abort();
|
|
6498
6529
|
}
|
|
6499
6530
|
};
|
|
6500
|
-
const emitCommandOutput = (text) => {
|
|
6531
|
+
const emitCommandOutput = (text, command = "") => {
|
|
6501
6532
|
if (!text) return;
|
|
6502
6533
|
if (!isInteractiveInput(input)) {
|
|
6503
6534
|
output.write(`${text}
|
|
@@ -6505,9 +6536,7 @@ async function startTuiWorkspace(options) {
|
|
|
6505
6536
|
return;
|
|
6506
6537
|
}
|
|
6507
6538
|
history.followBottom = true;
|
|
6508
|
-
|
|
6509
|
-
appendToCurrentTurn(history, text);
|
|
6510
|
-
finalizeCurrentTurn(history);
|
|
6539
|
+
appendLocalTurn(history, command, text);
|
|
6511
6540
|
renderHistoryToOutput();
|
|
6512
6541
|
if (fixedInput.active) fixedInput.repaint(buffer, cursorPos);
|
|
6513
6542
|
};
|
|
@@ -6528,21 +6557,17 @@ async function startTuiWorkspace(options) {
|
|
|
6528
6557
|
const previousAgentKey = state.agentKey;
|
|
6529
6558
|
state = result.nextState;
|
|
6530
6559
|
const interactive = isInteractiveInput(input);
|
|
6531
|
-
if (
|
|
6532
|
-
|
|
6533
|
-
startTurn(history, "user");
|
|
6534
|
-
appendToCurrentTurn(history, line.trim());
|
|
6535
|
-
finalizeCurrentTurn(history);
|
|
6536
|
-
renderHistoryToOutput();
|
|
6537
|
-
if (fixedInput.active) fixedInput.repaint(buffer, cursorPos);
|
|
6538
|
-
}
|
|
6539
|
-
if (result.output) {
|
|
6540
|
-
emitCommandOutput(result.output);
|
|
6560
|
+
if (result.action?.type !== "chat" && result.action?.type !== "exit" && result.output) {
|
|
6561
|
+
emitCommandOutput(result.output, interactive ? line.trim() : "");
|
|
6541
6562
|
}
|
|
6542
6563
|
if (state.agentKey !== previousAgentKey) {
|
|
6543
6564
|
persistExplicitAgentSwitch(previousAgentKey);
|
|
6544
6565
|
}
|
|
6545
|
-
if (result.action?.type === "exit")
|
|
6566
|
+
if (result.action?.type === "exit") {
|
|
6567
|
+
if (result.output) output.write(`${result.output}
|
|
6568
|
+
`);
|
|
6569
|
+
return true;
|
|
6570
|
+
}
|
|
6546
6571
|
if (result.action?.type === "clear") {
|
|
6547
6572
|
if (result.action.dialogId) {
|
|
6548
6573
|
const authToken = resolvePlatformAuthToken(options.env ?? {});
|
|
@@ -7375,6 +7400,7 @@ ${renderStatusLine(state)}
|
|
|
7375
7400
|
}
|
|
7376
7401
|
export {
|
|
7377
7402
|
ANSI_ESCAPE_REGEX,
|
|
7403
|
+
appendLocalTurn,
|
|
7378
7404
|
appendToCurrentTurn,
|
|
7379
7405
|
applyOutputChunkToCurrentTurn,
|
|
7380
7406
|
applyScrollAction,
|