agentfootprint 9.77.0 → 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.
Files changed (79) hide show
  1. package/CHANGELOG.md +110 -0
  2. package/CLAUDE.md +1 -0
  3. package/dist/core/Agent.js +50 -0
  4. package/dist/core/Agent.js.map +1 -1
  5. package/dist/core/agent/stages/callLLM.js +14 -0
  6. package/dist/core/agent/stages/callLLM.js.map +1 -1
  7. package/dist/core/agent/stages/toolCalls.js +107 -0
  8. package/dist/core/agent/stages/toolCalls.js.map +1 -1
  9. package/dist/core/tools.js +9 -1
  10. package/dist/core/tools.js.map +1 -1
  11. package/dist/esm/core/Agent.d.ts +7 -0
  12. package/dist/esm/core/Agent.js +50 -0
  13. package/dist/esm/core/Agent.js.map +1 -1
  14. package/dist/esm/core/agent/stages/callLLM.d.ts +11 -0
  15. package/dist/esm/core/agent/stages/callLLM.js +14 -0
  16. package/dist/esm/core/agent/stages/callLLM.js.map +1 -1
  17. package/dist/esm/core/agent/stages/toolCalls.d.ts +20 -0
  18. package/dist/esm/core/agent/stages/toolCalls.js +107 -0
  19. package/dist/esm/core/agent/stages/toolCalls.js.map +1 -1
  20. package/dist/esm/core/agent/types.d.ts +63 -0
  21. package/dist/esm/core/tools.d.ts +63 -0
  22. package/dist/esm/core/tools.js +17 -0
  23. package/dist/esm/core/tools.js.map +1 -1
  24. package/dist/esm/index.d.ts +2 -0
  25. package/dist/esm/index.js +11 -0
  26. package/dist/esm/index.js.map +1 -1
  27. package/dist/esm/integrity/column-types/check.d.ts +156 -0
  28. package/dist/esm/integrity/column-types/check.js +363 -0
  29. package/dist/esm/integrity/column-types/check.js.map +1 -0
  30. package/dist/esm/integrity/column-types/types.d.ts +121 -0
  31. package/dist/esm/integrity/column-types/types.js +107 -0
  32. package/dist/esm/integrity/column-types/types.js.map +1 -0
  33. package/dist/esm/integrity/disposition/lifecycle.d.ts +16 -1
  34. package/dist/esm/integrity/disposition/lifecycle.js +30 -1
  35. package/dist/esm/integrity/disposition/lifecycle.js.map +1 -1
  36. package/dist/esm/integrity/finding/types.d.ts +14 -2
  37. package/dist/esm/integrity/finding/types.js.map +1 -1
  38. package/dist/esm/lib/mcp/toolExtras.d.ts +17 -2
  39. package/dist/esm/lib/mcp/toolExtras.js +5 -2
  40. package/dist/esm/lib/mcp/toolExtras.js.map +1 -1
  41. package/dist/esm/lib/trace-toolpack/traceToolpack.js +2 -0
  42. package/dist/esm/lib/trace-toolpack/traceToolpack.js.map +1 -1
  43. package/dist/index.js +18 -3
  44. package/dist/index.js.map +1 -1
  45. package/dist/integrity/column-types/check.js +368 -0
  46. package/dist/integrity/column-types/check.js.map +1 -0
  47. package/dist/integrity/column-types/types.js +112 -0
  48. package/dist/integrity/column-types/types.js.map +1 -0
  49. package/dist/integrity/disposition/lifecycle.js +30 -1
  50. package/dist/integrity/disposition/lifecycle.js.map +1 -1
  51. package/dist/integrity/finding/types.js.map +1 -1
  52. package/dist/lib/mcp/toolExtras.js +4 -1
  53. package/dist/lib/mcp/toolExtras.js.map +1 -1
  54. package/dist/lib/trace-toolpack/traceToolpack.js +2 -0
  55. package/dist/lib/trace-toolpack/traceToolpack.js.map +1 -1
  56. package/dist/types/core/Agent.d.ts +7 -0
  57. package/dist/types/core/Agent.d.ts.map +1 -1
  58. package/dist/types/core/agent/stages/callLLM.d.ts +11 -0
  59. package/dist/types/core/agent/stages/callLLM.d.ts.map +1 -1
  60. package/dist/types/core/agent/stages/toolCalls.d.ts +20 -0
  61. package/dist/types/core/agent/stages/toolCalls.d.ts.map +1 -1
  62. package/dist/types/core/agent/types.d.ts +63 -0
  63. package/dist/types/core/agent/types.d.ts.map +1 -1
  64. package/dist/types/core/tools.d.ts +63 -0
  65. package/dist/types/core/tools.d.ts.map +1 -1
  66. package/dist/types/index.d.ts +2 -0
  67. package/dist/types/index.d.ts.map +1 -1
  68. package/dist/types/integrity/column-types/check.d.ts +157 -0
  69. package/dist/types/integrity/column-types/check.d.ts.map +1 -0
  70. package/dist/types/integrity/column-types/types.d.ts +122 -0
  71. package/dist/types/integrity/column-types/types.d.ts.map +1 -0
  72. package/dist/types/integrity/disposition/lifecycle.d.ts +16 -1
  73. package/dist/types/integrity/disposition/lifecycle.d.ts.map +1 -1
  74. package/dist/types/integrity/finding/types.d.ts +14 -2
  75. package/dist/types/integrity/finding/types.d.ts.map +1 -1
  76. package/dist/types/lib/mcp/toolExtras.d.ts +17 -2
  77. package/dist/types/lib/mcp/toolExtras.d.ts.map +1 -1
  78. package/dist/types/lib/trace-toolpack/traceToolpack.d.ts.map +1 -1
  79. package/package.json +1 -1
