agentfootprint 9.76.1 → 9.78.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 +188 -0
- package/CLAUDE.md +2 -0
- package/dist/core/Agent.js +86 -0
- package/dist/core/Agent.js.map +1 -1
- package/dist/core/agent/integrityFindings.js +47 -0
- package/dist/core/agent/integrityFindings.js.map +1 -0
- package/dist/core/agent/stages/callLLM.js +28 -29
- package/dist/core/agent/stages/callLLM.js.map +1 -1
- package/dist/core/agent/stages/toolCalls.js +184 -0
- package/dist/core/agent/stages/toolCalls.js.map +1 -1
- package/dist/core/tools.js +9 -1
- package/dist/core/tools.js.map +1 -1
- package/dist/esm/core/Agent.d.ts +10 -0
- package/dist/esm/core/Agent.js +86 -0
- package/dist/esm/core/Agent.js.map +1 -1
- package/dist/esm/core/agent/integrityFindings.d.ts +27 -0
- package/dist/esm/core/agent/integrityFindings.js +43 -0
- package/dist/esm/core/agent/integrityFindings.js.map +1 -0
- package/dist/esm/core/agent/stages/callLLM.d.ts +25 -0
- package/dist/esm/core/agent/stages/callLLM.js +25 -26
- package/dist/esm/core/agent/stages/callLLM.js.map +1 -1
- package/dist/esm/core/agent/stages/toolCalls.d.ts +43 -0
- package/dist/esm/core/agent/stages/toolCalls.js +185 -1
- package/dist/esm/core/agent/stages/toolCalls.js.map +1 -1
- package/dist/esm/core/agent/types.d.ts +112 -0
- package/dist/esm/core/tools.d.ts +63 -0
- package/dist/esm/core/tools.js +17 -0
- package/dist/esm/core/tools.js.map +1 -1
- package/dist/esm/index.d.ts +3 -0
- package/dist/esm/index.js +18 -0
- package/dist/esm/index.js.map +1 -1
- package/dist/esm/integrity/argumentLeaves.d.ts +33 -0
- package/dist/esm/integrity/argumentLeaves.js +49 -0
- package/dist/esm/integrity/argumentLeaves.js.map +1 -0
- package/dist/esm/integrity/column-types/check.d.ts +156 -0
- package/dist/esm/integrity/column-types/check.js +363 -0
- package/dist/esm/integrity/column-types/check.js.map +1 -0
- package/dist/esm/integrity/column-types/types.d.ts +121 -0
- package/dist/esm/integrity/column-types/types.js +107 -0
- package/dist/esm/integrity/column-types/types.js.map +1 -0
- package/dist/esm/integrity/disposition/lifecycle.d.ts +31 -1
- package/dist/esm/integrity/disposition/lifecycle.js +54 -1
- package/dist/esm/integrity/disposition/lifecycle.js.map +1 -1
- package/dist/esm/integrity/empty-lookup/check.d.ts +140 -0
- package/dist/esm/integrity/empty-lookup/check.js +212 -0
- package/dist/esm/integrity/empty-lookup/check.js.map +1 -0
- package/dist/esm/integrity/finding/types.d.ts +23 -2
- package/dist/esm/integrity/finding/types.js.map +1 -1
- package/dist/esm/integrity/unsupported-argument/check.js +11 -27
- package/dist/esm/integrity/unsupported-argument/check.js.map +1 -1
- package/dist/esm/lib/mcp/toolExtras.d.ts +17 -2
- package/dist/esm/lib/mcp/toolExtras.js +5 -2
- package/dist/esm/lib/mcp/toolExtras.js.map +1 -1
- package/dist/esm/lib/trace-toolpack/traceToolpack.js +8 -4
- package/dist/esm/lib/trace-toolpack/traceToolpack.js.map +1 -1
- package/dist/index.js +26 -3
- package/dist/index.js.map +1 -1
- package/dist/integrity/argumentLeaves.js +54 -0
- package/dist/integrity/argumentLeaves.js.map +1 -0
- package/dist/integrity/column-types/check.js +368 -0
- package/dist/integrity/column-types/check.js.map +1 -0
- package/dist/integrity/column-types/types.js +112 -0
- package/dist/integrity/column-types/types.js.map +1 -0
- package/dist/integrity/disposition/lifecycle.js +54 -1
- package/dist/integrity/disposition/lifecycle.js.map +1 -1
- package/dist/integrity/empty-lookup/check.js +217 -0
- package/dist/integrity/empty-lookup/check.js.map +1 -0
- package/dist/integrity/finding/types.js.map +1 -1
- package/dist/integrity/unsupported-argument/check.js +13 -29
- package/dist/integrity/unsupported-argument/check.js.map +1 -1
- package/dist/lib/mcp/toolExtras.js +4 -1
- package/dist/lib/mcp/toolExtras.js.map +1 -1
- package/dist/lib/trace-toolpack/traceToolpack.js +8 -4
- package/dist/lib/trace-toolpack/traceToolpack.js.map +1 -1
- package/dist/types/core/Agent.d.ts +10 -0
- package/dist/types/core/Agent.d.ts.map +1 -1
- package/dist/types/core/agent/integrityFindings.d.ts +28 -0
- package/dist/types/core/agent/integrityFindings.d.ts.map +1 -0
- package/dist/types/core/agent/stages/callLLM.d.ts +25 -0
- package/dist/types/core/agent/stages/callLLM.d.ts.map +1 -1
- package/dist/types/core/agent/stages/toolCalls.d.ts +43 -0
- package/dist/types/core/agent/stages/toolCalls.d.ts.map +1 -1
- package/dist/types/core/agent/types.d.ts +112 -0
- package/dist/types/core/agent/types.d.ts.map +1 -1
- package/dist/types/core/tools.d.ts +63 -0
- package/dist/types/core/tools.d.ts.map +1 -1
- package/dist/types/index.d.ts +3 -0
- package/dist/types/index.d.ts.map +1 -1
- package/dist/types/integrity/argumentLeaves.d.ts +34 -0
- package/dist/types/integrity/argumentLeaves.d.ts.map +1 -0
- package/dist/types/integrity/column-types/check.d.ts +157 -0
- package/dist/types/integrity/column-types/check.d.ts.map +1 -0
- package/dist/types/integrity/column-types/types.d.ts +122 -0
- package/dist/types/integrity/column-types/types.d.ts.map +1 -0
- package/dist/types/integrity/disposition/lifecycle.d.ts +31 -1
- package/dist/types/integrity/disposition/lifecycle.d.ts.map +1 -1
- package/dist/types/integrity/empty-lookup/check.d.ts +141 -0
- package/dist/types/integrity/empty-lookup/check.d.ts.map +1 -0
- package/dist/types/integrity/finding/types.d.ts +23 -2
- package/dist/types/integrity/finding/types.d.ts.map +1 -1
- package/dist/types/integrity/unsupported-argument/check.d.ts.map +1 -1
- package/dist/types/lib/mcp/toolExtras.d.ts +17 -2
- package/dist/types/lib/mcp/toolExtras.d.ts.map +1 -1
- package/dist/types/lib/trace-toolpack/traceToolpack.d.ts.map +1 -1
- package/package.json +1 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"lifecycle.js","sourceRoot":"","sources":["../../../src/integrity/disposition/lifecycle.ts"],"names":[],"mappings":";AAAA
|
|
1
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,CAAC,IAAI,KAAK,gBAAgB,CAAC,EAAE,CAAC;YAC7D,MAAM,CAAC,aAAa,CAAC,gBAAgB,EAAE,OAAO,EAAE,QAAQ,CAAC,CAAC;QAC5D,CAAC;IACH,CAAC;IACD,OAAO,MAAM,CAAC;AAChB,CAAC;AAnLD,8CAmLC"}
|
|
@@ -0,0 +1,217 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/**
|
|
3
|
+
* empty-lookup — the run itself produced this identifier, and the lookup for
|
|
4
|
+
* it found nothing. Filed at the WRITE seam, as an advisory, never an
|
|
5
|
+
* accusation.
|
|
6
|
+
*
|
|
7
|
+
* Pattern: pure function over (one finished call, the results its declared
|
|
8
|
+
* producers served); the domain check, one seam later than
|
|
9
|
+
* `unsupported-argument`.
|
|
10
|
+
* Role: the decidable fragment of "did this tool answer, or did it only
|
|
11
|
+
* appear to answer?".
|
|
12
|
+
*
|
|
13
|
+
* THE MEASURED FAILURE. A triage agent's reverse-lookup tool filtered a
|
|
14
|
+
* column before a pivot, so the column did not exist yet and EVERY reverse
|
|
15
|
+
* lookup returned an empty result — for every identifier, always. The tool
|
|
16
|
+
* then answered SUCCESSFULLY with an empty list, and the agent reported in a
|
|
17
|
+
* table, with confidence, that the device was "not currently logged in to any
|
|
18
|
+
* port on the collected switches" and advised checking physical cabling. It
|
|
19
|
+
* was logged in the whole time. Nothing in the framework noticed, because an
|
|
20
|
+
* empty result from a broken filter is byte-identical to an empty result from
|
|
21
|
+
* a genuine absence.
|
|
22
|
+
*
|
|
23
|
+
* WHAT THE LIBRARY ALREADY KNOWS, and this check is nothing more than the
|
|
24
|
+
* join of the two:
|
|
25
|
+
* (a) the identifier was GROUNDED — it came out of an earlier tool result
|
|
26
|
+
* in THIS run, from a tool the consumer's author named in
|
|
27
|
+
* `Tool.argumentsFrom`;
|
|
28
|
+
* (b) the lookup keyed on it came back EMPTY.
|
|
29
|
+
* When the run produced the identifier and the lookup for it finds nothing,
|
|
30
|
+
* that is worth filing. It is not worth accusing anyone of.
|
|
31
|
+
*
|
|
32
|
+
* THE CEILING, and it is the whole reason this is an advisory: an empty
|
|
33
|
+
* answer can be perfectly true. The device may exist and simply have no
|
|
34
|
+
* logins right now. NOTHING IN THIS FILE CAN TELL THOSE APART, and nothing in
|
|
35
|
+
* this file pretends to — the finding says "here is a pair worth a look", the
|
|
36
|
+
* record carries the ceiling sentence verbatim, and the same finding is filed
|
|
37
|
+
* for the true absence and the broken filter alike. A check that guessed
|
|
38
|
+
* which one it was looking at would be inventing the certainty the field
|
|
39
|
+
* failure was made of.
|
|
40
|
+
*
|
|
41
|
+
* DECLARED, NEVER INFERRED — the `argumentsFrom` precedent, THIRD use. A tool
|
|
42
|
+
* is this check's subject only because its author said its arguments come
|
|
43
|
+
* from another tool's results. One declaration now arms three seams:
|
|
44
|
+
* `dangling-reference` asks whether the ground is still in reach when the
|
|
45
|
+
* tool is OFFERED, `unsupported-argument` whether the value the model chose
|
|
46
|
+
* came from that ground when the tool was CALLED, and this whether the ground
|
|
47
|
+
* the run really did serve then found anything when the tool ANSWERED.
|
|
48
|
+
*
|
|
49
|
+
* WHAT COUNTS AS EMPTY — and what this refuses to judge. See
|
|
50
|
+
* {@link readLookupResult}. A rowset is counted, never interpreted; an
|
|
51
|
+
* absence is read from the marker its own helper mints. Every other shape a
|
|
52
|
+
* tool has ever returned — a sentence, an object, a `null`, a claim ticket —
|
|
53
|
+
* is BESPOKE: the library cannot see whether it holds rows, so the encounter
|
|
54
|
+
* is `not-applicable` and says so in the ledger. That row is the point. A
|
|
55
|
+
* check that silently skipped what it could not read would be the decoration
|
|
56
|
+
* the disposition family exists to make impossible.
|
|
57
|
+
*
|
|
58
|
+
* Detection only. Nothing here blocks, retries, rewrites or delays anything;
|
|
59
|
+
* the result the model reads is the result the tool returned.
|
|
60
|
+
*/
|
|
61
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
62
|
+
exports.emptyLookupOf = exports.readLookupResult = exports.EMPTY_LOOKUP_CEILING = void 0;
|
|
63
|
+
const argumentLeaves_js_1 = require("../argumentLeaves.js");
|
|
64
|
+
/**
|
|
65
|
+
* THE CEILING, as one string with one owner.
|
|
66
|
+
*
|
|
67
|
+
* Quoted verbatim into every finding's message, into the check's README and
|
|
68
|
+
* into its docs page, so the bound cannot drift out of one of them and leave
|
|
69
|
+
* a reader thinking the library knows more than it does.
|
|
70
|
+
*/
|
|
71
|
+
exports.EMPTY_LOOKUP_CEILING = 'An empty result can be perfectly true — the thing may exist and simply have nothing to show ' +
|
|
72
|
+
'right now — so this is a place to look, never a verdict that anything is wrong.';
|
|
73
|
+
/**
|
|
74
|
+
* READ a finished result's shape, or decline to.
|
|
75
|
+
*
|
|
76
|
+
* The two readable shapes, and why only these two:
|
|
77
|
+
*
|
|
78
|
+
* • a **rowset** — an array. Its length is COUNTED, not interpreted: zero
|
|
79
|
+
* rows is zero rows, and no judgement about what the tool meant is
|
|
80
|
+
* involved. This is the shape the recorded failure actually returned.
|
|
81
|
+
* • an **absence** — the `absent()` envelope, whose author said in so many
|
|
82
|
+
* words "the search ran and matched nothing".
|
|
83
|
+
*
|
|
84
|
+
* Everything else returns `undefined`, which the caller files as
|
|
85
|
+
* `not-applicable`. A prose sentence, a bespoke `{ rows: [...] }` wrapper, a
|
|
86
|
+
* `null`, a placement claim ticket — the library cannot see rows in any of
|
|
87
|
+
* them, and guessing is how a checker starts lying.
|
|
88
|
+
*
|
|
89
|
+
* @param value the tool's own answer, as it returned it.
|
|
90
|
+
* @param declaredAbsence whether `readAbsence` recognized the value. PASSED
|
|
91
|
+
* IN rather than re-derived here on purpose: the `af_absent` marker has
|
|
92
|
+
* exactly one owner (`core/agent/coverage/absent.ts`), a second spelling of
|
|
93
|
+
* a reserved word would eventually disagree with the first, and
|
|
94
|
+
* `src/integrity/` stays a leaf that imports no agent code.
|
|
95
|
+
*/
|
|
96
|
+
function readLookupResult(value, declaredAbsence) {
|
|
97
|
+
if (declaredAbsence)
|
|
98
|
+
return { shape: 'absence', empty: true };
|
|
99
|
+
if (Array.isArray(value))
|
|
100
|
+
return { shape: 'rowset', empty: value.length === 0, rows: value.length };
|
|
101
|
+
return undefined;
|
|
102
|
+
}
|
|
103
|
+
exports.readLookupResult = readLookupResult;
|
|
104
|
+
/**
|
|
105
|
+
* Judge one finished call to an armed tool.
|
|
106
|
+
*
|
|
107
|
+
* @param call the call and what the library could read of its result. The
|
|
108
|
+
* caller has already established the tool declared `argumentsFrom`;
|
|
109
|
+
* nothing here re-decides who is a subject.
|
|
110
|
+
* @param produced every tool result this run served BEFORE this call, with
|
|
111
|
+
* the tool that produced each. Filtered to the declared producers here.
|
|
112
|
+
* @param epoch the run iteration, stamped on every witness.
|
|
113
|
+
*/
|
|
114
|
+
function emptyLookupOf(call, produced, epoch) {
|
|
115
|
+
// A shape the library cannot read is not a pass and not a fail. It is the
|
|
116
|
+
// check looking at a subject that is out of its scope BY RULE, which is
|
|
117
|
+
// exactly what `not-applicable` was minted for.
|
|
118
|
+
if (call.reading === undefined)
|
|
119
|
+
return { findings: [], disposition: 'not-applicable' };
|
|
120
|
+
// The lookup found something. Nothing to say — and a `checked-pass` rather
|
|
121
|
+
// than silence, because a check that only speaks when it fires cannot be
|
|
122
|
+
// told apart from one that was never wired.
|
|
123
|
+
if (!call.reading.empty)
|
|
124
|
+
return { findings: [], disposition: 'checked-pass' };
|
|
125
|
+
// Only the DECLARED producers ground anything here. The choice seam asks
|
|
126
|
+
// the broader question (did ANYTHING the run served carry this value); this
|
|
127
|
+
// one is narrower on purpose — `argumentsFrom` says where the value was
|
|
128
|
+
// supposed to come from, and "it came from exactly there, and the lookup
|
|
129
|
+
// still found nothing" is the pair worth a person's attention.
|
|
130
|
+
const grounds = produced
|
|
131
|
+
.filter((p) => call.argumentsFrom.includes(p.toolName) && p.text.length > 0)
|
|
132
|
+
.map((p) => ({ toolName: p.toolName, lowered: p.text.toLowerCase() }));
|
|
133
|
+
// The declared ground served nothing at all in this run, so there is no
|
|
134
|
+
// corpus to join against and no identity edge between the two tools. Not a
|
|
135
|
+
// pass — the check could not run. `unreachable` is the family's word for
|
|
136
|
+
// exactly that, and it is the falsification instrument: an `empty-lookup`
|
|
137
|
+
// row dominated by `unreachable` means apps are calling consumers before
|
|
138
|
+
// their declared producers, and this check is watching a seam that is not
|
|
139
|
+
// where their identifiers come from.
|
|
140
|
+
if (grounds.length === 0)
|
|
141
|
+
return { findings: [], disposition: 'unreachable' };
|
|
142
|
+
const consumer = { kind: 'tool', id: call.toolName };
|
|
143
|
+
const emptyPhrase = call.reading.shape === 'absence'
|
|
144
|
+
? 'a declared absence — the tool said the search ran and matched nothing'
|
|
145
|
+
: 'a rowset with zero rows';
|
|
146
|
+
const findings = [];
|
|
147
|
+
for (const leaf of (0, argumentLeaves_js_1.stringLeaves)(call.args, '')) {
|
|
148
|
+
const value = leaf.value.trim();
|
|
149
|
+
// The same fences as the choice seam, for the same reasons and from the
|
|
150
|
+
// same file: non-strings are never identifier-shaped, and below four
|
|
151
|
+
// characters substring matching is noise in both directions.
|
|
152
|
+
if (value.length < argumentLeaves_js_1.MIN_CHECKED_LENGTH)
|
|
153
|
+
continue;
|
|
154
|
+
const needle = value.toLowerCase();
|
|
155
|
+
// Substring, case-insensitive — deliberately THE SAME rule the choice
|
|
156
|
+
// seam grounds by. The two checks must agree about what "this value came
|
|
157
|
+
// from that tool" means, or a value could fall between them and be seen
|
|
158
|
+
// by neither.
|
|
159
|
+
const ground = grounds.find((g) => g.lowered.includes(needle));
|
|
160
|
+
if (ground === undefined)
|
|
161
|
+
continue;
|
|
162
|
+
const producer = { kind: 'tool', id: ground.toolName };
|
|
163
|
+
const witnesses = [
|
|
164
|
+
{
|
|
165
|
+
subject: consumer,
|
|
166
|
+
predicate: leaf.path,
|
|
167
|
+
value: leaf.value,
|
|
168
|
+
epoch,
|
|
169
|
+
stratum: 'asserted',
|
|
170
|
+
provenance: `tool call ${call.toolCallId}: argument '${leaf.path}' as the model chose it`,
|
|
171
|
+
},
|
|
172
|
+
{
|
|
173
|
+
subject: producer,
|
|
174
|
+
predicate: leaf.path,
|
|
175
|
+
value: 'served this value earlier in this run',
|
|
176
|
+
epoch,
|
|
177
|
+
stratum: 'asserted',
|
|
178
|
+
provenance: `'${ground.toolName}' is a declared ground of '${call.toolName}' ` +
|
|
179
|
+
`(Tool.argumentsFrom) and one of its results in this run carries the value`,
|
|
180
|
+
},
|
|
181
|
+
{
|
|
182
|
+
subject: consumer,
|
|
183
|
+
predicate: leaf.path,
|
|
184
|
+
value: `found nothing — ${emptyPhrase}`,
|
|
185
|
+
epoch,
|
|
186
|
+
stratum: 'asserted',
|
|
187
|
+
provenance: `tool call ${call.toolCallId}: the result, as the tool returned it`,
|
|
188
|
+
},
|
|
189
|
+
];
|
|
190
|
+
findings.push({
|
|
191
|
+
kind: 'empty-lookup',
|
|
192
|
+
seam: 'write',
|
|
193
|
+
subjects: [consumer, producer],
|
|
194
|
+
// The dot-path IS the discriminator, exactly as at the choice seam: two
|
|
195
|
+
// arguments of one call are two notices. The stated limit is the same
|
|
196
|
+
// one — the SAME argument re-chosen with a different value stays one
|
|
197
|
+
// finding, and the ledger's `findings` count is what says how often.
|
|
198
|
+
predicate: leaf.path,
|
|
199
|
+
witnesses,
|
|
200
|
+
epoch,
|
|
201
|
+
// Doubt, not contradiction. Counted apart from real defects everywhere
|
|
202
|
+
// the family reports, because this check can never know it found one.
|
|
203
|
+
advisory: true,
|
|
204
|
+
message: `'${call.toolName}' was called with ${leaf.path} = "${(0, argumentLeaves_js_1.clipValue)(value)}" — a value ` +
|
|
205
|
+
`this run itself produced, in a result from '${ground.toolName}', which ` +
|
|
206
|
+
`'${call.toolName}' declares as where its arguments come from — and the lookup came ` +
|
|
207
|
+
`back with ${emptyPhrase}. That pairing is what makes it worth a look: the run had ` +
|
|
208
|
+
`the identifier, so an empty answer is either a true absence or a lookup that could ` +
|
|
209
|
+
`never have matched, and those two are byte-identical from here. ` +
|
|
210
|
+
`${exports.EMPTY_LOOKUP_CEILING} Call id ${call.toolCallId}. Nothing here blocked the call, ` +
|
|
211
|
+
`changed the result, or retried anything.`,
|
|
212
|
+
});
|
|
213
|
+
}
|
|
214
|
+
return { findings, disposition: findings.length > 0 ? 'checked-fail' : 'checked-pass' };
|
|
215
|
+
}
|
|
216
|
+
exports.emptyLookupOf = emptyLookupOf;
|
|
217
|
+
//# sourceMappingURL=check.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"check.js","sourceRoot":"","sources":["../../../src/integrity/empty-lookup/check.ts"],"names":[],"mappings":";AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA0DG;;;AAEH,4DAAmF;AAKnF;;;;;;GAMG;AACU,QAAA,oBAAoB,GAC/B,8FAA8F;IAC9F,iFAAiF,CAAC;AAWpF;;;;;;;;;;;;;;;;;;;;;;GAsBG;AACH,SAAgB,gBAAgB,CAC9B,KAAc,EACd,eAAwB;IAExB,IAAI,eAAe;QAAE,OAAO,EAAE,KAAK,EAAE,SAAS,EAAE,KAAK,EAAE,IAAI,EAAE,CAAC;IAC9D,IAAI,KAAK,CAAC,OAAO,CAAC,KAAK,CAAC;QACtB,OAAO,EAAE,KAAK,EAAE,QAAQ,EAAE,KAAK,EAAE,KAAK,CAAC,MAAM,KAAK,CAAC,EAAE,IAAI,EAAE,KAAK,CAAC,MAAM,EAAE,CAAC;IAC5E,OAAO,SAAS,CAAC;AACnB,CAAC;AARD,4CAQC;AAiCD;;;;;;;;;GASG;AACH,SAAgB,aAAa,CAC3B,IAAqB,EACrB,QAAmC,EACnC,KAAa;IAEb,0EAA0E;IAC1E,wEAAwE;IACxE,gDAAgD;IAChD,IAAI,IAAI,CAAC,OAAO,KAAK,SAAS;QAAE,OAAO,EAAE,QAAQ,EAAE,EAAE,EAAE,WAAW,EAAE,gBAAgB,EAAE,CAAC;IACvF,2EAA2E;IAC3E,yEAAyE;IACzE,4CAA4C;IAC5C,IAAI,CAAC,IAAI,CAAC,O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,EAAE,CAAC,QAAQ,EAAE,QAAQ,CAAC;YAC9B,wEAAwE;YACxE,sEAAsE;YACtE,qEAAqE;YACrE,qEAAqE;YACrE,SAAS,EAAE,IAAI,CAAC,IAAI;YACpB,SAAS;YACT,KAAK;YACL,uEAAuE;YACvE,sEAAsE;YACtE,QAAQ,EAAE,IAAI;YACd,OAAO,EACL,IAAI,IAAI,CAAC,QAAQ,qBAAqB,IAAI,CAAC,IAAI,OAAO,IAAA,6BAAS,EAAC,KAAK,CAAC,cAAc;gBACpF,+CAA+C,MAAM,CAAC,QAAQ,WAAW;gBACzE,IAAI,IAAI,CAAC,QAAQ,oEAAoE;gBACrF,aAAa,WAAW,4DAA4D;gBACpF,qFAAqF;gBACrF,kEAAkE;gBAClE,GAAG,4BAAoB,YAAY,IAAI,CAAC,UAAU,mCAAmC;gBACrF,0CAA0C;SAC7C,CAAC,CAAC;IACL,CAAC;IAED,OAAO,EAAE,QAAQ,EAAE,WAAW,EAAE,QAAQ,CAAC,MAAM,GAAG,CAAC,CAAC,CAAC,CAAC,cAAc,CAAC,CAAC,CAAC,cAAc,EAAE,CAAC;AAC1F,CAAC;AA7GD,sCA6GC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"types.js","sourceRoot":"","sources":["../../../src/integrity/finding/types.ts"],"names":[],"mappings":";AAAA;;;;;;;;;;;;;;;;;;GAkBG;;;
|
|
1
|
+
{"version":3,"file":"types.js","sourceRoot":"","sources":["../../../src/integrity/finding/types.ts"],"names":[],"mappings":";AAAA;;;;;;;;;;;;;;;;;;GAkBG;;;AAyFH;;;;;GAKG;AACH,SAAgB,oBAAoB,CAAC,CAAe;IAClD,MAAM,QAAQ,GAAG,CAAC,CAAC,QAAQ;SACxB,GAAG,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,GAAG,CAAC,CAAC,IAAI,IAAI,CAAC,CAAC,EAAE,EAAE,CAAC;SAC/B,IAAI,EAAE;SACN,IAAI,CAAC,KAAK,CAAC,CAAC;IACf,MAAM,KAAK,GAAG,CAAC,CAAC,KAAK,KAAK,SAAS,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,MAAM,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC;IAC3D,oEAAoE;IACpE,wEAAwE;IACxE,mDAAmD;IACnD,MAAM,SAAS,GAAG,CAAC,CAAC,SAAS,IAAI,EAAE,CAAC;IACpC,OAAO,GAAG,CAAC,CAAC,IAAI,KAAK,CAAC,CAAC,IAAI,KAAK,QAAQ,KAAK,SAAS,IAAI,KAAK,EAAE,CAAC;AACpE,CAAC;AAXD,oDAWC;AAED,8DAA8D;AAC9D,SAAgB,mBAAmB,CAAC,MAA+B;IACjE,MAAM,IAAI,GAAG,IAAI,GAAG,EAAU,CAAC;IAC/B,MAAM,IAAI,GAAmB,EAAE,CAAC;IAChC,KAAK,MAAM,CAAC,IAAI,MAAM,EAAE,CAAC;QACvB,MAAM,EAAE,GAAG,oBAAoB,CAAC,CAAC,CAAC,CAAC;QACnC,IAAI,IAAI,CAAC,GAAG,CAAC,EAAE,CAAC;YAAE,SAAS;QAC3B,IAAI,CAAC,GAAG,CAAC,EAAE,CAAC,CAAC;QACb,IAAI,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC;IACf,CAAC;IACD,OAAO,IAAI,CAAC;AACd,CAAC;AAVD,kDAUC"}
|
|
@@ -64,33 +64,17 @@
|
|
|
64
64
|
*/
|
|
65
65
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
66
66
|
exports.unsupportedArgumentsOf = exports.declaredEnumValuesOf = void 0;
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
67
|
+
const argumentLeaves_js_1 = require("../argumentLeaves.js");
|
|
68
|
+
/**
|
|
69
|
+
* The value fence, the quoting length and the argument walk moved to
|
|
70
|
+
* `../argumentLeaves.ts` when the write seam's `empty-lookup` check landed
|
|
71
|
+
* (9.77.0). Two checks now read one call's arguments and must agree, to the
|
|
72
|
+
* character, about which leaves are candidates and what their dot-paths are —
|
|
73
|
+
* the second check's whole job is to notice something about a value this one
|
|
74
|
+
* already excused.
|
|
75
|
+
*/
|
|
71
76
|
/** Deepest a schema is walked for `enum` declarations. */
|
|
72
77
|
const MAX_SCHEMA_DEPTH = 8;
|
|
73
|
-
function clip(value) {
|
|
74
|
-
return value.length <= MAX_QUOTED_CHARS ? value : `${value.slice(0, MAX_QUOTED_CHARS - 1)}…`;
|
|
75
|
-
}
|
|
76
|
-
/** Every string leaf of an arguments object, with its dot-path. */
|
|
77
|
-
function* stringLeaves(node, path) {
|
|
78
|
-
if (typeof node === 'string') {
|
|
79
|
-
yield { path, value: node };
|
|
80
|
-
return;
|
|
81
|
-
}
|
|
82
|
-
if (Array.isArray(node)) {
|
|
83
|
-
for (let i = 0; i < node.length; i++) {
|
|
84
|
-
yield* stringLeaves(node[i], path === '' ? String(i) : `${path}.${String(i)}`);
|
|
85
|
-
}
|
|
86
|
-
return;
|
|
87
|
-
}
|
|
88
|
-
if (node !== null && typeof node === 'object') {
|
|
89
|
-
for (const [key, value] of Object.entries(node)) {
|
|
90
|
-
yield* stringLeaves(value, path === '' ? key : `${path}.${key}`);
|
|
91
|
-
}
|
|
92
|
-
}
|
|
93
|
-
}
|
|
94
78
|
/**
|
|
95
79
|
* Best-effort: every string an `enum` array declares anywhere in a tool's
|
|
96
80
|
* `inputSchema`. Flat by design — a per-path map would be more precise, and on
|
|
@@ -158,9 +142,9 @@ function unsupportedArgumentsOf(calls, corpus, epoch) {
|
|
|
158
142
|
const refetch = grounds.length > 0
|
|
159
143
|
? `call ${grounds} again and use a value it returns`
|
|
160
144
|
: 're-read the value from the tool that serves it';
|
|
161
|
-
for (const leaf of stringLeaves(call.args, '')) {
|
|
145
|
+
for (const leaf of (0, argumentLeaves_js_1.stringLeaves)(call.args, '')) {
|
|
162
146
|
const value = leaf.value.trim();
|
|
163
|
-
if (value.length < MIN_CHECKED_LENGTH)
|
|
147
|
+
if (value.length < argumentLeaves_js_1.MIN_CHECKED_LENGTH)
|
|
164
148
|
continue;
|
|
165
149
|
const needle = value.toLowerCase();
|
|
166
150
|
if (declared.has(needle))
|
|
@@ -215,12 +199,12 @@ function unsupportedArgumentsOf(calls, corpus, epoch) {
|
|
|
215
199
|
witnesses,
|
|
216
200
|
epoch,
|
|
217
201
|
message: selfReferenced
|
|
218
|
-
? `'${call.toolName}' was called with ${leaf.path} = "${
|
|
202
|
+
? `'${call.toolName}' was called with ${leaf.path} = "${(0, argumentLeaves_js_1.clipValue)(value)}", and the only ` +
|
|
219
203
|
`place that value appears in the frame the model chose from is the model’s own ` +
|
|
220
204
|
`earlier answer. Rendered text is not evidence — a value re-read out of prose can ` +
|
|
221
205
|
`be a fragment of something else entirely. To ground it, ${refetch}. Nothing here ` +
|
|
222
206
|
`blocked the call.`
|
|
223
|
-
: `'${call.toolName}' was called with ${leaf.path} = "${
|
|
207
|
+
: `'${call.toolName}' was called with ${leaf.path} = "${(0, argumentLeaves_js_1.clipValue)(value)}", and that value ` +
|
|
224
208
|
`appears nowhere in the frame the model chose from — not in the instructions, not ` +
|
|
225
209
|
`in any message from the user, not in any tool result. Nothing served it, so ` +
|
|
226
210
|
`nothing in this run can say what it refers to. To ground it, ${refetch}. Nothing ` +
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"check.js","sourceRoot":"","sources":["../../../src/integrity/unsupported-argument/check.ts"],"names":[],"mappings":";AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA8DG;;;
|
|
1
|
+
{"version":3,"file":"check.js","sourceRoot":"","sources":["../../../src/integrity/unsupported-argument/check.ts"],"names":[],"mappings":";AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA8DG;;;AAEH,4DAAmF;AAuEnF;;;;;;;GAOG;AAEH,0DAA0D;AAC1D,MAAM,gBAAgB,GAAG,CAA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AC,IAAI,OAAO,IAAA,6BAAS,EAC7D,KAAK,CACN,oBAAoB;wBACrB,mFAAmF;wBACnF,8EAA8E;wBAC9E,gEAAgE,OAAO,YAAY;wBACnF,wBAAwB;aAC7B,CAAC,CAAC;QACL,CAAC;IACH,CAAC;IACD,OAAO,EAAE,QAAQ,EAAE,kBAAkB,EAAE,CAAC;AAC1C,CAAC;AAhHD,wDAgHC"}
|
|
@@ -29,7 +29,7 @@
|
|
|
29
29
|
*
|
|
30
30
|
* ── What may travel, and the bar ────────────────────────────────────────
|
|
31
31
|
* **A declaration a consumer-side check or rail reads; nothing that governs
|
|
32
|
-
* execution.**
|
|
32
|
+
* execution.** Every field below passes it. `needs` (credentials), `checkIn`
|
|
33
33
|
* (human consent) and the session hooks do NOT and never will: they govern how
|
|
34
34
|
* a tool RUNS, and the tool runs on the server. Sending them would tell a
|
|
35
35
|
* client to hold a gate that the only executor of the tool has already held,
|
|
@@ -74,6 +74,7 @@ function toolExtrasOf(tool) {
|
|
|
74
74
|
const extras = {
|
|
75
75
|
...(tool.argumentsFrom !== undefined && { argumentsFrom: tool.argumentsFrom }),
|
|
76
76
|
...(tool.resultKind !== undefined && { resultKind: tool.resultKind }),
|
|
77
|
+
...(tool.resultColumns !== undefined && { resultColumns: tool.resultColumns }),
|
|
77
78
|
...(tool.owner !== undefined && { owner: tool.owner }),
|
|
78
79
|
...(tool.resultClass !== undefined && { resultClass: tool.resultClass }),
|
|
79
80
|
...(tool.resultCeiling !== undefined && { resultCeiling: tool.resultCeiling }),
|
|
@@ -111,6 +112,7 @@ function readToolExtras(meta, origin) {
|
|
|
111
112
|
// rule has agreed it is the shape the field claims.
|
|
112
113
|
const argumentsFrom = kept('argumentsFrom', (v) => (0, tools_js_1.assertArgumentsFrom)(origin.tool, v));
|
|
113
114
|
const resultKind = kept('resultKind', (v) => (0, tools_js_1.assertResultKind)(origin.tool, v));
|
|
115
|
+
const resultColumns = kept('resultColumns', (v) => (0, tools_js_1.assertResultColumns)(origin.tool, v));
|
|
114
116
|
const owner = kept('owner', (v) => (0, tools_js_1.assertToolOwner)(origin.tool, v));
|
|
115
117
|
const resultClass = kept('resultClass', (v) => (0, tools_js_1.assertResultClass)(origin.tool, v));
|
|
116
118
|
const resultCeiling = kept('resultCeiling', (v) => (0, tools_js_1.assertResultCeiling)(origin.tool, v));
|
|
@@ -119,6 +121,7 @@ function readToolExtras(meta, origin) {
|
|
|
119
121
|
return {
|
|
120
122
|
...(argumentsFrom !== undefined && { argumentsFrom }),
|
|
121
123
|
...(resultKind !== undefined && { resultKind }),
|
|
124
|
+
...(resultColumns !== undefined && { resultColumns }),
|
|
122
125
|
...(owner !== undefined && { owner }),
|
|
123
126
|
...(resultClass !== undefined && { resultClass }),
|
|
124
127
|
...(resultCeiling !== undefined && { resultCeiling }),
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"toolExtras.js","sourceRoot":"","sources":["../../../src/lib/mcp/toolExtras.ts"],"names":[],"mappings":";AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAkDG;;;AAEH,
|
|
1
|
+
{"version":3,"file":"toolExtras.js","sourceRoot":"","sources":["../../../src/lib/mcp/toolExtras.ts"],"names":[],"mappings":";AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAkDG;;;AAEH,kDAa6B;AAG7B;;;;;;;GAOG;AACU,QAAA,mBAAmB,GAAG,gBAAgB,CAAC;AAqDpD;;;;;;;GAOG;AACH,SAAgB,YAAY,CAAC,IAAU;IACrC,MAAM,MAAM,GAAkB;QAC5B,GAAG,CAAC,IAAI,CAAC,aAAa,KAAK,SAAS,IAAI,EAAE,aAAa,EAAE,IAAI,CAAC,aAAa,EAAE,CAAC;QAC9E,GAAG,CAAC,IAAI,CAAC,UAAU,KAAK,SAAS,IAAI,EAAE,UAAU,EAAE,IAAI,CAAC,UAAU,EAAE,CAAC;QACrE,GAAG,CAAC,IA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AC,MAAM,EAAE,KAAK,EAAE,KAAK,YAAY,KAAK,CAAC,CAAC,CAAC,KAAK,CAAC,OAAO,CAAC,CAAC,CAAC,MAAM,CAAC,KAAK,CAAC,CAAC,CAAC;QAChF,OAAO,SAAS,CAAC;IACnB,CAAC;IACD,OAAO,KAAK,CAAC;AACf,CAAC;AAED,sEAAsE;AAEtE;;;;;;;;;GASG;AACH,MAAM,MAAM,GAAG,IAAI,GAAG,EAAU,CAAC;AACjC,MAAM,UAAU,GAAG,GAAG,CAAC;AAEvB;;;;;;;;;GASG;AACH,SAAS,QAAQ,CAAC,MAA2B,EAAE,KAAa,EAAE,IAAY;IACxE,MAAM,GAAG,GAAG,GAAG,MAAM,CAAC,MAAM,IAAI,MAAM,CAAC,IAAI,IAAI,KAAK,EAAE,CAAC;IACvD,IAAI,MAAM,CAAC,GAAG,CAAC,GAAG,CAAC;QAAE,OAAO;IAC5B,IAAI,MAAM,CAAC,IAAI,GAAG,UAAU;QAAE,MAAM,CAAC,GAAG,CAAC,GAAG,CAAC,CAAC;IAC9C,sCAAsC;IACtC,OAAO,CAAC,IAAI,CACV,gCAAgC,MAAM,CAAC,MAAM,gBAAgB,KAAK,aAAa;QAC7E,IAAI,MAAM,CAAC,IAAI,kBAAkB,2BAAmB,gCAAgC;QACpF,oFAAoF;QACpF,uEAAuE,IAAI,EAAE,CAChF,CAAC;AACJ,CAAC;AAED;;;;GAIG;AACH,SAAgB,wBAAwB;IACtC,MAAM,CAAC,KAAK,EAAE,CAAC;AACjB,CAAC;AAFD,4DAEC"}
|
|
@@ -446,7 +446,7 @@ function buildRunOverview(artifacts, index) {
|
|
|
446
446
|
}
|
|
447
447
|
// ── find_context_errors ────────────────────────────────────────────────────
|
|
448
448
|
/**
|
|
449
|
-
* The
|
|
449
|
+
* The six ContextErrorKinds — each mapped to the check that can FILE it in
|
|
450
450
|
* this build, or `false` when no check ships for that class.
|
|
451
451
|
*
|
|
452
452
|
* Two jobs in one table:
|
|
@@ -455,8 +455,8 @@ function buildRunOverview(artifacts, index) {
|
|
|
455
455
|
* a kind added to the finding type without joining this list fails to
|
|
456
456
|
* compile HERE, rather than becoming a value the tool's enum silently
|
|
457
457
|
* rejects at run time.
|
|
458
|
-
* - the honesty gate. `ContextErrorKind` names
|
|
459
|
-
* `src/integrity/` ships
|
|
458
|
+
* - the honesty gate. `ContextErrorKind` names six defect classes;
|
|
459
|
+
* `src/integrity/` ships five checks. Offering the sixth in the
|
|
460
460
|
* schema enum invites a query whose only possible answer is a negative
|
|
461
461
|
* verdict about a class nothing in the library could have filed — the
|
|
462
462
|
* tool telling a model "no duplicate-execution errors" when nothing on
|
|
@@ -470,6 +470,9 @@ const CONTEXT_ERROR_KIND_CHECKS = {
|
|
|
470
470
|
'dangling-reference': 'src/integrity/dangling-reference (compose)',
|
|
471
471
|
'duplicate-execution': false,
|
|
472
472
|
'unsupported-claim': 'src/integrity/unsupported-claim (claim)',
|
|
473
|
+
'empty-lookup': 'src/integrity/empty-lookup (write)',
|
|
474
|
+
'column-type-mismatch': 'src/integrity/column-types (write)',
|
|
475
|
+
'missing-column': 'src/integrity/column-types (write)',
|
|
473
476
|
};
|
|
474
477
|
const ALL_CONTEXT_ERROR_KINDS = Object.keys(CONTEXT_ERROR_KIND_CHECKS);
|
|
475
478
|
/** The kinds the tool OFFERS — the ones a shipped check can actually file. */
|
|
@@ -758,7 +761,8 @@ function buildFindContextErrors(artifacts, index, reader, opts) {
|
|
|
758
761
|
name: 'find_context_errors',
|
|
759
762
|
description: 'What did this run CONTRADICT ITSELF about? Lists the Context Integrity findings the ' +
|
|
760
763
|
'library already caught — an invariant violated, an offered action whose inputs left ' +
|
|
761
|
-
'scope, an argument nothing served, a claim the record does not support
|
|
764
|
+
'scope, an argument nothing served, a claim the record does not support, a lookup for a ' +
|
|
765
|
+
'value this run produced that came back empty — each with the ' +
|
|
762
766
|
'step it was filed at and the ' +
|
|
763
767
|
'exact drill that opens the state behind it. Call it EARLY when an answer looks wrong: a ' +
|
|
764
768
|
'contradiction the library already caught beats re-deriving one. Reads only; nothing is ' +
|