@parcha/agentrun-dsl 0.1.0-beta.3 → 0.1.0-beta.4
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/author.d.ts +3 -0
- package/dist/author.js +5 -0
- package/dist/index.d.ts +2 -2
- package/dist/index.js +1 -1
- package/dist/vocabulary.d.ts +3 -0
- package/dist/vocabulary.js +3 -0
- package/dist/workflow-shape.js +4 -0
- package/dist/workflow.d.ts +22 -0
- package/dist/workflow.js +2 -2
- package/package.json +1 -1
- package/schema/workflow.schema.json +102 -0
- package/skills/author/references/language.md +2 -0
package/dist/author.d.ts
CHANGED
|
@@ -16,6 +16,9 @@ export interface AuthorHostAddendum {
|
|
|
16
16
|
}>>;
|
|
17
17
|
/** The node kinds the host runs. Declared, a candidate using any other kind is refused. */
|
|
18
18
|
nodeKinds?: readonly WorkflowNodeKind[];
|
|
19
|
+
/** The node `metadata` keys an author may set, each with what it holds. Undeclared, an author sets no
|
|
20
|
+
* metadata. The engine never reads them; the host enforces them in its own acceptance checks. */
|
|
21
|
+
metadataKeys?: Readonly<Record<string, string>>;
|
|
19
22
|
/** Host rules, one sentence each. The host enforces them in its own acceptance checks. */
|
|
20
23
|
rules?: readonly string[];
|
|
21
24
|
}
|
package/dist/author.js
CHANGED
|
@@ -44,6 +44,8 @@ A workflow is {"v":2,"name","schemas","input"?,"output","root"}.
|
|
|
44
44
|
This is the complete set. Each kind accepts exactly these fields; any other field is an error.
|
|
45
45
|
${nodeFieldLines()}
|
|
46
46
|
|
|
47
|
+
Every kind also accepts ${code("metadata")}, an object the host owns and the engine never reads; set only the keys the host addendum names.
|
|
48
|
+
|
|
47
49
|
### Generative nodes: ${GENERATIVE_NODE_KINDS.join(", ")}
|
|
48
50
|
|
|
49
51
|
Each runs one adapter session. A kind is a preset (its duty, default effort and model tier), not a capability limit:
|
|
@@ -123,6 +125,9 @@ export function renderAuthorHostAddendum(host) {
|
|
|
123
125
|
const types = Object.entries(host.outputTypes).map(([type, spec]) => `${code(type)} (${spec.kind === "prose" ? "prose: the report writer, with the report's fields" : `file: ${code("path")} names the file an earlier shell call produced`}; ${spec.description})`);
|
|
124
126
|
lines.push(`- A terminal artifact's ${code("type")} is one of: ${types.join("; ")}.`);
|
|
125
127
|
}
|
|
128
|
+
if (host.metadataKeys && Object.keys(host.metadataKeys).length) {
|
|
129
|
+
lines.push(`- A node's ${code("metadata")} may carry only these keys: ${Object.entries(host.metadataKeys).map(([key, description]) => `${code(key)} (${description})`).join("; ")}.`);
|
|
130
|
+
}
|
|
126
131
|
if (host.nodeKinds)
|
|
127
132
|
lines.push(`- This host runs only these node kinds: ${list(host.nodeKinds)}. Author no other kind.`);
|
|
128
133
|
for (const rule of host.rules ?? [])
|
package/dist/index.d.ts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
export { defineWorkflow, runTypedWorkflow, WorkflowSchemaConversionError } from "./authoring.js";
|
|
2
2
|
export type { StandardJSONSchema, AuthoringSchema, TypedWorkflow, TypedWorkflowRunResult, WorkflowInput, WorkflowOutput, } from "./authoring.js";
|
|
3
3
|
export { runWorkflow, validateWorkflow, workflowSha256, WorkflowInvalidError, WorkflowInputInvalidError, WorkflowOutputInvalidError, WorkflowCodeError, WorkflowStateError, WorkflowVerificationError, EffectFailure, EffectDeadlineExceededError, EffectOutcomeUnknownError, EscalationSignal, } from "./workflow.js";
|
|
4
|
-
export type { Workflow, WorkflowNode, WorkflowDeps, WorkflowRunResult, HostPolicy, HostPolicyContext, Escalation, EffectSettlement, MapItem, LlmNode, JudgeNode, PickNode, SiftNode, RouteNode, WorkflowInvocation, ArtifactNode, ArtifactState, CallNode, CallRetryClass, CallPredicate, PollClause, ModelTier, WorkflowEffort, WorkflowThinking, VerifyClause, AskPredicate, MechanicalPredicate, Predicate, } from "./workflow.js";
|
|
4
|
+
export type { Workflow, WorkflowNode, NodeMetadata, WorkflowDeps, WorkflowRunResult, HostPolicy, HostPolicyContext, Escalation, EffectSettlement, MapItem, LlmNode, JudgeNode, PickNode, SiftNode, RouteNode, WorkflowInvocation, ArtifactNode, ArtifactState, CallNode, CallRetryClass, CallPredicate, PollClause, ModelTier, WorkflowEffort, WorkflowThinking, VerifyClause, AskPredicate, MechanicalPredicate, Predicate, } from "./workflow.js";
|
|
5
5
|
export { dryRunWorkflow, synthesizeInstance } from "./dry-run.js";
|
|
6
6
|
export type { DryRunOptions, DryRunResult } from "./dry-run.js";
|
|
7
7
|
export { compileQuestions, validateAnswers, answersToValue, answersSidecar, answerConfidence, synthesizeAnswers, SYSTEM_ONE_LIMITS, SystemOneError, isSystemOneResponseReason, } from "./system-one.js";
|
|
@@ -15,5 +15,5 @@ export { getPath, predicateMatches } from "./predicates.js";
|
|
|
15
15
|
export type { StopPredicate, AcceptPredicate } from "./predicates.js";
|
|
16
16
|
export { authorContract, renderAuthorContract, renderAuthorHostAddendum, candidatePolicyErrors, applyHostOutputTypes, authorWorkflow, AUTHOR_SKILL_NAME, authorSkillDirectory, loadAuthorReference, loadAuthorSkillBundle, } from "./author.js";
|
|
17
17
|
export type { AuthorHostAddendum, CandidatePolicyOptions, AuthorWorkflowOptions, AuthoredWorkflow } from "./author.js";
|
|
18
|
-
export { WORKFLOW_NODE_KINDS, GENERATIVE_NODE_KINDS, JUDGMENT_NODE_KINDS, NODE_FIELDS, IGNORED_NODE_FIELDS, MECHANICAL_PREDICATES, WORKFLOW_PREDICATES, PREDICATE_FIELDS, EFFORT_LEVELS, THINKING_LEVELS, MODEL_TIERS, CALL_TRANSPORTS, CALL_RETRY_CLASSES, PROSE_ARTIFACT_TYPES, } from "./vocabulary.js";
|
|
18
|
+
export { WORKFLOW_NODE_KINDS, GENERATIVE_NODE_KINDS, JUDGMENT_NODE_KINDS, NODE_FIELDS, HOST_NODE_FIELDS, IGNORED_NODE_FIELDS, MECHANICAL_PREDICATES, WORKFLOW_PREDICATES, PREDICATE_FIELDS, EFFORT_LEVELS, THINKING_LEVELS, MODEL_TIERS, CALL_TRANSPORTS, CALL_RETRY_CLASSES, PROSE_ARTIFACT_TYPES, } from "./vocabulary.js";
|
|
19
19
|
export type { WorkflowNodeKind, WorkflowPredicateName } from "./vocabulary.js";
|
package/dist/index.js
CHANGED
|
@@ -12,4 +12,4 @@ export { compileTransform, compileTransformSyntax } from "./code-exec.js";
|
|
|
12
12
|
export { resolveSchemaForWorkflow } from "./schema-references.js";
|
|
13
13
|
export { getPath, predicateMatches } from "./predicates.js";
|
|
14
14
|
export { authorContract, renderAuthorContract, renderAuthorHostAddendum, candidatePolicyErrors, applyHostOutputTypes, authorWorkflow, AUTHOR_SKILL_NAME, authorSkillDirectory, loadAuthorReference, loadAuthorSkillBundle, } from "./author.js";
|
|
15
|
-
export { WORKFLOW_NODE_KINDS, GENERATIVE_NODE_KINDS, JUDGMENT_NODE_KINDS, NODE_FIELDS, IGNORED_NODE_FIELDS, MECHANICAL_PREDICATES, WORKFLOW_PREDICATES, PREDICATE_FIELDS, EFFORT_LEVELS, THINKING_LEVELS, MODEL_TIERS, CALL_TRANSPORTS, CALL_RETRY_CLASSES, PROSE_ARTIFACT_TYPES, } from "./vocabulary.js";
|
|
15
|
+
export { WORKFLOW_NODE_KINDS, GENERATIVE_NODE_KINDS, JUDGMENT_NODE_KINDS, NODE_FIELDS, HOST_NODE_FIELDS, IGNORED_NODE_FIELDS, MECHANICAL_PREDICATES, WORKFLOW_PREDICATES, PREDICATE_FIELDS, EFFORT_LEVELS, THINKING_LEVELS, MODEL_TIERS, CALL_TRANSPORTS, CALL_RETRY_CLASSES, PROSE_ARTIFACT_TYPES, } from "./vocabulary.js";
|
package/dist/vocabulary.d.ts
CHANGED
|
@@ -8,6 +8,9 @@ export declare const JUDGMENT_NODE_KINDS: readonly ["judge", "pick", "sift", "ro
|
|
|
8
8
|
export declare const NODE_FIELDS: {
|
|
9
9
|
readonly [Kind in WorkflowNodeKind]: readonly string[];
|
|
10
10
|
};
|
|
11
|
+
/** Fields every node kind accepts in addition to its own. `metadata` is the host's: an optional object of
|
|
12
|
+
* host markers the engine admits, carries and hashes with the document, and never reads. */
|
|
13
|
+
export declare const HOST_NODE_FIELDS: readonly ["metadata"];
|
|
11
14
|
/** Accepted and ignored for older v2 documents; never taught. The engine invokes the adapter once per node. */
|
|
12
15
|
export declare const IGNORED_NODE_FIELDS: {
|
|
13
16
|
readonly [Kind in WorkflowNodeKind]?: readonly string[];
|
package/dist/vocabulary.js
CHANGED
|
@@ -29,6 +29,9 @@ export const NODE_FIELDS = {
|
|
|
29
29
|
sift: ["node", "label", "itemsPath", "describe", "state", "out", "as", "keep", "requires"],
|
|
30
30
|
route: ["node", "label", "state", "instructions", "branches", "unsure", "as", "requires"],
|
|
31
31
|
};
|
|
32
|
+
/** Fields every node kind accepts in addition to its own. `metadata` is the host's: an optional object of
|
|
33
|
+
* host markers the engine admits, carries and hashes with the document, and never reads. */
|
|
34
|
+
export const HOST_NODE_FIELDS = ["metadata"];
|
|
32
35
|
/** Accepted and ignored for older v2 documents; never taught. The engine invokes the adapter once per node. */
|
|
33
36
|
export const IGNORED_NODE_FIELDS = {
|
|
34
37
|
agent: ["budget"],
|
package/dist/workflow-shape.js
CHANGED
|
@@ -124,6 +124,10 @@ export function workflowShapeErrors(value, complete = false) {
|
|
|
124
124
|
stringList(entry.sopSection, `${path}.sopSection`);
|
|
125
125
|
for (const key of ["state", "args", "input", "env"])
|
|
126
126
|
objectField(entry, path, key);
|
|
127
|
+
// Host-owned and opaque: only its container is checked, never its keys or values.
|
|
128
|
+
if (entry.metadata !== undefined && !isRecord(entry.metadata)) {
|
|
129
|
+
errors.push(`${path} (${typeof entry.label === "string" && entry.label ? entry.label : String(entry.node)}): metadata must be a plain object of host markers`);
|
|
130
|
+
}
|
|
127
131
|
for (const key of ["until", "when"])
|
|
128
132
|
objectField(entry, path, key, predicate);
|
|
129
133
|
objectField(entry, path, "verify", (verify, at) => {
|
package/dist/workflow.d.ts
CHANGED
|
@@ -28,14 +28,21 @@ export type Predicate = MechanicalPredicate | AskPredicate;
|
|
|
28
28
|
export type WorkflowEffort = "minimal" | "low" | "medium" | "high";
|
|
29
29
|
/** The author's thinking dial. There is deliberately no "off": thinking is never off. */
|
|
30
30
|
export type WorkflowThinking = "low" | "medium" | "high";
|
|
31
|
+
/** Host-owned markers on a node: any JSON object. The engine admits, carries and hashes it with the
|
|
32
|
+
* document and never reads it; it never reaches state, events, prompts or effect identities. */
|
|
33
|
+
export type NodeMetadata = {
|
|
34
|
+
[key: string]: unknown;
|
|
35
|
+
};
|
|
31
36
|
export type WorkflowNode = {
|
|
32
37
|
node: "chain";
|
|
33
38
|
steps: WorkflowNode[];
|
|
39
|
+
metadata?: NodeMetadata;
|
|
34
40
|
} | {
|
|
35
41
|
node: "code";
|
|
36
42
|
label: string;
|
|
37
43
|
code: string;
|
|
38
44
|
as?: string;
|
|
45
|
+
metadata?: NodeMetadata;
|
|
39
46
|
} | {
|
|
40
47
|
node: "agent";
|
|
41
48
|
label: string;
|
|
@@ -50,6 +57,7 @@ export type WorkflowNode = {
|
|
|
50
57
|
thinking?: WorkflowThinking;
|
|
51
58
|
verify?: VerifyClause;
|
|
52
59
|
tier?: ModelTier;
|
|
60
|
+
metadata?: NodeMetadata;
|
|
53
61
|
} | {
|
|
54
62
|
node: "decide";
|
|
55
63
|
label: string;
|
|
@@ -64,6 +72,7 @@ export type WorkflowNode = {
|
|
|
64
72
|
thinking?: WorkflowThinking;
|
|
65
73
|
verify?: VerifyClause;
|
|
66
74
|
tier?: ModelTier;
|
|
75
|
+
metadata?: NodeMetadata;
|
|
67
76
|
} | {
|
|
68
77
|
node: "extract";
|
|
69
78
|
label: string;
|
|
@@ -78,6 +87,7 @@ export type WorkflowNode = {
|
|
|
78
87
|
thinking?: WorkflowThinking;
|
|
79
88
|
verify?: VerifyClause;
|
|
80
89
|
tier?: ModelTier;
|
|
90
|
+
metadata?: NodeMetadata;
|
|
81
91
|
} | {
|
|
82
92
|
node: "report";
|
|
83
93
|
label: string;
|
|
@@ -88,6 +98,7 @@ export type WorkflowNode = {
|
|
|
88
98
|
tools?: string[];
|
|
89
99
|
effort?: WorkflowEffort;
|
|
90
100
|
thinking?: WorkflowThinking;
|
|
101
|
+
metadata?: NodeMetadata;
|
|
91
102
|
} | ArtifactNode | {
|
|
92
103
|
node: "map";
|
|
93
104
|
label: string;
|
|
@@ -96,16 +107,19 @@ export type WorkflowNode = {
|
|
|
96
107
|
as: string;
|
|
97
108
|
resultPath?: string;
|
|
98
109
|
maxConcurrency?: number;
|
|
110
|
+
metadata?: NodeMetadata;
|
|
99
111
|
} | {
|
|
100
112
|
node: "parallel";
|
|
101
113
|
label: string;
|
|
102
114
|
branches: WorkflowNode[];
|
|
115
|
+
metadata?: NodeMetadata;
|
|
103
116
|
} | {
|
|
104
117
|
node: "loop";
|
|
105
118
|
label: string;
|
|
106
119
|
body: WorkflowNode;
|
|
107
120
|
until: Predicate;
|
|
108
121
|
maxIters: number;
|
|
122
|
+
metadata?: NodeMetadata;
|
|
109
123
|
} | {
|
|
110
124
|
node: "escalate";
|
|
111
125
|
label: string;
|
|
@@ -113,6 +127,7 @@ export type WorkflowNode = {
|
|
|
113
127
|
kind: string;
|
|
114
128
|
stage: string;
|
|
115
129
|
summary: string;
|
|
130
|
+
metadata?: NodeMetadata;
|
|
116
131
|
} | JudgeNode | PickNode | SiftNode | RouteNode | CallNode | WorkflowInvocation;
|
|
117
132
|
/** A judgment as typed questions. `state` is what the questions see, interpolated by value from the
|
|
118
133
|
* workflow state (a whole-string placeholder keeps its type); `out` is a flat schema of enums,
|
|
@@ -125,6 +140,7 @@ export type JudgeNode = {
|
|
|
125
140
|
out: string;
|
|
126
141
|
as: string;
|
|
127
142
|
requires?: string[];
|
|
143
|
+
metadata?: NodeMetadata;
|
|
128
144
|
};
|
|
129
145
|
/** One choice whose options are the items of a list. `describe` renders each item as its option
|
|
130
146
|
* text (`{item.field}`); `allowNone` adds a none-of-these option. The result at `as` is
|
|
@@ -140,6 +156,7 @@ export type PickNode = {
|
|
|
140
156
|
allowNone?: boolean;
|
|
141
157
|
as: string;
|
|
142
158
|
requires?: string[];
|
|
159
|
+
metadata?: NodeMetadata;
|
|
143
160
|
};
|
|
144
161
|
/** The same question set (`out`, a judge schema) asked of every item of a list in ONE request: item i's
|
|
145
162
|
* questions are prefixed `i.`; every answer lands in `as.answers[i]` and `as.values[i]`. `keep`
|
|
@@ -158,6 +175,7 @@ export type SiftNode = {
|
|
|
158
175
|
gte?: number;
|
|
159
176
|
};
|
|
160
177
|
requires?: string[];
|
|
178
|
+
metadata?: NodeMetadata;
|
|
161
179
|
};
|
|
162
180
|
/** A choice among subgraphs. The options are the branch names, their criteria the branch
|
|
163
181
|
* descriptions; the chosen branch runs on the state. `as` (optional) records the choice and its
|
|
@@ -179,6 +197,7 @@ export type RouteNode = {
|
|
|
179
197
|
};
|
|
180
198
|
as?: string;
|
|
181
199
|
requires?: string[];
|
|
200
|
+
metadata?: NodeMetadata;
|
|
182
201
|
};
|
|
183
202
|
/** A child workflow invoked as one step of its parent. The child is embedded whole, so the parent
|
|
184
203
|
* digest covers every child byte; `input` is interpolated by value and is the child's ENTIRE initial
|
|
@@ -192,6 +211,7 @@ export type WorkflowInvocation = {
|
|
|
192
211
|
input: Record<string, unknown>;
|
|
193
212
|
out: string;
|
|
194
213
|
as: string;
|
|
214
|
+
metadata?: NodeMetadata;
|
|
195
215
|
};
|
|
196
216
|
/** `exit` is a shell command that ended with a non-zero status: retried only when the author
|
|
197
217
|
* declared retry, since re-running a command is the author's call. */
|
|
@@ -214,6 +234,7 @@ export type ArtifactNode = {
|
|
|
214
234
|
effort?: WorkflowEffort;
|
|
215
235
|
thinking?: WorkflowThinking;
|
|
216
236
|
requires?: string[];
|
|
237
|
+
metadata?: NodeMetadata;
|
|
217
238
|
};
|
|
218
239
|
export type ArtifactState = {
|
|
219
240
|
path: string;
|
|
@@ -271,6 +292,7 @@ export type CallNode = {
|
|
|
271
292
|
/** Repeat the call until its result settles (a queued job, an eventually consistent read). */
|
|
272
293
|
poll?: PollClause;
|
|
273
294
|
requires?: string[];
|
|
295
|
+
metadata?: NodeMetadata;
|
|
274
296
|
};
|
|
275
297
|
export declare const SHELL_RESULT_SCHEMA: Record<string, unknown>;
|
|
276
298
|
export type LlmNode = Extract<WorkflowNode, {
|
package/dist/workflow.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { createHash } from "node:crypto";
|
|
2
2
|
import { isDeepStrictEqual, types as utilTypes } from "node:util";
|
|
3
3
|
import { predicateMatches, getPath, MECHANICAL_PREDICATE_NAMES } from "./predicates.js";
|
|
4
|
-
import { WORKFLOW_NODE_KINDS, NODE_FIELDS, IGNORED_NODE_FIELDS, WORKFLOW_PREDICATES, THINKING_LEVELS, MODEL_TIERS, CALL_TRANSPORTS, CALL_RETRY_CLASSES, PROSE_ARTIFACT_TYPES } from "./vocabulary.js";
|
|
4
|
+
import { WORKFLOW_NODE_KINDS, NODE_FIELDS, HOST_NODE_FIELDS, IGNORED_NODE_FIELDS, WORKFLOW_PREDICATES, THINKING_LEVELS, MODEL_TIERS, CALL_TRANSPORTS, CALL_RETRY_CLASSES, PROSE_ARTIFACT_TYPES } from "./vocabulary.js";
|
|
5
5
|
import { validateAnswers, answerConfidence, answersSidecar, answersToValue, compileQuestions, SYSTEM_ONE_LIMITS } from "./system-one.js";
|
|
6
6
|
import { Compile } from "typebox/compile";
|
|
7
7
|
import { compileTransform, compileTransformSyntax } from "./code-exec.js";
|
|
@@ -123,7 +123,7 @@ const snapshotState = (state) => {
|
|
|
123
123
|
const KINDS = new Set(WORKFLOW_NODE_KINDS);
|
|
124
124
|
const kindsMatchType = true;
|
|
125
125
|
void kindsMatchType;
|
|
126
|
-
const KIND_KEYS = Object.fromEntries(WORKFLOW_NODE_KINDS.map((kind) => [kind, new Set([...NODE_FIELDS[kind], ...(IGNORED_NODE_FIELDS[kind] ?? [])])]));
|
|
126
|
+
const KIND_KEYS = Object.fromEntries(WORKFLOW_NODE_KINDS.map((kind) => [kind, new Set([...NODE_FIELDS[kind], ...HOST_NODE_FIELDS, ...(IGNORED_NODE_FIELDS[kind] ?? [])])]));
|
|
127
127
|
export const childSteps = (child) => {
|
|
128
128
|
const root = child?.root;
|
|
129
129
|
if (!root || typeof root !== "object")
|
package/package.json
CHANGED
|
@@ -18,6 +18,12 @@
|
|
|
18
18
|
"$ref": "#/definitions/WorkflowNode"
|
|
19
19
|
},
|
|
20
20
|
"title": "steps"
|
|
21
|
+
},
|
|
22
|
+
"metadata": {
|
|
23
|
+
"description": "Host-owned markers on a node: any JSON object. The engine admits, carries and hashes it with the\ndocument and never reads it; it never reaches state, events, prompts or effect identities.",
|
|
24
|
+
"type": "object",
|
|
25
|
+
"additionalProperties": {},
|
|
26
|
+
"title": "metadata"
|
|
21
27
|
}
|
|
22
28
|
},
|
|
23
29
|
"required": [
|
|
@@ -44,6 +50,12 @@
|
|
|
44
50
|
"as": {
|
|
45
51
|
"type": "string",
|
|
46
52
|
"title": "as"
|
|
53
|
+
},
|
|
54
|
+
"metadata": {
|
|
55
|
+
"description": "Host-owned markers on a node: any JSON object. The engine admits, carries and hashes it with the\ndocument and never reads it; it never reaches state, events, prompts or effect identities.",
|
|
56
|
+
"type": "object",
|
|
57
|
+
"additionalProperties": {},
|
|
58
|
+
"title": "metadata"
|
|
47
59
|
}
|
|
48
60
|
},
|
|
49
61
|
"required": [
|
|
@@ -171,6 +183,12 @@
|
|
|
171
183
|
],
|
|
172
184
|
"type": "string",
|
|
173
185
|
"title": "tier"
|
|
186
|
+
},
|
|
187
|
+
"metadata": {
|
|
188
|
+
"description": "Host-owned markers on a node: any JSON object. The engine admits, carries and hashes it with the\ndocument and never reads it; it never reaches state, events, prompts or effect identities.",
|
|
189
|
+
"type": "object",
|
|
190
|
+
"additionalProperties": {},
|
|
191
|
+
"title": "metadata"
|
|
174
192
|
}
|
|
175
193
|
},
|
|
176
194
|
"required": [
|
|
@@ -299,6 +317,12 @@
|
|
|
299
317
|
],
|
|
300
318
|
"type": "string",
|
|
301
319
|
"title": "tier"
|
|
320
|
+
},
|
|
321
|
+
"metadata": {
|
|
322
|
+
"description": "Host-owned markers on a node: any JSON object. The engine admits, carries and hashes it with the\ndocument and never reads it; it never reaches state, events, prompts or effect identities.",
|
|
323
|
+
"type": "object",
|
|
324
|
+
"additionalProperties": {},
|
|
325
|
+
"title": "metadata"
|
|
302
326
|
}
|
|
303
327
|
},
|
|
304
328
|
"required": [
|
|
@@ -427,6 +451,12 @@
|
|
|
427
451
|
],
|
|
428
452
|
"type": "string",
|
|
429
453
|
"title": "tier"
|
|
454
|
+
},
|
|
455
|
+
"metadata": {
|
|
456
|
+
"description": "Host-owned markers on a node: any JSON object. The engine admits, carries and hashes it with the\ndocument and never reads it; it never reaches state, events, prompts or effect identities.",
|
|
457
|
+
"type": "object",
|
|
458
|
+
"additionalProperties": {},
|
|
459
|
+
"title": "metadata"
|
|
430
460
|
}
|
|
431
461
|
},
|
|
432
462
|
"required": [
|
|
@@ -503,6 +533,12 @@
|
|
|
503
533
|
],
|
|
504
534
|
"type": "string",
|
|
505
535
|
"title": "thinking"
|
|
536
|
+
},
|
|
537
|
+
"metadata": {
|
|
538
|
+
"description": "Host-owned markers on a node: any JSON object. The engine admits, carries and hashes it with the\ndocument and never reads it; it never reaches state, events, prompts or effect identities.",
|
|
539
|
+
"type": "object",
|
|
540
|
+
"additionalProperties": {},
|
|
541
|
+
"title": "metadata"
|
|
506
542
|
}
|
|
507
543
|
},
|
|
508
544
|
"required": [
|
|
@@ -590,6 +626,12 @@
|
|
|
590
626
|
"type": "string"
|
|
591
627
|
},
|
|
592
628
|
"title": "requires"
|
|
629
|
+
},
|
|
630
|
+
"metadata": {
|
|
631
|
+
"description": "Host-owned markers on a node: any JSON object. The engine admits, carries and hashes it with the\ndocument and never reads it; it never reaches state, events, prompts or effect identities.",
|
|
632
|
+
"type": "object",
|
|
633
|
+
"additionalProperties": {},
|
|
634
|
+
"title": "metadata"
|
|
593
635
|
}
|
|
594
636
|
},
|
|
595
637
|
"required": [
|
|
@@ -629,6 +671,12 @@
|
|
|
629
671
|
"maxConcurrency": {
|
|
630
672
|
"type": "number",
|
|
631
673
|
"title": "maxConcurrency"
|
|
674
|
+
},
|
|
675
|
+
"metadata": {
|
|
676
|
+
"description": "Host-owned markers on a node: any JSON object. The engine admits, carries and hashes it with the\ndocument and never reads it; it never reaches state, events, prompts or effect identities.",
|
|
677
|
+
"type": "object",
|
|
678
|
+
"additionalProperties": {},
|
|
679
|
+
"title": "metadata"
|
|
632
680
|
}
|
|
633
681
|
},
|
|
634
682
|
"required": [
|
|
@@ -657,6 +705,12 @@
|
|
|
657
705
|
"$ref": "#/definitions/WorkflowNode"
|
|
658
706
|
},
|
|
659
707
|
"title": "branches"
|
|
708
|
+
},
|
|
709
|
+
"metadata": {
|
|
710
|
+
"description": "Host-owned markers on a node: any JSON object. The engine admits, carries and hashes it with the\ndocument and never reads it; it never reaches state, events, prompts or effect identities.",
|
|
711
|
+
"type": "object",
|
|
712
|
+
"additionalProperties": {},
|
|
713
|
+
"title": "metadata"
|
|
660
714
|
}
|
|
661
715
|
},
|
|
662
716
|
"required": [
|
|
@@ -688,6 +742,12 @@
|
|
|
688
742
|
"maxIters": {
|
|
689
743
|
"type": "number",
|
|
690
744
|
"title": "maxIters"
|
|
745
|
+
},
|
|
746
|
+
"metadata": {
|
|
747
|
+
"description": "Host-owned markers on a node: any JSON object. The engine admits, carries and hashes it with the\ndocument and never reads it; it never reaches state, events, prompts or effect identities.",
|
|
748
|
+
"type": "object",
|
|
749
|
+
"additionalProperties": {},
|
|
750
|
+
"title": "metadata"
|
|
691
751
|
}
|
|
692
752
|
},
|
|
693
753
|
"required": [
|
|
@@ -725,6 +785,12 @@
|
|
|
725
785
|
"summary": {
|
|
726
786
|
"type": "string",
|
|
727
787
|
"title": "summary"
|
|
788
|
+
},
|
|
789
|
+
"metadata": {
|
|
790
|
+
"description": "Host-owned markers on a node: any JSON object. The engine admits, carries and hashes it with the\ndocument and never reads it; it never reaches state, events, prompts or effect identities.",
|
|
791
|
+
"type": "object",
|
|
792
|
+
"additionalProperties": {},
|
|
793
|
+
"title": "metadata"
|
|
728
794
|
}
|
|
729
795
|
},
|
|
730
796
|
"required": [
|
|
@@ -767,6 +833,12 @@
|
|
|
767
833
|
"type": "string"
|
|
768
834
|
},
|
|
769
835
|
"title": "requires"
|
|
836
|
+
},
|
|
837
|
+
"metadata": {
|
|
838
|
+
"description": "Host-owned markers on a node: any JSON object. The engine admits, carries and hashes it with the\ndocument and never reads it; it never reaches state, events, prompts or effect identities.",
|
|
839
|
+
"type": "object",
|
|
840
|
+
"additionalProperties": {},
|
|
841
|
+
"title": "metadata"
|
|
770
842
|
}
|
|
771
843
|
},
|
|
772
844
|
"required": [
|
|
@@ -820,6 +892,12 @@
|
|
|
820
892
|
"type": "string"
|
|
821
893
|
},
|
|
822
894
|
"title": "requires"
|
|
895
|
+
},
|
|
896
|
+
"metadata": {
|
|
897
|
+
"description": "Host-owned markers on a node: any JSON object. The engine admits, carries and hashes it with the\ndocument and never reads it; it never reaches state, events, prompts or effect identities.",
|
|
898
|
+
"type": "object",
|
|
899
|
+
"additionalProperties": {},
|
|
900
|
+
"title": "metadata"
|
|
823
901
|
}
|
|
824
902
|
},
|
|
825
903
|
"required": [
|
|
@@ -887,6 +965,12 @@
|
|
|
887
965
|
"type": "string"
|
|
888
966
|
},
|
|
889
967
|
"title": "requires"
|
|
968
|
+
},
|
|
969
|
+
"metadata": {
|
|
970
|
+
"description": "Host-owned markers on a node: any JSON object. The engine admits, carries and hashes it with the\ndocument and never reads it; it never reaches state, events, prompts or effect identities.",
|
|
971
|
+
"type": "object",
|
|
972
|
+
"additionalProperties": {},
|
|
973
|
+
"title": "metadata"
|
|
890
974
|
}
|
|
891
975
|
},
|
|
892
976
|
"required": [
|
|
@@ -966,6 +1050,12 @@
|
|
|
966
1050
|
"type": "string"
|
|
967
1051
|
},
|
|
968
1052
|
"title": "requires"
|
|
1053
|
+
},
|
|
1054
|
+
"metadata": {
|
|
1055
|
+
"description": "Host-owned markers on a node: any JSON object. The engine admits, carries and hashes it with the\ndocument and never reads it; it never reaches state, events, prompts or effect identities.",
|
|
1056
|
+
"type": "object",
|
|
1057
|
+
"additionalProperties": {},
|
|
1058
|
+
"title": "metadata"
|
|
969
1059
|
}
|
|
970
1060
|
},
|
|
971
1061
|
"required": [
|
|
@@ -1299,6 +1389,12 @@
|
|
|
1299
1389
|
"type": "string"
|
|
1300
1390
|
},
|
|
1301
1391
|
"title": "requires"
|
|
1392
|
+
},
|
|
1393
|
+
"metadata": {
|
|
1394
|
+
"description": "Host-owned markers on a node: any JSON object. The engine admits, carries and hashes it with the\ndocument and never reads it; it never reaches state, events, prompts or effect identities.",
|
|
1395
|
+
"type": "object",
|
|
1396
|
+
"additionalProperties": {},
|
|
1397
|
+
"title": "metadata"
|
|
1302
1398
|
}
|
|
1303
1399
|
},
|
|
1304
1400
|
"required": [
|
|
@@ -1337,6 +1433,12 @@
|
|
|
1337
1433
|
"as": {
|
|
1338
1434
|
"type": "string",
|
|
1339
1435
|
"title": "as"
|
|
1436
|
+
},
|
|
1437
|
+
"metadata": {
|
|
1438
|
+
"description": "Host-owned markers on a node: any JSON object. The engine admits, carries and hashes it with the\ndocument and never reads it; it never reaches state, events, prompts or effect identities.",
|
|
1439
|
+
"type": "object",
|
|
1440
|
+
"additionalProperties": {},
|
|
1441
|
+
"title": "metadata"
|
|
1340
1442
|
}
|
|
1341
1443
|
},
|
|
1342
1444
|
"required": [
|
|
@@ -36,6 +36,8 @@ This is the complete set. Each kind accepts exactly these fields; any other fiel
|
|
|
36
36
|
- `sift`: `label`, `itemsPath`, `describe`, `state`, `out`, `as`, `keep`, `requires`
|
|
37
37
|
- `route`: `label`, `state`, `instructions`, `branches`, `unsure`, `as`, `requires`
|
|
38
38
|
|
|
39
|
+
Every kind also accepts `metadata`, an object the host owns and the engine never reads; set only the keys the host addendum names.
|
|
40
|
+
|
|
39
41
|
### Generative nodes: agent, decide, extract, report
|
|
40
42
|
|
|
41
43
|
Each runs one adapter session. A kind is a preset (its duty, default effort and model tier), not a capability limit:
|