@@ -0,0 +1,122 @@
1
+ /**
2
+ * The COLUMN-TYPE CONTRACT's vocabulary — what a tool may say about the
3
+ * columns of the rowset it returns, and the one rule that judges the saying.
4
+ *
5
+ * Pattern: closed vocabulary + definition-time assert (the `resultCeiling` /
6
+ * `resultClass` law: a declaration this library cannot honour fails
7
+ * at `defineTool`, never at the first row of the first run).
8
+ * Role: leaf. `src/integrity/` imports nothing outside itself, so the
9
+ * vocabulary lives HERE and `core/tools.ts` reaches in for it —
10
+ * never the other way round.
11
+ *
12
+ * ── Why the words are these words ───────────────────────────────────────
13
+ * They are NOT invented. `number | string | boolean | date` is the vocabulary
14
+ * this ecosystem's rowset consumers already speak — a column-type union with
15
+ * exactly these members is what the visualization layer sniffs its way to
16
+ * today. Declaring in the consumer's own words is the `resultKind` law
17
+ * (9.70.0) restated one level down: the tool's result in the CONSUMER's
18
+ * vocabulary, not the framework's.
19
+ *
20
+ * The one member deliberately NOT carried over is `unknown`. A sniffer needs
21
+ * that word — it is what "I looked at the values and could not tell" sounds
22
+ * like. A DECLARATION has no use for it: an author who does not know what a
23
+ * column holds should not name the column, and `columns: { x: 'unknown' }`
24
+ * would be a promise about nothing that the checker would then have to
25
+ * pretend to verify.
26
+ *
27
+ * ── Two spellings, one meaning ──────────────────────────────────────────
28
+ * A column maps to a bare type (`lun: 'number'`) or to an object form
29
+ * (`note: { type: 'string', nullable: true }`). That is this library's house
30
+ * pattern for exactly this shape — `CostBudget` takes a bare number or
31
+ * `{ usd, onExceed }`, `artifacts` takes a bare store or `{ store, placement }`
32
+ * — and it is normalized ONCE, here, so every reader downstream sees one
33
+ * shape and no downstream file learns that there were two.
34
+ */
35
+ /**
36
+ * What a declared column holds.
37
+ *
38
+ * | word | what a value must be |
39
+ * | --- | --- |
40
+ * | `number` | a JavaScript number that is FINITE — `NaN` and the infinities are a number that means "no number", and a chart handed one draws nothing |
41
+ * | `string` | a JavaScript string, including the empty one (emptiness is meaning, and meaning is above this check's ceiling) |
42
+ * | `boolean` | `true` or `false` — never `'true'`, never `0`, never `1` |
43
+ * | `date` | a valid `Date` instance, or a string `Date.parse` accepts (an epoch NUMBER is a `number`; say so and the axis picker stops guessing) |
44
+ */
45
+ export type ColumnType = 'number' | 'string' | 'boolean' | 'date';
46
+ /** The closed set, in one place, for the assert and for its own error message. */
47
+ export declare const COLUMN_TYPES: readonly ColumnType[];
48
+ /** The object spelling of one column's declaration. */
49
+ export interface ColumnDeclaration {
50
+ /** What the column holds. */
51
+ readonly type: ColumnType;
52
+ /**
53
+ * `true` — a row of this column may legitimately carry NO VALUE (`null`,
54
+ * `undefined`, or the key simply not set on that row), and such a row is
55
+ * never a type violation.
56
+ *
57
+ * Default `false`, and the default is the strict one ON PURPOSE. The field
58
+ * failure this check is built from was a value that went missing and left
59
+ * an empty string behind; had the same code left a `null` behind, the
60
+ * defect would have been identical and a lenient default would have waved
61
+ * it through. One word turns it off, and every finding names that word — so
62
+ * a legitimate null column costs a one-word edit, while a silent default
63
+ * would cost the bug.
64
+ *
65
+ * `nullable` is a promise about VALUES. It is NOT a promise about the
66
+ * column's existence: a declared column that appears in no row at all is a
67
+ * `missing-column` finding whether or not it is nullable, because the
68
+ * declaration named a column and the result has no such column. The valve
69
+ * for "this column may or may not be there" is to not declare it —
70
+ * unlisted columns are allowed and unjudged.
71
+ */
72
+ readonly nullable?: boolean;
73
+ }
74
+ /**
75
+ * What a tool declares about the columns of its rowset — column name to type.
76
+ *
77
+ * OPEN, NEVER CLOSED. A declaration is a promise about what it NAMES, not a
78
+ * schema of everything the result may contain: a column nobody listed is
79
+ * allowed and is never judged. Two reasons, and both are the same reason.
80
+ *
81
+ * • A closed schema punishes the wrong party. The day the backend adds a
82
+ * column, every one of these tools starts filing findings about a change
83
+ * that broke nothing — and a check that cries about correct behaviour is
84
+ * a check people switch off, which is how the failure it exists to catch
85
+ * gets back in.
86
+ * • It is the rule the neighbouring boundary already keeps.
87
+ * `toolArgsValidation` is permissive on keywords it does not know and
88
+ * enforces `additionalProperties: false` only when an author explicitly
89
+ * asks for it. Two validators at one seam disagreeing about whether
90
+ * silence means "allowed" would be a worse defect than either could
91
+ * catch.
92
+ */
93
+ export type ToolResultColumns = Readonly<Record<string, ColumnType | ColumnDeclaration>>;
94
+ /** One column's declaration after normalization — the ONLY shape any reader
95
+ * downstream of `normalizeColumns` ever sees. */
96
+ export interface NormalizedColumn {
97
+ readonly name: string;
98
+ readonly type: ColumnType;
99
+ readonly nullable: boolean;
100
+ }
101
+ /**
102
+ * Both spellings into one list, in declaration order.
103
+ *
104
+ * Order is kept because it is the author's order, and a finding that names
105
+ * columns in the order the author wrote them is a finding they can scan
106
+ * against their own source.
107
+ */
108
+ export declare function normalizeColumns(columns: ToolResultColumns): readonly NormalizedColumn[];
109
+ /**
110
+ * Refuse a `resultColumns` this library cannot honour, at definition time —
111
+ * naming the tool, the column and the fix.
112
+ *
113
+ * Exported beside {@link ColumnType} and called from `defineTool`, so a
114
+ * misspelled type fails on the line that wrote it rather than at the first
115
+ * rowset of the first armed run. Also called by the MCP ingest
116
+ * (`readToolExtras`) on a bag from a server this process does not control —
117
+ * which is why every read below goes through a fallback: a `null`, a number
118
+ * or an array must reach the teaching refusal, never blow up on the way to
119
+ * it.
120
+ */
121
+ export declare function assertResultColumns(toolName: string, columns: unknown): void;
122
+ //# sourceMappingURL=types.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../../src/integrity/column-types/types.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAiCG;AAEH;;;;;;;;;GASG;AACH,MAAM,MAAM,UAAU,GAAG,QAAQ,GAAG,QAAQ,GAAG,SAAS,GAAG,MAAM,CAAC;AAElE,kFAAkF;AAClF,eAAO,MAAM,YAAY,EAAE,SAAS,UAAU,EAA4C,CAAC;AAE3F,uDAAuD;AACvD,MAAM,WAAW,iBAAiB;IAChC,6BAA6B;IAC7B,QAAQ,CAAC,IAAI,EAAE,UAAU,CAAC;IAC1B;;;;;;;;;;;;;;;;;;;OAmBG;IACH,QAAQ,CAAC,QAAQ,CAAC,EAAE,OAAO,CAAC;CAC7B;AAED;;;;;;;;;;;;;;;;;;GAkBG;AACH,MAAM,MAAM,iBAAiB,GAAG,QAAQ,CAAC,MAAM,CAAC,MAAM,EAAE,UAAU,GAAG,iBAAiB,CAAC,CAAC,CAAC;AAEzF;kDACkD;AAClD,MAAM,WAAW,gBAAgB;IAC/B,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAC;IACtB,QAAQ,CAAC,IAAI,EAAE,UAAU,CAAC;IAC1B,QAAQ,CAAC,QAAQ,EAAE,OAAO,CAAC;CAC5B;AAED;;;;;;GAMG;AACH,wBAAgB,gBAAgB,CAAC,OAAO,EAAE,iBAAiB,GAAG,SAAS,gBAAgB,EAAE,CAUxF;AAED;;;;;;;;;;;GAWG;AACH,wBAAgB,mBAAmB,CAAC,QAAQ,EAAE,MAAM,EAAE,OAAO,EAAE,OAAO,GAAG,IAAI,CAgD5E"}
@@ -14,7 +14,10 @@
14
14
  * empty-lookup: that same declaration AND the operator's
