@staff0rd/assist 0.1231.0 → 0.1231.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/.build-files +81 -81
- package/dist/{addActivity-Q4IDY2CA.js → addActivity-TWBP5R55.js} +2 -2
- package/dist/{addPhase-OIYOFSYJ.js → addPhase-25CUDUEH.js} +3 -3
- package/dist/{advise-MCRTCUSC.js → advise-RQNYI5ZS.js} +3 -3
- package/dist/{askCheck-O2ZHKOGN.js → askCheck-RACJG7Y5.js} +7 -7
- package/dist/{askDesign-6B62VLVV.js → askDesign-64NKSBQ6.js} +1 -1
- package/dist/{branch-WYW6UX56.js → branch-TY5LTVFK.js} +3 -3
- package/dist/built-version +1 -1
- package/dist/{chunk-NGVZRCA6.js → chunk-3ZHTSOYH.js} +1 -1
- package/dist/{chunk-YUIFOZJH.js → chunk-57OKR5TN.js} +1 -1
- package/dist/{chunk-M73WI3RX.js → chunk-6BO62LUF.js} +2 -2
- package/dist/{chunk-RKSERHPK.js → chunk-AF3VNHUW.js} +1 -1
- package/dist/{chunk-HXPH2JGU.js → chunk-BDAHWG46.js} +1 -1
- package/dist/{chunk-AAWKMMB4.js → chunk-BGRNWO7S.js} +1 -1
- package/dist/{chunk-HLEWJVET.js → chunk-BT663JQX.js} +1 -1
- package/dist/{chunk-TOC56YEJ.js → chunk-BVJPDL4X.js} +1 -1
- package/dist/{chunk-TF4OSGBP.js → chunk-BX2JQE66.js} +1 -1
- package/dist/{chunk-EK2RLFXR.js → chunk-BZGSHBFU.js} +1 -1
- package/dist/{chunk-JJ5JR72H.js → chunk-CGCOYUP4.js} +2 -2
- package/dist/{chunk-6FHQI76J.js → chunk-CVBCIVI6.js} +1 -1
- package/dist/{chunk-4PEGE74T.js → chunk-GEFOX4XS.js} +1 -1
- package/dist/{chunk-KEJPYXEY.js → chunk-H3XWOCH7.js} +5 -5
- package/dist/{chunk-H3MVAHB2.js → chunk-HLDM4R3D.js} +1 -1
- package/dist/{chunk-Q5LGQWGS.js → chunk-IWQPS3XV.js} +1 -1
- package/dist/{chunk-JYCKBPC2.js → chunk-JBNAFQ4Q.js} +6 -6
- package/dist/{chunk-WY4GWL6X.js → chunk-MQBXLYZK.js} +2 -2
- package/dist/{chunk-DU4T5PQK.js → chunk-OBCSHJ5A.js} +1 -1
- package/dist/{chunk-IKHXY2LH.js → chunk-OCFSZVB4.js} +1 -1
- package/dist/{chunk-D2ZSVKQJ.js → chunk-OKMUPY5D.js} +3 -3
- package/dist/{chunk-IK33FSGP.js → chunk-ORLSVRIS.js} +1 -1
- package/dist/{chunk-5WHMKYM5.js → chunk-P6ISEEWQ.js} +1 -1
- package/dist/{chunk-QJUGU4T6.js → chunk-Q4VLNWPA.js} +2 -2
- package/dist/{chunk-26J2OOOR.js → chunk-QK4HRTJ7.js} +2 -2
- package/dist/{chunk-VOEELPO6.js → chunk-RHGJ7MLT.js} +1 -1
- package/dist/{chunk-2TFVO6SC.js → chunk-RQZPXJ24.js} +1 -1
- package/dist/{chunk-TQBIVBVZ.js → chunk-SLA3JY7M.js} +1 -1
- package/dist/{chunk-QQUVV2UE.js → chunk-SPFJCIKI.js} +1 -1
- package/dist/{chunk-TIS5FCAG.js → chunk-TEN7Y5M4.js} +1 -1
- package/dist/{chunk-VQMTVCM6.js → chunk-TMGB3VJT.js} +2 -2
- package/dist/{chunk-I4GISTNT.js → chunk-TWOISHDM.js} +7 -7
- package/dist/{chunk-PSEMXVYR.js → chunk-UBMNM3FH.js} +1 -1
- package/dist/{chunk-4CMHZS4L.js → chunk-UWECDFQ7.js} +97 -77
- package/dist/{chunk-IS644QZW.js → chunk-WB4AONKW.js} +3 -3
- package/dist/{chunk-4FTWTJTG.js → chunk-WNJ5HWIN.js} +1 -1
- package/dist/{chunk-A2X4BPWJ.js → chunk-XFHYKQSY.js} +1 -1
- package/dist/{chunk-HWXN5MWN.js → chunk-ZSL7KTO7.js} +1 -1
- package/dist/{cliHook-4VY6PEWU.js → cliHook-PAIGTRQJ.js} +6 -6
- package/dist/{cliHookCheck-OXVLMBJR.js → cliHookCheck-7T24PCFL.js} +2 -2
- package/dist/{codexHook-V3H6TKXB.js → codexHook-ORTKWMH7.js} +8 -8
- package/dist/commands/sessions/web/bundle.js +1 -1
- package/dist/{commit-VVABO3BK.js → commit-S7B2QZVQ.js} +6 -6
- package/dist/{doctorNodes-XRCNZ4PT.js → doctorNodes-G77LMIWJ.js} +3 -3
- package/dist/{done-HXY6Q5RV.js → done-XXQJDV2B.js} +4 -4
- package/dist/{editHook-MWYUNOT7.js → editHook-RN5UYZXP.js} +6 -6
- package/dist/{fixConflict-ORQJIU3O.js → fixConflict-ISKD26XD.js} +4 -4
- package/dist/index.js +50 -50
- package/dist/{launchMode-DQVZ2QQT.js → launchMode-5LLP2KHE.js} +14 -14
- package/dist/{list-OCXKZZRJ.js → list-N4XILKFL.js} +5 -5
- package/dist/{migrate-LFDL5NE5.js → migrate-DBHZC4G3.js} +3 -3
- package/dist/{next-KO7OOVXB.js → next-JBLY4RJR.js} +13 -13
- package/dist/{phaseDone-RCREM5TT.js → phaseDone-QEEVXWYG.js} +5 -5
- package/dist/{piHook-KYZYUHTK.js → piHook-PAM5R5QL.js} +6 -6
- package/dist/{propose-J5XJSSMJ.js → propose-A23WHXGL.js} +4 -4
- package/dist/{refine-O6YAALTY.js → refine-WQDC36WM.js} +15 -15
- package/dist/{restartNode-SWBP25OT.js → restartNode-O5UFOIDE.js} +5 -5
- package/dist/{review-RW7JZUI7.js → review-DH6IW6XX.js} +4 -4
- package/dist/{reviewPrComments-ZH5SXLCM.js → reviewPrComments-EC7A3MI3.js} +4 -4
- package/dist/{rewindPhase-WOETPIBA.js → rewindPhase-IFYZRJ4K.js} +8 -8
- package/dist/{run-ELV3PXR7.js → run-KRPWLBMG.js} +11 -11
- package/dist/{run-MW4USXCH.js → run-U3BWDNHC.js} +11 -11
- package/dist/{runDaemon-CSBCYYN4.js → runDaemon-WJ2UNCYT.js} +14 -14
- package/dist/{runParallelPhase-VIFZOO5R.js → runParallelPhase-JMDSJQVL.js} +7 -7
- package/dist/{runRefine-QX2JW4YO.js → runRefine-WMGQDYOJ.js} +15 -15
- package/dist/{scan-LMRO6SL2.js → scan-JGAAJJFD.js} +2 -2
- package/dist/{schemaConfirm-6KKGGJP3.js → schemaConfirm-S2VDR7LG.js} +2 -2
- package/dist/{schemaLock-IVAVASNF.js → schemaLock-2AT7SNHW.js} +2 -2
- package/dist/{schemaUnlock-YLDIYA5N.js → schemaUnlock-IPOIB3SO.js} +2 -2
- package/dist/{search-GHB5N7NM.js → search-MFD52AFY.js} +5 -5
- package/dist/{show-C5XSXCVP.js → show-COIEPVBU.js} +3 -3
- package/dist/{show-ITUSVXIN.js → show-CQOFC52U.js} +3 -3
- package/dist/{signExtension-YPCFB6OC.js → signExtension-GJROAYK5.js} +1 -1
- package/dist/{updateNode-GFGASMAX.js → updateNode-2AQLR2GC.js} +5 -5
- package/dist/{updatePlan-2RWNPSX7.js → updatePlan-S6L7HLOT.js} +4 -4
- package/dist/{web-KHBRC3YS.js → web-7PB245R7.js} +16 -16
- package/dist/{web-UGWDYQ53.js → web-LM5TFGVE.js} +16 -16
- package/package.json +1 -1
|
@@ -6,10 +6,10 @@ import {
|
|
|
6
6
|
} from "./chunk-MB26GQDS.js";
|
|
7
7
|
import {
|
|
8
8
|
resolveRewindPlan
|
|
9
|
-
} from "./chunk-
|
|
9
|
+
} from "./chunk-MQBXLYZK.js";
|
|
10
10
|
import {
|
|
11
11
|
resolvePlan
|
|
12
|
-
} from "./chunk-
|
|
12
|
+
} from "./chunk-BDAHWG46.js";
|
|
13
13
|
import {
|
|
14
14
|
resetPhaseAndDependents,
|
|
15
15
|
updateStatus
|
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
import {
|
|
2
2
|
next
|
|
3
|
-
} from "./chunk-
|
|
3
|
+
} from "./chunk-TMGB3VJT.js";
|
|
4
4
|
import {
|
|
5
5
|
pullIfConfigured
|
|
6
6
|
} from "./chunk-BTVSTYTZ.js";
|
|
7
7
|
import {
|
|
8
8
|
run
|
|
9
|
-
} from "./chunk-
|
|
9
|
+
} from "./chunk-JBNAFQ4Q.js";
|
|
10
10
|
import {
|
|
11
11
|
launchBlocker
|
|
12
12
|
} from "./chunk-GJFTADBZ.js";
|
|
@@ -15,7 +15,7 @@ import {
|
|
|
15
15
|
readSignal,
|
|
16
16
|
stopWatching,
|
|
17
17
|
watchForMarker
|
|
18
|
-
} from "./chunk-
|
|
18
|
+
} from "./chunk-WB4AONKW.js";
|
|
19
19
|
import {
|
|
20
20
|
resumeNudge
|
|
21
21
|
} from "./chunk-7NZOH4LN.js";
|
|
@@ -31,7 +31,7 @@ import {
|
|
|
31
31
|
} from "./chunk-3DNFNT2L.js";
|
|
32
32
|
import {
|
|
33
33
|
isBlocked
|
|
34
|
-
} from "./chunk-
|
|
34
|
+
} from "./chunk-TEN7Y5M4.js";
|
|
35
35
|
import {
|
|
36
36
|
loadItemSummaries
|
|
37
37
|
} from "./chunk-7WZ2QL34.js";
|
|
@@ -49,7 +49,7 @@ import {
|
|
|
49
49
|
} from "./chunk-N65VOEFI.js";
|
|
50
50
|
import {
|
|
51
51
|
harnessAdapter
|
|
52
|
-
} from "./chunk-
|
|
52
|
+
} from "./chunk-UWECDFQ7.js";
|
|
53
53
|
|
|
54
54
|
// src/commands/backlog/launchMode.ts
|
|
55
55
|
import chalk3 from "chalk";
|
|
@@ -18,16 +18,16 @@ import {
|
|
|
18
18
|
import {
|
|
19
19
|
createBranch,
|
|
20
20
|
generateBranchSlug
|
|
21
|
-
} from "./chunk-
|
|
21
|
+
} from "./chunk-AF3VNHUW.js";
|
|
22
22
|
import {
|
|
23
23
|
inWebSession
|
|
24
24
|
} from "./chunk-HKGCLAZ7.js";
|
|
25
25
|
import {
|
|
26
26
|
executePhase
|
|
27
|
-
} from "./chunk-
|
|
27
|
+
} from "./chunk-WB4AONKW.js";
|
|
28
28
|
import {
|
|
29
29
|
backlogPhaseActivity
|
|
30
|
-
} from "./chunk-
|
|
30
|
+
} from "./chunk-OCFSZVB4.js";
|
|
31
31
|
import {
|
|
32
32
|
awaitHarness
|
|
33
33
|
} from "./chunk-ZYK7V4PG.js";
|
|
@@ -62,10 +62,10 @@ import {
|
|
|
62
62
|
import {
|
|
63
63
|
buildReviewPhase,
|
|
64
64
|
resolveReviewPhase
|
|
65
|
-
} from "./chunk-
|
|
65
|
+
} from "./chunk-GEFOX4XS.js";
|
|
66
66
|
import {
|
|
67
67
|
resolvePlan
|
|
68
|
-
} from "./chunk-
|
|
68
|
+
} from "./chunk-BDAHWG46.js";
|
|
69
69
|
import {
|
|
70
70
|
findOneItem,
|
|
71
71
|
getOrigin,
|
|
@@ -89,7 +89,7 @@ import {
|
|
|
89
89
|
import {
|
|
90
90
|
harnessAdapter,
|
|
91
91
|
withoutResumeSession
|
|
92
|
-
} from "./chunk-
|
|
92
|
+
} from "./chunk-UWECDFQ7.js";
|
|
93
93
|
import {
|
|
94
94
|
buildFeature
|
|
95
95
|
} from "./chunk-LKZ7J5AK.js";
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import {
|
|
2
2
|
resolveReviewPhase
|
|
3
|
-
} from "./chunk-
|
|
3
|
+
} from "./chunk-GEFOX4XS.js";
|
|
4
4
|
import {
|
|
5
5
|
resolvePlan
|
|
6
|
-
} from "./chunk-
|
|
6
|
+
} from "./chunk-BDAHWG46.js";
|
|
7
7
|
|
|
8
8
|
// src/commands/backlog/resolveRewindPlan.ts
|
|
9
9
|
function resolveRewindPlan(item) {
|
|
@@ -8,10 +8,10 @@ import {
|
|
|
8
8
|
isDocsPath,
|
|
9
9
|
isSchemaPath,
|
|
10
10
|
mentionsDocsPath
|
|
11
|
-
} from "./chunk-
|
|
11
|
+
} from "./chunk-CVBCIVI6.js";
|
|
12
12
|
import {
|
|
13
13
|
isSchemaLocked
|
|
14
|
-
} from "./chunk-
|
|
14
|
+
} from "./chunk-BZGSHBFU.js";
|
|
15
15
|
import {
|
|
16
16
|
findBuiltinDenyRaw,
|
|
17
17
|
findDeny,
|
|
@@ -21,7 +21,7 @@ import {
|
|
|
21
21
|
isApprovedRead,
|
|
22
22
|
resolvePermission,
|
|
23
23
|
splitCompound
|
|
24
|
-
} from "./chunk-
|
|
24
|
+
} from "./chunk-XFHYKQSY.js";
|
|
25
25
|
import {
|
|
26
26
|
inWebSession
|
|
27
27
|
} from "./chunk-HKGCLAZ7.js";
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import {
|
|
2
2
|
checkoutPr
|
|
3
|
-
} from "./chunk-
|
|
3
|
+
} from "./chunk-57OKR5TN.js";
|
|
4
4
|
import {
|
|
5
5
|
launchBlocker
|
|
6
6
|
} from "./chunk-GJFTADBZ.js";
|
|
@@ -19,7 +19,7 @@ import {
|
|
|
19
19
|
} from "./chunk-3DNFNT2L.js";
|
|
20
20
|
import {
|
|
21
21
|
harnessAdapter
|
|
22
|
-
} from "./chunk-
|
|
22
|
+
} from "./chunk-UWECDFQ7.js";
|
|
23
23
|
|
|
24
24
|
// src/commands/launchPrSkill.ts
|
|
25
25
|
import chalk from "chalk";
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import {
|
|
2
2
|
lookupConversation
|
|
3
|
-
} from "./chunk-
|
|
3
|
+
} from "./chunk-RQZPXJ24.js";
|
|
4
4
|
import {
|
|
5
5
|
harnessAdapter,
|
|
6
6
|
readTranscriptTail
|
|
7
|
-
} from "./chunk-
|
|
7
|
+
} from "./chunk-UWECDFQ7.js";
|
|
8
8
|
|
|
9
9
|
// src/commands/sessions/shared/targetConversationEvents.ts
|
|
10
10
|
async function targetConversationEvents(cwd, target) {
|
|
@@ -3,14 +3,14 @@ import {
|
|
|
3
3
|
} from "./chunk-BTVSTYTZ.js";
|
|
4
4
|
import {
|
|
5
5
|
run
|
|
6
|
-
} from "./chunk-
|
|
6
|
+
} from "./chunk-JBNAFQ4Q.js";
|
|
7
7
|
import {
|
|
8
8
|
isLockedByOther
|
|
9
9
|
} from "./chunk-BXGPF3TG.js";
|
|
10
10
|
import {
|
|
11
11
|
isBlocked,
|
|
12
12
|
typeLabel
|
|
13
|
-
} from "./chunk-
|
|
13
|
+
} from "./chunk-TEN7Y5M4.js";
|
|
14
14
|
import {
|
|
15
15
|
loadBacklog
|
|
16
16
|
} from "./chunk-H7AYKAJD.js";
|
|
@@ -10,7 +10,7 @@ import {
|
|
|
10
10
|
} from "./chunk-JM57BCD6.js";
|
|
11
11
|
import {
|
|
12
12
|
firstBrokenHop
|
|
13
|
-
} from "./chunk-
|
|
13
|
+
} from "./chunk-ORLSVRIS.js";
|
|
14
14
|
import {
|
|
15
15
|
describePeerError,
|
|
16
16
|
fetchPeerJson
|
|
@@ -40,7 +40,7 @@ import {
|
|
|
40
40
|
resolveLinkTarget,
|
|
41
41
|
usageWindowKey,
|
|
42
42
|
watcherLogPath
|
|
43
|
-
} from "./chunk-
|
|
43
|
+
} from "./chunk-3ZHTSOYH.js";
|
|
44
44
|
import {
|
|
45
45
|
TRACE_HEADER,
|
|
46
46
|
newTraceId
|
|
@@ -48,7 +48,7 @@ import {
|
|
|
48
48
|
import {
|
|
49
49
|
ASSIST_VERSION,
|
|
50
50
|
PROTOCOL_VERSION
|
|
51
|
-
} from "./chunk-
|
|
51
|
+
} from "./chunk-SPFJCIKI.js";
|
|
52
52
|
import {
|
|
53
53
|
findLinkSpec
|
|
54
54
|
} from "./chunk-P7QEHVJJ.js";
|
|
@@ -85,7 +85,7 @@ import {
|
|
|
85
85
|
} from "./chunk-UJBW7FVI.js";
|
|
86
86
|
import {
|
|
87
87
|
targetConversationEvents
|
|
88
|
-
} from "./chunk-
|
|
88
|
+
} from "./chunk-QK4HRTJ7.js";
|
|
89
89
|
import {
|
|
90
90
|
configEntryLayers,
|
|
91
91
|
ghFailure,
|
|
@@ -253,7 +253,7 @@ import {
|
|
|
253
253
|
} from "./chunk-H2WZXCE4.js";
|
|
254
254
|
import {
|
|
255
255
|
rewindItemToPhase
|
|
256
|
-
} from "./chunk-
|
|
256
|
+
} from "./chunk-CGCOYUP4.js";
|
|
257
257
|
import {
|
|
258
258
|
loadItemSummaries,
|
|
259
259
|
phaseUsageTotals,
|
|
@@ -282,7 +282,7 @@ import {
|
|
|
282
282
|
} from "./chunk-2RM5RFIH.js";
|
|
283
283
|
import {
|
|
284
284
|
resolveRewindPlan
|
|
285
|
-
} from "./chunk-
|
|
285
|
+
} from "./chunk-MQBXLYZK.js";
|
|
286
286
|
import {
|
|
287
287
|
deleteItem,
|
|
288
288
|
getOrigin,
|
|
@@ -331,7 +331,7 @@ import {
|
|
|
331
331
|
discoverSessionJsonlPaths,
|
|
332
332
|
harnessAdapter,
|
|
333
333
|
parseSessionFile
|
|
334
|
-
} from "./chunk-
|
|
334
|
+
} from "./chunk-UWECDFQ7.js";
|
|
335
335
|
import {
|
|
336
336
|
harnessLabel
|
|
337
337
|
} from "./chunk-XZSATLYY.js";
|
|
@@ -1107,72 +1107,6 @@ function claudeArtifactResultUrls(entries) {
|
|
|
1107
1107
|
return urls;
|
|
1108
1108
|
}
|
|
1109
1109
|
|
|
1110
|
-
// src/commands/sessions/shared/renderPrompt.ts
|
|
1111
|
-
function renderPrompt(raw) {
|
|
1112
|
-
const command = marker(raw, "command-name");
|
|
1113
|
-
if (command) {
|
|
1114
|
-
const args = marker(raw, "command-args");
|
|
1115
|
-
const name = `/${command.replace(/^\/+/, "")}`;
|
|
1116
|
-
return args ? `${name} ${args}` : name;
|
|
1117
|
-
}
|
|
1118
|
-
const bashInput = marker(raw, "bash-input");
|
|
1119
|
-
if (bashInput)
|
|
1120
|
-
return stripBlocks(raw.replace(/<bash-input>[\s\S]*?<\/bash-input>/g, "")) || `! ${bashInput}`;
|
|
1121
|
-
return stripBlocks(raw);
|
|
1122
|
-
}
|
|
1123
|
-
function marker(raw, tag) {
|
|
1124
|
-
const match = raw.match(new RegExp(`<${tag}>([\\s\\S]*?)</${tag}>`));
|
|
1125
|
-
return match ? match[1].trim() : "";
|
|
1126
|
-
}
|
|
1127
|
-
function stripBlocks(raw) {
|
|
1128
|
-
return raw.replace(/<system-reminder>[\s\S]*?<\/system-reminder>/g, "").replace(/<task-notification>[\s\S]*?<\/task-notification>/g, "").replace(/<command-[^>]*>[\s\S]*?<\/command-[^>]*>/g, "").replace(/<local-command-[^>]*>[\s\S]*?<\/local-command-[^>]*>/g, "").replace(/<bash-(stdout|stderr)>[\s\S]*?<\/bash-\1>/g, "").trim();
|
|
1129
|
-
}
|
|
1130
|
-
|
|
1131
|
-
// src/commands/sessions/shared/userPromptRaw.ts
|
|
1132
|
-
var INTERRUPT_PREFIX2 = "[Request interrupted";
|
|
1133
|
-
function userPromptRaw(entry) {
|
|
1134
|
-
if (entry.isSidechain || entry.isMeta) return null;
|
|
1135
|
-
if (entry.type !== "user" || isTaskNotification(entry)) return null;
|
|
1136
|
-
const raw = promptTextOrNull(entry);
|
|
1137
|
-
if (raw === null || parseRestartNudge(raw) !== null) return null;
|
|
1138
|
-
return raw;
|
|
1139
|
-
}
|
|
1140
|
-
function isTaskNotification(entry) {
|
|
1141
|
-
return asRecord4(entry.origin)?.kind === "task-notification";
|
|
1142
|
-
}
|
|
1143
|
-
function promptTextOrNull(entry) {
|
|
1144
|
-
const content = asRecord4(entry.message)?.content;
|
|
1145
|
-
if (typeof content === "string") return isInterrupt(content) ? null : content;
|
|
1146
|
-
if (!Array.isArray(content)) return null;
|
|
1147
|
-
const parts = [];
|
|
1148
|
-
for (const block of content) {
|
|
1149
|
-
const b = asRecord4(block);
|
|
1150
|
-
if (b?.type !== "text") continue;
|
|
1151
|
-
const text = typeof b.text === "string" ? b.text : "";
|
|
1152
|
-
if (isInterrupt(text)) return null;
|
|
1153
|
-
parts.push(text);
|
|
1154
|
-
}
|
|
1155
|
-
return parts.length === 0 ? null : parts.join("\n");
|
|
1156
|
-
}
|
|
1157
|
-
function isInterrupt(value) {
|
|
1158
|
-
return value.trimStart().startsWith(INTERRUPT_PREFIX2);
|
|
1159
|
-
}
|
|
1160
|
-
function asRecord4(value) {
|
|
1161
|
-
return value && typeof value === "object" ? value : null;
|
|
1162
|
-
}
|
|
1163
|
-
|
|
1164
|
-
// src/commands/sessions/shared/renderUserPrompt.ts
|
|
1165
|
-
var MAX_LENGTH = 2048;
|
|
1166
|
-
function renderUserPrompt(entry, maxLength = MAX_LENGTH) {
|
|
1167
|
-
const raw = userPromptRaw(entry);
|
|
1168
|
-
if (raw === null) return void 0;
|
|
1169
|
-
const message2 = renderPrompt(raw);
|
|
1170
|
-
return message2 ? cap(message2, maxLength) : void 0;
|
|
1171
|
-
}
|
|
1172
|
-
function cap(message2, maxLength) {
|
|
1173
|
-
return message2.length <= maxLength ? message2 : `${message2.slice(0, maxLength).trimEnd()}\u2026`;
|
|
1174
|
-
}
|
|
1175
|
-
|
|
1176
1110
|
// src/commands/sessions/shared/toolTarget.ts
|
|
1177
1111
|
function toolTarget(input) {
|
|
1178
1112
|
if (!input || typeof input !== "object") return "";
|
|
@@ -1301,6 +1235,72 @@ function claudeAssistantEvents(content, at, resultUrls) {
|
|
|
1301
1235
|
];
|
|
1302
1236
|
}
|
|
1303
1237
|
|
|
1238
|
+
// src/commands/sessions/shared/renderPrompt.ts
|
|
1239
|
+
function renderPrompt(raw) {
|
|
1240
|
+
const command = marker(raw, "command-name");
|
|
1241
|
+
if (command) {
|
|
1242
|
+
const args = marker(raw, "command-args");
|
|
1243
|
+
const name = `/${command.replace(/^\/+/, "")}`;
|
|
1244
|
+
return args ? `${name} ${args}` : name;
|
|
1245
|
+
}
|
|
1246
|
+
const bashInput = marker(raw, "bash-input");
|
|
1247
|
+
if (bashInput)
|
|
1248
|
+
return stripBlocks(raw.replace(/<bash-input>[\s\S]*?<\/bash-input>/g, "")) || `! ${bashInput}`;
|
|
1249
|
+
return stripBlocks(raw);
|
|
1250
|
+
}
|
|
1251
|
+
function marker(raw, tag) {
|
|
1252
|
+
const match = raw.match(new RegExp(`<${tag}>([\\s\\S]*?)</${tag}>`));
|
|
1253
|
+
return match ? match[1].trim() : "";
|
|
1254
|
+
}
|
|
1255
|
+
function stripBlocks(raw) {
|
|
1256
|
+
return raw.replace(/<system-reminder>[\s\S]*?<\/system-reminder>/g, "").replace(/<task-notification>[\s\S]*?<\/task-notification>/g, "").replace(/<command-[^>]*>[\s\S]*?<\/command-[^>]*>/g, "").replace(/<local-command-[^>]*>[\s\S]*?<\/local-command-[^>]*>/g, "").replace(/<bash-(stdout|stderr)>[\s\S]*?<\/bash-\1>/g, "").trim();
|
|
1257
|
+
}
|
|
1258
|
+
|
|
1259
|
+
// src/commands/sessions/shared/userPromptRaw.ts
|
|
1260
|
+
var INTERRUPT_PREFIX2 = "[Request interrupted";
|
|
1261
|
+
function userPromptRaw(entry) {
|
|
1262
|
+
if (entry.isSidechain || entry.isMeta) return null;
|
|
1263
|
+
if (entry.type !== "user" || isTaskNotification(entry)) return null;
|
|
1264
|
+
const raw = promptTextOrNull(entry);
|
|
1265
|
+
if (raw === null || parseRestartNudge(raw) !== null) return null;
|
|
1266
|
+
return raw;
|
|
1267
|
+
}
|
|
1268
|
+
function isTaskNotification(entry) {
|
|
1269
|
+
return asRecord4(entry.origin)?.kind === "task-notification";
|
|
1270
|
+
}
|
|
1271
|
+
function promptTextOrNull(entry) {
|
|
1272
|
+
const content = asRecord4(entry.message)?.content;
|
|
1273
|
+
if (typeof content === "string") return isInterrupt(content) ? null : content;
|
|
1274
|
+
if (!Array.isArray(content)) return null;
|
|
1275
|
+
const parts = [];
|
|
1276
|
+
for (const block of content) {
|
|
1277
|
+
const b = asRecord4(block);
|
|
1278
|
+
if (b?.type !== "text") continue;
|
|
1279
|
+
const text = typeof b.text === "string" ? b.text : "";
|
|
1280
|
+
if (isInterrupt(text)) return null;
|
|
1281
|
+
parts.push(text);
|
|
1282
|
+
}
|
|
1283
|
+
return parts.length === 0 ? null : parts.join("\n");
|
|
1284
|
+
}
|
|
1285
|
+
function isInterrupt(value) {
|
|
1286
|
+
return value.trimStart().startsWith(INTERRUPT_PREFIX2);
|
|
1287
|
+
}
|
|
1288
|
+
function asRecord4(value) {
|
|
1289
|
+
return value && typeof value === "object" ? value : null;
|
|
1290
|
+
}
|
|
1291
|
+
|
|
1292
|
+
// src/commands/sessions/shared/renderUserPrompt.ts
|
|
1293
|
+
var MAX_LENGTH = 2048;
|
|
1294
|
+
function renderUserPrompt(entry, maxLength = MAX_LENGTH) {
|
|
1295
|
+
const raw = userPromptRaw(entry);
|
|
1296
|
+
if (raw === null) return void 0;
|
|
1297
|
+
const message2 = renderPrompt(raw);
|
|
1298
|
+
return message2 ? cap(message2, maxLength) : void 0;
|
|
1299
|
+
}
|
|
1300
|
+
function cap(message2, maxLength) {
|
|
1301
|
+
return message2.length <= maxLength ? message2 : `${message2.slice(0, maxLength).trimEnd()}\u2026`;
|
|
1302
|
+
}
|
|
1303
|
+
|
|
1304
1304
|
// src/commands/sessions/shared/splitShellBlocks.ts
|
|
1305
1305
|
var SHELL_BLOCK = /<bash-input>([\s\S]*?)<\/bash-input>\s*(?:<bash-stdout>([\s\S]*?)<\/bash-stdout>)?\s*(?:<bash-stderr>([\s\S]*?)<\/bash-stderr>)?/g;
|
|
1306
1306
|
function splitShellBlocks(raw) {
|
|
@@ -1328,15 +1328,8 @@ function claudeShellEvents(entry, at) {
|
|
|
1328
1328
|
};
|
|
1329
1329
|
}
|
|
1330
1330
|
|
|
1331
|
-
// src/shared/harnessAdapters/
|
|
1332
|
-
function
|
|
1333
|
-
return entry.message?.content;
|
|
1334
|
-
}
|
|
1335
|
-
function resultText2(content) {
|
|
1336
|
-
if (typeof content === "string") return content;
|
|
1337
|
-
return claudeContentBlocksOf(content).filter((block) => block.type === "text").map((block) => String(block.text ?? "")).join("\n");
|
|
1338
|
-
}
|
|
1339
|
-
function userEvents(entry, at) {
|
|
1331
|
+
// src/shared/harnessAdapters/claudeUserEvents.ts
|
|
1332
|
+
function claudeUserEvents(entry, at) {
|
|
1340
1333
|
const shell = claudeShellEvents(entry, at);
|
|
1341
1334
|
const events = shell.events;
|
|
1342
1335
|
const text = shell.textless ? void 0 : renderUserPrompt(entry, Number.POSITIVE_INFINITY);
|
|
@@ -1354,12 +1347,39 @@ function userEvents(entry, at) {
|
|
|
1354
1347
|
}
|
|
1355
1348
|
return events;
|
|
1356
1349
|
}
|
|
1350
|
+
function contentOf(entry) {
|
|
1351
|
+
return entry.message?.content;
|
|
1352
|
+
}
|
|
1353
|
+
function resultText2(content) {
|
|
1354
|
+
if (typeof content === "string") return content;
|
|
1355
|
+
return claudeContentBlocksOf(content).filter((block) => block.type === "text").map((block) => String(block.text ?? "")).join("\n");
|
|
1356
|
+
}
|
|
1357
|
+
|
|
1358
|
+
// src/shared/harnessAdapters/claudeEntryEvents.ts
|
|
1359
|
+
function contentOf2(entry) {
|
|
1360
|
+
return entry.message?.content;
|
|
1361
|
+
}
|
|
1362
|
+
function queuedPromptOf(entry) {
|
|
1363
|
+
const attachment = entry.attachment;
|
|
1364
|
+
if (attachment?.type !== "queued_command" || attachment.commandMode !== "prompt" || attachment.isMeta)
|
|
1365
|
+
return void 0;
|
|
1366
|
+
return attachment.prompt;
|
|
1367
|
+
}
|
|
1368
|
+
function attachmentEvents(entry, at) {
|
|
1369
|
+
const prompt = queuedPromptOf(entry);
|
|
1370
|
+
if (prompt === void 0) return [];
|
|
1371
|
+
return claudeUserEvents(
|
|
1372
|
+
{ type: "user", message: { role: "user", content: prompt } },
|
|
1373
|
+
at
|
|
1374
|
+
);
|
|
1375
|
+
}
|
|
1357
1376
|
function claudeEntryEvents(entry, resultUrls) {
|
|
1358
1377
|
if (entry.isSidechain || entry.isMeta) return [];
|
|
1359
1378
|
const at = typeof entry.timestamp === "string" ? entry.timestamp : void 0;
|
|
1360
|
-
if (entry.type === "user") return
|
|
1379
|
+
if (entry.type === "user") return claudeUserEvents(entry, at);
|
|
1380
|
+
if (entry.type === "attachment") return attachmentEvents(entry, at);
|
|
1361
1381
|
if (entry.type === "assistant")
|
|
1362
|
-
return claudeAssistantEvents(
|
|
1382
|
+
return claudeAssistantEvents(contentOf2(entry), at, resultUrls);
|
|
1363
1383
|
return [];
|
|
1364
1384
|
}
|
|
1365
1385
|
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import {
|
|
2
2
|
backlogPhaseActivity,
|
|
3
3
|
recordPhaseSession
|
|
4
|
-
} from "./chunk-
|
|
4
|
+
} from "./chunk-OCFSZVB4.js";
|
|
5
5
|
import {
|
|
6
6
|
resumeNudge
|
|
7
7
|
} from "./chunk-7NZOH4LN.js";
|
|
@@ -26,7 +26,7 @@ import {
|
|
|
26
26
|
} from "./chunk-MB26GQDS.js";
|
|
27
27
|
import {
|
|
28
28
|
buildPhasePrompt
|
|
29
|
-
} from "./chunk-
|
|
29
|
+
} from "./chunk-HLDM4R3D.js";
|
|
30
30
|
import {
|
|
31
31
|
getReady
|
|
32
32
|
} from "./chunk-H7AYKAJD.js";
|
|
@@ -38,7 +38,7 @@ import {
|
|
|
38
38
|
} from "./chunk-PE5ZNTLO.js";
|
|
39
39
|
import {
|
|
40
40
|
harnessAdapter
|
|
41
|
-
} from "./chunk-
|
|
41
|
+
} from "./chunk-UWECDFQ7.js";
|
|
42
42
|
import {
|
|
43
43
|
getSignalPath
|
|
44
44
|
} from "./chunk-P23ZWXGY.js";
|