Skip to content

abso-core

Public

abso is version control for agents: the client, the engine and a server you can run on your own Cloudflare account.

Check passed

Versions 190 to 318

Compare

+26 −5 in 2 places
Lines 1–15 at 318 (were 1–13 at 190)
1−// Ask Jev how to settle each marker block in one file (#19), the way abso pull
2−// leaves a held push's file. Prints Jev's pick and its probabilities; changes nothing.
1+// Ask a model how to settle each marker block in one file (#19), the way abso
2+// pull leaves a held push's file. Prints its pick; changes nothing.
33//
4−// node scripts/autosettle/settle-one.ts <file> [--message "<your held push's message>"] [--issue "..."] [--name <path in the project>] [--json]
4+// node scripts/autosettle/settle-one.ts <file> [--via workers-ai|clef|jev] [--model <id>] [--message "<your held push's message>"] [--issue "..."] [--name <path in the project>] [--json]
55//
6−// Needs JEV_API_KEY in the environment.
6+// --via workers-ai (the default) needs workers-ai/ running under wrangler dev; --via jev needs JEV_API_KEY.
77
88import { readFileSync } from "node:fs";
99import { findBlocks } from "../../client/src/settle.ts";
10+import { askClef } from "./clef.ts";
1011import { ask, dollars, type Hold, PICKS } from "./jev.ts";
12+import { askWorkersAi } from "./workers-ai.ts";
1113
1214const CONTEXT = 15;
1315const CLOSE = /^>>>>>>> theirs: (.*?), version (\d+) "(.*)"$/;
Lines 59–85 at 318 (were 57–64 at 190)
5759 process.exit(1);
5860 }
5961 const results = [];
62+ const model = flag(args, "--model") ? { model: flag(args, "--model")! } : {};
6063 for (const [i, h] of holds.entries()) {
61− const v = await ask(h);
64+ if (flag(args, "--via") === "clef") {
65+ const c = await askClef(h, { model: (flag(args, "--model") as "clef" | "clef-flash" | undefined) ?? "clef" });
66+ results.push({ block: i + 1, ...c });
67+ if (!args.includes("--json"))
68+ console.log(
69+ `Block ${i + 1} of ${holds.length} in ${h.file}: ${c.pick}, confidence ${c.confidence.toFixed(2)} (${c.by}${c.modelPick ? `, Clef said ${c.modelPick}` : ""})\n probabilities: ${PICKS.map((k) => `${k} ${(c.probabilities[k] * 100).toFixed(0)}%`).join(", ")}\n ${c.model}, ${c.ms.toFixed(0)} ms`,
70+ );
71+ continue;
72+ }
73+ if (flag(args, "--via") !== "jev") {
74+ const w = await askWorkersAi(h, model);
75+ results.push({ block: i + 1, ...w });
76+ if (!args.includes("--json"))
77+ console.log(
78+ `Block ${i + 1} of ${holds.length} in ${h.file}: ${w.pick}, confidence ${w.confidence.toFixed(2)}\n ${w.reason}\n ${w.model}, ${w.ms.toFixed(0)} ms (model ${w.modelMs} ms), ${w.inputTokens} input tokens`,
79+ );
80+ continue;
81+ }
82+ const v = await ask(h, model);
6283 results.push({ block: i + 1, ...v });
6384 if (args.includes("--json")) continue;
6485 const pct = (x: number) => `${(x * 100).toFixed(0)}%`;
MCP
compare on this site's /mcp
CLI
abso diff 190 318 scripts/autosettle/settle-one.ts --json
JSON
/christopher/abso-core/compare/190..318?file=scripts%2Fautosettle%2Fsettle-one.ts&format=json