15
15
  * `noticeEmptyLookups` dial — two halves, because an advisory that
16
16
  * armed itself off a declaration made for something else would not
17
- * be opt-in at all).
17
+ * be opt-in at all; column-types: `Tool.resultColumns` AND the
18
+ * operator's `checkColumnTypes` dial off `'off'` — the same two
19
+ * halves, arming BOTH `column-type-mismatch` and `missing-column`
20
+ * off the one declaration).
18
21
  * Registration is what makes silence auditable — an unregistered
19
22
  * check is honest
20
23
  * absence, a registered one that never notes is the wiring rot
@@ -60,6 +63,18 @@ export interface IntegrityChecksPresent {
60
63
  * silence.
61
64
  */
62
65
  readonly emptyLookup?: boolean;
66
+ /**
67
+ * The write seam's COLUMN-TYPE CONTRACT (9.78.0) — armed only when BOTH
68
+ * halves are true: the operator set `checkColumnTypes` to something other
69
+ * than `'off'` AND at least one tool declared `resultColumns`. The same
70
+ * two-halves law as `empty-lookup`, for the same reason: a declaration is
71
+ * a promise a consumer may already be reading for its own purposes, and
72
+ * arming a boundary check off it alone would make an absent dial change a
73
+ * run's bytes. ONE FLAG, TWO CHECKS — `column-type-mismatch` and
74
+ * `missing-column` are the same declaration read two ways, and nothing can
75
+ * arm one without arming the other.
76
+ */
77
+ readonly columnTypes?: boolean;
63
78
  }
