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
MCP
show on this site's /mcp
CLI
abso show 267 --json
JSON
/christopher/abso-core/versions/267?format=json

Pipelines: uses: agent replaces uses: review (abso issue 688, Agent VCS's shape). One general step: a model reads the version's diff and acts as the run's own seat. instructions: names a file in the project to follow (the server's built-in review when none); model: names a model as the AI binding does (anthropic/claude-sonnet-5, @cf/...); may: lists what the seat may do, and slice 1 knows only note. A path outside the project, a model name that isn't one, and an unknown may are refused. Tests: src/pipeline/test, 32 pass.

of shared·approvals-page··Not checked

Pipelines: uses: agent replaces uses: review (abso issue 688 · not public, Agent VCS's shape). One general step: a model reads the version's diff and acts as the run's own seat. instructions: names a file in the project to follow (the server's built-in review when none); model: names a model as the AI binding does (anthropic/claude-sonnet-5, @cf/...); may: lists what the seat may do, and slice 1 knows only note.

A path outside the project, a model name that isn't one, and an unknown may are refused. Tests: src/pipeline/test, 32 pass.

Version 266 · Files at version 267

2 files, 72 lines added, 9 removed.

--- a/src/pipeline/pipeline.ts
+++ b/src/pipeline/pipeline.ts
@@ -74,7 +74,7 @@
7474 | { readonly ok: true; readonly file: PipelineFile }
7575 | { readonly ok: false; readonly problems: readonly Problem[] };
7676
77−export const BUILT_INS = ["deploy", "preview", "notify", "npm-publish", "review"] as const;
77+export const BUILT_INS = ["deploy", "preview", "notify", "npm-publish", "agent"] as const;
7878export type BuiltIn = (typeof BUILT_INS)[number];
7979
8080/** Each built-in step's own settings, beside the keys every job has. */
@@ -84,10 +84,16 @@
8484 notify: ["to"],
8585 // The npm packages it may publish, from the .tgz files its from: job kept, and the dist-tag (latest if none).
8686 "npm-publish": ["packages", "tag"],
87− // A model reads the version's diff and leaves notes on it (abso issue 688). The server picks the model and the caps.
88− review: [],
87+ // A model reads the version's diff and acts on it as the run's own seat (abso issue 688): the instructions file it
88+ // follows (a built-in review when none), the model, and what the seat may do (note: notes on the changed lines).
89+ agent: ["instructions", "model", "may"],
8990};
9091
92+/** What an agent step's seat may do (688). Slice 1: leave notes on the version's changed lines. */
93+export const AGENT_MAY = ["note"] as const;
94+/** A model as the server's AI binding names it: provider/model or Workers AI's @cf/author/model. */
95+const MODEL_NAME = /^(@cf\/)?[a-z0-9][a-z0-9_.-]*\/[a-z0-9][a-z0-9_.:-]*$/i;
9197/** An npm dist-tag: npm refuses one that reads as a version, so it starts with a letter. */
9298const DIST_TAG = /^[a-z][a-z0-9_-]{0,31}$/;
9399
@@ -337,6 +343,29 @@
337343 for (const k of settings) if (j[k] !== undefined) withs[k] = j[k];
338344 if (uses === "deploy" && typeof j.worker !== "string")
339345 say(`${at}.worker`, "names the Worker deploy ships, and is missing");
346+ if (uses === "agent") {
347+ const instructions = j.instructions;
348+ if (
349+ instructions !== undefined &&
350+ (typeof instructions !== "string" ||
351+ instructions === "" ||
352+ instructions.startsWith("/") ||
353+ instructions.split("/").includes(".."))
354+ )
355+ say(`${at}.instructions`, `names a file in the project, such as .abso/review.md, not ${q(instructions)}`);
356+ if (j.model !== undefined && (typeof j.model !== "string" || !MODEL_NAME.test(j.model)))
357+ say(`${at}.model`, `names a model such as anthropic/claude-sonnet-5, not ${q(j.model)}`);
358+ if (j.may !== undefined) {
359+ const may = typeof j.may === "string" ? [j.may] : j.may;
360+ if (!Array.isArray(may) || may.length === 0)
361+ say(`${at}.may`, `lists what the seat may do: ${AGENT_MAY.join(", ")}`);
362+ else
363+ may.forEach((m, i) => {
364+ if (!(AGENT_MAY as readonly unknown[]).includes(m))
365+ say(`${at}.may[${i}]`, `${q(m)} isn't something an agent step may do yet (${AGENT_MAY.join(", ")})`);
366+ });
367+ }
368+ }
340369 if (uses === "npm-publish") {
341370 if (j.from === undefined)
342371 say(`${at}.from`, "names the job whose kept .tgz files npm-publish pushes, and is missing");
--- a/src/pipeline/test/pipeline.test.ts
+++ b/src/pipeline/test/pipeline.test.ts
@@ -252,16 +252,50 @@
252252 has(ps, "pipelines.p.jobs.c.packages[2]", /isn't an npm package name/);
253253 });
254254
255− it("review: a step with no settings of its own; the server picks the model (abso issue 688)", () => {
256− const read = checkPipelines(one({ review: { uses: "review" } }, { only: ["shared"] }));
255+ it("agent: instructions, a model and what its seat may do; all optional (abso issue 688)", () => {
256+ ok(checkPipelines(one({ review: { uses: "agent" } }, { only: ["shared"] })));
257+ const read = checkPipelines(
258+ one(
259+ {
260+ review: {
261+ uses: "agent",
262+ instructions: ".abso/review.md",
263+ model: "anthropic/claude-sonnet-5",
264+ may: ["note"],
265+ },
266+ tidy: { uses: "agent", model: "@cf/meta/llama-3.3-70b-instruct-fp8-fast", may: "note" },
267+ },
268+ { only: ["shared"] },
269+ ),
270+ );
257271 ok(read);
258272 const job = read.ok ? read.file.pipelines[0]!.jobs.find((j) => j.name === "review") : undefined;
259− assert.equal(job?.uses, "review");
260− assert.deepEqual(job?.with, {});
273+ assert.equal(job?.uses, "agent");
274+ assert.deepEqual(job?.with, {
275+ instructions: ".abso/review.md",
276+ model: "anthropic/claude-sonnet-5",
277+ may: ["note"],
278+ });
279+ const bad = problems(
280+ checkPipelines(
281+ one({
282+ a: { uses: "agent", instructions: "../outside.md" },
283+ b: { uses: "agent", model: "sonnet please" },
284+ c: { uses: "agent", may: ["note", "land"] },
285+ d: { uses: "agent", may: [] },
286+ e: { uses: "agent", instructions: "/etc/passwd" },
287+ }),
288+ ),
289+ );
290+ has(bad, "pipelines.p.jobs.a.instructions", /names a file in the project/);
291+ has(bad, "pipelines.p.jobs.b.model", /names a model/);
292+ has(bad, "pipelines.p.jobs.c.may[1]", /isn't something an agent step may do yet/);
293+ has(bad, "pipelines.p.jobs.d.may", /lists what the seat may do/);
294+ has(bad, "pipelines.p.jobs.e.instructions", /names a file in the project/);
261295 const ps = problems(
262− checkPipelines(one({ a: { uses: "review", model: "x" }, b: { uses: "review", abso: "writer" } })),
296+ checkPipelines(one({ a: { uses: "agent", worker: "x" }, b: { uses: "agent", abso: "writer" } })),
263297 );
264− has(ps, "pipelines.p.jobs.a.model", /./);
298+ has(ps, "pipelines.p.jobs.a.worker", /isn't a key here/);
265299 has(ps, "pipelines.p.jobs.b.abso", /a uses step runs on the server/);
266300 });
267301