wildcrane-runner 0.6.41 → 0.6.43
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/akb/dist/kanban.mjs +973 -816
- package/dist/akb/package.json +1 -1
- package/dist/akb-proxy.mjs +1 -1
- package/dist/launcher.mjs +62 -6
- package/dist/plugin.mjs +62 -6
- package/dist/runner.mjs +219 -80
- package/dist/settings.mjs +62 -6
- package/package.json +1 -1
package/dist/settings.mjs
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
// wildcrane-runner 0.6.
|
|
1
|
+
// wildcrane-runner 0.6.43 — built by runner/scripts/build.mjs. Do not edit.
|
|
2
2
|
import { createRequire as __ai4kanbanRequire } from 'node:module'
|
|
3
3
|
const require = __ai4kanbanRequire(import.meta.url)
|
|
4
4
|
var __create = Object.create;
|
|
@@ -26966,8 +26966,8 @@ function alive(pid) {
|
|
|
26966
26966
|
var sleep = (ms) => new Promise((resolve2) => setTimeout(resolve2, ms));
|
|
26967
26967
|
|
|
26968
26968
|
// src/protocol.ts
|
|
26969
|
-
var VERSION = true ? "0.6.
|
|
26970
|
-
var AKB_VERSION = true ? "0.11.
|
|
26969
|
+
var VERSION = true ? "0.6.43" : "0.0.0";
|
|
26970
|
+
var AKB_VERSION = true ? "0.11.37" : "0.0.0";
|
|
26971
26971
|
|
|
26972
26972
|
// src/api.ts
|
|
26973
26973
|
var RUNTIMES = ["claude-code", "codex", "cursor", "opencode", "kimi", "dsh", "zcode", "grok"];
|
|
@@ -27880,6 +27880,11 @@ function createEventCollector() {
|
|
|
27880
27880
|
const t2 = target ? targetOf(target) : void 0;
|
|
27881
27881
|
queue.push({ kind: "tool_call", data: { toolCallId, title, kind, status: "in_progress", ...t2 ? { target: t2 } : {} } });
|
|
27882
27882
|
},
|
|
27883
|
+
/** A subagent the agent started, titled by its task; it ends with its call's `toolResult`. */
|
|
27884
|
+
subagent(toolCallId, title) {
|
|
27885
|
+
close();
|
|
27886
|
+
queue.push({ kind: "tool_call", data: { toolCallId, title: targetOf(title) ?? "subagent", kind: "other", status: "in_progress", subagent: true } });
|
|
27887
|
+
},
|
|
27883
27888
|
toolResult(toolCallId, status2, result) {
|
|
27884
27889
|
close();
|
|
27885
27890
|
queue.push({ kind: "tool_call_update", data: { toolCallId, status: status2, ...result.trim() ? { result: result.trim() } : {} } });
|
|
@@ -27967,6 +27972,7 @@ var TOOL_KINDS2 = {
|
|
|
27967
27972
|
WebFetch: "fetch",
|
|
27968
27973
|
WebSearch: "fetch"
|
|
27969
27974
|
};
|
|
27975
|
+
var SUBAGENT_TOOLS = /* @__PURE__ */ new Set(["Agent", "Task"]);
|
|
27970
27976
|
function targetOf2(input) {
|
|
27971
27977
|
const args = obj(input);
|
|
27972
27978
|
for (const key of ARG_KEYS) if (str(args[key]).trim()) return str(args[key]);
|
|
@@ -28035,6 +28041,13 @@ function createStreamRenderer() {
|
|
|
28035
28041
|
const backgrounded = /* @__PURE__ */ new Set();
|
|
28036
28042
|
const events = createEventCollector();
|
|
28037
28043
|
const plans = /* @__PURE__ */ new Set();
|
|
28044
|
+
const subagents = /* @__PURE__ */ new Map();
|
|
28045
|
+
const detached = /* @__PURE__ */ new Set();
|
|
28046
|
+
const endSubagent = (id, status2) => {
|
|
28047
|
+
if (subagents.get(id) !== false) return;
|
|
28048
|
+
subagents.set(id, true);
|
|
28049
|
+
events.toolResult(id, status2, "");
|
|
28050
|
+
};
|
|
28038
28051
|
const renderLine = (line) => {
|
|
28039
28052
|
if (!line.trim()) return "";
|
|
28040
28053
|
const ev = frame(line);
|
|
@@ -28044,6 +28057,7 @@ function createStreamRenderer() {
|
|
|
28044
28057
|
`;
|
|
28045
28058
|
}
|
|
28046
28059
|
if (model === void 0) model = eventModel(ev);
|
|
28060
|
+
if (str(ev.parent_tool_use_id)) return "";
|
|
28047
28061
|
switch (ev.type) {
|
|
28048
28062
|
case "assistant": {
|
|
28049
28063
|
const msg = ev.message;
|
|
@@ -28061,7 +28075,12 @@ function createStreamRenderer() {
|
|
|
28061
28075
|
} else if (b?.type === "tool_use" && typeof b.name === "string") {
|
|
28062
28076
|
out.push(`\u23FA ${b.name}${argHint(b.input, ARG_KEYS)}
|
|
28063
28077
|
`);
|
|
28064
|
-
if (b.name
|
|
28078
|
+
if (SUBAGENT_TOOLS.has(b.name)) {
|
|
28079
|
+
const input = obj(b.input);
|
|
28080
|
+
subagents.set(str(b.id), false);
|
|
28081
|
+
if (input.run_in_background === true) detached.add(str(b.id));
|
|
28082
|
+
events.subagent(str(b.id), str(input.description) || str(input.subagent_type) || b.name);
|
|
28083
|
+
} else if (b.name === "TodoWrite") {
|
|
28065
28084
|
plans.add(str(b.id));
|
|
28066
28085
|
events.plan(obj(b.input).todos);
|
|
28067
28086
|
} else {
|
|
@@ -28076,6 +28095,10 @@ function createStreamRenderer() {
|
|
|
28076
28095
|
for (const raw of Array.isArray(content) ? content : []) {
|
|
28077
28096
|
const b = obj(raw);
|
|
28078
28097
|
if (b.type !== "tool_result" || plans.has(str(b.tool_use_id))) continue;
|
|
28098
|
+
if (subagents.has(str(b.tool_use_id))) {
|
|
28099
|
+
if (!detached.has(str(b.tool_use_id))) endSubagent(str(b.tool_use_id), b.is_error === true ? "failed" : "completed");
|
|
28100
|
+
continue;
|
|
28101
|
+
}
|
|
28079
28102
|
events.toolResult(str(b.tool_use_id), b.is_error === true ? "failed" : "completed", resultText(b.content));
|
|
28080
28103
|
}
|
|
28081
28104
|
return "";
|
|
@@ -28103,6 +28126,9 @@ function createStreamRenderer() {
|
|
|
28103
28126
|
case "system":
|
|
28104
28127
|
if (ev.subtype === "background_tasks_changed" && Array.isArray(ev.tasks)) background = ev.tasks.length;
|
|
28105
28128
|
if (ev.subtype === "task_started" && ev.is_backgrounded === true) backgrounded.add(str(ev.task_id));
|
|
28129
|
+
if (ev.subtype === "task_notification" && subagents.has(str(ev.tool_use_id))) {
|
|
28130
|
+
endSubagent(str(ev.tool_use_id), str(ev.status) === "completed" ? "completed" : "failed");
|
|
28131
|
+
}
|
|
28106
28132
|
if (ev.subtype === "task_notification" && backgrounded.has(str(ev.task_id)) && str(ev.summary)) {
|
|
28107
28133
|
return `\u23FA ${str(ev.summary)}
|
|
28108
28134
|
`;
|
|
@@ -28632,6 +28658,14 @@ function callArgs(raw) {
|
|
|
28632
28658
|
return {};
|
|
28633
28659
|
}
|
|
28634
28660
|
}
|
|
28661
|
+
var TOOL_KINDS3 = [
|
|
28662
|
+
[/read/i, "read"],
|
|
28663
|
+
[/grep|glob|search/i, "search"],
|
|
28664
|
+
[/fetch|web/i, "fetch"],
|
|
28665
|
+
[/bash|shell/i, "execute"],
|
|
28666
|
+
[/write|edit|replace/i, "edit"]
|
|
28667
|
+
];
|
|
28668
|
+
var kindOf = (name) => TOOL_KINDS3.find(([re]) => re.test(name))?.[1] ?? "other";
|
|
28635
28669
|
function toolCalls(row) {
|
|
28636
28670
|
const calls = Array.isArray(row.tool_calls) ? row.tool_calls : [];
|
|
28637
28671
|
return calls.map((raw) => {
|
|
@@ -28655,6 +28689,8 @@ function createKimiStreamRenderer(cwd) {
|
|
|
28655
28689
|
let sessionId;
|
|
28656
28690
|
let facts;
|
|
28657
28691
|
let lookedAt = 0;
|
|
28692
|
+
const events = createEventCollector();
|
|
28693
|
+
const subagents = /* @__PURE__ */ new Set();
|
|
28658
28694
|
const look = (now) => {
|
|
28659
28695
|
const at = Date.now();
|
|
28660
28696
|
if (!now && at - lookedAt < LOOK_EVERY_MS2) return;
|
|
@@ -28671,6 +28707,18 @@ function createKimiStreamRenderer(cwd) {
|
|
|
28671
28707
|
case "assistant": {
|
|
28672
28708
|
const said = str(row.content).trim();
|
|
28673
28709
|
if (said) final = said;
|
|
28710
|
+
if (said) events.message(said);
|
|
28711
|
+
for (const raw of Array.isArray(row.tool_calls) ? row.tool_calls : []) {
|
|
28712
|
+
const call = obj(raw);
|
|
28713
|
+
const name = str(obj(call.function).name) || "tool";
|
|
28714
|
+
const args = obj(callArgs(obj(call.function).arguments));
|
|
28715
|
+
if (name === "Agent") {
|
|
28716
|
+
subagents.add(str(call.id));
|
|
28717
|
+
events.subagent(str(call.id), str(args.description) || name);
|
|
28718
|
+
} else {
|
|
28719
|
+
events.toolCall(str(call.id), name, kindOf(name), ARG_KEYS2.map((k) => str(args[k])).find((v) => v.trim()));
|
|
28720
|
+
}
|
|
28721
|
+
}
|
|
28674
28722
|
return `${said ? `${said}
|
|
28675
28723
|
|
|
28676
28724
|
` : ""}${toolCalls(row)}`;
|
|
@@ -28678,6 +28726,13 @@ function createKimiStreamRenderer(cwd) {
|
|
|
28678
28726
|
case "meta":
|
|
28679
28727
|
if (row.type === "session.resume_hint") sessionId ??= str(row.session_id).trim() || void 0;
|
|
28680
28728
|
return row.type === "turn.step.retrying" ? retry(row) : "";
|
|
28729
|
+
case "tool": {
|
|
28730
|
+
const id = str(row.tool_call_id);
|
|
28731
|
+
const text2 = str(row.content);
|
|
28732
|
+
if (subagents.delete(id)) events.toolResult(id, /^status: completed$/m.test(text2) ? "completed" : "failed", "");
|
|
28733
|
+
else events.toolResult(id, "completed", text2);
|
|
28734
|
+
return "";
|
|
28735
|
+
}
|
|
28681
28736
|
default:
|
|
28682
28737
|
return "";
|
|
28683
28738
|
}
|
|
@@ -28691,6 +28746,7 @@ function createKimiStreamRenderer(cwd) {
|
|
|
28691
28746
|
return out;
|
|
28692
28747
|
},
|
|
28693
28748
|
result: () => final,
|
|
28749
|
+
events: events.events,
|
|
28694
28750
|
usage: () => facts?.usage,
|
|
28695
28751
|
context: () => {
|
|
28696
28752
|
look(false);
|
|
@@ -28841,8 +28897,8 @@ function createTail(log) {
|
|
|
28841
28897
|
// ../cli/package.json
|
|
28842
28898
|
var package_default = {
|
|
28843
28899
|
name: "wildcrane",
|
|
28844
|
-
version: "0.11.
|
|
28845
|
-
akbContract:
|
|
28900
|
+
version: "0.11.37",
|
|
28901
|
+
akbContract: 9,
|
|
28846
28902
|
description: "WildCrane's `akb` command \u2014 scaffold the Markdown board under docs/kanban/, put an agent on a card, and carry the flows the agent works by.",
|
|
28847
28903
|
keywords: [
|
|
28848
28904
|
"kanban",
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "wildcrane-runner",
|
|
3
|
-
"version": "0.6.
|
|
3
|
+
"version": "0.6.43",
|
|
4
4
|
"description": "WildCrane's Local Runner — connects this computer to WildCrane and runs its jobs on your local Claude Code, Codex, OpenCode or Cursor.",
|
|
5
5
|
"license": "Apache-2.0",
|
|
6
6
|
"homepage": "https://wildcrane.ai/",
|