@ai-agent-forge/plugin-todo-set 0.85.0
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/README.md +22 -0
- package/agent-forge.json +11 -0
- package/dist/entry.d.ts +14 -0
- package/dist/entry.d.ts.map +1 -0
- package/dist/entry.js +23 -0
- package/dist/entry.js.map +1 -0
- package/dist/index.d.ts +29 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +136 -0
- package/dist/index.js.map +1 -0
- package/package.json +54 -0
- package/plugin.json +8 -0
package/README.md
ADDED
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
# @agent-forge/plugin-todo-set
|
|
2
|
+
|
|
3
|
+
Todo-set capability plugin for [Agent Forge](https://github.com/agent-forge/agent-forge), extracted from the host's
|
|
4
|
+
`src/capabilities/todo-set.ts` (D-075 S4, first B-class batch). It registers a single tool, `todo_update`: a
|
|
5
|
+
self-contained todo state machine whose `planId` field softly references a plan by plain id.
|
|
6
|
+
|
|
7
|
+
Todos persist as append-only `todo.state` session entries and every change is announced as a `todo.changed` event. The
|
|
8
|
+
soft reference is advisory (#10): an unknown `planId` never fails the write — the tool response carries a `warning`
|
|
9
|
+
field instead, read from the session branch's latest `plan.state` snapshot through the shared session entry protocol.
|
|
10
|
+
|
|
11
|
+
## Install
|
|
12
|
+
|
|
13
|
+
```sh
|
|
14
|
+
# from a local checkout
|
|
15
|
+
agent-forge plugin install ./plugins/todo-set
|
|
16
|
+
|
|
17
|
+
# from npm
|
|
18
|
+
agent-forge plugin install @ai-agent-forge/plugin-todo-set
|
|
19
|
+
```
|
|
20
|
+
|
|
21
|
+
Suites declare the capability through the `builtin.todo-set` short id; after the S4 split that id is assembled from
|
|
22
|
+
this package through the install store (bootstrap factory manifest or manual install).
|
package/agent-forge.json
ADDED
package/dist/entry.d.ts
ADDED
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import type { CapabilityAPI } from "@agent-forge/plugin-sdk";
|
|
2
|
+
/**
|
|
3
|
+
* Default-export factory consumed by the host's `loadCapabilityPluginFromManifest`.
|
|
4
|
+
*
|
|
5
|
+
* The capability factory returns its registrations as an array, while the
|
|
6
|
+
* manifest loader contract expects `void` or a single `{ dispose() }` instance
|
|
7
|
+
* (`normalizePluginInstance` does not accept arrays). The wrapper collects the
|
|
8
|
+
* registrations and disposes them in reverse order on plugin teardown — the
|
|
9
|
+
* same disposal semantics as the host's embedded `syncRegistrationFactory`.
|
|
10
|
+
*/
|
|
11
|
+
export default function createTodoSetPluginEntry(api: CapabilityAPI): Promise<{
|
|
12
|
+
dispose: () => void;
|
|
13
|
+
}>;
|
|
14
|
+
//# sourceMappingURL=entry.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"entry.d.ts","sourceRoot":"","sources":["../src/entry.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,yBAAyB,CAAC;AAG7D;;;;;;;;GAQG;AACH,wBAA8B,wBAAwB,CACrD,GAAG,EAAE,aAAa,GAChB,OAAO,CAAC;IAAE,OAAO,EAAE,MAAM,IAAI,CAAA;CAAE,CAAC,CAWlC","sourcesContent":["import type { CapabilityAPI } from \"@agent-forge/plugin-sdk\";\nimport { createCapability } from \"./index.ts\";\n\n/**\n * Default-export factory consumed by the host's `loadCapabilityPluginFromManifest`.\n *\n * The capability factory returns its registrations as an array, while the\n * manifest loader contract expects `void` or a single `{ dispose() }` instance\n * (`normalizePluginInstance` does not accept arrays). The wrapper collects the\n * registrations and disposes them in reverse order on plugin teardown — the\n * same disposal semantics as the host's embedded `syncRegistrationFactory`.\n */\nexport default async function createTodoSetPluginEntry(\n\tapi: CapabilityAPI,\n): Promise<{ dispose: () => void }> {\n\tconst registrations = await createCapability(api);\n\treturn {\n\t\tdispose: () => {\n\t\t\tfor (const registration of [...registrations].reverse()) {\n\t\t\t\t// Registration disposal in the capability runtime is synchronous;\n\t\t\t\t// void consumes the declared Promise possibility of the contract.\n\t\t\t\tvoid registration.dispose();\n\t\t\t}\n\t\t},\n\t};\n}\n"]}
|
package/dist/entry.js
ADDED
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import { createCapability } from "./index.js";
|
|
2
|
+
/**
|
|
3
|
+
* Default-export factory consumed by the host's `loadCapabilityPluginFromManifest`.
|
|
4
|
+
*
|
|
5
|
+
* The capability factory returns its registrations as an array, while the
|
|
6
|
+
* manifest loader contract expects `void` or a single `{ dispose() }` instance
|
|
7
|
+
* (`normalizePluginInstance` does not accept arrays). The wrapper collects the
|
|
8
|
+
* registrations and disposes them in reverse order on plugin teardown — the
|
|
9
|
+
* same disposal semantics as the host's embedded `syncRegistrationFactory`.
|
|
10
|
+
*/
|
|
11
|
+
export default async function createTodoSetPluginEntry(api) {
|
|
12
|
+
const registrations = await createCapability(api);
|
|
13
|
+
return {
|
|
14
|
+
dispose: () => {
|
|
15
|
+
for (const registration of [...registrations].reverse()) {
|
|
16
|
+
// Registration disposal in the capability runtime is synchronous;
|
|
17
|
+
// void consumes the declared Promise possibility of the contract.
|
|
18
|
+
void registration.dispose();
|
|
19
|
+
}
|
|
20
|
+
},
|
|
21
|
+
};
|
|
22
|
+
}
|
|
23
|
+
//# sourceMappingURL=entry.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"entry.js","sourceRoot":"","sources":["../src/entry.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,gBAAgB,EAAE,MAAM,YAAY,CAAC;AAE9C;;;;;;;;GAQG;AACH,MAAM,CAAC,OAAO,CAAC,KAAK,UAAU,wBAAwB,CACrD,GAAkB,EACiB;IACnC,MAAM,aAAa,GAAG,MAAM,gBAAgB,CAAC,GAAG,CAAC,CAAC;IAClD,OAAO;QACN,OAAO,EAAE,GAAG,EAAE,CAAC;YACd,KAAK,MAAM,YAAY,IAAI,CAAC,GAAG,aAAa,CAAC,CAAC,OAAO,EAAE,EAAE,CAAC;gBACzD,kEAAkE;gBAClE,kEAAkE;gBAClE,KAAK,YAAY,CAAC,OAAO,EAAE,CAAC;YAC7B,CAAC;QAAA,CACD;KACD,CAAC;AAAA,CACF","sourcesContent":["import type { CapabilityAPI } from \"@agent-forge/plugin-sdk\";\nimport { createCapability } from \"./index.ts\";\n\n/**\n * Default-export factory consumed by the host's `loadCapabilityPluginFromManifest`.\n *\n * The capability factory returns its registrations as an array, while the\n * manifest loader contract expects `void` or a single `{ dispose() }` instance\n * (`normalizePluginInstance` does not accept arrays). The wrapper collects the\n * registrations and disposes them in reverse order on plugin teardown — the\n * same disposal semantics as the host's embedded `syncRegistrationFactory`.\n */\nexport default async function createTodoSetPluginEntry(\n\tapi: CapabilityAPI,\n): Promise<{ dispose: () => void }> {\n\tconst registrations = await createCapability(api);\n\treturn {\n\t\tdispose: () => {\n\t\t\tfor (const registration of [...registrations].reverse()) {\n\t\t\t\t// Registration disposal in the capability runtime is synchronous;\n\t\t\t\t// void consumes the declared Promise possibility of the contract.\n\t\t\t\tvoid registration.dispose();\n\t\t\t}\n\t\t},\n\t};\n}\n"]}
|
package/dist/index.d.ts
ADDED
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Todo-set capability plugin: a self-contained todo state machine, extracted
|
|
3
|
+
* from the host's `src/capabilities/todo-set.ts` (D-075 S4, first B-class
|
|
4
|
+
* batch).
|
|
5
|
+
*
|
|
6
|
+
* Todos persist as append-only `todo.state` session entries and every change
|
|
7
|
+
* is announced as a `todo.changed` event. `planId` is a soft reference: a
|
|
8
|
+
* plain string whose target is checked ADVISORILY against the plan plugin's
|
|
9
|
+
* LATEST `plan.state` snapshot (the same latest-snapshot semantics as this
|
|
10
|
+
* plugin's own {@link loadState}); an unknown id yields a response warning,
|
|
11
|
+
* never a failure (the same #10 pattern as the plan plugin's goalId check).
|
|
12
|
+
* The plugin only consumes the public `session`, `events`, and `tools`
|
|
13
|
+
* capabilities and never writes state owned by another plugin.
|
|
14
|
+
*/
|
|
15
|
+
import type { CapabilityAPI, DisposableRegistration } from "@agent-forge/plugin-sdk";
|
|
16
|
+
export interface TodoRecord {
|
|
17
|
+
id: string;
|
|
18
|
+
/** Soft reference: a plain string; unknown ids yield a response warning, not a failure. */
|
|
19
|
+
planId: string;
|
|
20
|
+
title: string;
|
|
21
|
+
status: "pending" | "done" | "blocked";
|
|
22
|
+
revision: number;
|
|
23
|
+
evidence: string[];
|
|
24
|
+
}
|
|
25
|
+
export interface TodoState {
|
|
26
|
+
todos: TodoRecord[];
|
|
27
|
+
}
|
|
28
|
+
export declare function createCapability(api: CapabilityAPI): Promise<readonly DisposableRegistration[]> | readonly DisposableRegistration[];
|
|
29
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;GAaG;AAGH,OAAO,KAAK,EAAE,aAAa,EAAE,sBAAsB,EAAE,MAAM,yBAAyB,CAAC;AAErF,MAAM,WAAW,UAAU;IAC1B,EAAE,EAAE,MAAM,CAAC;IACX,2FAA2F;IAC3F,MAAM,EAAE,MAAM,CAAC;IACf,KAAK,EAAE,MAAM,CAAC;IACd,MAAM,EAAE,SAAS,GAAG,MAAM,GAAG,SAAS,CAAC;IACvC,QAAQ,EAAE,MAAM,CAAC;IACjB,QAAQ,EAAE,MAAM,EAAE,CAAC;CACnB;AAED,MAAM,WAAW,SAAS;IACzB,KAAK,EAAE,UAAU,EAAE,CAAC;CACpB;AAoFD,wBAAgB,gBAAgB,CAC/B,GAAG,EAAE,aAAa,GAChB,OAAO,CAAC,SAAS,sBAAsB,EAAE,CAAC,GAAG,SAAS,sBAAsB,EAAE,CA4ChF","sourcesContent":["/**\n * Todo-set capability plugin: a self-contained todo state machine, extracted\n * from the host's `src/capabilities/todo-set.ts` (D-075 S4, first B-class\n * batch).\n *\n * Todos persist as append-only `todo.state` session entries and every change\n * is announced as a `todo.changed` event. `planId` is a soft reference: a\n * plain string whose target is checked ADVISORILY against the plan plugin's\n * LATEST `plan.state` snapshot (the same latest-snapshot semantics as this\n * plugin's own {@link loadState}); an unknown id yields a response warning,\n * never a failure (the same #10 pattern as the plan plugin's goalId check).\n * The plugin only consumes the public `session`, `events`, and `tools`\n * capabilities and never writes state owned by another plugin.\n */\n\nimport { Type } from \"typebox\";\nimport type { CapabilityAPI, DisposableRegistration } from \"@agent-forge/plugin-sdk\";\n\nexport interface TodoRecord {\n\tid: string;\n\t/** Soft reference: a plain string; unknown ids yield a response warning, not a failure. */\n\tplanId: string;\n\ttitle: string;\n\tstatus: \"pending\" | \"done\" | \"blocked\";\n\trevision: number;\n\tevidence: string[];\n}\n\nexport interface TodoState {\n\ttodos: TodoRecord[];\n}\n\nconst stateEntry = \"todo.state\";\n/** Session protocol key of the plan plugin's snapshot entry (plugins/plan). */\nconst planStateEntry = \"plan.state\";\n\nconst todoSchema = Type.Object({\n\tid: Type.String({ description: \"Stable id of the todo to create or update\" }),\n\tplanId: Type.String({\n\t\tdescription:\n\t\t\t\"Soft reference to a plan id; an id unknown to this session's plan state yields a response warning, not a failure\",\n\t}),\n\ttitle: Type.String({ description: \"Human-readable todo title\" }),\n\trevision: Type.Integer({\n\t\tdescription: \"New revision counter; must be greater than the stored revision of an existing todo\",\n\t\tminimum: 0,\n\t}),\n\tstatus: Type.Optional(\n\t\tType.Union([Type.Literal(\"pending\"), Type.Literal(\"done\"), Type.Literal(\"blocked\")], {\n\t\t\tdescription: \"Next status; defaults to the stored status for existing todos, otherwise pending\",\n\t\t}),\n\t),\n\tevidence: Type.Optional(\n\t\tType.Array(Type.String(), {\n\t\t\tdescription: \"Evidence references; at least one is required when status is done\",\n\t\t}),\n\t),\n});\n\nfunction objectInput(first: unknown, second: unknown): Record<string, unknown> {\n\tconst value = second === undefined ? first : second;\n\tif (!value || typeof value !== \"object\" || Array.isArray(value)) throw new Error(\"Todo input must be an object\");\n\treturn value as Record<string, unknown>;\n}\n\nfunction text(value: unknown, name: string): string {\n\tif (typeof value !== \"string\" || value.trim() === \"\") throw new Error(`${name} must be a non-empty string`);\n\treturn value;\n}\n\nfunction revision(value: unknown): number {\n\tif (!Number.isInteger(value) || (value as number) < 0) throw new Error(\"revision must be a non-negative integer\");\n\treturn value as number;\n}\n\nfunction evidence(value: unknown): string[] {\n\tif (value === undefined) return [];\n\tif (!Array.isArray(value) || value.some((item) => typeof item !== \"string\" || item.trim() === \"\")) {\n\t\tthrow new Error(\"evidence must be a string array\");\n\t}\n\treturn [...(value as string[])];\n}\n\nfunction loadState(api: CapabilityAPI): TodoState {\n\tconst entries = api.session?.getBranchEntries() ?? [];\n\tconst entry = [...entries].reverse().find((item) => item.customType === stateEntry);\n\tif (!entry?.data || typeof entry.data !== \"object\") return { todos: [] };\n\tconst data = entry.data as Partial<TodoState>;\n\treturn { todos: Array.isArray(data.todos) ? [...data.todos] : [] };\n}\n\n/**\n * Whether the session branch's LATEST `plan.state` snapshot knows a plan with\n * the given id (the same latest-snapshot semantics as {@link loadState} and\n * the same advisory pattern as the plan plugin's goalKnownToSession). The\n * check is advisory only (#10): a missing plan downgrades to a warning in the\n * tool response — the soft-reference write path never fails on it.\n */\nfunction planKnownToSession(api: CapabilityAPI, planId: string): boolean {\n\tconst entries = api.session?.getBranchEntries() ?? [];\n\tfor (let index = entries.length - 1; index >= 0; index -= 1) {\n\t\tconst entry = entries[index];\n\t\tif (entry.customType !== planStateEntry) continue;\n\t\tconst data = entry.data;\n\t\tif (!data || typeof data !== \"object\" || Array.isArray(data)) return false;\n\t\tconst plans = (data as { plans?: unknown }).plans;\n\t\tif (!Array.isArray(plans)) return false;\n\t\treturn plans.some(\n\t\t\t(plan) => plan !== null && typeof plan === \"object\" && (plan as { id?: unknown }).id === planId,\n\t\t);\n\t}\n\treturn false;\n}\n\nexport function createCapability(\n\tapi: CapabilityAPI,\n): Promise<readonly DisposableRegistration[]> | readonly DisposableRegistration[] {\n\tlet state = loadState(api);\n\n\tconst persist = async (): Promise<TodoState> => {\n\t\tapi.session?.appendEntry(stateEntry, state);\n\t\tawait api.publish({ type: \"todo.changed\", version: 1, correlationId: stateEntry, data: state });\n\t\treturn state;\n\t};\n\n\tconst tool = api.registerTool({\n\t\tname: \"todo_update\",\n\t\tlabel: \"Update todo\",\n\t\tdescription: \"Update a todo that softly references a plan by id\",\n\t\tparameters: todoSchema,\n\t\texecute: async (first: unknown, second?: unknown) => {\n\t\t\tconst input = objectInput(first, second);\n\t\t\tconst id = text(input.id, \"id\");\n\t\t\tconst planId = text(input.planId, \"planId\");\n\t\t\tconst title = text(input.title, \"title\");\n\t\t\tconst nextRevision = revision(input.revision);\n\t\t\tconst current = state.todos.find((item) => item.id === id);\n\t\t\tif (current && nextRevision <= current.revision) throw new Error(`stale todo revision: ${id}`);\n\t\t\tif (current?.status === \"done\") throw new Error(`todo is terminal and cannot be updated: ${id}`);\n\t\t\tconst status =\n\t\t\t\tinput.status === undefined\n\t\t\t\t\t? (current?.status ?? \"pending\")\n\t\t\t\t\t: (text(input.status, \"status\") as TodoRecord[\"status\"]);\n\t\t\tif (![\"pending\", \"done\", \"blocked\"].includes(status)) throw new Error(\"invalid todo status\");\n\t\t\tconst values = evidence(input.evidence);\n\t\t\tif (status === \"done\" && values.length === 0) {\n\t\t\t\tthrow new Error(\"todo completion requires at least one evidence reference\");\n\t\t\t}\n\t\t\tconst record: TodoRecord = { id, planId, title, status, revision: nextRevision, evidence: values };\n\t\t\tstate = { ...state, todos: [...state.todos.filter((item) => item.id !== id), record] };\n\t\t\tconst saved = await persist();\n\t\t\tif (planKnownToSession(api, planId)) return saved;\n\t\t\treturn {\n\t\t\t\t...saved,\n\t\t\t\twarning: `planId \"${planId}\" does not match any plan in this session's plan state; the todo keeps the soft reference, but the plan is unknown`,\n\t\t\t};\n\t\t},\n\t});\n\n\treturn [tool];\n}\n"]}
|
package/dist/index.js
ADDED
|
@@ -0,0 +1,136 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Todo-set capability plugin: a self-contained todo state machine, extracted
|
|
3
|
+
* from the host's `src/capabilities/todo-set.ts` (D-075 S4, first B-class
|
|
4
|
+
* batch).
|
|
5
|
+
*
|
|
6
|
+
* Todos persist as append-only `todo.state` session entries and every change
|
|
7
|
+
* is announced as a `todo.changed` event. `planId` is a soft reference: a
|
|
8
|
+
* plain string whose target is checked ADVISORILY against the plan plugin's
|
|
9
|
+
* LATEST `plan.state` snapshot (the same latest-snapshot semantics as this
|
|
10
|
+
* plugin's own {@link loadState}); an unknown id yields a response warning,
|
|
11
|
+
* never a failure (the same #10 pattern as the plan plugin's goalId check).
|
|
12
|
+
* The plugin only consumes the public `session`, `events`, and `tools`
|
|
13
|
+
* capabilities and never writes state owned by another plugin.
|
|
14
|
+
*/
|
|
15
|
+
import { Type } from "typebox";
|
|
16
|
+
const stateEntry = "todo.state";
|
|
17
|
+
/** Session protocol key of the plan plugin's snapshot entry (plugins/plan). */
|
|
18
|
+
const planStateEntry = "plan.state";
|
|
19
|
+
const todoSchema = Type.Object({
|
|
20
|
+
id: Type.String({ description: "Stable id of the todo to create or update" }),
|
|
21
|
+
planId: Type.String({
|
|
22
|
+
description: "Soft reference to a plan id; an id unknown to this session's plan state yields a response warning, not a failure",
|
|
23
|
+
}),
|
|
24
|
+
title: Type.String({ description: "Human-readable todo title" }),
|
|
25
|
+
revision: Type.Integer({
|
|
26
|
+
description: "New revision counter; must be greater than the stored revision of an existing todo",
|
|
27
|
+
minimum: 0,
|
|
28
|
+
}),
|
|
29
|
+
status: Type.Optional(Type.Union([Type.Literal("pending"), Type.Literal("done"), Type.Literal("blocked")], {
|
|
30
|
+
description: "Next status; defaults to the stored status for existing todos, otherwise pending",
|
|
31
|
+
})),
|
|
32
|
+
evidence: Type.Optional(Type.Array(Type.String(), {
|
|
33
|
+
description: "Evidence references; at least one is required when status is done",
|
|
34
|
+
})),
|
|
35
|
+
});
|
|
36
|
+
function objectInput(first, second) {
|
|
37
|
+
const value = second === undefined ? first : second;
|
|
38
|
+
if (!value || typeof value !== "object" || Array.isArray(value))
|
|
39
|
+
throw new Error("Todo input must be an object");
|
|
40
|
+
return value;
|
|
41
|
+
}
|
|
42
|
+
function text(value, name) {
|
|
43
|
+
if (typeof value !== "string" || value.trim() === "")
|
|
44
|
+
throw new Error(`${name} must be a non-empty string`);
|
|
45
|
+
return value;
|
|
46
|
+
}
|
|
47
|
+
function revision(value) {
|
|
48
|
+
if (!Number.isInteger(value) || value < 0)
|
|
49
|
+
throw new Error("revision must be a non-negative integer");
|
|
50
|
+
return value;
|
|
51
|
+
}
|
|
52
|
+
function evidence(value) {
|
|
53
|
+
if (value === undefined)
|
|
54
|
+
return [];
|
|
55
|
+
if (!Array.isArray(value) || value.some((item) => typeof item !== "string" || item.trim() === "")) {
|
|
56
|
+
throw new Error("evidence must be a string array");
|
|
57
|
+
}
|
|
58
|
+
return [...value];
|
|
59
|
+
}
|
|
60
|
+
function loadState(api) {
|
|
61
|
+
const entries = api.session?.getBranchEntries() ?? [];
|
|
62
|
+
const entry = [...entries].reverse().find((item) => item.customType === stateEntry);
|
|
63
|
+
if (!entry?.data || typeof entry.data !== "object")
|
|
64
|
+
return { todos: [] };
|
|
65
|
+
const data = entry.data;
|
|
66
|
+
return { todos: Array.isArray(data.todos) ? [...data.todos] : [] };
|
|
67
|
+
}
|
|
68
|
+
/**
|
|
69
|
+
* Whether the session branch's LATEST `plan.state` snapshot knows a plan with
|
|
70
|
+
* the given id (the same latest-snapshot semantics as {@link loadState} and
|
|
71
|
+
* the same advisory pattern as the plan plugin's goalKnownToSession). The
|
|
72
|
+
* check is advisory only (#10): a missing plan downgrades to a warning in the
|
|
73
|
+
* tool response — the soft-reference write path never fails on it.
|
|
74
|
+
*/
|
|
75
|
+
function planKnownToSession(api, planId) {
|
|
76
|
+
const entries = api.session?.getBranchEntries() ?? [];
|
|
77
|
+
for (let index = entries.length - 1; index >= 0; index -= 1) {
|
|
78
|
+
const entry = entries[index];
|
|
79
|
+
if (entry.customType !== planStateEntry)
|
|
80
|
+
continue;
|
|
81
|
+
const data = entry.data;
|
|
82
|
+
if (!data || typeof data !== "object" || Array.isArray(data))
|
|
83
|
+
return false;
|
|
84
|
+
const plans = data.plans;
|
|
85
|
+
if (!Array.isArray(plans))
|
|
86
|
+
return false;
|
|
87
|
+
return plans.some((plan) => plan !== null && typeof plan === "object" && plan.id === planId);
|
|
88
|
+
}
|
|
89
|
+
return false;
|
|
90
|
+
}
|
|
91
|
+
export function createCapability(api) {
|
|
92
|
+
let state = loadState(api);
|
|
93
|
+
const persist = async () => {
|
|
94
|
+
api.session?.appendEntry(stateEntry, state);
|
|
95
|
+
await api.publish({ type: "todo.changed", version: 1, correlationId: stateEntry, data: state });
|
|
96
|
+
return state;
|
|
97
|
+
};
|
|
98
|
+
const tool = api.registerTool({
|
|
99
|
+
name: "todo_update",
|
|
100
|
+
label: "Update todo",
|
|
101
|
+
description: "Update a todo that softly references a plan by id",
|
|
102
|
+
parameters: todoSchema,
|
|
103
|
+
execute: async (first, second) => {
|
|
104
|
+
const input = objectInput(first, second);
|
|
105
|
+
const id = text(input.id, "id");
|
|
106
|
+
const planId = text(input.planId, "planId");
|
|
107
|
+
const title = text(input.title, "title");
|
|
108
|
+
const nextRevision = revision(input.revision);
|
|
109
|
+
const current = state.todos.find((item) => item.id === id);
|
|
110
|
+
if (current && nextRevision <= current.revision)
|
|
111
|
+
throw new Error(`stale todo revision: ${id}`);
|
|
112
|
+
if (current?.status === "done")
|
|
113
|
+
throw new Error(`todo is terminal and cannot be updated: ${id}`);
|
|
114
|
+
const status = input.status === undefined
|
|
115
|
+
? (current?.status ?? "pending")
|
|
116
|
+
: text(input.status, "status");
|
|
117
|
+
if (!["pending", "done", "blocked"].includes(status))
|
|
118
|
+
throw new Error("invalid todo status");
|
|
119
|
+
const values = evidence(input.evidence);
|
|
120
|
+
if (status === "done" && values.length === 0) {
|
|
121
|
+
throw new Error("todo completion requires at least one evidence reference");
|
|
122
|
+
}
|
|
123
|
+
const record = { id, planId, title, status, revision: nextRevision, evidence: values };
|
|
124
|
+
state = { ...state, todos: [...state.todos.filter((item) => item.id !== id), record] };
|
|
125
|
+
const saved = await persist();
|
|
126
|
+
if (planKnownToSession(api, planId))
|
|
127
|
+
return saved;
|
|
128
|
+
return {
|
|
129
|
+
...saved,
|
|
130
|
+
warning: `planId "${planId}" does not match any plan in this session's plan state; the todo keeps the soft reference, but the plan is unknown`,
|
|
131
|
+
};
|
|
132
|
+
},
|
|
133
|
+
});
|
|
134
|
+
return [tool];
|
|
135
|
+
}
|
|
136
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;GAaG;AAEH,OAAO,EAAE,IAAI,EAAE,MAAM,SAAS,CAAC;AAiB/B,MAAM,UAAU,GAAG,YAAY,CAAC;AAChC,+EAA+E;AAC/E,MAAM,cAAc,GAAG,YAAY,CAAC;AAEpC,MAAM,UAAU,GAAG,IAAI,CAAC,MAAM,CAAC;IAC9B,EAAE,EAAE,IAAI,CAAC,MAAM,CAAC,EAAE,WAAW,EAAE,2CAA2C,EAAE,CAAC;IAC7E,MAAM,EAAE,IAAI,CAAC,MAAM,CAAC;QACnB,WAAW,EACV,kHAAkH;KACnH,CAAC;IACF,KAAK,EAAE,IAAI,CAAC,MAAM,CAAC,EAAE,WAAW,EAAE,2BAA2B,EAAE,CAAC;IAChE,QAAQ,EAAE,IAAI,CAAC,OAAO,CAAC;QACtB,WAAW,EAAE,oFAAoF;QACjG,OAAO,EAAE,CAAC;KACV,CAAC;IACF,MAAM,EAAE,IAAI,CAAC,QAAQ,CACpB,IAAI,CAAC,KAAK,CAAC,CAAC,IAAI,CAAC,OAAO,CAAC,SAAS,CAAC,EAAE,IAAI,CAAC,OAAO,CAAC,MAAM,CAAC,EAAE,IAAI,CAAC,OAAO,CAAC,SAAS,CAAC,CAAC,EAAE;QACpF,WAAW,EAAE,kFA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AAG,EAAE,GAAG,KAAK,EAAE,KAAK,EAAE,CAAC,GAAG,KAAK,CAAC,KAAK,CAAC,MAAM,CAAC,CAAC,IAAI,EAAE,EAAE,CAAC,IAAI,CAAC,EAAE,KAAK,EAAE,CAAC,EAAE,MAAM,CAAC,EAAE,CAAC;YACvF,MAAM,KAAK,GAAG,MAAM,OAAO,EAAE,CAAC;YAC9B,IAAI,kBAAkB,CAAC,GAAG,EAAE,MAAM,CAAC;gBAAE,OAAO,KAAK,CAAC;YAClD,OAAO;gBACN,GAAG,KAAK;gBACR,OAAO,EAAE,WAAW,MAAM,oHAAoH;aAC9I,CAAC;QAAA,CACF;KACD,CAAC,CAAC;IAEH,OAAO,CAAC,IAAI,CAAC,CAAC;AAAA,CACd","sourcesContent":["/**\n * Todo-set capability plugin: a self-contained todo state machine, extracted\n * from the host's `src/capabilities/todo-set.ts` (D-075 S4, first B-class\n * batch).\n *\n * Todos persist as append-only `todo.state` session entries and every change\n * is announced as a `todo.changed` event. `planId` is a soft reference: a\n * plain string whose target is checked ADVISORILY against the plan plugin's\n * LATEST `plan.state` snapshot (the same latest-snapshot semantics as this\n * plugin's own {@link loadState}); an unknown id yields a response warning,\n * never a failure (the same #10 pattern as the plan plugin's goalId check).\n * The plugin only consumes the public `session`, `events`, and `tools`\n * capabilities and never writes state owned by another plugin.\n */\n\nimport { Type } from \"typebox\";\nimport type { CapabilityAPI, DisposableRegistration } from \"@agent-forge/plugin-sdk\";\n\nexport interface TodoRecord {\n\tid: string;\n\t/** Soft reference: a plain string; unknown ids yield a response warning, not a failure. */\n\tplanId: string;\n\ttitle: string;\n\tstatus: \"pending\" | \"done\" | \"blocked\";\n\trevision: number;\n\tevidence: string[];\n}\n\nexport interface TodoState {\n\ttodos: TodoRecord[];\n}\n\nconst stateEntry = \"todo.state\";\n/** Session protocol key of the plan plugin's snapshot entry (plugins/plan). */\nconst planStateEntry = \"plan.state\";\n\nconst todoSchema = Type.Object({\n\tid: Type.String({ description: \"Stable id of the todo to create or update\" }),\n\tplanId: Type.String({\n\t\tdescription:\n\t\t\t\"Soft reference to a plan id; an id unknown to this session's plan state yields a response warning, not a failure\",\n\t}),\n\ttitle: Type.String({ description: \"Human-readable todo title\" }),\n\trevision: Type.Integer({\n\t\tdescription: \"New revision counter; must be greater than the stored revision of an existing todo\",\n\t\tminimum: 0,\n\t}),\n\tstatus: Type.Optional(\n\t\tType.Union([Type.Literal(\"pending\"), Type.Literal(\"done\"), Type.Literal(\"blocked\")], {\n\t\t\tdescription: \"Next status; defaults to the stored status for existing todos, otherwise pending\",\n\t\t}),\n\t),\n\tevidence: Type.Optional(\n\t\tType.Array(Type.String(), {\n\t\t\tdescription: \"Evidence references; at least one is required when status is done\",\n\t\t}),\n\t),\n});\n\nfunction objectInput(first: unknown, second: unknown): Record<string, unknown> {\n\tconst value = second === undefined ? first : second;\n\tif (!value || typeof value !== \"object\" || Array.isArray(value)) throw new Error(\"Todo input must be an object\");\n\treturn value as Record<string, unknown>;\n}\n\nfunction text(value: unknown, name: string): string {\n\tif (typeof value !== \"string\" || value.trim() === \"\") throw new Error(`${name} must be a non-empty string`);\n\treturn value;\n}\n\nfunction revision(value: unknown): number {\n\tif (!Number.isInteger(value) || (value as number) < 0) throw new Error(\"revision must be a non-negative integer\");\n\treturn value as number;\n}\n\nfunction evidence(value: unknown): string[] {\n\tif (value === undefined) return [];\n\tif (!Array.isArray(value) || value.some((item) => typeof item !== \"string\" || item.trim() === \"\")) {\n\t\tthrow new Error(\"evidence must be a string array\");\n\t}\n\treturn [...(value as string[])];\n}\n\nfunction loadState(api: CapabilityAPI): TodoState {\n\tconst entries = api.session?.getBranchEntries() ?? [];\n\tconst entry = [...entries].reverse().find((item) => item.customType === stateEntry);\n\tif (!entry?.data || typeof entry.data !== \"object\") return { todos: [] };\n\tconst data = entry.data as Partial<TodoState>;\n\treturn { todos: Array.isArray(data.todos) ? [...data.todos] : [] };\n}\n\n/**\n * Whether the session branch's LATEST `plan.state` snapshot knows a plan with\n * the given id (the same latest-snapshot semantics as {@link loadState} and\n * the same advisory pattern as the plan plugin's goalKnownToSession). The\n * check is advisory only (#10): a missing plan downgrades to a warning in the\n * tool response — the soft-reference write path never fails on it.\n */\nfunction planKnownToSession(api: CapabilityAPI, planId: string): boolean {\n\tconst entries = api.session?.getBranchEntries() ?? [];\n\tfor (let index = entries.length - 1; index >= 0; index -= 1) {\n\t\tconst entry = entries[index];\n\t\tif (entry.customType !== planStateEntry) continue;\n\t\tconst data = entry.data;\n\t\tif (!data || typeof data !== \"object\" || Array.isArray(data)) return false;\n\t\tconst plans = (data as { plans?: unknown }).plans;\n\t\tif (!Array.isArray(plans)) return false;\n\t\treturn plans.some(\n\t\t\t(plan) => plan !== null && typeof plan === \"object\" && (plan as { id?: unknown }).id === planId,\n\t\t);\n\t}\n\treturn false;\n}\n\nexport function createCapability(\n\tapi: CapabilityAPI,\n): Promise<readonly DisposableRegistration[]> | readonly DisposableRegistration[] {\n\tlet state = loadState(api);\n\n\tconst persist = async (): Promise<TodoState> => {\n\t\tapi.session?.appendEntry(stateEntry, state);\n\t\tawait api.publish({ type: \"todo.changed\", version: 1, correlationId: stateEntry, data: state });\n\t\treturn state;\n\t};\n\n\tconst tool = api.registerTool({\n\t\tname: \"todo_update\",\n\t\tlabel: \"Update todo\",\n\t\tdescription: \"Update a todo that softly references a plan by id\",\n\t\tparameters: todoSchema,\n\t\texecute: async (first: unknown, second?: unknown) => {\n\t\t\tconst input = objectInput(first, second);\n\t\t\tconst id = text(input.id, \"id\");\n\t\t\tconst planId = text(input.planId, \"planId\");\n\t\t\tconst title = text(input.title, \"title\");\n\t\t\tconst nextRevision = revision(input.revision);\n\t\t\tconst current = state.todos.find((item) => item.id === id);\n\t\t\tif (current && nextRevision <= current.revision) throw new Error(`stale todo revision: ${id}`);\n\t\t\tif (current?.status === \"done\") throw new Error(`todo is terminal and cannot be updated: ${id}`);\n\t\t\tconst status =\n\t\t\t\tinput.status === undefined\n\t\t\t\t\t? (current?.status ?? \"pending\")\n\t\t\t\t\t: (text(input.status, \"status\") as TodoRecord[\"status\"]);\n\t\t\tif (![\"pending\", \"done\", \"blocked\"].includes(status)) throw new Error(\"invalid todo status\");\n\t\t\tconst values = evidence(input.evidence);\n\t\t\tif (status === \"done\" && values.length === 0) {\n\t\t\t\tthrow new Error(\"todo completion requires at least one evidence reference\");\n\t\t\t}\n\t\t\tconst record: TodoRecord = { id, planId, title, status, revision: nextRevision, evidence: values };\n\t\t\tstate = { ...state, todos: [...state.todos.filter((item) => item.id !== id), record] };\n\t\t\tconst saved = await persist();\n\t\t\tif (planKnownToSession(api, planId)) return saved;\n\t\t\treturn {\n\t\t\t\t...saved,\n\t\t\t\twarning: `planId \"${planId}\" does not match any plan in this session's plan state; the todo keeps the soft reference, but the plan is unknown`,\n\t\t\t};\n\t\t},\n\t});\n\n\treturn [tool];\n}\n"]}
|
package/package.json
ADDED
|
@@ -0,0 +1,54 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "@ai-agent-forge/plugin-todo-set",
|
|
3
|
+
"version": "0.85.0",
|
|
4
|
+
"description": "Todo-set capability plugin for Agent Forge (todo_update state machine over session entries)",
|
|
5
|
+
"type": "module",
|
|
6
|
+
"main": "./dist/index.js",
|
|
7
|
+
"types": "./dist/index.d.ts",
|
|
8
|
+
"exports": {
|
|
9
|
+
".": {
|
|
10
|
+
"types": "./dist/index.d.ts",
|
|
11
|
+
"import": "./dist/index.js"
|
|
12
|
+
}
|
|
13
|
+
},
|
|
14
|
+
"files": [
|
|
15
|
+
"dist",
|
|
16
|
+
"agent-forge.json",
|
|
17
|
+
"plugin.json",
|
|
18
|
+
"README.md"
|
|
19
|
+
],
|
|
20
|
+
"scripts": {
|
|
21
|
+
"clean": "shx rm -rf dist",
|
|
22
|
+
"build": "tsgo -p tsconfig.build.json",
|
|
23
|
+
"test": "vitest --run",
|
|
24
|
+
"prepublishOnly": "npm run clean && npm run build"
|
|
25
|
+
},
|
|
26
|
+
"keywords": [
|
|
27
|
+
"agent-forge",
|
|
28
|
+
"plugin",
|
|
29
|
+
"todo"
|
|
30
|
+
],
|
|
31
|
+
"author": "Agent Forge contributors",
|
|
32
|
+
"license": "MIT",
|
|
33
|
+
"repository": {
|
|
34
|
+
"type": "git",
|
|
35
|
+
"url": "git+https://github.com/agent-forge/agent-forge.git",
|
|
36
|
+
"directory": "plugins/todo-set"
|
|
37
|
+
},
|
|
38
|
+
"bugs": {
|
|
39
|
+
"url": "https://github.com/agent-forge/agent-forge/issues"
|
|
40
|
+
},
|
|
41
|
+
"homepage": "https://github.com/agent-forge/agent-forge#readme",
|
|
42
|
+
"engines": {
|
|
43
|
+
"node": ">=22.19.0"
|
|
44
|
+
},
|
|
45
|
+
"dependencies": {
|
|
46
|
+
"@agent-forge/plugin-sdk": "^0.85.0",
|
|
47
|
+
"typebox": "1.3.27"
|
|
48
|
+
},
|
|
49
|
+
"devDependencies": {
|
|
50
|
+
"@agent-forge/agent-forge": "^0.85.0",
|
|
51
|
+
"shx": "0.4.0",
|
|
52
|
+
"vitest": "4.1.9"
|
|
53
|
+
}
|
|
54
|
+
}
|