@vaudience/aigentflow-flow-validator 0.18.0 → 0.19.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/PARITY.md +15 -2
- package/README.md +1 -1
- package/dist/cli.js +14 -1
- package/dist/index.cjs +14 -1
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +4 -0
- package/dist/index.d.ts +4 -0
- package/dist/index.js +14 -1
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/PARITY.md
CHANGED
|
@@ -4,8 +4,21 @@ This document maps every rule in this JavaScript validator back to the AIgentFlo
|
|
|
4
4
|
Go reference implementation, records the intentional divergences, and defines the
|
|
5
5
|
discipline for keeping the two in sync.
|
|
6
6
|
|
|
7
|
-
**Tracks AIgentFlow flow schema: `v2.
|
|
8
|
-
|
|
7
|
+
**Tracks AIgentFlow flow schema: `v2.820.0`** (`SPEC_VERSION` in [`src/spec/aigentflow-spec.json`](./src/spec/aigentflow-spec.json)), which adds `orchestrator.region` / `orchestrator.enforce_region` (package 0.19.0, below). Earlier: the AigentChat executor was removed (package 0.18.0). Earlier additions: the `examples:` block (package 0.17.0), `server_owned_query_key` (package 0.15.1) from the AIgentFlow release after v2.790.0, `credential_endpoint_unpaired` (package 0.15.2) from AIgentFlow v2.793.0 and the release after it, and `display_name_too_long` (package 0.15.3) from AIgentFlow v2.802.0.
|
|
8
|
+
|
|
9
|
+
> package 0.19.0 — **`orchestrator.region` and `orchestrator.enforce_region`**, in step
|
|
10
|
+
> with the reference (AIgentFlow v2.820.0; `specVersion` 2.820.0). Both are new keys of
|
|
11
|
+
> the `orchestrator:` block (a `string` and a `bool`), added to the known-key table.
|
|
12
|
+
> One rule ported: `enforce_region: true` with an absent, null, empty or
|
|
13
|
+
> whitespace-only `region` is an **error**, `orchestrator_enforce_region_needs_region`
|
|
14
|
+
> (field `orchestrator.enforce_region`), because the provider would refuse every turn.
|
|
15
|
+
> The reference raises it from its parser's orchestrator validation as a plain
|
|
16
|
+
> flow-validation error with no machine-readable code; this package's code and field
|
|
17
|
+
> are its own naming, the same as for `orchestrator_mode_invalid`. Only a YAML boolean
|
|
18
|
+
> `true` arms the rule. The runtime effect (the region reaching the provider request) is
|
|
19
|
+
> engine behaviour and out of scope. New conformance fixtures:
|
|
20
|
+
> `valid-orchestrator-region.yaml`, `invalid-orchestrator-enforce-region-no-region.yaml`.
|
|
21
|
+
>
|
|
9
22
|
> package 0.18.0 — **the AigentChat executor is removed**, in step with the reference
|
|
10
23
|
> (AIgentFlow v2.819.0; `specVersion` 2.819.0). The reference no longer registers the
|
|
11
24
|
> `nexus://` protocol or its `aigentchat://` alias, so the spec drops: `nexus` from
|
package/README.md
CHANGED
|
@@ -116,7 +116,7 @@ Low-level: parse YAML into `{ flow?, parseErrors, parseWarnings }` without valid
|
|
|
116
116
|
|
|
117
117
|
### `SPEC_VERSION: string`
|
|
118
118
|
|
|
119
|
-
The AIgentFlow flow-schema version this build tracks (e.g. `"2.
|
|
119
|
+
The AIgentFlow flow-schema version this build tracks (e.g. `"2.820.0"`).
|
|
120
120
|
|
|
121
121
|
### Options
|
|
122
122
|
|
package/dist/cli.js
CHANGED
|
@@ -436,7 +436,7 @@ function validateBasicStructure(flow, issues) {
|
|
|
436
436
|
// src/spec/aigentflow-spec.json
|
|
437
437
|
var aigentflow_spec_default = {
|
|
438
438
|
$comment: "Vendored enum surface mirrored from the AIgentFlow Go reference implementation. Regenerate / review on every flow-YAML schema change. See PARITY.md. Values here are public protocol/type names only.",
|
|
439
|
-
specVersion: "2.
|
|
439
|
+
specVersion: "2.820.0",
|
|
440
440
|
inputSchemaVersion: 1,
|
|
441
441
|
executorSchemes: [
|
|
442
442
|
"a2a",
|
|
@@ -1726,6 +1726,7 @@ var aigentflow_spec_default = {
|
|
|
1726
1726
|
deny_tools: "list<scalar>",
|
|
1727
1727
|
discoverable_tools: "list<scalar>",
|
|
1728
1728
|
enable_signals: "scalar",
|
|
1729
|
+
enforce_region: "scalar",
|
|
1729
1730
|
engram_scope: "scalar",
|
|
1730
1731
|
exons: "scalar",
|
|
1731
1732
|
human_question_timeout: "scalar",
|
|
@@ -1734,6 +1735,7 @@ var aigentflow_spec_default = {
|
|
|
1734
1735
|
max_tool_turns: "scalar",
|
|
1735
1736
|
max_turns: "scalar",
|
|
1736
1737
|
mode: "scalar",
|
|
1738
|
+
region: "scalar",
|
|
1737
1739
|
require_approval_for: "list<scalar>",
|
|
1738
1740
|
timeout_seconds: "scalar",
|
|
1739
1741
|
tool_discovery: "scalar",
|
|
@@ -3157,6 +3159,17 @@ function validateOrchestratorCampaign(flow, issues, opts) {
|
|
|
3157
3159
|
code: "orchestrator_owner_needs_yield"
|
|
3158
3160
|
});
|
|
3159
3161
|
}
|
|
3162
|
+
if (orch.enforce_region === true) {
|
|
3163
|
+
const region = issues.stringOf(orch, "region", "orchestrator");
|
|
3164
|
+
if (region === null || region.trim() === "") {
|
|
3165
|
+
issues.error({
|
|
3166
|
+
field: "orchestrator.enforce_region",
|
|
3167
|
+
message: "orchestrator: enforce_region requires region (name the region the model must run in, e.g. region: eu)",
|
|
3168
|
+
code: "orchestrator_enforce_region_needs_region",
|
|
3169
|
+
suggestion: "Add `region: eu` (or the region the model must run in), or drop enforce_region"
|
|
3170
|
+
});
|
|
3171
|
+
}
|
|
3172
|
+
}
|
|
3160
3173
|
if (Array.isArray(orch.triggers)) {
|
|
3161
3174
|
orch.triggers.forEach((rawTrigger, i) => {
|
|
3162
3175
|
if (!isRecord(rawTrigger)) return;
|
package/dist/index.cjs
CHANGED
|
@@ -432,7 +432,7 @@ function validateBasicStructure(flow, issues) {
|
|
|
432
432
|
|
|
433
433
|
// src/spec/aigentflow-spec.json
|
|
434
434
|
var aigentflow_spec_default = {
|
|
435
|
-
specVersion: "2.
|
|
435
|
+
specVersion: "2.820.0",
|
|
436
436
|
inputSchemaVersion: 1,
|
|
437
437
|
executorSchemes: [
|
|
438
438
|
"a2a",
|
|
@@ -1644,6 +1644,7 @@ var aigentflow_spec_default = {
|
|
|
1644
1644
|
deny_tools: "list<scalar>",
|
|
1645
1645
|
discoverable_tools: "list<scalar>",
|
|
1646
1646
|
enable_signals: "scalar",
|
|
1647
|
+
enforce_region: "scalar",
|
|
1647
1648
|
engram_scope: "scalar",
|
|
1648
1649
|
exons: "scalar",
|
|
1649
1650
|
human_question_timeout: "scalar",
|
|
@@ -1652,6 +1653,7 @@ var aigentflow_spec_default = {
|
|
|
1652
1653
|
max_tool_turns: "scalar",
|
|
1653
1654
|
max_turns: "scalar",
|
|
1654
1655
|
mode: "scalar",
|
|
1656
|
+
region: "scalar",
|
|
1655
1657
|
require_approval_for: "list<scalar>",
|
|
1656
1658
|
timeout_seconds: "scalar",
|
|
1657
1659
|
tool_discovery: "scalar",
|
|
@@ -3064,6 +3066,17 @@ function validateOrchestratorCampaign(flow, issues, opts) {
|
|
|
3064
3066
|
code: "orchestrator_owner_needs_yield"
|
|
3065
3067
|
});
|
|
3066
3068
|
}
|
|
3069
|
+
if (orch.enforce_region === true) {
|
|
3070
|
+
const region = issues.stringOf(orch, "region", "orchestrator");
|
|
3071
|
+
if (region === null || region.trim() === "") {
|
|
3072
|
+
issues.error({
|
|
3073
|
+
field: "orchestrator.enforce_region",
|
|
3074
|
+
message: "orchestrator: enforce_region requires region (name the region the model must run in, e.g. region: eu)",
|
|
3075
|
+
code: "orchestrator_enforce_region_needs_region",
|
|
3076
|
+
suggestion: "Add `region: eu` (or the region the model must run in), or drop enforce_region"
|
|
3077
|
+
});
|
|
3078
|
+
}
|
|
3079
|
+
}
|
|
3067
3080
|
if (Array.isArray(orch.triggers)) {
|
|
3068
3081
|
orch.triggers.forEach((rawTrigger, i) => {
|
|
3069
3082
|
if (!isRecord(rawTrigger)) return;
|