@dadado/agent-kit-cli 6.21.0 → 6.22.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/dashboard/dashboard-data.mjs +325 -22
- package/dashboard/dashboard.html +63 -21
- package/dist/{add-XDGERL6L.js → add-YVDIFP4N.js} +3 -3
- package/dist/{chunk-TUEREBTR.js → chunk-2FKAKFMH.js} +1 -1
- package/dist/{chunk-7MKWNRAC.js → chunk-4SEQ76BQ.js} +3 -3
- package/dist/{chunk-IWCJ6RM6.js → chunk-5HH3HSUR.js} +2 -2
- package/dist/{chunk-NJ3JGF2O.js → chunk-BCU54M2P.js} +1 -1
- package/dist/{chunk-UATQQDVR.js → chunk-DZCLMIAS.js} +95 -1
- package/dist/{chunk-4FCK4QNB.js → chunk-EYNSSL6B.js} +92 -6
- package/dist/{chunk-DJKZLY3E.js → chunk-GT5R7W66.js} +1 -1
- package/dist/{chunk-5KF4IHXO.js → chunk-GV4VKIPO.js} +2 -2
- package/dist/{chunk-U23SLQGX.js → chunk-IESSMKOV.js} +3 -1
- package/dist/{chunk-44AVHJRV.js → chunk-LDZAK5DU.js} +1 -1
- package/dist/{chunk-5U6AGH7T.js → chunk-MGIPA6SD.js} +1 -1
- package/dist/{chunk-BTQ3D6N7.js → chunk-SDJIMC5S.js} +2 -2
- package/dist/{chunk-HMJNIIWG.js → chunk-WHBGJ7IJ.js} +3 -3
- package/dist/{chunk-FOGD3MWJ.js → chunk-XZQM55BK.js} +2 -2
- package/dist/{chunk-YXGD3FST.js → chunk-YRBRYTM5.js} +8 -8
- package/dist/{chunk-27NYWS3N.js → chunk-ZJDJCMQO.js} +4 -1
- package/dist/{chunk-DYIIOALZ.js → chunk-ZNY32NK2.js} +1 -1
- package/dist/{commands-UIV535OI.js → commands-LEBG6DMD.js} +2 -2
- package/dist/{conflicts-7T7KKQOY.js → conflicts-FJD3IVPQ.js} +1 -1
- package/dist/{contribute-2ATM22YG.js → contribute-XPAR2JER.js} +4 -4
- package/dist/{countdown-7ONIVAG6.js → countdown-25E5C7AR.js} +24 -6
- package/dist/{diff-JJH42JFA.js → diff-KFID4SX3.js} +5 -5
- package/dist/{doctor-EE3BSJC3.js → doctor-J2GJFTSE.js} +9 -9
- package/dist/{hook-KPE2EOM6.js → hook-HV6U3ANI.js} +6 -6
- package/dist/index.js +17 -17
- package/dist/{init-RTGM5G6T.js → init-47WA2SCG.js} +12 -12
- package/dist/{install-SD3H67Y2.js → install-Y63HEM4G.js} +12 -12
- package/dist/{run-S27AZ6ZE.js → run-Z2GHNVBO.js} +24 -9
- package/dist/{run-plan-OC3IF4PH.js → run-plan-XA7MYOQ3.js} +7 -3
- package/dist/{session-start-5PVH7L5K.js → session-start-PEVTDMOZ.js} +6 -6
- package/dist/{sessions-HUWIIEGD.js → sessions-6IGVH467.js} +1 -1
- package/dist/{setup-global-GGFLE6QQ.js → setup-global-KBJL7QRD.js} +6 -6
- package/dist/{status-77NJN2G4.js → status-3UGVDIO6.js} +7 -7
- package/dist/{update-26HHB5JD.js → update-4UQHGENC.js} +10 -10
- package/package.json +1 -1
|
@@ -257,6 +257,91 @@ function describeResolvedRoles(input) {
|
|
|
257
257
|
const sub = input.subworker?.model ? `, subworker ${input.subworker.model} (${input.subworker.source})` : "";
|
|
258
258
|
return `roles: worker ${input.backendId} (${input.backendSource}), model ${model}${sub}`;
|
|
259
259
|
}
|
|
260
|
+
function resolveReviewerRole(roles, externalPlanReview) {
|
|
261
|
+
const r = roles?.reviewer;
|
|
262
|
+
const legacyOn = isPlainObject(externalPlanReview) && externalPlanReview.enabled === true;
|
|
263
|
+
const fields = {
|
|
264
|
+
...r?.backend ? { backend: r.backend } : {},
|
|
265
|
+
...r?.model ? { model: r.model } : {},
|
|
266
|
+
...r?.advisorModel ? { advisorModel: r.advisorModel } : {}
|
|
267
|
+
};
|
|
268
|
+
if (r?.enabled === false || r?.scope === "off") {
|
|
269
|
+
return { scope: "off", source: "roles", ...fields };
|
|
270
|
+
}
|
|
271
|
+
const on = r?.enabled === true || legacyOn;
|
|
272
|
+
const source = r?.enabled === true ? "roles" : legacyOn ? "externalPlanReview" : "default";
|
|
273
|
+
if (!on) return { scope: "off", source, ...fields };
|
|
274
|
+
return { scope: r?.scope ?? "plan", source, ...fields };
|
|
275
|
+
}
|
|
276
|
+
function normalizeReviewModelId(raw) {
|
|
277
|
+
const id = (raw ?? "").toLowerCase().replace(/\s+/g, "").replace(/\[.*$/, "");
|
|
278
|
+
if (id === "" || id === "auto" || id === "cursor-auto" || id === "cursorauto" || id === "default")
|
|
279
|
+
return "auto";
|
|
280
|
+
return id;
|
|
281
|
+
}
|
|
282
|
+
var FAMILY_PATTERNS = [
|
|
283
|
+
[
|
|
284
|
+
"haiku",
|
|
285
|
+
/^(haiku|claude-haiku|claude-3-haiku.*|claude-3\.5-haiku.*|claude-3-5-haiku.*|claude-haiku-.*|claude-4-haiku.*|claude-4\.5-haiku.*)$/
|
|
286
|
+
],
|
|
287
|
+
[
|
|
288
|
+
"opus",
|
|
289
|
+
/^(opus|claude-opus|claude-3-opus.*|claude-opus-.*|claude-4-opus.*|claude-4\.5-opus.*)$/
|
|
290
|
+
],
|
|
291
|
+
[
|
|
292
|
+
"sonnet",
|
|
293
|
+
/^(sonnet|claude-sonnet|claude-3-sonnet.*|claude-3\.5-sonnet.*|claude-3-5-sonnet.*|claude-3-7-sonnet.*|claude-sonnet-.*|claude-4-sonnet.*|claude-4\.5-sonnet.*)$/
|
|
294
|
+
],
|
|
295
|
+
["fable", /^(fable|claude-fable|claude-fable-.*)$/],
|
|
296
|
+
["composer", /^(composer|composer-.*|cursor-composer.*)$/],
|
|
297
|
+
["grok", /^(grok|grok-.*)$/]
|
|
298
|
+
];
|
|
299
|
+
function reviewModelFamily(raw) {
|
|
300
|
+
const id = normalizeReviewModelId(raw);
|
|
301
|
+
for (const [family, pattern] of FAMILY_PATTERNS) if (pattern.test(id)) return family;
|
|
302
|
+
return id;
|
|
303
|
+
}
|
|
304
|
+
function isFamilyAlias(id, family) {
|
|
305
|
+
return id === family || id === `claude-${family}` || id === `cursor-${family}`;
|
|
306
|
+
}
|
|
307
|
+
function reviewModelRelation(implementer, reviewer) {
|
|
308
|
+
const a = normalizeReviewModelId(implementer);
|
|
309
|
+
const b = normalizeReviewModelId(reviewer);
|
|
310
|
+
if (a === b) return "identical";
|
|
311
|
+
const fa = reviewModelFamily(a);
|
|
312
|
+
const fb = reviewModelFamily(b);
|
|
313
|
+
if (fa !== fb) return "different";
|
|
314
|
+
if (isFamilyAlias(a, fa) || isFamilyAlias(b, fb)) return "identical";
|
|
315
|
+
return "same-family";
|
|
316
|
+
}
|
|
317
|
+
function describeIdenticalReviewModel(implementer, reviewer) {
|
|
318
|
+
return `reviewer model ${reviewer} is the implementer model (${implementer}): identical-model review is refused, Auto/Auto and a family alias against an id of that family included. This is not a silent self-review; set roles.reviewer.model to a different model`;
|
|
319
|
+
}
|
|
320
|
+
function describeSameFamilyReviewModel(implementer, reviewer) {
|
|
321
|
+
return `reviewer model ${reviewer} and implementer model ${implementer} are the same family (${reviewModelFamily(reviewer)}): the review runs, as a second read by a different model of one family`;
|
|
322
|
+
}
|
|
323
|
+
function resolveReviewJobRole(input) {
|
|
324
|
+
const flagBackend = input.flagBackend?.trim() ?? "";
|
|
325
|
+
const flagModel = input.flagModel?.trim() ?? "";
|
|
326
|
+
const reviewer = input.roles?.reviewer;
|
|
327
|
+
const backend = flagBackend || reviewer?.backend || "auto";
|
|
328
|
+
const backendSource = flagBackend ? "flag" : reviewer?.backend ? "config" : "default";
|
|
329
|
+
const model = flagModel || (flagBackend ? "" : reviewer?.model ?? "");
|
|
330
|
+
const out = {
|
|
331
|
+
backend,
|
|
332
|
+
backendSource,
|
|
333
|
+
...model ? { model, modelSource: flagModel ? "flag" : "config" } : {}
|
|
334
|
+
};
|
|
335
|
+
const implementer = input.roles?.worker?.model;
|
|
336
|
+
if (model && implementer) {
|
|
337
|
+
const relation = reviewModelRelation(implementer, model);
|
|
338
|
+
if (relation === "identical") out.refusal = describeIdenticalReviewModel(implementer, model);
|
|
339
|
+
else if (relation === "same-family") {
|
|
340
|
+
out.warning = describeSameFamilyReviewModel(implementer, model);
|
|
341
|
+
}
|
|
342
|
+
}
|
|
343
|
+
return out;
|
|
344
|
+
}
|
|
260
345
|
function checkPlanRoleOverrides(plan) {
|
|
261
346
|
if (plan.workerBackend && !isRequestedBackend(plan.workerBackend.toLowerCase())) {
|
|
262
347
|
return `plan frontmatter worker_backend must be auto or a kit backend id (got ${JSON.stringify(plan.workerBackend)})`;
|
|
@@ -284,7 +369,12 @@ async function loadRolesContext(root, usePlan) {
|
|
|
284
369
|
if (problem) return { ok: false, error: `${planPath}: ${problem}` };
|
|
285
370
|
}
|
|
286
371
|
}
|
|
287
|
-
return {
|
|
372
|
+
return {
|
|
373
|
+
ok: true,
|
|
374
|
+
roles: parsed.roles,
|
|
375
|
+
plan,
|
|
376
|
+
reviewer: resolveReviewerRole(parsed.roles, config?.externalPlanReview)
|
|
377
|
+
};
|
|
288
378
|
}
|
|
289
379
|
|
|
290
380
|
export {
|
|
@@ -293,5 +383,9 @@ export {
|
|
|
293
383
|
resolveWorkerRole,
|
|
294
384
|
resolveSubworkerModel,
|
|
295
385
|
describeResolvedRoles,
|
|
386
|
+
reviewModelRelation,
|
|
387
|
+
describeIdenticalReviewModel,
|
|
388
|
+
describeSameFamilyReviewModel,
|
|
389
|
+
resolveReviewJobRole,
|
|
296
390
|
loadRolesContext
|
|
297
391
|
};
|
|
@@ -24,10 +24,17 @@ import {
|
|
|
24
24
|
} from "./chunk-DTSL2RH7.js";
|
|
25
25
|
import {
|
|
26
26
|
CLAUDE_SUBAGENT_MODEL_ENV,
|
|
27
|
+
describeIdenticalReviewModel,
|
|
27
28
|
describeResolvedRoles,
|
|
29
|
+
describeSameFamilyReviewModel,
|
|
28
30
|
readPlanRoleOverrides,
|
|
29
|
-
resolveSubworkerModel
|
|
30
|
-
|
|
31
|
+
resolveSubworkerModel,
|
|
32
|
+
reviewModelRelation
|
|
33
|
+
} from "./chunk-DZCLMIAS.js";
|
|
34
|
+
import {
|
|
35
|
+
REVIEW_BACKENDS,
|
|
36
|
+
runReviewJob
|
|
37
|
+
} from "./chunk-IESSMKOV.js";
|
|
31
38
|
import {
|
|
32
39
|
countPendingTodos,
|
|
33
40
|
findActivePlanFile,
|
|
@@ -36,6 +43,9 @@ import {
|
|
|
36
43
|
resolveActivePlanFromHandoff,
|
|
37
44
|
resolveActivePlanPath
|
|
38
45
|
} from "./chunk-7ABY6DYH.js";
|
|
46
|
+
import {
|
|
47
|
+
detectAgentBackend
|
|
48
|
+
} from "./chunk-C4LCOOL4.js";
|
|
39
49
|
import {
|
|
40
50
|
classifyGateExit,
|
|
41
51
|
landGateExit
|
|
@@ -503,6 +513,8 @@ async function armExternalPlanReview(root, options = {}) {
|
|
|
503
513
|
}
|
|
504
514
|
log("Plan exhausted: arming optional external plan review (opt-in handled by script)...");
|
|
505
515
|
const args = force ? [scriptPath, "--force", "--print"] : [scriptPath, "--print"];
|
|
516
|
+
const implementerModel = options.implementerModel?.trim();
|
|
517
|
+
if (implementerModel) args.push("--implementer-model", implementerModel);
|
|
506
518
|
return new Promise((resolve) => {
|
|
507
519
|
const child = spawnFn("bash", args, {
|
|
508
520
|
cwd: root,
|
|
@@ -1109,6 +1121,68 @@ async function runPlanLoop(opts) {
|
|
|
1109
1121
|
let backend = opts.backend;
|
|
1110
1122
|
let limitSwitched = false;
|
|
1111
1123
|
const rolesWarned = /* @__PURE__ */ new Set();
|
|
1124
|
+
let implementerModel = opts.model;
|
|
1125
|
+
const reviewAfterTick = async (tickBackend, tickModel) => {
|
|
1126
|
+
const reviewer = opts.roles?.reviewer;
|
|
1127
|
+
const proceed = { stop: false, exitCode: 0 };
|
|
1128
|
+
if (reviewer?.scope !== "tick") return proceed;
|
|
1129
|
+
const warnOnce = (line) => {
|
|
1130
|
+
if (rolesWarned.has(line)) return;
|
|
1131
|
+
rolesWarned.add(line);
|
|
1132
|
+
say(`roles: ${line}`, "warn");
|
|
1133
|
+
};
|
|
1134
|
+
const relation = reviewModelRelation(tickModel, reviewer.model);
|
|
1135
|
+
if (relation === "identical") {
|
|
1136
|
+
warnOnce(
|
|
1137
|
+
`post-tick review skipped: ${describeIdenticalReviewModel(tickModel ?? "auto", reviewer.model ?? "auto")}`
|
|
1138
|
+
);
|
|
1139
|
+
return proceed;
|
|
1140
|
+
}
|
|
1141
|
+
if (relation === "same-family") {
|
|
1142
|
+
warnOnce(describeSameFamilyReviewModel(tickModel ?? "auto", reviewer.model ?? "auto"));
|
|
1143
|
+
}
|
|
1144
|
+
const requested = reviewer.backend && reviewer.backend !== "auto" ? reviewer.backend : reviewer.backend !== "auto" && REVIEW_BACKENDS.includes(tickBackend) ? tickBackend : "auto";
|
|
1145
|
+
const detected = await (opts.tickReview?.detect ?? detectAgentBackend)(requested);
|
|
1146
|
+
if (!detected.ok) {
|
|
1147
|
+
say(`roles: post-tick review not run: ${detected.message}`, "warn");
|
|
1148
|
+
return proceed;
|
|
1149
|
+
}
|
|
1150
|
+
say(
|
|
1151
|
+
`roles: reviewer ${detected.id}, model ${reviewer.model ?? "(backend default)"} (scope tick) after tick ${tick}`
|
|
1152
|
+
);
|
|
1153
|
+
let result;
|
|
1154
|
+
try {
|
|
1155
|
+
result = await (opts.tickReview?.run ?? runReviewJob)({
|
|
1156
|
+
root: opts.root,
|
|
1157
|
+
backendId: detected.id,
|
|
1158
|
+
bin: detected.bin,
|
|
1159
|
+
...reviewer.model ? { model: reviewer.model } : {},
|
|
1160
|
+
noHitl: true,
|
|
1161
|
+
dryRun: false,
|
|
1162
|
+
log: (line) => say(line),
|
|
1163
|
+
...driver ? { render: { feed: () => {
|
|
1164
|
+
}, end: () => {
|
|
1165
|
+
} } } : {},
|
|
1166
|
+
// The review session is this run's live agent while it runs: the
|
|
1167
|
+
// lease names it and a host signal (driver mode) is forwarded to it.
|
|
1168
|
+
onSpawn: (info) => {
|
|
1169
|
+
lease?.setAgent(info.pid);
|
|
1170
|
+
tickAgent = info.pid === void 0 ? null : { pid: info.pid, start: procStart(info.pid) };
|
|
1171
|
+
}
|
|
1172
|
+
});
|
|
1173
|
+
} catch (err) {
|
|
1174
|
+
tickAgent = null;
|
|
1175
|
+
say(`roles: post-tick review failed to run: ${String(err)}`, "warn");
|
|
1176
|
+
return proceed;
|
|
1177
|
+
}
|
|
1178
|
+
tickAgent = null;
|
|
1179
|
+
if (result.error) {
|
|
1180
|
+
say(`roles: post-tick review not run: ${result.error}`, "warn");
|
|
1181
|
+
return proceed;
|
|
1182
|
+
}
|
|
1183
|
+
if (result.outcome !== "landed") return proceed;
|
|
1184
|
+
return { stop: true, exitCode: result.exitCode };
|
|
1185
|
+
};
|
|
1112
1186
|
const stopRequested = () => {
|
|
1113
1187
|
if (!driver?.reader.stopRequested()) return false;
|
|
1114
1188
|
const msg = `Stop requested by the driver (stop_after_tick) - stopping after tick ${ticksRun}. The plan is as the tick left it.`;
|
|
@@ -1187,6 +1261,7 @@ async function runPlanLoop(opts) {
|
|
|
1187
1261
|
try {
|
|
1188
1262
|
const switched = backend !== opts.backend;
|
|
1189
1263
|
const tickModel = switched && opts.roles && opts.roles.modelSource !== "flag" ? void 0 : opts.model;
|
|
1264
|
+
implementerModel = tickModel;
|
|
1190
1265
|
let tickEnv;
|
|
1191
1266
|
if (opts.roles) {
|
|
1192
1267
|
const planOverrides = readPlanRoleOverrides(await readPlan(planPath).catch(() => ""));
|
|
@@ -1343,6 +1418,17 @@ async function runPlanLoop(opts) {
|
|
|
1343
1418
|
banners.tickEnd(`pending: ${after}`);
|
|
1344
1419
|
}
|
|
1345
1420
|
endTick(after, sentinel);
|
|
1421
|
+
const review = await reviewAfterTick(backend.id, implementerModel);
|
|
1422
|
+
if (review.stop) {
|
|
1423
|
+
const msg = `Post-tick review landed a gate exit after tick ${tick} - stopping. Read the ticket before the next tick.`;
|
|
1424
|
+
if (banners) banners.stop(msg);
|
|
1425
|
+
else say(msg);
|
|
1426
|
+
if (sentinel.kind === "stop") stopReason = sentinel.reason;
|
|
1427
|
+
if (after === 0) planExhausted = true;
|
|
1428
|
+
exitCode = review.exitCode;
|
|
1429
|
+
endReason = "review findings landed; gate exit pending";
|
|
1430
|
+
break;
|
|
1431
|
+
}
|
|
1346
1432
|
if (sentinel.kind === "continue") {
|
|
1347
1433
|
} else if (sentinel.kind === "stop") {
|
|
1348
1434
|
say(`Agent requested stop: ${formatSentinelLine(sentinel)}`);
|
|
@@ -1390,10 +1476,10 @@ async function runPlanLoop(opts) {
|
|
|
1390
1476
|
`Loop finished after ${tick} tick(s). Pending now: ${pendingNow}. Logs in ${path4.relative(opts.root, logDir)}/`
|
|
1391
1477
|
);
|
|
1392
1478
|
if (planExhausted || shouldArmExternalPlanReview({ pending: pendingNow, stopReason })) {
|
|
1393
|
-
await armExternalPlanReview(
|
|
1394
|
-
|
|
1395
|
-
|
|
1396
|
-
);
|
|
1479
|
+
await armExternalPlanReview(opts.root, {
|
|
1480
|
+
...driver ? { log: (line) => say(line), writeOut: driver.writeErr } : {},
|
|
1481
|
+
...implementerModel ? { implementerModel } : {}
|
|
1482
|
+
});
|
|
1397
1483
|
}
|
|
1398
1484
|
await landIfNeeded(exitCode, endReason || "stopped", pendingNow);
|
|
1399
1485
|
return finishRun(exitCode, endReason || "stopped", pendingNow, planExhausted);
|
|
@@ -24,13 +24,13 @@ import {
|
|
|
24
24
|
} from "./chunk-HAFRAXGV.js";
|
|
25
25
|
import {
|
|
26
26
|
stampLastCheckedAt
|
|
27
|
-
} from "./chunk-
|
|
27
|
+
} from "./chunk-5HH3HSUR.js";
|
|
28
28
|
import {
|
|
29
29
|
loadContextConfig
|
|
30
30
|
} from "./chunk-PFEUZXVT.js";
|
|
31
31
|
import {
|
|
32
32
|
MANIFEST_RELATIVE_PATH
|
|
33
|
-
} from "./chunk-
|
|
33
|
+
} from "./chunk-LDZAK5DU.js";
|
|
34
34
|
import {
|
|
35
35
|
HANDOFF_REL
|
|
36
36
|
} from "./chunk-C4Q77GGJ.js";
|
|
@@ -419,7 +419,9 @@ async function runReviewJob(input) {
|
|
|
419
419
|
logPath,
|
|
420
420
|
readOnly: true,
|
|
421
421
|
hitl: { policy: input.noHitl ? "off" : "prompt" },
|
|
422
|
-
log: (line) => say(line)
|
|
422
|
+
log: (line) => say(line),
|
|
423
|
+
...input.render ? { render: input.render } : {},
|
|
424
|
+
...input.onSpawn ? { onSpawn: input.onSpawn } : {}
|
|
423
425
|
});
|
|
424
426
|
for (const line of formatHitlSummary(result.hitl)) say(line);
|
|
425
427
|
exitCode = hitlExitCode(result.exitCode, result.hitl);
|
|
@@ -4,10 +4,10 @@ import {
|
|
|
4
4
|
import {
|
|
5
5
|
compareSemver,
|
|
6
6
|
normalizeSemver
|
|
7
|
-
} from "./chunk-
|
|
7
|
+
} from "./chunk-5HH3HSUR.js";
|
|
8
8
|
import {
|
|
9
9
|
MANIFEST_RELATIVE_PATH
|
|
10
|
-
} from "./chunk-
|
|
10
|
+
} from "./chunk-LDZAK5DU.js";
|
|
11
11
|
import {
|
|
12
12
|
KIT_VERSION,
|
|
13
13
|
pinnedCliSpec
|
|
@@ -2,7 +2,7 @@ import {
|
|
|
2
2
|
compareSemver,
|
|
3
3
|
normalizeSemver,
|
|
4
4
|
readLocalKitVersion
|
|
5
|
-
} from "./chunk-
|
|
5
|
+
} from "./chunk-5HH3HSUR.js";
|
|
6
6
|
import {
|
|
7
7
|
L0_ARTIFACTS
|
|
8
8
|
} from "./chunk-WS6OX2IG.js";
|
|
@@ -15,11 +15,11 @@ import {
|
|
|
15
15
|
mergeStats,
|
|
16
16
|
recordOutcome,
|
|
17
17
|
resolveProtectedGlobs
|
|
18
|
-
} from "./chunk-
|
|
18
|
+
} from "./chunk-LDZAK5DU.js";
|
|
19
19
|
import {
|
|
20
20
|
loadManagedHashLedger,
|
|
21
21
|
saveManagedHashLedger
|
|
22
|
-
} from "./chunk-
|
|
22
|
+
} from "./chunk-ZJDJCMQO.js";
|
|
23
23
|
import {
|
|
24
24
|
KIT_PACKAGE_SPEC,
|
|
25
25
|
KIT_VERSION
|
|
@@ -4,11 +4,11 @@ import {
|
|
|
4
4
|
RESOLVE_AGENT_KIT_REL,
|
|
5
5
|
SESSION_START_HOOK_MARKER,
|
|
6
6
|
mergeAllowRowsWithoutGuard
|
|
7
|
-
} from "./chunk-
|
|
7
|
+
} from "./chunk-MGIPA6SD.js";
|
|
8
8
|
import {
|
|
9
9
|
CLAUDE_COMMANDS_DIR_REL,
|
|
10
10
|
discoverInstalledCommands
|
|
11
|
-
} from "./chunk-
|
|
11
|
+
} from "./chunk-2FKAKFMH.js";
|
|
12
12
|
import {
|
|
13
13
|
findOnPath
|
|
14
14
|
} from "./chunk-WGLPZXNU.js";
|
|
@@ -6,7 +6,7 @@ import {
|
|
|
6
6
|
formatStaleCliRefusal,
|
|
7
7
|
installL0,
|
|
8
8
|
syncFromManifest
|
|
9
|
-
} from "./chunk-
|
|
9
|
+
} from "./chunk-WHBGJ7IJ.js";
|
|
10
10
|
import {
|
|
11
11
|
SkippedSymlinkError,
|
|
12
12
|
formatPersonalizationSkippedSymlinks,
|
|
@@ -15,21 +15,21 @@ import {
|
|
|
15
15
|
import {
|
|
16
16
|
REGISTRY_CLI_ARGS,
|
|
17
17
|
resolveRegistryFromCli
|
|
18
|
-
} from "./chunk-
|
|
18
|
+
} from "./chunk-BCU54M2P.js";
|
|
19
19
|
import {
|
|
20
20
|
assessClaudeCommandAdapters,
|
|
21
21
|
executeSafeReadinessFixes
|
|
22
|
-
} from "./chunk-
|
|
22
|
+
} from "./chunk-XZQM55BK.js";
|
|
23
23
|
import {
|
|
24
24
|
writeReadinessSnapshot
|
|
25
25
|
} from "./chunk-HAFRAXGV.js";
|
|
26
26
|
import {
|
|
27
27
|
writeClaudeSessionStartHook
|
|
28
|
-
} from "./chunk-
|
|
28
|
+
} from "./chunk-MGIPA6SD.js";
|
|
29
29
|
import {
|
|
30
30
|
CLAUDE_HITL_FALLBACK,
|
|
31
31
|
generateClaudeCommandAdapters
|
|
32
|
-
} from "./chunk-
|
|
32
|
+
} from "./chunk-2FKAKFMH.js";
|
|
33
33
|
import {
|
|
34
34
|
shouldUseWelcomeColor,
|
|
35
35
|
withCliProgress
|
|
@@ -56,13 +56,13 @@ import {
|
|
|
56
56
|
npxPinned,
|
|
57
57
|
pathCliStatus,
|
|
58
58
|
syncPathCliToRuntime
|
|
59
|
-
} from "./chunk-
|
|
59
|
+
} from "./chunk-SDJIMC5S.js";
|
|
60
60
|
import {
|
|
61
61
|
assessEnvironment
|
|
62
62
|
} from "./chunk-B3VR5YBQ.js";
|
|
63
63
|
import {
|
|
64
64
|
warnIfRunningCliBehindNpm
|
|
65
|
-
} from "./chunk-
|
|
65
|
+
} from "./chunk-5HH3HSUR.js";
|
|
66
66
|
import {
|
|
67
67
|
DOMAIN_PACK_IDS,
|
|
68
68
|
allPacks,
|
|
@@ -79,7 +79,7 @@ import {
|
|
|
79
79
|
resolveProtectedGlobs,
|
|
80
80
|
saveManifest,
|
|
81
81
|
skillTargetDir
|
|
82
|
-
} from "./chunk-
|
|
82
|
+
} from "./chunk-LDZAK5DU.js";
|
|
83
83
|
import {
|
|
84
84
|
KIT_VERSION,
|
|
85
85
|
pinnedCliSpec
|
|
@@ -472,7 +472,10 @@ var KNOWN_SHIPPED_OVERLAY_HASHES = /* @__PURE__ */ new Set([
|
|
|
472
472
|
"afde6839f7d35fbfdddee85068252e1f5187b0caf3e29728b31e1ce81dea1f83",
|
|
473
473
|
"d0f95082a50d53b5b8fd33c55c538ce8104a1be5439e4bc596cbe35e22a4e5c5",
|
|
474
474
|
"27dc66786d9071f30fc5068a7b3a1ed5c2c904a26f928f311e33432ac5b6571b",
|
|
475
|
-
"b2fb21604ca3cdc4f42a48a6f29873a41ca7decad7133419c982a4a340f733b3"
|
|
475
|
+
"b2fb21604ca3cdc4f42a48a6f29873a41ca7decad7133419c982a4a340f733b3",
|
|
476
|
+
"48b3aae36a8baf10d5dcc5a9de441c93782835ce8b87c7e09e0971101c6f1614",
|
|
477
|
+
"82e65afe6d183e9dcad0fbc6c60d381eee4e854e7ddffff56d1996b0f86886bd",
|
|
478
|
+
"9b3e6543d8b3cda4a9a5fe39f3d205b9d466fa7f9a466fd51c0cccf354065a7e"
|
|
476
479
|
]);
|
|
477
480
|
|
|
478
481
|
// src/lifecycle/paths.ts
|
|
@@ -7,14 +7,14 @@ import "./chunk-P7732A25.js";
|
|
|
7
7
|
import {
|
|
8
8
|
CURSOR_COMMANDS_DIR_REL,
|
|
9
9
|
discoverInstalledCommands
|
|
10
|
-
} from "./chunk-
|
|
10
|
+
} from "./chunk-2FKAKFMH.js";
|
|
11
11
|
import "./chunk-WGLPZXNU.js";
|
|
12
12
|
import "./chunk-Q35TWISF.js";
|
|
13
13
|
import "./chunk-QTON2GQX.js";
|
|
14
14
|
import {
|
|
15
15
|
L0_ARTIFACTS
|
|
16
16
|
} from "./chunk-WS6OX2IG.js";
|
|
17
|
-
import "./chunk-
|
|
17
|
+
import "./chunk-ZJDJCMQO.js";
|
|
18
18
|
import {
|
|
19
19
|
KIT_VERSION
|
|
20
20
|
} from "./chunk-7HDQEK6T.js";
|
|
@@ -1,21 +1,21 @@
|
|
|
1
1
|
import {
|
|
2
2
|
REGISTRY_CLI_ARGS,
|
|
3
3
|
resolveRegistryFromCli
|
|
4
|
-
} from "./chunk-
|
|
4
|
+
} from "./chunk-BCU54M2P.js";
|
|
5
5
|
import {
|
|
6
6
|
logger
|
|
7
7
|
} from "./chunk-ZB43YMHW.js";
|
|
8
8
|
import {
|
|
9
9
|
managedPairs
|
|
10
|
-
} from "./chunk-
|
|
10
|
+
} from "./chunk-ZNY32NK2.js";
|
|
11
11
|
import "./chunk-WS6OX2IG.js";
|
|
12
12
|
import {
|
|
13
13
|
loadAgentKitManifest,
|
|
14
14
|
normalizeRelPath
|
|
15
|
-
} from "./chunk-
|
|
15
|
+
} from "./chunk-LDZAK5DU.js";
|
|
16
16
|
import {
|
|
17
17
|
resolveContained
|
|
18
|
-
} from "./chunk-
|
|
18
|
+
} from "./chunk-ZJDJCMQO.js";
|
|
19
19
|
import "./chunk-C4Q77GGJ.js";
|
|
20
20
|
import "./chunk-5B4DVO6C.js";
|
|
21
21
|
|
|
@@ -1,14 +1,15 @@
|
|
|
1
|
+
import {
|
|
2
|
+
loadRolesContext,
|
|
3
|
+
resolveReviewJobRole,
|
|
4
|
+
resolveWorkerRole
|
|
5
|
+
} from "./chunk-DZCLMIAS.js";
|
|
1
6
|
import {
|
|
2
7
|
REVIEW_BACKENDS,
|
|
3
8
|
REVIEW_PACK_DEFAULT_MAX_BYTES,
|
|
4
9
|
REVIEW_PACK_SLASH,
|
|
5
10
|
parseReviewPackMaxBytes,
|
|
6
11
|
reviewBackendMessage
|
|
7
|
-
} from "./chunk-
|
|
8
|
-
import {
|
|
9
|
-
loadRolesContext,
|
|
10
|
-
resolveWorkerRole
|
|
11
|
-
} from "./chunk-UATQQDVR.js";
|
|
12
|
+
} from "./chunk-IESSMKOV.js";
|
|
12
13
|
import "./chunk-7ABY6DYH.js";
|
|
13
14
|
import {
|
|
14
15
|
detectAgentBackend,
|
|
@@ -291,6 +292,23 @@ async function executeCountdown(input) {
|
|
|
291
292
|
rolesNotes.push(
|
|
292
293
|
`roles: worker ${worker.backend} (${worker.backendSource}), model ${worker.model ? `${worker.model} (${worker.modelSource})` : "backend default"}`
|
|
293
294
|
);
|
|
295
|
+
} else if (job === "review") {
|
|
296
|
+
const ctx = await loadRolesContext(root, false);
|
|
297
|
+
if (!ctx.ok) return usage(ctx.error);
|
|
298
|
+
const review = resolveReviewJobRole({
|
|
299
|
+
flagBackend: input.backend,
|
|
300
|
+
flagModel: input.model,
|
|
301
|
+
roles: ctx.roles
|
|
302
|
+
});
|
|
303
|
+
if (review.refusal) return usage(review.refusal);
|
|
304
|
+
backendRequest = review.backend;
|
|
305
|
+
model = review.model;
|
|
306
|
+
if (review.warning) rolesNotes.push(`roles: ${review.warning}`);
|
|
307
|
+
if (review.backendSource === "config" || review.modelSource === "config") {
|
|
308
|
+
rolesNotes.push(
|
|
309
|
+
`roles: reviewer ${review.backend} (${review.backendSource}), model ${review.model ? `${review.model} (${review.modelSource})` : "backend default"}`
|
|
310
|
+
);
|
|
311
|
+
}
|
|
294
312
|
}
|
|
295
313
|
const detected = await detectAgentBackend(backendRequest, input.whichFn);
|
|
296
314
|
if (!detected.ok) return usage(detected.message);
|
|
@@ -440,7 +458,7 @@ var countdownCommand = defineCommand({
|
|
|
440
458
|
},
|
|
441
459
|
backend: {
|
|
442
460
|
type: "string",
|
|
443
|
-
description: `Agent backend (${listDetectBackendIds().join(" | ")}; default: auto; the tick job reads plan worker_backend and config roles.worker first)`,
|
|
461
|
+
description: `Agent backend (${listDetectBackendIds().join(" | ")}; default: auto; the tick job reads plan worker_backend and config roles.worker first, the review job config roles.reviewer)`,
|
|
444
462
|
default: ""
|
|
445
463
|
},
|
|
446
464
|
model: {
|
|
@@ -1,20 +1,20 @@
|
|
|
1
1
|
import {
|
|
2
2
|
REGISTRY_CLI_ARGS,
|
|
3
3
|
resolveRegistryFromCli
|
|
4
|
-
} from "./chunk-
|
|
4
|
+
} from "./chunk-BCU54M2P.js";
|
|
5
5
|
import {
|
|
6
6
|
logger
|
|
7
7
|
} from "./chunk-ZB43YMHW.js";
|
|
8
8
|
import {
|
|
9
9
|
diffAgainstRegistry,
|
|
10
10
|
summarizeDiff
|
|
11
|
-
} from "./chunk-
|
|
12
|
-
import "./chunk-
|
|
11
|
+
} from "./chunk-4SEQ76BQ.js";
|
|
12
|
+
import "./chunk-ZNY32NK2.js";
|
|
13
13
|
import "./chunk-WS6OX2IG.js";
|
|
14
14
|
import {
|
|
15
15
|
loadAgentKitManifest
|
|
16
|
-
} from "./chunk-
|
|
17
|
-
import "./chunk-
|
|
16
|
+
} from "./chunk-LDZAK5DU.js";
|
|
17
|
+
import "./chunk-ZJDJCMQO.js";
|
|
18
18
|
import "./chunk-C4Q77GGJ.js";
|
|
19
19
|
import "./chunk-5B4DVO6C.js";
|
|
20
20
|
|
|
@@ -2,12 +2,12 @@ import {
|
|
|
2
2
|
assessHooksHealth,
|
|
3
3
|
executeSafeReadinessFixes,
|
|
4
4
|
refreshRepositoryProfile
|
|
5
|
-
} from "./chunk-
|
|
5
|
+
} from "./chunk-XZQM55BK.js";
|
|
6
6
|
import {
|
|
7
7
|
writeReadinessSnapshot
|
|
8
8
|
} from "./chunk-HAFRAXGV.js";
|
|
9
|
-
import "./chunk-
|
|
10
|
-
import "./chunk-
|
|
9
|
+
import "./chunk-MGIPA6SD.js";
|
|
10
|
+
import "./chunk-2FKAKFMH.js";
|
|
11
11
|
import "./chunk-WGLPZXNU.js";
|
|
12
12
|
import "./chunk-Q35TWISF.js";
|
|
13
13
|
import {
|
|
@@ -16,7 +16,7 @@ import {
|
|
|
16
16
|
import {
|
|
17
17
|
detectWorkspaceParent,
|
|
18
18
|
workspaceParentAdvisoryLines
|
|
19
|
-
} from "./chunk-
|
|
19
|
+
} from "./chunk-GT5R7W66.js";
|
|
20
20
|
import {
|
|
21
21
|
createReadinessReport
|
|
22
22
|
} from "./chunk-PNFF6OU3.js";
|
|
@@ -33,13 +33,13 @@ import {
|
|
|
33
33
|
} from "./chunk-B3VR5YBQ.js";
|
|
34
34
|
import {
|
|
35
35
|
warnIfRunningCliBehindNpm
|
|
36
|
-
} from "./chunk-
|
|
36
|
+
} from "./chunk-5HH3HSUR.js";
|
|
37
37
|
import "./chunk-PFEUZXVT.js";
|
|
38
|
-
import "./chunk-
|
|
39
|
-
import "./chunk-
|
|
38
|
+
import "./chunk-4SEQ76BQ.js";
|
|
39
|
+
import "./chunk-ZNY32NK2.js";
|
|
40
40
|
import "./chunk-WS6OX2IG.js";
|
|
41
|
-
import "./chunk-
|
|
42
|
-
import "./chunk-
|
|
41
|
+
import "./chunk-LDZAK5DU.js";
|
|
42
|
+
import "./chunk-ZJDJCMQO.js";
|
|
43
43
|
import {
|
|
44
44
|
KIT_VERSION
|
|
45
45
|
} from "./chunk-7HDQEK6T.js";
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import {
|
|
2
2
|
buildSessionStartAdditionalContext,
|
|
3
3
|
resolveSessionRoot
|
|
4
|
-
} from "./chunk-
|
|
4
|
+
} from "./chunk-GV4VKIPO.js";
|
|
5
5
|
import "./chunk-2YU2H7I6.js";
|
|
6
6
|
import {
|
|
7
7
|
readStdinJson
|
|
@@ -13,13 +13,13 @@ import "./chunk-4CRBUEJ6.js";
|
|
|
13
13
|
import "./chunk-L5V3W3DY.js";
|
|
14
14
|
import "./chunk-MUTTNRX4.js";
|
|
15
15
|
import "./chunk-HAFRAXGV.js";
|
|
16
|
-
import "./chunk-
|
|
16
|
+
import "./chunk-5HH3HSUR.js";
|
|
17
17
|
import "./chunk-PFEUZXVT.js";
|
|
18
|
-
import "./chunk-
|
|
19
|
-
import "./chunk-
|
|
18
|
+
import "./chunk-4SEQ76BQ.js";
|
|
19
|
+
import "./chunk-ZNY32NK2.js";
|
|
20
20
|
import "./chunk-WS6OX2IG.js";
|
|
21
|
-
import "./chunk-
|
|
22
|
-
import "./chunk-
|
|
21
|
+
import "./chunk-LDZAK5DU.js";
|
|
22
|
+
import "./chunk-ZJDJCMQO.js";
|
|
23
23
|
import "./chunk-7HDQEK6T.js";
|
|
24
24
|
import "./chunk-C4Q77GGJ.js";
|
|
25
25
|
import "./chunk-5B4DVO6C.js";
|