64
79
  /**
65
80
  * Start one run's ledger: register the present checks and, in dev posture,
@@ -1 +1 @@
1
- {"version":3,"file":"lifecycle.d.ts","sourceRoot":"","sources":["../../../../src/integrity/disposition/lifecycle.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA4BG;AAEH,OAAO,EAAqB,KAAK,iBAAiB,EAAE,MAAM,aAAa,CAAC;AAUxE,MAAM,MAAM,gBAAgB,GAAG,SAAS,GAAG,KAAK,CAAC;AAEjD,gEAAgE;AAChE,MAAM,WAAW,sBAAsB;IACrC,QAAQ,CAAC,IAAI,EAAE,OAAO,CAAC;IACvB,QAAQ,CAAC,gBAAgB,EAAE,OAAO,CAAC;IACnC;;;;;;;;;;;;OAYG;IACH,QAAQ,CAAC,QAAQ,EAAE,OAAO,CAAC;IAC3B,mDAAmD;IACnD,QAAQ,CAAC,KAAK,CAAC,EAAE,OAAO,CAAC;IACzB;;;;;;;;;OASG;IACH,QAAQ,CAAC,WAAW,CAAC,EAAE,OAAO,CAAC;CAChC;AAED;;;GAGG;AACH,wBAAgB,iBAAiB,CAC/B,OAAO,EAAE,sBAAsB,EAC/B,OAAO,EAAE,gBAAgB,GACxB,iBAAiB,CAoJnB"}
1
+ {"version":3,"file":"lifecycle.d.ts","sourceRoot":"","sources":["../../../../src/integrity/disposition/lifecycle.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA+BG;AAEH,OAAO,EAAqB,KAAK,iBAAiB,EAAE,MAAM,aAAa,CAAC;AAWxE,MAAM,MAAM,gBAAgB,GAAG,SAAS,GAAG,KAAK,CAAC;AAEjD,gEAAgE;AAChE,MAAM,WAAW,sBAAsB;IACrC,QAAQ,CAAC,IAAI,EAAE,OAAO,CAAC;IACvB,QAAQ,CAAC,gBAAgB,EAAE,OAAO,CAAC;IACnC;;;;;;;;;;;;OAYG;IACH,QAAQ,CAAC,QAAQ,EAAE,OAAO,CAAC;IAC3B,mDAAmD;IACnD,QAAQ,CAAC,KAAK,CAAC,EAAE,OAAO,CAAC;IACzB;;;;;;;;;OASG;IACH,QAAQ,CAAC,WAAW,CAAC,EAAE,OAAO,CAAC;IAC/B;;;;;;;;;;OAUG;IACH,QAAQ,CAAC,WAAW,CAAC,EAAE,OAAO,CAAC;CAChC;AAED;;;GAGG;AACH,wBAAgB,iBAAiB,CAC/B,OAAO,EAAE,sBAAsB,EAC/B,OAAO,EAAE,gBAAgB,GACxB,iBAAiB,CAgLnB"}
@@ -20,7 +20,7 @@
20
20
  import type { Assertion, SubjectRef } from '../assertion/types.js';
21
21
  import type { IntegritySeam } from '../disposition/types.js';
22
22
  /**
23
- * The six defect classes, by their plain names:
23
+ * The eight defect classes, by their plain names:
24
24
  *
25
25
  * | kind | means | mechanism |
26
26
  * |---|---|---|
@@ -30,6 +30,8 @@ import type { IntegritySeam } from '../disposition/types.js';
30
30
  * | `duplicate-execution` | did settled work again | once |
31
31
  * | `unsupported-claim` | stated something the record does not support | grounding |
32
32
  * | `empty-lookup` | the run produced this value, and the lookup for it found nothing | join |
33
+ * | `column-type-mismatch` | a column holds something other than the type its tool declared | type |
34
+ * | `missing-column` | a column the tool declared is in none of its rows | presence |
33
35
  *
34
36
  * `empty-lookup` is the one class that is ADVISORY BY CONSTRUCTION (9.77.0) —
35
37
  * every finding it files carries `advisory: true`, because an empty result
@@ -38,8 +40,18 @@ import type { IntegritySeam } from '../disposition/types.js';
38
40
  * defect that was proven. It is deliberately NOT `dangling-reference`, whose
39
41
  * meaning is the opposite: there the ground has left reach, here the ground
40
42
  * is in reach and the lookup came back with nothing.
43
+ *
44
+ * `column-type-mismatch` and `missing-column` (9.78.0) are two classes rather
45
+ * than one ON PURPOSE, and the field failure they come from is the argument:
46
+ * a LUN of 0 stored as `''` and a LUN column that was never delivered send a
47
+ * person to two different files, and a checker that said only "something is
48
+ * off with logical_unit_number" would have helped with neither. Unlike
49
+ * `empty-lookup`, neither is advisory: a column declared `number` that holds
50
+ * a string is not a place to look, it is a broken promise — though what the
51
+ * check can see about it is bounded, and the bound ships as
52
+ * `COLUMN_TYPE_CEILING` in every message.
41
53
  */
