@odla-ai/cli 0.46.11 → 0.46.12
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/bin.cjs +72 -16
- package/dist/bin.cjs.map +1 -1
- package/dist/bin.js +1 -1
- package/dist/{chunk-J6GIGX6T.js → chunk-Q4BGAUEH.js} +66 -10
- package/dist/chunk-Q4BGAUEH.js.map +1 -0
- package/dist/{cli-BI26ENP4.js → cli-5CDFI4AY.js} +2 -2
- package/dist/index.cjs +65 -9
- package/dist/index.cjs.map +1 -1
- package/dist/index.js +1 -1
- package/package.json +1 -1
- package/dist/chunk-J6GIGX6T.js.map +0 -1
- /package/dist/{cli-BI26ENP4.js.map → cli-5CDFI4AY.js.map} +0 -0
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
2
|
import {
|
|
3
3
|
runCli
|
|
4
|
-
} from "./chunk-
|
|
4
|
+
} from "./chunk-Q4BGAUEH.js";
|
|
5
5
|
import {
|
|
6
6
|
exitCodeFor
|
|
7
7
|
} from "./chunk-5MEO3BVF.js";
|
|
@@ -9,4 +9,4 @@ export {
|
|
|
9
9
|
exitCodeFor,
|
|
10
10
|
runCli
|
|
11
11
|
};
|
|
12
|
-
//# sourceMappingURL=cli-
|
|
12
|
+
//# sourceMappingURL=cli-5CDFI4AY.js.map
|
package/dist/index.cjs
CHANGED
|
@@ -6119,10 +6119,10 @@ var import_node_fs16 = require("fs");
|
|
|
6119
6119
|
var import_node_os5 = require("os");
|
|
6120
6120
|
var import_node_path16 = require("path");
|
|
6121
6121
|
|
|
6122
|
-
// ../harness/dist/chunk-
|
|
6122
|
+
// ../harness/dist/chunk-I43KTCJ2.js
|
|
6123
6123
|
var HARNESS_PROTOCOL_VERSION = 1;
|
|
6124
6124
|
|
|
6125
|
-
// ../harness/dist/chunk-
|
|
6125
|
+
// ../harness/dist/chunk-HDIR4MM5.js
|
|
6126
6126
|
var import_child_process = require("child_process");
|
|
6127
6127
|
var import_fs = require("fs");
|
|
6128
6128
|
var import_promises2 = require("fs/promises");
|
|
@@ -6495,7 +6495,7 @@ async function stageWorkspacePair(baselineSource, workspaceSource, options = {})
|
|
|
6495
6495
|
}
|
|
6496
6496
|
}
|
|
6497
6497
|
|
|
6498
|
-
// ../harness/dist/chunk-
|
|
6498
|
+
// ../harness/dist/chunk-4EPJJMFG.js
|
|
6499
6499
|
var import_crypto = require("crypto");
|
|
6500
6500
|
var import_promises5 = require("fs/promises");
|
|
6501
6501
|
var import_path5 = require("path");
|
|
@@ -6832,7 +6832,7 @@ function validateSnapshot(snapshot, limits) {
|
|
|
6832
6832
|
}
|
|
6833
6833
|
}
|
|
6834
6834
|
|
|
6835
|
-
// ../harness/dist/chunk-
|
|
6835
|
+
// ../harness/dist/chunk-4EPJJMFG.js
|
|
6836
6836
|
var import_child_process4 = require("child_process");
|
|
6837
6837
|
var import_promises6 = require("fs/promises");
|
|
6838
6838
|
var import_path6 = require("path");
|
|
@@ -7136,7 +7136,7 @@ function looksLikeDestination(value2) {
|
|
|
7136
7136
|
return /^(?:[a-z][a-z0-9+.-]*:\/\/|\/|\\\\)/i.test(text4) || /^[\w.-]+\.[a-z]{2,}(?:[/:]|$)/i.test(text4);
|
|
7137
7137
|
}
|
|
7138
7138
|
|
|
7139
|
-
// ../harness/dist/chunk-
|
|
7139
|
+
// ../harness/dist/chunk-4EPJJMFG.js
|
|
7140
7140
|
var import_promises10 = require("fs/promises");
|
|
7141
7141
|
var import_promises11 = require("fs/promises");
|
|
7142
7142
|
var import_path10 = require("path");
|
|
@@ -7404,7 +7404,7 @@ async function buildCodeGraph(input) {
|
|
|
7404
7404
|
return builder.build();
|
|
7405
7405
|
}
|
|
7406
7406
|
|
|
7407
|
-
// ../harness/dist/chunk-
|
|
7407
|
+
// ../harness/dist/chunk-4EPJJMFG.js
|
|
7408
7408
|
var import_crypto4 = require("crypto");
|
|
7409
7409
|
async function digestStagedWorkspace(root, limits) {
|
|
7410
7410
|
const files = [];
|
|
@@ -10047,6 +10047,55 @@ function codeRuntimeAcknowledgementGate(signal) {
|
|
|
10047
10047
|
else signal.addEventListener("abort", onAbort, { once: true });
|
|
10048
10048
|
return { ready, release };
|
|
10049
10049
|
}
|
|
10050
|
+
function observeCodeRuntimeSessionSkills(command, skills, emit4) {
|
|
10051
|
+
return skills.map((skill) => ({
|
|
10052
|
+
...skill,
|
|
10053
|
+
tools: skill.tools.map((tool) => {
|
|
10054
|
+
if (!tool.handler) return tool;
|
|
10055
|
+
const handler = tool.handler;
|
|
10056
|
+
return {
|
|
10057
|
+
...tool,
|
|
10058
|
+
handler: async (input, context) => {
|
|
10059
|
+
const startedAt = Date.now();
|
|
10060
|
+
const operationId = digestRuntimeValue(
|
|
10061
|
+
`${command.commandId}:${skill.name}:${tool.name}:${context.toolCallId ?? "missing"}`
|
|
10062
|
+
);
|
|
10063
|
+
await emit4({
|
|
10064
|
+
type: "collaboration",
|
|
10065
|
+
phase: "started",
|
|
10066
|
+
skill: skill.name,
|
|
10067
|
+
tool: tool.name,
|
|
10068
|
+
operationId
|
|
10069
|
+
}).catch(() => void 0);
|
|
10070
|
+
try {
|
|
10071
|
+
const output = await handler(input, context);
|
|
10072
|
+
await emit4({
|
|
10073
|
+
type: "collaboration",
|
|
10074
|
+
phase: "completed",
|
|
10075
|
+
skill: skill.name,
|
|
10076
|
+
tool: tool.name,
|
|
10077
|
+
operationId,
|
|
10078
|
+
ok: output.isError !== true,
|
|
10079
|
+
durationMs: Date.now() - startedAt
|
|
10080
|
+
}).catch(() => void 0);
|
|
10081
|
+
return output;
|
|
10082
|
+
} catch (cause) {
|
|
10083
|
+
await emit4({
|
|
10084
|
+
type: "collaboration",
|
|
10085
|
+
phase: "completed",
|
|
10086
|
+
skill: skill.name,
|
|
10087
|
+
tool: tool.name,
|
|
10088
|
+
operationId,
|
|
10089
|
+
ok: false,
|
|
10090
|
+
durationMs: Date.now() - startedAt
|
|
10091
|
+
}).catch(() => void 0);
|
|
10092
|
+
throw cause;
|
|
10093
|
+
}
|
|
10094
|
+
}
|
|
10095
|
+
};
|
|
10096
|
+
})
|
|
10097
|
+
}));
|
|
10098
|
+
}
|
|
10050
10099
|
var TheseusRuntimeEngine = class {
|
|
10051
10100
|
constructor(options) {
|
|
10052
10101
|
this.options = options;
|
|
@@ -10243,7 +10292,7 @@ var TheseusRuntimeEngine = class {
|
|
|
10243
10292
|
event: (event) => this.#event(command, event, active.conversationRefs)
|
|
10244
10293
|
});
|
|
10245
10294
|
await this.#event(command, { type: "status", status: "running" }, active.conversationRefs);
|
|
10246
|
-
const extraSkills = await sessionSkillsFor(this.options, command);
|
|
10295
|
+
const extraSkills = observeCodeRuntimeSessionSkills(command, await sessionSkillsFor(this.options, command), (event) => this.#event(command, event, active.conversationRefs));
|
|
10247
10296
|
const result = await this.#attempt({
|
|
10248
10297
|
inference,
|
|
10249
10298
|
broker,
|
|
@@ -12619,13 +12668,15 @@ async function pmNext(ctx, parsed) {
|
|
|
12619
12668
|
const ready = tasks.filter((record11) => record11.column === READY_COLUMN);
|
|
12620
12669
|
const doing = tasks.filter((record11) => record11.column === "doing");
|
|
12621
12670
|
const guidance = !goals.length ? "discuss alignment with the user before creating or claiming project work" : !ready.length ? 'refine a linked Backlog task and mark it Ready with "pm task ready <id>"' : `claim the top Ready task in one call: odla-ai pm start --app ${appId}`;
|
|
12671
|
+
const monitor = `odla-ai pm watch --app ${appId} --jsonl`;
|
|
12622
12672
|
const result = {
|
|
12623
12673
|
appId,
|
|
12624
12674
|
projectId,
|
|
12625
12675
|
openGoals: leanRecords("goal", goals, verbose),
|
|
12626
12676
|
doing: leanRecords("task", doing, verbose),
|
|
12627
12677
|
ready: leanRecords("task", ready, verbose),
|
|
12628
|
-
next: guidance
|
|
12678
|
+
next: guidance,
|
|
12679
|
+
monitor
|
|
12629
12680
|
};
|
|
12630
12681
|
emit2(ctx, result, () => {
|
|
12631
12682
|
ctx.out.log(`${appId}: goal-aligned work intake (read only)`);
|
|
@@ -12639,6 +12690,7 @@ async function pmNext(ctx, parsed) {
|
|
|
12639
12690
|
else for (const record11 of records) printRecord(ctx, entity, record11);
|
|
12640
12691
|
}
|
|
12641
12692
|
ctx.out.log(`next: ${guidance}`);
|
|
12693
|
+
ctx.out.log(`monitor: ${monitor}`);
|
|
12642
12694
|
});
|
|
12643
12695
|
}
|
|
12644
12696
|
async function pmHandoff(ctx, parsed) {
|
|
@@ -12650,17 +12702,20 @@ async function pmHandoff(ctx, parsed) {
|
|
|
12650
12702
|
listFiltered(ctx, "bug", appId, projectId, { status: OPEN_BUG_STATUSES })
|
|
12651
12703
|
]);
|
|
12652
12704
|
const clean4 = !goals.length && !tasks.length && !bugs.length;
|
|
12705
|
+
const monitor = `odla-ai pm watch --app ${appId} --jsonl`;
|
|
12653
12706
|
const result = {
|
|
12654
12707
|
appId,
|
|
12655
12708
|
projectId,
|
|
12656
12709
|
unmetGoals: leanRecords("goal", goals, verbose),
|
|
12657
12710
|
activeTasks: leanRecords("task", tasks, verbose),
|
|
12658
12711
|
openBugs: leanRecords("bug", bugs, verbose),
|
|
12659
|
-
clean: clean4
|
|
12712
|
+
clean: clean4,
|
|
12713
|
+
monitor
|
|
12660
12714
|
};
|
|
12661
12715
|
emit2(ctx, result, () => {
|
|
12662
12716
|
if (clean4) {
|
|
12663
12717
|
ctx.out.log(`${appId}: no unresolved PM work`);
|
|
12718
|
+
ctx.out.log(`monitor: ${monitor}`);
|
|
12664
12719
|
return;
|
|
12665
12720
|
}
|
|
12666
12721
|
ctx.out.log(`${appId}: authoritative PM handoff`);
|
|
@@ -12673,6 +12728,7 @@ async function pmHandoff(ctx, parsed) {
|
|
|
12673
12728
|
if (!records.length) ctx.out.log("- (none)");
|
|
12674
12729
|
else for (const record11 of records) printRecord(ctx, entity, record11);
|
|
12675
12730
|
}
|
|
12731
|
+
ctx.out.log(`monitor: ${monitor}`);
|
|
12676
12732
|
});
|
|
12677
12733
|
}
|
|
12678
12734
|
|