@namzu/sdk 5.1.0 → 6.0.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/CHANGELOG.md +465 -0
- package/dist/agents/__tests__/run-agent-forwarding.test.d.ts +2 -0
- package/dist/agents/__tests__/run-agent-forwarding.test.d.ts.map +1 -0
- package/dist/agents/__tests__/run-agent-forwarding.test.js +76 -0
- package/dist/agents/__tests__/run-agent-forwarding.test.js.map +1 -0
- package/dist/agents/__tests__/run-completed-stop-reason.test.d.ts +2 -0
- package/dist/agents/__tests__/run-completed-stop-reason.test.d.ts.map +1 -0
- package/dist/agents/__tests__/run-completed-stop-reason.test.js +50 -0
- package/dist/agents/__tests__/run-completed-stop-reason.test.js.map +1 -0
- package/dist/agents/index.d.ts +1 -0
- package/dist/agents/index.d.ts.map +1 -1
- package/dist/agents/index.js +4 -0
- package/dist/agents/index.js.map +1 -1
- package/dist/agents/runAgent.d.ts +34 -0
- package/dist/agents/runAgent.d.ts.map +1 -1
- package/dist/agents/runAgent.js +5 -3
- package/dist/agents/runAgent.js.map +1 -1
- package/dist/config/runtime.d.ts +30 -30
- package/dist/constants/tools/__tests__/dangerous-patterns.test.d.ts +2 -0
- package/dist/constants/tools/__tests__/dangerous-patterns.test.d.ts.map +1 -0
- package/dist/constants/tools/__tests__/dangerous-patterns.test.js +54 -0
- package/dist/constants/tools/__tests__/dangerous-patterns.test.js.map +1 -0
- package/dist/constants/tools/index.d.ts.map +1 -1
- package/dist/constants/tools/index.js +28 -1
- package/dist/constants/tools/index.js.map +1 -1
- package/dist/contracts/a2a.d.ts +44 -44
- package/dist/directory/__tests__/derive.test.d.ts +2 -0
- package/dist/directory/__tests__/derive.test.d.ts.map +1 -0
- package/dist/directory/__tests__/derive.test.js +111 -0
- package/dist/directory/__tests__/derive.test.js.map +1 -0
- package/dist/directory/__tests__/load-diagnostics.test.d.ts +2 -0
- package/dist/directory/__tests__/load-diagnostics.test.d.ts.map +1 -0
- package/dist/directory/__tests__/load-diagnostics.test.js +106 -0
- package/dist/directory/__tests__/load-diagnostics.test.js.map +1 -0
- package/dist/directory/__tests__/load-directory.test.d.ts +2 -0
- package/dist/directory/__tests__/load-directory.test.d.ts.map +1 -0
- package/dist/directory/__tests__/load-directory.test.js +196 -0
- package/dist/directory/__tests__/load-directory.test.js.map +1 -0
- package/dist/directory/__tests__/subagents.test.d.ts +2 -0
- package/dist/directory/__tests__/subagents.test.d.ts.map +1 -0
- package/dist/directory/__tests__/subagents.test.js +117 -0
- package/dist/directory/__tests__/subagents.test.js.map +1 -0
- package/dist/directory/__tests__/supervisor-budget.test.d.ts +2 -0
- package/dist/directory/__tests__/supervisor-budget.test.d.ts.map +1 -0
- package/dist/directory/__tests__/supervisor-budget.test.js +97 -0
- package/dist/directory/__tests__/supervisor-budget.test.js.map +1 -0
- package/dist/directory/derive-supervisor.d.ts +58 -0
- package/dist/directory/derive-supervisor.d.ts.map +1 -0
- package/dist/directory/derive-supervisor.js +88 -0
- package/dist/directory/derive-supervisor.js.map +1 -0
- package/dist/directory/derive.d.ts +12 -0
- package/dist/directory/derive.d.ts.map +1 -0
- package/dist/directory/derive.js +58 -0
- package/dist/directory/derive.js.map +1 -0
- package/dist/directory/index.d.ts +7 -0
- package/dist/directory/index.d.ts.map +1 -0
- package/dist/directory/index.js +5 -0
- package/dist/directory/index.js.map +1 -0
- package/dist/directory/load.d.ts +14 -0
- package/dist/directory/load.d.ts.map +1 -0
- package/dist/directory/load.js +488 -0
- package/dist/directory/load.js.map +1 -0
- package/dist/directory/scan.d.ts +36 -0
- package/dist/directory/scan.d.ts.map +1 -0
- package/dist/directory/scan.js +136 -0
- package/dist/directory/scan.js.map +1 -0
- package/dist/directory/types.d.ts +215 -0
- package/dist/directory/types.d.ts.map +1 -0
- package/dist/directory/types.js +8 -0
- package/dist/directory/types.js.map +1 -0
- package/dist/plugin/__tests__/path-containment.test.d.ts +2 -0
- package/dist/plugin/__tests__/path-containment.test.d.ts.map +1 -0
- package/dist/plugin/__tests__/path-containment.test.js +91 -0
- package/dist/plugin/__tests__/path-containment.test.js.map +1 -0
- package/dist/plugin/lifecycle.d.ts.map +1 -1
- package/dist/plugin/lifecycle.js +3 -3
- package/dist/plugin/lifecycle.js.map +1 -1
- package/dist/plugin/loader.d.ts.map +1 -1
- package/dist/plugin/loader.js +12 -2
- package/dist/plugin/loader.js.map +1 -1
- package/dist/provider/__tests__/model-version.test.d.ts +2 -0
- package/dist/provider/__tests__/model-version.test.d.ts.map +1 -0
- package/dist/provider/__tests__/model-version.test.js +80 -0
- package/dist/provider/__tests__/model-version.test.js.map +1 -0
- package/dist/provider/__tests__/strict-schema.test.d.ts +2 -0
- package/dist/provider/__tests__/strict-schema.test.d.ts.map +1 -0
- package/dist/provider/__tests__/strict-schema.test.js +157 -0
- package/dist/provider/__tests__/strict-schema.test.js.map +1 -0
- package/dist/provider/__tests__/vendor-detail.test.d.ts +2 -0
- package/dist/provider/__tests__/vendor-detail.test.d.ts.map +1 -0
- package/dist/provider/__tests__/vendor-detail.test.js +89 -0
- package/dist/provider/__tests__/vendor-detail.test.js.map +1 -0
- package/dist/provider/errors.d.ts +38 -5
- package/dist/provider/errors.d.ts.map +1 -1
- package/dist/provider/errors.js +107 -5
- package/dist/provider/errors.js.map +1 -1
- package/dist/provider/model-version.d.ts +60 -0
- package/dist/provider/model-version.d.ts.map +1 -0
- package/dist/provider/model-version.js +64 -0
- package/dist/provider/model-version.js.map +1 -0
- package/dist/provider/strict-schema.d.ts +49 -0
- package/dist/provider/strict-schema.d.ts.map +1 -0
- package/dist/provider/strict-schema.js +168 -0
- package/dist/provider/strict-schema.js.map +1 -0
- package/dist/public-runtime.d.ts +9 -1
- package/dist/public-runtime.d.ts.map +1 -1
- package/dist/public-runtime.js +27 -1
- package/dist/public-runtime.js.map +1 -1
- package/dist/public-types.d.ts +2 -0
- package/dist/public-types.d.ts.map +1 -1
- package/dist/registry/tool/__tests__/dialect.test.d.ts +2 -0
- package/dist/registry/tool/__tests__/dialect.test.d.ts.map +1 -0
- package/dist/registry/tool/__tests__/dialect.test.js +143 -0
- package/dist/registry/tool/__tests__/dialect.test.js.map +1 -0
- package/dist/registry/tool/__tests__/strict-registration.test.d.ts +2 -0
- package/dist/registry/tool/__tests__/strict-registration.test.d.ts.map +1 -0
- package/dist/registry/tool/__tests__/strict-registration.test.js +82 -0
- package/dist/registry/tool/__tests__/strict-registration.test.js.map +1 -0
- package/dist/registry/tool/dialect.d.ts +50 -0
- package/dist/registry/tool/dialect.d.ts.map +1 -0
- package/dist/registry/tool/dialect.js +131 -0
- package/dist/registry/tool/dialect.js.map +1 -0
- package/dist/registry/tool/execute.d.ts.map +1 -1
- package/dist/registry/tool/execute.js +16 -0
- package/dist/registry/tool/execute.js.map +1 -1
- package/dist/registry/toolset/catalog.d.ts.map +1 -1
- package/dist/registry/toolset/catalog.js +10 -5
- package/dist/registry/toolset/catalog.js.map +1 -1
- package/dist/runtime/query/__tests__/stream-recovery.test.js +6 -0
- package/dist/runtime/query/__tests__/stream-recovery.test.js.map +1 -1
- package/dist/runtime/query/result.d.ts.map +1 -1
- package/dist/runtime/query/result.js +11 -0
- package/dist/runtime/query/result.js.map +1 -1
- package/dist/tools/builtins/__tests__/edit-insert-reachable.test.js +7 -1
- package/dist/tools/builtins/__tests__/edit-insert-reachable.test.js.map +1 -1
- package/dist/tools/builtins/__tests__/edit.test.js +1 -1
- package/dist/tools/builtins/__tests__/edit.test.js.map +1 -1
- package/dist/tools/builtins/edit.d.ts.map +1 -1
- package/dist/tools/builtins/edit.js +20 -2
- package/dist/tools/builtins/edit.js.map +1 -1
- package/dist/types/plugin/index.d.ts +4 -4
- package/dist/types/provider/error.d.ts +20 -4
- package/dist/types/provider/error.d.ts.map +1 -1
- package/dist/types/run/events.d.ts +17 -2
- package/dist/types/run/events.d.ts.map +1 -1
- package/dist/types/run/events.js.map +1 -1
- package/dist/types/verification/index.d.ts +6 -6
- package/package.json +1 -1
- package/src/agents/__tests__/run-agent-forwarding.test.ts +85 -0
- package/src/agents/__tests__/run-completed-stop-reason.test.ts +59 -0
- package/src/agents/index.ts +8 -0
- package/src/agents/runAgent.ts +30 -4
- package/src/constants/tools/__tests__/dangerous-patterns.test.ts +62 -0
- package/src/constants/tools/index.ts +28 -1
- package/src/directory/__tests__/derive.test.ts +135 -0
- package/src/directory/__tests__/load-diagnostics.test.ts +126 -0
- package/src/directory/__tests__/load-directory.test.ts +243 -0
- package/src/directory/__tests__/subagents.test.ts +155 -0
- package/src/directory/__tests__/supervisor-budget.test.ts +117 -0
- package/src/directory/derive-supervisor.ts +149 -0
- package/src/directory/derive.ts +70 -0
- package/src/directory/index.ts +27 -0
- package/src/directory/load.ts +556 -0
- package/src/directory/scan.ts +163 -0
- package/src/directory/types.ts +254 -0
- package/src/plugin/__tests__/path-containment.test.ts +107 -0
- package/src/plugin/lifecycle.ts +3 -3
- package/src/plugin/loader.ts +12 -2
- package/src/provider/__tests__/model-version.test.ts +93 -0
- package/src/provider/__tests__/strict-schema.test.ts +189 -0
- package/src/provider/__tests__/vendor-detail.test.ts +107 -0
- package/src/provider/errors.ts +106 -5
- package/src/provider/model-version.ts +98 -0
- package/src/provider/strict-schema.ts +182 -0
- package/src/public-runtime.ts +38 -0
- package/src/public-types.ts +8 -0
- package/src/registry/tool/__tests__/dialect.test.ts +197 -0
- package/src/registry/tool/__tests__/strict-registration.test.ts +115 -0
- package/src/registry/tool/dialect.ts +136 -0
- package/src/registry/tool/execute.ts +16 -0
- package/src/registry/toolset/catalog.ts +10 -5
- package/src/runtime/query/__tests__/stream-recovery.test.ts +6 -0
- package/src/runtime/query/result.ts +11 -0
- package/src/tools/builtins/__tests__/edit-insert-reachable.test.ts +8 -2
- package/src/tools/builtins/__tests__/edit.test.ts +1 -1
- package/src/tools/builtins/edit.ts +20 -2
- package/src/types/provider/error.ts +20 -4
- package/src/types/run/events.ts +15 -2
package/dist/provider/errors.js
CHANGED
|
@@ -11,11 +11,19 @@
|
|
|
11
11
|
*
|
|
12
12
|
* So the contract here is deliberately narrow:
|
|
13
13
|
*
|
|
14
|
-
* - the message is built from the STATUS LINE
|
|
15
|
-
*
|
|
16
|
-
*
|
|
17
|
-
* survives every logger that serializes an error chain,
|
|
18
|
-
* point.
|
|
14
|
+
* - the message is built from the STATUS LINE, the classified `kind`, and the
|
|
15
|
+
* provider's own complaint in `detail` — truncated and scrubbed of anything
|
|
16
|
+
* credential-shaped. The raw body is never re-thrown and never attached as
|
|
17
|
+
* `cause`; a `cause` survives every logger that serializes an error chain,
|
|
18
|
+
* which defeats the point.
|
|
19
|
+
*
|
|
20
|
+
* The body used to be dropped entirely. That was over-corrected: a provider
|
|
21
|
+
* rejecting a request names the exact offending field, and deleting that
|
|
22
|
+
* sentence turned a one-line diagnosis into hypothesis elimination against a
|
|
23
|
+
* live API — once at the cost of a day of production downtime, while the
|
|
24
|
+
* wire had been saying `tools.0.custom.input_schema: … must match JSON
|
|
25
|
+
* Schema draft 2020-12` the entire time. Scrubbing what looks like a
|
|
26
|
+
* credential keeps the safety and returns the sentence.
|
|
19
27
|
* - `retryAfterMs` is DATA. Nothing in this module sleeps, backs off or
|
|
20
28
|
* retries. A retry loop inside a driver burns the run's wall clock and hides
|
|
21
29
|
* the failure from the layer that should decide.
|
|
@@ -41,6 +49,22 @@ export class ProviderRequestError extends Error {
|
|
|
41
49
|
providerId;
|
|
42
50
|
status;
|
|
43
51
|
retryAfterMs;
|
|
52
|
+
/**
|
|
53
|
+
* What the provider said was wrong, truncated and redacted.
|
|
54
|
+
*
|
|
55
|
+
* `ProviderRequestErrorInit` has declared this field all along and the
|
|
56
|
+
* constructor never read it, so every caller that set it was writing to
|
|
57
|
+
* nothing. That is not a cosmetic gap: a provider rejecting a request
|
|
58
|
+
* usually names the exact offending field, and losing that sentence turns
|
|
59
|
+
* a one-line diagnosis into hypothesis elimination against a live API. It
|
|
60
|
+
* did — a tool schema in the wrong JSON Schema dialect cost a day of
|
|
61
|
+
* production downtime while the wire had been saying
|
|
62
|
+
* `tools.0.custom.input_schema: … must match JSON Schema draft 2020-12`
|
|
63
|
+
* the whole time.
|
|
64
|
+
*
|
|
65
|
+
* See {@link vendorDetail} for what is kept and what is scrubbed.
|
|
66
|
+
*/
|
|
67
|
+
detail;
|
|
44
68
|
constructor(init) {
|
|
45
69
|
super(buildProviderErrorMessage(init));
|
|
46
70
|
this.name = 'ProviderRequestError';
|
|
@@ -50,7 +74,81 @@ export class ProviderRequestError extends Error {
|
|
|
50
74
|
this.status = init.status;
|
|
51
75
|
if (init.retryAfterMs !== undefined)
|
|
52
76
|
this.retryAfterMs = init.retryAfterMs;
|
|
77
|
+
if (init.detail !== undefined)
|
|
78
|
+
this.detail = init.detail;
|
|
79
|
+
}
|
|
80
|
+
}
|
|
81
|
+
/** Longest detail worth carrying. A provider's complaint is a sentence. */
|
|
82
|
+
const DETAIL_MAX = 400;
|
|
83
|
+
/**
|
|
84
|
+
* Credential shapes to scrub before a provider's words are kept.
|
|
85
|
+
*
|
|
86
|
+
* The original decision to discard the body outright was not paranoia — an
|
|
87
|
+
* error body can echo the request, and a request can carry a key. The answer
|
|
88
|
+
* is to scrub what looks like a credential rather than to throw away the
|
|
89
|
+
* sentence that names the broken field.
|
|
90
|
+
*/
|
|
91
|
+
const SECRET_PATTERNS = [
|
|
92
|
+
/\b(?:sk|pk|rk)[-_][A-Za-z0-9_-]{12,}/g,
|
|
93
|
+
/\bnpm_[A-Za-z0-9]{20,}/g,
|
|
94
|
+
/\bgh[pousr]_[A-Za-z0-9]{20,}/g,
|
|
95
|
+
/\bBearer\s+[A-Za-z0-9._~+/-]{12,}=*/gi,
|
|
96
|
+
/\bAKIA[0-9A-Z]{16}\b/g,
|
|
97
|
+
/("(?:api[_-]?key|authorization|token|secret|password)"\s*:\s*)"[^"]*"/gi,
|
|
98
|
+
];
|
|
99
|
+
/**
|
|
100
|
+
* The provider's own account of what was wrong, safe to log.
|
|
101
|
+
*
|
|
102
|
+
* Prefers the structured `error.message` a JSON body carries, because that is
|
|
103
|
+
* the field vendors put the actionable sentence in and it is bounded; falls
|
|
104
|
+
* back to the raw text. Truncated, and every credential shape replaced.
|
|
105
|
+
*/
|
|
106
|
+
export function vendorDetail(body) {
|
|
107
|
+
if (body === undefined || body === null)
|
|
108
|
+
return undefined;
|
|
109
|
+
let text;
|
|
110
|
+
if (typeof body === 'string') {
|
|
111
|
+
try {
|
|
112
|
+
text = pickMessage(JSON.parse(body)) ?? body;
|
|
113
|
+
}
|
|
114
|
+
catch {
|
|
115
|
+
text = body;
|
|
116
|
+
}
|
|
117
|
+
}
|
|
118
|
+
else {
|
|
119
|
+
text = pickMessage(body) ?? '';
|
|
120
|
+
}
|
|
121
|
+
const cleaned = redactSecrets(text.trim());
|
|
122
|
+
if (cleaned.length === 0)
|
|
123
|
+
return undefined;
|
|
124
|
+
return cleaned.length > DETAIL_MAX ? `${cleaned.slice(0, DETAIL_MAX)}…` : cleaned;
|
|
125
|
+
}
|
|
126
|
+
export function redactSecrets(text) {
|
|
127
|
+
let out = text;
|
|
128
|
+
for (const pattern of SECRET_PATTERNS) {
|
|
129
|
+
out = out.replace(pattern, (_match, prefix) => prefix === undefined ? '[redacted]' : `${prefix}"[redacted]"`);
|
|
53
130
|
}
|
|
131
|
+
return out;
|
|
132
|
+
}
|
|
133
|
+
function pickMessage(value) {
|
|
134
|
+
if (typeof value === 'string')
|
|
135
|
+
return value;
|
|
136
|
+
if (typeof value !== 'object' || value === null)
|
|
137
|
+
return undefined;
|
|
138
|
+
const node = value;
|
|
139
|
+
// `{ error: { message } }` is what every wire in this tree uses; the rest
|
|
140
|
+
// are the shapes seen in the drivers' own fixtures.
|
|
141
|
+
const nested = node.error;
|
|
142
|
+
if (typeof nested === 'string')
|
|
143
|
+
return nested;
|
|
144
|
+
if (typeof nested === 'object' && nested !== null) {
|
|
145
|
+
const message = nested.message;
|
|
146
|
+
if (typeof message === 'string')
|
|
147
|
+
return message;
|
|
148
|
+
}
|
|
149
|
+
if (typeof node.message === 'string')
|
|
150
|
+
return node.message;
|
|
151
|
+
return undefined;
|
|
54
152
|
}
|
|
55
153
|
/** Is this a classified provider failure, whichever SDK copy threw it? */
|
|
56
154
|
export function isProviderRequestError(err) {
|
|
@@ -285,11 +383,13 @@ export function providerVendorError(input) {
|
|
|
285
383
|
kind = vendorTypeKind(message) ?? 'network';
|
|
286
384
|
}
|
|
287
385
|
const retryAfterMs = parseRetryAfterMs(input.retryAfter ?? vendorRetryAfter(error), input.now ?? Date.now());
|
|
386
|
+
const detail = vendorDetail(message);
|
|
288
387
|
return new ProviderRequestError({
|
|
289
388
|
kind,
|
|
290
389
|
providerId: input.providerId,
|
|
291
390
|
...(status !== undefined ? { status } : {}),
|
|
292
391
|
...(retryAfterMs !== undefined ? { retryAfterMs } : {}),
|
|
392
|
+
...(detail !== undefined ? { detail } : {}),
|
|
293
393
|
});
|
|
294
394
|
}
|
|
295
395
|
/**
|
|
@@ -301,11 +401,13 @@ export function providerVendorError(input) {
|
|
|
301
401
|
export function providerHttpError(input) {
|
|
302
402
|
const kind = classifyProviderHttpStatus(input.status, input.body);
|
|
303
403
|
const retryAfterMs = parseRetryAfterMs(input.retryAfter, input.now ?? Date.now());
|
|
404
|
+
const detail = vendorDetail(input.body);
|
|
304
405
|
return new ProviderRequestError({
|
|
305
406
|
kind,
|
|
306
407
|
providerId: input.providerId,
|
|
307
408
|
status: input.status,
|
|
308
409
|
...(retryAfterMs !== undefined ? { retryAfterMs } : {}),
|
|
410
|
+
...(detail !== undefined ? { detail } : {}),
|
|
309
411
|
});
|
|
310
412
|
}
|
|
311
413
|
//# sourceMappingURL=errors.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"errors.js","sourceRoot":"","sources":["../../src/provider/errors.ts"],"names":[],"mappings":"AAAA
|
|
1
|
+
{"version":3,"file":"errors.js","sourceRoot":"","sources":["../../src/provider/errors.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA6BG;AASH,MAAM,o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G,YAAY,CAAC,KAAK,CAAC,IAAI,CAAC,CAAA;IACvC,OAAO,IAAI,oBAAoB,CAAC;QAC/B,IAAI;QACJ,UAAU,EAAE,KAAK,CAAC,UAAU;QAC5B,MAAM,EAAE,KAAK,CAAC,MAAM;QACpB,GAAG,CAAC,YAAY,KAAK,SAAS,CAAC,CAAC,CAAC,EAAE,YAAY,EAAE,CAAC,CAAC,CAAC,EAAE,CAAC;QACvD,GAAG,CAAC,MAAM,KAAK,SAAS,CAAC,CAAC,CAAC,EAAE,MAAM,EAAE,CAAC,CAAC,CAAC,EAAE,CAAC;KAC3C,CAAC,CAAA;AACH,CAAC"}
|
|
@@ -0,0 +1,60 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Parse a versioned model id, given the vocabulary that names one.
|
|
3
|
+
*
|
|
4
|
+
* Several vendors spell an id the same way — a product segment, a family, a
|
|
5
|
+
* major version, sometimes a minor, and sometimes an 8-digit release date:
|
|
6
|
+
*
|
|
7
|
+
* ```
|
|
8
|
+
* <product>-<family>-<major>[-<minor>][-<YYYYMMDD>]
|
|
9
|
+
* ```
|
|
10
|
+
*
|
|
11
|
+
* The SHAPE is general and lives here; the vocabulary is not, and is supplied
|
|
12
|
+
* by the driver that knows it. That split is deliberate: a driver package
|
|
13
|
+
* exists to speak one service's dialect, and the kernel has no business
|
|
14
|
+
* knowing whose ids these are.
|
|
15
|
+
*
|
|
16
|
+
* It exists at all because three drivers had each written the same matcher and
|
|
17
|
+
* all three had the same defect: the minor-version group was `\d+`, which
|
|
18
|
+
* happily swallowed the date. An id naming no minor therefore parsed as
|
|
19
|
+
* `major.<the date>` and compared as enormously NEWER than one that does, so
|
|
20
|
+
* every capability gate keyed on `minor >= n` inverted for exactly those ids —
|
|
21
|
+
* a model was told it supported features it does not.
|
|
22
|
+
*
|
|
23
|
+
* A real minor version is one to three digits; a date is exactly eight.
|
|
24
|
+
* Bounding the group is what stops it reaching across the separator, and the
|
|
25
|
+
* expression then backtracks into leaving the minor absent so the date suffix
|
|
26
|
+
* can match where it belongs.
|
|
27
|
+
*/
|
|
28
|
+
export interface ModelVersion {
|
|
29
|
+
readonly family: string;
|
|
30
|
+
readonly major: number;
|
|
31
|
+
/** `0` when the id names no minor — a bare major is `<major>.0`. */
|
|
32
|
+
readonly minor: number;
|
|
33
|
+
}
|
|
34
|
+
/**
|
|
35
|
+
* What a driver must say to have its ids parsed.
|
|
36
|
+
*
|
|
37
|
+
* Every field is a wire value the driver already carries. Passing them in
|
|
38
|
+
* rather than hard-coding them is what keeps this module free of any one
|
|
39
|
+
* service's names.
|
|
40
|
+
*/
|
|
41
|
+
export interface ModelIdGrammar {
|
|
42
|
+
/** The product segment an id begins with. */
|
|
43
|
+
readonly product: string;
|
|
44
|
+
/** The family segment that follows it. */
|
|
45
|
+
readonly families: readonly string[];
|
|
46
|
+
/** An optional routing segment a gateway may prepend, including its slash. */
|
|
47
|
+
readonly routingPrefix?: string;
|
|
48
|
+
}
|
|
49
|
+
/** `undefined` for anything the grammar does not describe — never a guess. */
|
|
50
|
+
export declare function parseVersionedModelId(id: string, grammar: ModelIdGrammar): ModelVersion | undefined;
|
|
51
|
+
/**
|
|
52
|
+
* Whether an id names a version at or above `major.minor`.
|
|
53
|
+
*
|
|
54
|
+
* The comparison every caller was writing by hand. An id this cannot parse
|
|
55
|
+
* returns `false`: a capability gate must not open for a name it does not
|
|
56
|
+
* understand, which is the fail-safe reading and the one those callers' own
|
|
57
|
+
* comments already claimed.
|
|
58
|
+
*/
|
|
59
|
+
export declare function modelVersionAtLeast(id: string, grammar: ModelIdGrammar, major: number, minor: number): boolean;
|
|
60
|
+
//# sourceMappingURL=model-version.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"model-version.d.ts","sourceRoot":"","sources":["../../src/provider/model-version.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;GA0BG;AAEH,MAAM,WAAW,YAAY;IAC5B,QAAQ,CAAC,MAAM,EAAE,MAAM,CAAA;IACvB,QAAQ,CAAC,KAAK,EAAE,MAAM,CAAA;IACtB,oEAAoE;IACpE,QAAQ,CAAC,KAAK,EAAE,MAAM,CAAA;CACtB;AAED;;;;;;GAMG;AACH,MAAM,WAAW,cAAc;IAC9B,6CAA6C;IAC7C,QAAQ,CAAC,OAAO,EAAE,MAAM,CAAA;IACxB,0CAA0C;IAC1C,QAAQ,CAAC,QAAQ,EAAE,SAAS,MAAM,EAAE,CAAA;IACpC,8EAA8E;IAC9E,QAAQ,CAAC,aAAa,CAAC,EAAE,MAAM,CAAA;CAC/B;AAiBD,8EAA8E;AAC9E,wBAAgB,qBAAqB,CACpC,EAAE,EAAE,MAAM,EACV,OAAO,EAAE,cAAc,GACrB,YAAY,GAAG,SAAS,CAQ1B;AAED;;;;;;;GAOG;AACH,wBAAgB,mBAAmB,CAClC,EAAE,EAAE,MAAM,EACV,OAAO,EAAE,cAAc,EACvB,KAAK,EAAE,MAAM,EACb,KAAK,EAAE,MAAM,GACX,OAAO,CAIT"}
|
|
@@ -0,0 +1,64 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Parse a versioned model id, given the vocabulary that names one.
|
|
3
|
+
*
|
|
4
|
+
* Several vendors spell an id the same way — a product segment, a family, a
|
|
5
|
+
* major version, sometimes a minor, and sometimes an 8-digit release date:
|
|
6
|
+
*
|
|
7
|
+
* ```
|
|
8
|
+
* <product>-<family>-<major>[-<minor>][-<YYYYMMDD>]
|
|
9
|
+
* ```
|
|
10
|
+
*
|
|
11
|
+
* The SHAPE is general and lives here; the vocabulary is not, and is supplied
|
|
12
|
+
* by the driver that knows it. That split is deliberate: a driver package
|
|
13
|
+
* exists to speak one service's dialect, and the kernel has no business
|
|
14
|
+
* knowing whose ids these are.
|
|
15
|
+
*
|
|
16
|
+
* It exists at all because three drivers had each written the same matcher and
|
|
17
|
+
* all three had the same defect: the minor-version group was `\d+`, which
|
|
18
|
+
* happily swallowed the date. An id naming no minor therefore parsed as
|
|
19
|
+
* `major.<the date>` and compared as enormously NEWER than one that does, so
|
|
20
|
+
* every capability gate keyed on `minor >= n` inverted for exactly those ids —
|
|
21
|
+
* a model was told it supported features it does not.
|
|
22
|
+
*
|
|
23
|
+
* A real minor version is one to three digits; a date is exactly eight.
|
|
24
|
+
* Bounding the group is what stops it reaching across the separator, and the
|
|
25
|
+
* expression then backtracks into leaving the minor absent so the date suffix
|
|
26
|
+
* can match where it belongs.
|
|
27
|
+
*/
|
|
28
|
+
const quoteMeta = (value) => value.replace(/[.*+?^${}()|[\]\\]/g, '\\$&');
|
|
29
|
+
function expressionFor(grammar) {
|
|
30
|
+
const routing = grammar.routingPrefix ? `(?:${quoteMeta(grammar.routingPrefix)})?` : '';
|
|
31
|
+
// `.map(quoteMeta)` and not `.map(escape)`: the latter resolves to the
|
|
32
|
+
// global, deprecated `escape()`, which percent-encodes instead of escaping
|
|
33
|
+
// regex metacharacters — and would pass every test here, because no family
|
|
34
|
+
// name contains a character either function changes.
|
|
35
|
+
const families = grammar.families.map((f) => quoteMeta(f)).join('|');
|
|
36
|
+
// `\d{1,3}` on the minor, not `\d+`. That single bound is the whole fix.
|
|
37
|
+
return new RegExp(`^${routing}${quoteMeta(grammar.product)}-(${families})-(\\d+)(?:[-_.](\\d{1,3}))?(?:-\\d{8})?$`);
|
|
38
|
+
}
|
|
39
|
+
/** `undefined` for anything the grammar does not describe — never a guess. */
|
|
40
|
+
export function parseVersionedModelId(id, grammar) {
|
|
41
|
+
const match = id.toLowerCase().match(expressionFor(grammar));
|
|
42
|
+
if (!match)
|
|
43
|
+
return undefined;
|
|
44
|
+
return {
|
|
45
|
+
family: match[1],
|
|
46
|
+
major: Number(match[2]),
|
|
47
|
+
minor: match[3] === undefined ? 0 : Number(match[3]),
|
|
48
|
+
};
|
|
49
|
+
}
|
|
50
|
+
/**
|
|
51
|
+
* Whether an id names a version at or above `major.minor`.
|
|
52
|
+
*
|
|
53
|
+
* The comparison every caller was writing by hand. An id this cannot parse
|
|
54
|
+
* returns `false`: a capability gate must not open for a name it does not
|
|
55
|
+
* understand, which is the fail-safe reading and the one those callers' own
|
|
56
|
+
* comments already claimed.
|
|
57
|
+
*/
|
|
58
|
+
export function modelVersionAtLeast(id, grammar, major, minor) {
|
|
59
|
+
const version = parseVersionedModelId(id, grammar);
|
|
60
|
+
if (!version)
|
|
61
|
+
return false;
|
|
62
|
+
return version.major > major || (version.major === major && version.minor >= minor);
|
|
63
|
+
}
|
|
64
|
+
//# sourceMappingURL=model-version.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"model-version.js","sourceRoot":"","sources":["../../src/provider/model-version.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;GA0BG;AAyBH,MAAM,SAAS,GAAG,CAAC,KAAa,EAAU,EAAE,CAAC,KAAK,CAAC,OAAO,CAAC,qBAAqB,EAAE,MAAM,CAAC,CAAA;AAEzF,SAAS,aAAa,CAAC,OAAuB;IAC7C,MAAM,OAAO,GAAG,OAAO,CAAC,aAAa,CAAC,CAAC,CAAC,MAAM,SAAS,CAAC,OAAO,CAAC,aAAa,CAAC,IAAI,CAAC,CAAC,CAAC,EAAE,CAAA;IACvF,uEAAuE;IACvE,2EAA2E;IAC3E,2EAA2E;IAC3E,qDAAqD;IACrD,MAAM,QAAQ,GAAG,OAAO,CAAC,QAAQ,CAAC,GAAG,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,SAAS,CAAC,CAAC,CAAC,CAAC,CAAC,IAAI,CAAC,GAAG,CAAC,CAAA;IACpE,yEAAyE;IACzE,OAAO,IAAI,MAAM,CAChB,IAAI,OAAO,GAAG,SAAS,CAAC,OAAO,CAAC,OAAO,CAAC,KAAK,QAAQ,2CAA2C,CAChG,CAAA;AACF,CAAC;AAED,8EAA8E;AAC9E,MAAM,UAAU,qBAAqB,CACpC,EAAU,EACV,OAAuB;IAEvB,MAAM,KAAK,GAAG,EAAE,CAAC,WAAW,EAAE,CAAC,KAAK,CAAC,aAAa,CAAC,OAAO,CAAC,CAAC,CAAA;IAC5D,IAAI,CAAC,KAAK;QAAE,OAAO,SAAS,CAAA;IAC5B,OAAO;QACN,MAAM,EAAE,KAAK,CAAC,CAAC,CAAW;QAC1B,KAAK,EAAE,MAAM,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC;QACvB,KAAK,EAAE,KAAK,CAAC,CAAC,CAAC,KAAK,SAAS,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,MAAM,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC;KACpD,CAAA;AACF,CAAC;AAED;;;;;;;GAOG;AACH,MAAM,UAAU,mBAAmB,CAClC,EAAU,EACV,OAAuB,EACvB,KAAa,EACb,KAAa;IAEb,MAAM,OAAO,GAAG,qBAAqB,CAAC,EAAE,EAAE,OAAO,CAAC,CAAA;IAClD,IAAI,CAAC,OAAO;QAAE,OAAO,KAAK,CAAA;IAC1B,OAAO,OAAO,CAAC,KAAK,GAAG,KAAK,IAAI,CAAC,OAAO,CAAC,KAAK,KAAK,KAAK,IAAI,OAAO,CAAC,KAAK,IAAI,KAAK,CAAC,CAAA;AACpF,CAAC"}
|
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Which JSON Schema a driver may mark as strictly validated.
|
|
3
|
+
*
|
|
4
|
+
* Strict tool input is not "JSON Schema, enforced" — it is a SUBSET of JSON
|
|
5
|
+
* Schema, and a keyword outside that subset does not degrade. The vendor
|
|
6
|
+
* rejects the entire request, so one unexpressible field in one tool takes down
|
|
7
|
+
* every tool in the call and the turn dies before a single token is produced.
|
|
8
|
+
*
|
|
9
|
+
* This exists because that happened. A tool declared its integer-or-`"end"`
|
|
10
|
+
* field as `oneOf`, which is outside the subset while its synonym `anyOf` is
|
|
11
|
+
* inside it, and the driver marked the tool strict without ever asking whether
|
|
12
|
+
* the schema it was vouching for could be said in that dialect. Measured
|
|
13
|
+
* against the live API: strict + `oneOf` is a 400, strict + `anyOf` is
|
|
14
|
+
* accepted, and non-strict + `oneOf` is accepted.
|
|
15
|
+
*
|
|
16
|
+
* That last row is why nothing caught it. Neither half is wrong on its own —
|
|
17
|
+
* the schema is valid JSON Schema and the strict decision is correct policy —
|
|
18
|
+
* so no test of either one fails. Only the pairing does, and the pairing had no
|
|
19
|
+
* owner until this function.
|
|
20
|
+
*
|
|
21
|
+
* The check is cheap and runs where the pairing is made, which is the only
|
|
22
|
+
* place both facts are in hand.
|
|
23
|
+
*/
|
|
24
|
+
export interface StrictSchemaViolation {
|
|
25
|
+
/** Dotted path to the offending keyword, e.g. `properties.insertLine.oneOf`. */
|
|
26
|
+
readonly path: string;
|
|
27
|
+
readonly keyword: string;
|
|
28
|
+
/** What to write instead. */
|
|
29
|
+
readonly remedy: string;
|
|
30
|
+
}
|
|
31
|
+
/**
|
|
32
|
+
* Every place a schema leaves the strict subset, with its exact path.
|
|
33
|
+
*
|
|
34
|
+
* The path is the point. The vendor's own error names the tool and the
|
|
35
|
+
* keyword but not where inside the schema it sits, which on a schema of any
|
|
36
|
+
* size is the difference between a glance and an afternoon.
|
|
37
|
+
*/
|
|
38
|
+
export declare function findStrictSchemaViolations(schema: unknown, path?: string): StrictSchemaViolation[];
|
|
39
|
+
/**
|
|
40
|
+
* Refuse a schema the driver is about to vouch for and cannot.
|
|
41
|
+
*
|
|
42
|
+
* Refusing here rather than dropping `strict` quietly: a caller who set
|
|
43
|
+
* `enforceModelInput` asked for the guarantee, and silently not providing it
|
|
44
|
+
* is the failure this repo names `refuse, do not degrade`. The alternative
|
|
45
|
+
* costs a turn and teaches nothing — the vendor's 400 arrives with the tool
|
|
46
|
+
* name and the keyword, but not the path, and not the fix.
|
|
47
|
+
*/
|
|
48
|
+
export declare function assertStrictSchema(toolName: string, schema: unknown): void;
|
|
49
|
+
//# sourceMappingURL=strict-schema.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"strict-schema.d.ts","sourceRoot":"","sources":["../../src/provider/strict-schema.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;GAsBG;AAyEH,MAAM,WAAW,qBAAqB;IACrC,gFAAgF;IAChF,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAA;IACrB,QAAQ,CAAC,OAAO,EAAE,MAAM,CAAA;IACxB,6BAA6B;IAC7B,QAAQ,CAAC,MAAM,EAAE,MAAM,CAAA;CACvB;AAED;;;;;;GAMG;AACH,wBAAgB,0BAA0B,CAAC,MAAM,EAAE,OAAO,EAAE,IAAI,SAAK,GAAG,qBAAqB,EAAE,CAoD9F;AAED;;;;;;;;GAQG;AACH,wBAAgB,kBAAkB,CAAC,QAAQ,EAAE,MAAM,EAAE,MAAM,EAAE,OAAO,GAAG,IAAI,CAQ1E"}
|
|
@@ -0,0 +1,168 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Which JSON Schema a driver may mark as strictly validated.
|
|
3
|
+
*
|
|
4
|
+
* Strict tool input is not "JSON Schema, enforced" — it is a SUBSET of JSON
|
|
5
|
+
* Schema, and a keyword outside that subset does not degrade. The vendor
|
|
6
|
+
* rejects the entire request, so one unexpressible field in one tool takes down
|
|
7
|
+
* every tool in the call and the turn dies before a single token is produced.
|
|
8
|
+
*
|
|
9
|
+
* This exists because that happened. A tool declared its integer-or-`"end"`
|
|
10
|
+
* field as `oneOf`, which is outside the subset while its synonym `anyOf` is
|
|
11
|
+
* inside it, and the driver marked the tool strict without ever asking whether
|
|
12
|
+
* the schema it was vouching for could be said in that dialect. Measured
|
|
13
|
+
* against the live API: strict + `oneOf` is a 400, strict + `anyOf` is
|
|
14
|
+
* accepted, and non-strict + `oneOf` is accepted.
|
|
15
|
+
*
|
|
16
|
+
* That last row is why nothing caught it. Neither half is wrong on its own —
|
|
17
|
+
* the schema is valid JSON Schema and the strict decision is correct policy —
|
|
18
|
+
* so no test of either one fails. Only the pairing does, and the pairing had no
|
|
19
|
+
* owner until this function.
|
|
20
|
+
*
|
|
21
|
+
* The check is cheap and runs where the pairing is made, which is the only
|
|
22
|
+
* place both facts are in hand.
|
|
23
|
+
*/
|
|
24
|
+
/**
|
|
25
|
+
* Keywords the strict subset does not accept.
|
|
26
|
+
*
|
|
27
|
+
* A deny-list rather than an allow-list, deliberately. An allow-list would have
|
|
28
|
+
* to enumerate every annotation a schema may carry — `description`, `title`,
|
|
29
|
+
* `examples`, vendor extensions — and would refuse a schema for saying
|
|
30
|
+
* something harmless. Each entry names what to write instead.
|
|
31
|
+
*
|
|
32
|
+
* MEASURED against the live API, not read off a page. The first version of this
|
|
33
|
+
* list was derived from documentation and was wrong in both directions: it
|
|
34
|
+
* refused `minLength`/`maxLength`, which the wire accepts, and it permitted
|
|
35
|
+
* `prefixItems`, which the wire rejects. A deny-list nobody probed is a guess
|
|
36
|
+
* with a confident tone, and this one would have refused working tools while
|
|
37
|
+
* still letting a broken one through.
|
|
38
|
+
*
|
|
39
|
+
* The probe lives in the live contract test; run it against a new model before
|
|
40
|
+
* trusting this list on that model.
|
|
41
|
+
*/
|
|
42
|
+
const NO_CONDITIONALS = 'strict mode has no conditional schemas; flatten the object';
|
|
43
|
+
const NO_NUMERIC_BOUNDS = 'numeric bounds are not in the subset; enforce at execution';
|
|
44
|
+
const NO_ARRAY_BOUNDS = 'array bounds are not in the subset; enforce at execution';
|
|
45
|
+
// A Map rather than an object literal, because one of the keys is `then`: an
|
|
46
|
+
// ordinary object carrying a `then` property is a thenable, and awaiting it
|
|
47
|
+
// anywhere would silently call the string. The lint rule that says so is
|
|
48
|
+
// right, and a Map has no such hazard.
|
|
49
|
+
const UNSUPPORTED = new Map([
|
|
50
|
+
['oneOf', 'use `anyOf` — for disjoint branches the two are equivalent'],
|
|
51
|
+
['not', 'express the constraint positively, or validate it at execution'],
|
|
52
|
+
['if', NO_CONDITIONALS],
|
|
53
|
+
['then', NO_CONDITIONALS],
|
|
54
|
+
['else', NO_CONDITIONALS],
|
|
55
|
+
['minimum', NO_NUMERIC_BOUNDS],
|
|
56
|
+
['maximum', NO_NUMERIC_BOUNDS],
|
|
57
|
+
['exclusiveMinimum', NO_NUMERIC_BOUNDS],
|
|
58
|
+
['exclusiveMaximum', NO_NUMERIC_BOUNDS],
|
|
59
|
+
['multipleOf', NO_NUMERIC_BOUNDS],
|
|
60
|
+
// `minLength`/`maxLength` are NOT here. The first version of this list put
|
|
61
|
+
// them here on documentation alone, and measurement says the wire accepts
|
|
62
|
+
// both — so the list was refusing tools that would have worked. A deny-list
|
|
63
|
+
// derived from prose and never probed is a guess with a confident tone.
|
|
64
|
+
// `minItems` is NOT a flat denial — see MIN_ITEMS_ALLOWED below. The wire
|
|
65
|
+
// accepts 0 and 1 and refuses everything above, naming the value in the
|
|
66
|
+
// error, so a blanket entry here would refuse `.nonempty()` on a schema the
|
|
67
|
+
// wire would have taken.
|
|
68
|
+
['maxItems', NO_ARRAY_BOUNDS],
|
|
69
|
+
['uniqueItems', NO_ARRAY_BOUNDS],
|
|
70
|
+
// The other direction of the same mistake: this was missing, and it is the
|
|
71
|
+
// one that interacts with the dialect conversion. A tuple becomes
|
|
72
|
+
// `prefixItems` for the 2020-12 wire — and strict rejects `prefixItems`
|
|
73
|
+
// outright, so a tool that is BOTH strict AND tuple-shaped cannot be
|
|
74
|
+
// expressed at all. Better to say that at registration than to convert a
|
|
75
|
+
// schema into a different rejection.
|
|
76
|
+
['prefixItems', 'strict arrays take one `items` schema; a tuple cannot be expressed'],
|
|
77
|
+
['patternProperties', 'name the properties explicitly'],
|
|
78
|
+
['propertyNames', 'name the properties explicitly'],
|
|
79
|
+
['dependentSchemas', 'flatten the object and validate at execution'],
|
|
80
|
+
['dependentRequired', 'flatten the object and validate at execution'],
|
|
81
|
+
]);
|
|
82
|
+
/**
|
|
83
|
+
* The only `minItems` values the strict subset admits.
|
|
84
|
+
*
|
|
85
|
+
* Measured: `minItems: 0` and `minItems: 1` are accepted, `minItems: 2` comes
|
|
86
|
+
* back *"For 'array' type, 'minItems' values other than 0 or 1 are not
|
|
87
|
+
* supported"*. So the constraint is on the VALUE, not the keyword, and that is
|
|
88
|
+
* the whole difference between refusing a required-non-empty array — the
|
|
89
|
+
* ordinary spelling of `z.array(...).nonempty()` — and letting it through.
|
|
90
|
+
*/
|
|
91
|
+
const MIN_ITEMS_ALLOWED = new Set([0, 1]);
|
|
92
|
+
/**
|
|
93
|
+
* Every place a schema leaves the strict subset, with its exact path.
|
|
94
|
+
*
|
|
95
|
+
* The path is the point. The vendor's own error names the tool and the
|
|
96
|
+
* keyword but not where inside the schema it sits, which on a schema of any
|
|
97
|
+
* size is the difference between a glance and an afternoon.
|
|
98
|
+
*/
|
|
99
|
+
export function findStrictSchemaViolations(schema, path = '') {
|
|
100
|
+
if (Array.isArray(schema)) {
|
|
101
|
+
return schema.flatMap((item, index) => findStrictSchemaViolations(item, `${path}[${index}]`));
|
|
102
|
+
}
|
|
103
|
+
if (typeof schema !== 'object' || schema === null)
|
|
104
|
+
return [];
|
|
105
|
+
const found = [];
|
|
106
|
+
for (const [keyword, value] of Object.entries(schema)) {
|
|
107
|
+
const here = path ? `${path}.${keyword}` : keyword;
|
|
108
|
+
const remedy = UNSUPPORTED.get(keyword);
|
|
109
|
+
if (remedy !== undefined) {
|
|
110
|
+
found.push({ path: here, keyword, remedy });
|
|
111
|
+
continue;
|
|
112
|
+
}
|
|
113
|
+
// `additionalProperties` is admitted only as `false`; any schema there
|
|
114
|
+
// is an open object, which the subset does not allow.
|
|
115
|
+
if (keyword === 'additionalProperties' && value !== false) {
|
|
116
|
+
found.push({
|
|
117
|
+
path: here,
|
|
118
|
+
keyword,
|
|
119
|
+
remedy: 'strict objects must set `additionalProperties: false`',
|
|
120
|
+
});
|
|
121
|
+
continue;
|
|
122
|
+
}
|
|
123
|
+
// A tuple in the OTHER spelling. This check runs at registration, on the
|
|
124
|
+
// schema as rendered — which is draft-07, where a tuple is `items: [a,
|
|
125
|
+
// b]` — while the wire sees the 2020-12 `prefixItems` the driver
|
|
126
|
+
// converts it to. So a `prefixItems` entry alone never fires on the
|
|
127
|
+
// path that produces tuples, and the entry added to catch this case was
|
|
128
|
+
// dead for exactly the case it was added for.
|
|
129
|
+
//
|
|
130
|
+
// Both spellings mean the same thing and strict admits neither, so this
|
|
131
|
+
// names the tuple rather than the dialect it happens to be written in.
|
|
132
|
+
if (keyword === 'items' && Array.isArray(value)) {
|
|
133
|
+
found.push({
|
|
134
|
+
path: here,
|
|
135
|
+
keyword,
|
|
136
|
+
remedy: 'strict arrays take one `items` schema; a tuple cannot be expressed',
|
|
137
|
+
});
|
|
138
|
+
continue;
|
|
139
|
+
}
|
|
140
|
+
if (keyword === 'minItems' && typeof value === 'number' && !MIN_ITEMS_ALLOWED.has(value)) {
|
|
141
|
+
found.push({
|
|
142
|
+
path: here,
|
|
143
|
+
keyword,
|
|
144
|
+
remedy: 'strict accepts `minItems` of 0 or 1 only; enforce a larger bound at execution',
|
|
145
|
+
});
|
|
146
|
+
continue;
|
|
147
|
+
}
|
|
148
|
+
found.push(...findStrictSchemaViolations(value, here));
|
|
149
|
+
}
|
|
150
|
+
return found;
|
|
151
|
+
}
|
|
152
|
+
/**
|
|
153
|
+
* Refuse a schema the driver is about to vouch for and cannot.
|
|
154
|
+
*
|
|
155
|
+
* Refusing here rather than dropping `strict` quietly: a caller who set
|
|
156
|
+
* `enforceModelInput` asked for the guarantee, and silently not providing it
|
|
157
|
+
* is the failure this repo names `refuse, do not degrade`. The alternative
|
|
158
|
+
* costs a turn and teaches nothing — the vendor's 400 arrives with the tool
|
|
159
|
+
* name and the keyword, but not the path, and not the fix.
|
|
160
|
+
*/
|
|
161
|
+
export function assertStrictSchema(toolName, schema) {
|
|
162
|
+
const violations = findStrictSchemaViolations(schema);
|
|
163
|
+
if (violations.length === 0)
|
|
164
|
+
return;
|
|
165
|
+
const detail = violations.map((v) => ` ${toolName}.${v.path} — ${v.remedy}`).join('\n');
|
|
166
|
+
throw new Error(`Tool "${toolName}" is marked for strict input validation, but its model-facing schema uses ${violations.length} construct(s) the strict subset does not accept. The request would be rejected whole, taking every other tool in it down as well.\n${detail}`);
|
|
167
|
+
}
|
|
168
|
+
//# sourceMappingURL=strict-schema.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"strict-schema.js","sourceRoot":"","sources":["../../src/provider/strict-schema.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;GAsBG;AAEH;;;;;;;;;;;;;;;;;GAiBG;AACH,MAAM,eAAe,GAAG,4DAA4D,CAAA;AACpF,MAAM,iBAAiB,GAAG,4DAA4D,CAAA;AACtF,MAAM,eAAe,GAAG,0DAA0D,CAAA;AAElF,6EAA6E;AAC7E,4EAA4E;AAC5E,yEAAyE;AACzE,uCAAuC;AACvC,MAAM,WAAW,GAAgC,IAAI,GAAG,CAAC;IACxD,CAAC,OAAO,EAAE,4DAA4D,CAAC;IACvE,CAAC,KAAK,EAAE,gEAAgE,CAAC;IACzE,CAAC,IAAI,EAAE,eAAe,CAAC;IACvB,CAAC,MAAM,EAAE,eAAe,CAAC;IACzB,CAAC,MAAM,EAAE,eAAe,CAAC;IACzB,CAAC,SAAS,EAAE,iBAAiB,CAAC;IAC9B,CAAC,SAAS,EAAE,iBAAiB,CAAC;IAC9B,CAAC,kBAAkB,EAAE,iBAAiB,CAAC;IACvC,CAAC,kBAAkB,EAAE,iBAAiB,CAAC;IACvC,CAAC,YAAY,EAAE,iBAAiB,CAAC;IACjC,2EAA2E;IAC3E,0EAA0E;IAC1E,4EAA4E;IAC5E,wEAAwE;IACxE,0EAA0E;IAC1E,wEAAwE;IACxE,4EAA4E;IAC5E,yBAAyB;IACzB,CAAC,UAAU,EAAE,eAAe,CAAC;IAC7B,CAAC,aAAa,EAAE,eAAe,CAAC;IAChC,2EAA2E;IAC3E,kEAAkE;IAClE,wEAAwE;IACxE,qEAAqE;IACrE,yEAAyE;IACzE,qCAAqC;IACrC,CAAC,aAAa,EAAE,oEAAoE,CAAC;IACrF,CAAC,mBAAmB,EAAE,gCAAgC,CAAC;IACvD,CAAC,eAAe,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SAAS,QAAQ,6EAA6E,UAAU,CAAC,MAAM,sIAAsI,MAAM,EAAE,CAC7P,CAAA;AACF,CAAC"}
|
package/dist/public-runtime.d.ts
CHANGED
|
@@ -14,6 +14,13 @@ export { memoizeAsync } from './utils/memoize.js';
|
|
|
14
14
|
export { extractFinalResponse } from './utils/conversation.js';
|
|
15
15
|
export { resolveTaskModel } from './router/task-router.js';
|
|
16
16
|
export { assertThinkingUnsupported } from './provider/thinking-support.js';
|
|
17
|
+
export { modelVersionAtLeast, parseVersionedModelId } from './provider/model-version.js';
|
|
18
|
+
export { assertStrictSchema, findStrictSchemaViolations } from './provider/strict-schema.js';
|
|
19
|
+
export { findDraft07Only, toSchemaDialect } from './registry/tool/dialect.js';
|
|
20
|
+
export type { JsonSchemaDialect } from './registry/tool/dialect.js';
|
|
21
|
+
export { renderToolSchema } from './registry/tool/schema.js';
|
|
22
|
+
export type { StrictSchemaViolation } from './provider/strict-schema.js';
|
|
23
|
+
export type { ModelIdGrammar, ModelVersion } from './provider/model-version.js';
|
|
17
24
|
export { drainQuery, query } from './runtime/query/index.js';
|
|
18
25
|
export { SteeringBinding, attachSteering, formatSteeringNote } from './runtime/query/steering.js';
|
|
19
26
|
export type { SteeringChannel } from './runtime/query/steering.js';
|
|
@@ -34,8 +41,9 @@ export { DecisionParser, FallbackResolver } from './runtime/decision/index.js';
|
|
|
34
41
|
export { buildLimitConfig, checkLimitsDetailed, createRunReporter, } from './run/index.js';
|
|
35
42
|
export { assembleSystemPrompt, mergePersonas, withSessionContext, } from './persona/index.js';
|
|
36
43
|
export { discoverSkills, loadSkill, resolveSkillChain, SkillRegistry, } from './skills/index.js';
|
|
44
|
+
export { ALL_SLOTS, deriveRunOptions, deriveSupervisorOptions, loadDirectory, } from './directory/index.js';
|
|
37
45
|
export { AdvisorRegistry, AdvisoryContext, AdvisoryExecutor, TriggerEvaluator, } from './advisory/index.js';
|
|
38
|
-
export { AbstractAgent, ConcurrentInvocationError, defineAgent, InvocationLock, PipelineAgent, ReactiveAgent, RouterAgent, runAgent, SupervisorAgent, } from './agents/index.js';
|
|
46
|
+
export { AbstractAgent, ConcurrentInvocationError, defineAgent, InvocationLock, PipelineAgent, ReactiveAgent, RouterAgent, runAgent, DEFAULT_MAX_ITERATIONS, DEFAULT_TIMEOUT_MS, DEFAULT_TOKEN_BUDGET, SupervisorAgent, } from './agents/index.js';
|
|
39
47
|
export { ActivityStore, DiskCheckpointStore, DiskMemoryStore, DiskTaskStore, InMemoryMemoryIndex, InMemoryMemoryStore, InMemoryStore, InMemoryTaskStore, RunDiskStore, } from './store/index.js';
|
|
40
48
|
export { AgentRegistry, ManagedRegistry, PluginRegistry, Registry, ToolCatalog, ToolNameCollisionError, ToolRegistry, createToolCatalogFromRegistry, loadingFromAvailability, toolDefinitionToCatalogEntry, } from './registry/index.js';
|
|
41
49
|
export { discoverAllPluginDirs, discoverPlugins, loadPluginManifest, PluginLifecycleManager, PluginResolver, } from './plugin/index.js';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"public-runtime.d.ts","sourceRoot":"","sources":["../src/public-runtime.ts"],"names":[],"mappings":"AAYA,OAAO,EAAE,OAAO,EAAE,MAAM,cAAc,CAAA;AAEtC,OAAO,EACN,sBAAsB,EACtB,yBAAyB,EACzB,gBAAgB,EAChB,mBAAmB,EACnB,mBAAmB,EACnB,sBAAsB,GACtB,MAAM,qBAAqB,CAAA;AAI5B,cAAc,sBAAsB,CAAA;AAIpC,OAAO,EACN,mBAAmB,EACnB,eAAe,EACf,wBAAwB,EACxB,eAAe,EACf,gBAAgB,EAChB,eAAe,EACf,eAAe,EACf,WAAW,EACX,kBAAkB,GAClB,MAAM,wBAAwB,CAAA;AAE/B,cAAc,oBAAoB,CAAA;AAIlC,cAAc,eAAe,CAAA;AAI7B,OAAO,EACN,cAAc,EACd,aAAa,EACb,UAAU,EACV,SAAS,GACT,MAAM,iBAAiB,CAAA;AACxB,OAAO,EAAE,cAAc,EAAE,MAAM,kBAAkB,C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