42
- export type ContextErrorKind = 'invariant-violation' | 'unsupported-argument' | 'dangling-reference' | 'duplicate-execution' | 'unsupported-claim' | 'empty-lookup';
54
+ export type ContextErrorKind = 'invariant-violation' | 'unsupported-argument' | 'dangling-reference' | 'duplicate-execution' | 'unsupported-claim' | 'empty-lookup' | 'column-type-mismatch' | 'missing-column';
43
55
  /** One detected context error — a labelled instance, automatically. */
44
56
  export interface ContextError {
45
57
  readonly kind: ContextErrorKind;
@@ -1 +1 @@
1
- {"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../../src/integrity/finding/types.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;GAkBG;AAEH,OAAO,KAAK,EAAE,SAAS,EAAE,UAAU,EAAE,MAAM,uBAAuB,CAAC;AACnE,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,yBAAyB,CAAC;AAE7D;;;;;;;;;;;;;;;;;;;GA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B,GACxB,qBAAqB,GACrB,sBAAsB,GACtB,oBAAoB,GACpB,qBAAqB,GACrB,mBAAmB,GACnB,cAAc,GACd,sBAAsB,GACtB,gBAAgB,CAAC;AAErB,uEAAuE;AACvE,MAAM,WAAW,YAAY;IAC3B,QAAQ,CAAC,IAAI,EAAE,gBAAgB,CAAC;IAChC,QAAQ,CAAC,IAAI,EAAE,aAAa,CAAC;IAC7B,0CAA0C;IAC1C,QAAQ,CAAC,QAAQ,EAAE,SAAS,UAAU,EAAE,CAAC;IACzC,qEAAqE;IACrE,QAAQ,CAAC,SAAS,EAAE,SAAS,SAAS,EAAE,CAAC;IACzC;;;;;;;;;;;;;OAaG;IACH,QAAQ,CAAC,SAAS,CAAC,EAAE,MAAM,CAAC;IAC5B,0EAA0E;IAC1E,QAAQ,CAAC,KAAK,CAAC,EAAE,MAAM,CAAC;IACxB,0EAA0E;IAC1E,QAAQ,CAAC,SAAS,CAAC,EAAE,IAAI,CAAC;IAC1B;;;;;;;;;OASG;IACH,QAAQ,CAAC,QAAQ,CAAC,EAAE,IAAI,CAAC;IACzB,kGAAkG;IAClG,QAAQ,CAAC,OAAO,EAAE,MAAM,CAAC;CAC1B;AAED;;;;;GAKG;AACH,wBAAgB,oBAAoB,CAAC,CAAC,EAAE,YAAY,GAAG,MAAM,CAW5D;AAED,8DAA8D;AAC9D,wBAAgB,mBAAmB,CAAC,MAAM,EAAE,SAAS,YAAY,EAAE,GAAG,SAAS,YAAY,EAAE,CAU5F"}
@@ -28,7 +28,7 @@
28
28
  *
29
29
  * ── What may travel, and the bar ────────────────────────────────────────
30
30
  * **A declaration a consumer-side check or rail reads; nothing that governs
31
- * execution.** The five fields below pass it. `needs` (credentials), `checkIn`
31
+ * execution.** Every field below passes it. `needs` (credentials), `checkIn`
32
32
  * (human consent) and the session hooks do NOT and never will: they govern how
33
33
  * a tool RUNS, and the tool runs on the server. Sending them would tell a
34
34
  * client to hold a gate that the only executor of the tool has already held,
@@ -49,7 +49,7 @@
49
49
  * That is the honest outcome: the rail it would have armed stays unarmed, and
50
50
  * the developer is told which rail and why.
51
51
  */
52
- import { type Tool, type ToolOwner, type ToolResultCeiling } from '../../core/tools.js';
52
+ import { type Tool, type ToolOwner, type ToolResultCeiling, type ToolResultColumns } from '../../core/tools.js';
53
53
  import type { ToolResultClass } from '../semantics/types.js';
54
54
  /**
55
55
  * The single `_meta` key every agentfootprint declaration travels under.
@@ -79,6 +79,21 @@ export interface McpToolExtras {
79
79
  /** The artifact kind a PLACED result is minted under — see
80
80
  * {@link Tool.resultKind}. What makes a placed result spendable by `wants`. */
81
81
  readonly resultKind?: string;
82
+ /**
83
+ * What this tool's ROWS contain (9.78.0) — see {@link Tool.resultColumns}.
84
+ * Arms the write seam's `column-type-mismatch` and `missing-column` checks.
85
+ *
86
+ * It clears the bar this file states, and by the widest margin of the eight.
87
+ * It is a flat, inert fact about the RESULT that a consumer-side check
88
+ * reads; it governs nothing about how the tool runs, and the tool runs on
89
+ * the server. It is also the field case for carrying declarations at all: a
90
+ * remote catalogue of rowset tools is exactly where a numeric column
91
+ * arriving as text goes unnoticed, because the consumer holding the chart
92
+ * has no way to know what the producer meant. Leaving it behind would arm
93
+ * the check for local tools and leave every MCP tool a second-class citizen
94
+ * of it — the whole defect `toolExtras` was built to end.
95
+ */
96
+ readonly resultColumns?: ToolResultColumns;
82
97
  /** The identity edge integrity checks join on — see {@link Tool.owner}. */
83
98
  readonly owner?: ToolOwner;
84
99
  /** The declared class of this tool's results — see {@link Tool.resultClass}. */
@@ -1 +1 @@
1
- {"version":3,"file":"toolExtras.d.ts","sourceRoot":"","sources":["../../../../src/lib/mcp/toolExtras.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAkDG;AAEH,OAAO,EAQL,KAAK,IAAI,EACT,KAAK,SAAS,EACd,KAAK,iBAAiB,EACvB,MAAM,qBAAqB,CAAC;AAC7B,OAAO,KAAK,EAAE,eAAe,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BAAwB,IAAI,IAAI,CAE/C"}
@@ -1 +1 @@
1
- {"version":3,"file":"traceToolpack.d.ts","sourceRoot":"","sources":["../../../../src/lib/trace-toolpack/traceToolpack.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAkCG;AASH,OAAO,EAAc,KAAK,IAAI,EAA6B,MAAM,qBAAqB,CAAC;AAcvF,OAAO,EAIL,KAAK,sBAAsB,EAC3B,KAAK,oBAAoB,EAC1B,MAAM,YAAY,CAAC;AAuQpB;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA4BG;AACH,wBAAgB,aAAa,CAC3B,SAAS,EAAE,sBAAsB,EACjC,OAAO,CAAC,EAAE,oBAAoB,GAC7B,IAAI,EAAE,CA0BR;AAED;;;;;;;GAOG;AACH,eAAO,MAAM,gBAAgB,kMAYnB,CAAC;AAspEX;;;;;GAKG;AACH,wBAAsB,aAAa,CACjC,KAAK,EAAE,SAAS,IAAI,EAAE,EACtB,IAAI,EAAE,MAAM,EACZ,IAAI,GAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAM,GACjC,OAAO,CAAC,MAAM,CAAC,CASjB"}
1
+ {"version":3,"file":"traceToolpack.d.ts","sourceRoot":"","sources":["../../../../src/lib/trace-toolpack/traceToolpack.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAkCG;AASH,OAAO,EAAc,KAAK,IAAI,EAA6B,MAAM,qBAAqB,CAAC;AAcvF,OAAO,EAIL,KAAK,sBAAsB,EAC3B,KAAK,oBAAoB,EAC1B,MAAM,YAAY,CAAC;AAuQpB;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA4BG;AACH,wBAAgB,aAAa,CAC3B,SAAS,EAAE,sBAAsB,EACjC,OAAO,CAAC,EAAE,oBAAoB,GAC7B,IAAI,EAAE,CA0BR;AAED;;;;;;;GAOG;AACH,eAAO,MAAM,gBAAgB,kMAYnB,CAAC;AAwpEX;;;;;GAKG;AACH,wBAAsB,aAAa,CACjC,KAAK,EAAE,SAAS,IAAI,EAAE,EACtB,IAAI,EAAE,MAAM,EACZ,IAAI,GAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAM,GACjC,OAAO,CAAC,MAAM,CAAC,CASjB"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "agentfootprint",
3
- "version": "9.77.0",
3
+ "version": "9.78.0",
4
4
  "description": "The explainable agent framework — backtrack a wrong answer to the exact context that caused it (evidence, not guesses). Built on footprintjs.",
5
5
  "license": "MIT",
6
6
  "type": "commonjs",