agentfootprint 9.84.0 → 9.86.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 (174) hide show
  1. package/CHANGELOG.md +438 -8
  2. package/dist/artifacts/present.js +21 -3
  3. package/dist/artifacts/present.js.map +1 -1
  4. package/dist/artifacts/wants.js +19 -4
  5. package/dist/artifacts/wants.js.map +1 -1
  6. package/dist/core/Agent.js +15 -4
  7. package/dist/core/Agent.js.map +1 -1
  8. package/dist/core/agent/AgentBuilder.js.map +1 -1
  9. package/dist/core/agent/buildAgentChart.js +5 -0
  10. package/dist/core/agent/buildAgentChart.js.map +1 -1
  11. package/dist/core/agent/buildDynamicAgentChart.js +22 -4
  12. package/dist/core/agent/buildDynamicAgentChart.js.map +1 -1
  13. package/dist/core/agent/buildToolRegistry.js +149 -1
  14. package/dist/core/agent/buildToolRegistry.js.map +1 -1
  15. package/dist/core/agent/selfCallNotice.js +20 -7
  16. package/dist/core/agent/selfCallNotice.js.map +1 -1
  17. package/dist/core/agent/skillBrains.js +3 -2
  18. package/dist/core/agent/skillBrains.js.map +1 -1
  19. package/dist/core/agent/stages/routeTurn.js +28 -3
  20. package/dist/core/agent/stages/routeTurn.js.map +1 -1
  21. package/dist/core/agent/stages/stepNudge.js +13 -4
  22. package/dist/core/agent/stages/stepNudge.js.map +1 -1
  23. package/dist/core/agent/stages/toolCalls.js +389 -58
  24. package/dist/core/agent/stages/toolCalls.js.map +1 -1
  25. package/dist/core/agent/stages/wrapUp.js +43 -6
  26. package/dist/core/agent/stages/wrapUp.js.map +1 -1
  27. package/dist/core/agent/window/currentRequest.js +4 -2
  28. package/dist/core/agent/window/currentRequest.js.map +1 -1
  29. package/dist/core/codeRunnerTool.js +25 -6
  30. package/dist/core/codeRunnerTool.js.map +1 -1
  31. package/dist/core/slots/buildToolsSlot.js +20 -4
  32. package/dist/core/slots/buildToolsSlot.js.map +1 -1
  33. package/dist/doors/skill-graph.js +4 -1
  34. package/dist/doors/skill-graph.js.map +1 -1
  35. package/dist/esm/artifacts/present.js +21 -3
  36. package/dist/esm/artifacts/present.js.map +1 -1
  37. package/dist/esm/artifacts/wants.js +19 -4
  38. package/dist/esm/artifacts/wants.js.map +1 -1
  39. package/dist/esm/core/Agent.js +15 -4
  40. package/dist/esm/core/Agent.js.map +1 -1
  41. package/dist/esm/core/agent/AgentBuilder.d.ts +2 -1
  42. package/dist/esm/core/agent/AgentBuilder.js.map +1 -1
  43. package/dist/esm/core/agent/buildAgentChart.js +5 -0
  44. package/dist/esm/core/agent/buildAgentChart.js.map +1 -1
  45. package/dist/esm/core/agent/buildDynamicAgentChart.js +22 -4
  46. package/dist/esm/core/agent/buildDynamicAgentChart.js.map +1 -1
  47. package/dist/esm/core/agent/buildToolRegistry.d.ts +157 -0
  48. package/dist/esm/core/agent/buildToolRegistry.js +149 -1
  49. package/dist/esm/core/agent/buildToolRegistry.js.map +1 -1
  50. package/dist/esm/core/agent/selfCallNotice.d.ts +20 -7
  51. package/dist/esm/core/agent/selfCallNotice.js +20 -7
  52. package/dist/esm/core/agent/selfCallNotice.js.map +1 -1
  53. package/dist/esm/core/agent/skillBrains.d.ts +12 -4
  54. package/dist/esm/core/agent/skillBrains.js +3 -2
  55. package/dist/esm/core/agent/skillBrains.js.map +1 -1
  56. package/dist/esm/core/agent/stages/routeTurn.js +28 -3
  57. package/dist/esm/core/agent/stages/routeTurn.js.map +1 -1
  58. package/dist/esm/core/agent/stages/stepNudge.d.ts +13 -4
  59. package/dist/esm/core/agent/stages/stepNudge.js +13 -4
  60. package/dist/esm/core/agent/stages/stepNudge.js.map +1 -1
  61. package/dist/esm/core/agent/stages/toolCalls.d.ts +171 -0
  62. package/dist/esm/core/agent/stages/toolCalls.js +385 -57
  63. package/dist/esm/core/agent/stages/toolCalls.js.map +1 -1
  64. package/dist/esm/core/agent/stages/wrapUp.d.ts +33 -2
  65. package/dist/esm/core/agent/stages/wrapUp.js +41 -5
  66. package/dist/esm/core/agent/stages/wrapUp.js.map +1 -1
  67. package/dist/esm/core/agent/types.d.ts +21 -4
  68. package/dist/esm/core/agent/window/currentRequest.d.ts +4 -2
  69. package/dist/esm/core/agent/window/currentRequest.js +4 -2
  70. package/dist/esm/core/agent/window/currentRequest.js.map +1 -1
  71. package/dist/esm/core/codeRunnerTool.js +25 -6
  72. package/dist/esm/core/codeRunnerTool.js.map +1 -1
  73. package/dist/esm/core/slots/buildToolsSlot.d.ts +1 -1
  74. package/dist/esm/core/slots/buildToolsSlot.js +20 -4
  75. package/dist/esm/core/slots/buildToolsSlot.js.map +1 -1
  76. package/dist/esm/doors/skill-graph.d.ts +1 -1
  77. package/dist/esm/doors/skill-graph.js +4 -1
  78. package/dist/esm/doors/skill-graph.js.map +1 -1
  79. package/dist/esm/events/payloads.d.ts +26 -2
  80. package/dist/esm/index.js +6 -5
  81. package/dist/esm/index.js.map +1 -1
  82. package/dist/esm/lib/injection-engine/index.d.ts +1 -1
  83. package/dist/esm/lib/injection-engine/index.js +4 -1
  84. package/dist/esm/lib/injection-engine/index.js.map +1 -1
  85. package/dist/esm/lib/injection-engine/skillGraph.d.ts +56 -0
  86. package/dist/esm/lib/injection-engine/skillGraph.js +29 -3
  87. package/dist/esm/lib/injection-engine/skillGraph.js.map +1 -1
  88. package/dist/esm/lib/injection-engine/skillSteps.d.ts +20 -1
  89. package/dist/esm/lib/injection-engine/skillSteps.js +24 -3
  90. package/dist/esm/lib/injection-engine/skillSteps.js.map +1 -1
  91. package/dist/esm/lib/injection-engine/skillToolDescriptors.d.ts +18 -0
  92. package/dist/esm/lib/injection-engine/skillToolDescriptors.js +151 -11
  93. package/dist/esm/lib/injection-engine/skillToolDescriptors.js.map +1 -1
  94. package/dist/esm/lib/injection-engine/types.d.ts +12 -10
  95. package/dist/esm/lib/injection-engine/types.js +5 -4
  96. package/dist/esm/lib/injection-engine/types.js.map +1 -1
  97. package/dist/esm/lib/saidByPerson.d.ts +48 -15
  98. package/dist/esm/lib/saidByPerson.js +52 -17
  99. package/dist/esm/lib/saidByPerson.js.map +1 -1
  100. package/dist/esm/lib/spokenIds.d.ts +52 -0
  101. package/dist/esm/lib/spokenIds.js +11 -0
  102. package/dist/esm/lib/spokenIds.js.map +1 -0
  103. package/dist/esm/lib/trace-toolpack/traceToolpack.js +12 -5
  104. package/dist/esm/lib/trace-toolpack/traceToolpack.js.map +1 -1
  105. package/dist/esm/maps/engagement/parkCard.js +7 -1
  106. package/dist/esm/maps/engagement/parkCard.js.map +1 -1
  107. package/dist/index.js +6 -5
  108. package/dist/index.js.map +1 -1
  109. package/dist/lib/injection-engine/index.js +5 -2
  110. package/dist/lib/injection-engine/index.js.map +1 -1
  111. package/dist/lib/injection-engine/skillGraph.js +31 -4
  112. package/dist/lib/injection-engine/skillGraph.js.map +1 -1
  113. package/dist/lib/injection-engine/skillSteps.js +24 -3
  114. package/dist/lib/injection-engine/skillSteps.js.map +1 -1
  115. package/dist/lib/injection-engine/skillToolDescriptors.js +151 -11
  116. package/dist/lib/injection-engine/skillToolDescriptors.js.map +1 -1
  117. package/dist/lib/injection-engine/types.js +5 -4
  118. package/dist/lib/injection-engine/types.js.map +1 -1
  119. package/dist/lib/saidByPerson.js +53 -18
  120. package/dist/lib/saidByPerson.js.map +1 -1
  121. package/dist/lib/spokenIds.js +15 -0
  122. package/dist/lib/spokenIds.js.map +1 -0
  123. package/dist/lib/trace-toolpack/traceToolpack.js +12 -5
  124. package/dist/lib/trace-toolpack/traceToolpack.js.map +1 -1
  125. package/dist/maps/engagement/parkCard.js +7 -1
  126. package/dist/maps/engagement/parkCard.js.map +1 -1
  127. package/dist/types/artifacts/present.d.ts.map +1 -1
  128. package/dist/types/artifacts/wants.d.ts.map +1 -1
  129. package/dist/types/core/Agent.d.ts.map +1 -1
  130. package/dist/types/core/agent/AgentBuilder.d.ts +2 -1
  131. package/dist/types/core/agent/AgentBuilder.d.ts.map +1 -1
  132. package/dist/types/core/agent/buildAgentChart.d.ts.map +1 -1
  133. package/dist/types/core/agent/buildDynamicAgentChart.d.ts.map +1 -1
  134. package/dist/types/core/agent/buildToolRegistry.d.ts +157 -0
  135. package/dist/types/core/agent/buildToolRegistry.d.ts.map +1 -1
  136. package/dist/types/core/agent/selfCallNotice.d.ts +20 -7
  137. package/dist/types/core/agent/selfCallNotice.d.ts.map +1 -1
  138. package/dist/types/core/agent/skillBrains.d.ts +12 -4
  139. package/dist/types/core/agent/skillBrains.d.ts.map +1 -1
  140. package/dist/types/core/agent/stages/routeTurn.d.ts.map +1 -1
  141. package/dist/types/core/agent/stages/stepNudge.d.ts +13 -4
  142. package/dist/types/core/agent/stages/stepNudge.d.ts.map +1 -1
  143. package/dist/types/core/agent/stages/toolCalls.d.ts +171 -0
  144. package/dist/types/core/agent/stages/toolCalls.d.ts.map +1 -1
  145. package/dist/types/core/agent/stages/wrapUp.d.ts +33 -2
  146. package/dist/types/core/agent/stages/wrapUp.d.ts.map +1 -1
  147. package/dist/types/core/agent/types.d.ts +21 -4
  148. package/dist/types/core/agent/types.d.ts.map +1 -1
  149. package/dist/types/core/agent/window/currentRequest.d.ts +4 -2
  150. package/dist/types/core/agent/window/currentRequest.d.ts.map +1 -1
  151. package/dist/types/core/slots/buildToolsSlot.d.ts +1 -1
  152. package/dist/types/core/slots/buildToolsSlot.d.ts.map +1 -1
  153. package/dist/types/doors/skill-graph.d.ts +1 -1
  154. package/dist/types/doors/skill-graph.d.ts.map +1 -1
  155. package/dist/types/events/payloads.d.ts +26 -2
  156. package/dist/types/events/payloads.d.ts.map +1 -1
  157. package/dist/types/index.d.ts.map +1 -1
  158. package/dist/types/lib/injection-engine/index.d.ts +1 -1
  159. package/dist/types/lib/injection-engine/index.d.ts.map +1 -1
  160. package/dist/types/lib/injection-engine/skillGraph.d.ts +56 -0
  161. package/dist/types/lib/injection-engine/skillGraph.d.ts.map +1 -1
  162. package/dist/types/lib/injection-engine/skillSteps.d.ts +20 -1
  163. package/dist/types/lib/injection-engine/skillSteps.d.ts.map +1 -1
  164. package/dist/types/lib/injection-engine/skillToolDescriptors.d.ts +18 -0
  165. package/dist/types/lib/injection-engine/skillToolDescriptors.d.ts.map +1 -1
  166. package/dist/types/lib/injection-engine/types.d.ts +12 -10
  167. package/dist/types/lib/injection-engine/types.d.ts.map +1 -1
  168. package/dist/types/lib/saidByPerson.d.ts +48 -15
  169. package/dist/types/lib/saidByPerson.d.ts.map +1 -1
  170. package/dist/types/lib/spokenIds.d.ts +53 -0
  171. package/dist/types/lib/spokenIds.d.ts.map +1 -0
  172. package/dist/types/lib/trace-toolpack/traceToolpack.d.ts.map +1 -1
  173. package/dist/types/maps/engagement/parkCard.d.ts.map +1 -1
  174. package/package.json +1 -1
@@ -6,20 +6,24 @@
6
6
  * imports, no state, no clock.
7
7
  * Role: Leaf. Several layers ask the same question and must not answer it
8
8
  * differently: the window's refusal engine (`currentRequest.ts`,
9
- * which will not let a strategy drop the request), the four authors
9
+ * which will not let a strategy drop the request), the six authors
10
10
  * of library-written user turns (`window/notice.ts`,
11
- * `window/summarize.ts`, `outputEnforcement.ts`, `evidence/gate.ts`
12
- * — they own the sentences and take the markers from here), and —
13
- * since 9.84.0 — a rule author reading `InjectionContext.history`
14
- * (`saidByPerson(ctx)`).
11
+ * `window/summarize.ts`, `outputEnforcement.ts`, `evidence/gate.ts`,
12
+ * `stages/wrapUp.ts`, and `skillSteps.ts` for the nudge
13
+ * `stages/stepNudge.ts` appends — they own the sentences and take
14
+ * the markers from here), and — since 9.84.0 — a rule author reading
15
+ * `InjectionContext.history` (`saidByPerson(ctx)`).
15
16
  * Emits: N/A.
16
17
  *
17
18
  * ## Why this is a leaf and not a private helper
18
19
  *
19
- * This library writes FIVE kinds of `role: 'user'` message that nobody said:
20
+ * This library writes SEVEN kinds of `role: 'user'` message that nobody said:
20
21
  * a compaction frame, a drop notice, a schema-check correction, an
21
- * evidence-check correction, and a message an Injection delivered. The window
22
- * layer knew two of them and the marker; the evidence layer knew the other two
22
+ * evidence-check correction, a budget wrap-up instruction, a stepped-skill
23
+ * nudge, and a message an Injection delivered. Six of the seven are read off
24
+ * the OPENING they carry ({@link LIBRARY_AUTHORED_PREFIXES}); the delivered
25
+ * one carries an `injectedBy` marker instead. The window layer knew two of the
26
+ * openings and the marker; the evidence layer knew two more
23
27
  * (`evidence/frames.ts`); neither list was reachable from the routing layer at
24
28
  * all — the skill-graph fence forbids it from importing the agent loop, and
25
29
  * rightly. So a predicate reading `history` could filter some of the classes
@@ -32,12 +36,27 @@
32
36
  * wrote. That is a fixable bug in one place only: the rule has to be one
33
37
  * implementation both sides import, not two that agree until they do not.
34
38
  *
35
- * The markers move here with it, as a LIST rather than four constants in four
36
- * files. A prefix is what the recognizer matches AND what the writer emits;
37
- * separating those is how a prefix silently stops being recognized, and a
38
- * sixth authored frame that lands anywhere else is a hole nobody will see
39
- * until a rule fires on it. Adding one means adding it to
40
- * {@link LIBRARY_AUTHORED_PREFIXES}, and every reader is fixed at once.
39
+ * The two frames added in 9.86.0 are the same bug found again, and found by
40
+ * counting rather than by reading: 9.84.0 registered four openings and wrote
41
+ * "five classes" in prose, while the tree already had SEVEN producers of a
42
+ * user-role message that reach `scope.history`. The budget wrap-up
43
+ * (`stages/wrapUp.ts`) carried an unprefixed sentence containing "Do not
44
+ * request tools", and the stepped-skill nudge (`stages/stepNudge.ts`) carries
45
+ * a skill id and every unrun step's TOOL NAME — so both were credited to a
46
+ * person, a `saidByPerson(ctx).some(m => m.content.includes(…))` rule matched
47
+ * on them, and the window could anchor its refusal on the wrap-up frame.
48
+ *
49
+ * The markers live here, as a LIST rather than one constant per writing file.
50
+ * A prefix is what the recognizer matches AND what the writer emits;
51
+ * separating those is how a prefix silently stops being recognized, and an
52
+ * authored frame that lands anywhere else is a hole nobody will see until a
53
+ * rule fires on it. Adding one means adding it to
54
+ * {@link LIBRARY_AUTHORED_PREFIXES}, and every reader is fixed at once —
55
+ * which is why the count is no longer asserted in prose alone:
56
+ * `test/lib/injection-engine/userTurnProducers.test.ts` WALKS the tree for
57
+ * every `role: 'user'` construction site and fails, with the file and line, on
58
+ * one that is neither registered here, nor a person's own turn, nor
59
+ * wire-only.
41
60
  */
42
61
  /**
43
62
  * The fields authorship is decided from — structural, so both
@@ -65,6 +84,14 @@ export declare const SCHEMA_CHECK_FRAME_PREFIX = "[schema check";
65
84
  /** Opening of the authored frame the evidence gate writes. Stable — tests,
66
85
  * docs and readers match on it. Written by `buildEvidenceCorrection`. */
67
86
  export declare const EVIDENCE_CHECK_FRAME_PREFIX = "[evidence check";
87
+ /** Opening of the authored instruction the out-of-budget WRAP-UP call carries.
88
+ * Stable — tests and readers match on it. Written by `wrapUpStage`
89
+ * (`WRAP_UP_INSTRUCTION`). */
90
+ export declare const WRAP_UP_FRAME_PREFIX = "[budget exhausted";
91
+ /** Opening of the authored frame the stepped-skill NUDGE carries. Stable —
92
+ * tests and readers match on it. Written by `nudgeTeachingMessage`, appended
93
+ * by `buildStepNudgeStage`. */
94
+ export declare const STEP_NUDGE_FRAME_PREFIX = "[steps unrun";
68
95
  /**
69
96
  * Every opening this library puts on a `role: 'user'` message it wrote itself.
70
97
  *
@@ -76,7 +103,13 @@ export declare const EVIDENCE_CHECK_FRAME_PREFIX = "[evidence check";
76
103
  *
77
104
  * The two correction frames both QUOTE untrusted text after their label (a
78
105
  * validator's error, the model's own flagged values), which is exactly why
79
- * they are matched by PREFIX and never by anything further in.
106
+ * they are matched by PREFIX and never by anything further in. The nudge is
107
+ * the same shape for a different reason: its body is a list of a skill's own
108
+ * step notes and tool names, which is exactly the text a rule watches for.
109
+ *
110
+ * The list is frozen because it is a registry, not a scratch array: a consumer
111
+ * holds the same object this library's own readers hold, and a `push` into it
112
+ * would change what every reader calls a person's message.
80
113
  */
81
114
  export declare const LIBRARY_AUTHORED_PREFIXES: readonly string[];
82
115
  /** True when this user-role message opens with a frame this library authored. */
@@ -1 +1 @@
1
- {"version":3,"file":"saidByPerson.d.ts","sourceRoot":"","sources":["../../../src/lib/saidByPerson.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAwCG;AAEH;;;;;;;;GAQG;AACH,MAAM,WAAW,eAAe;IAC9B,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAC;IACtB,QAAQ,CAAC,OAAO,EAAE,MAAM,CAAC;IACzB,QAAQ,CAAC,UAAU,CAAC,EAAE,OAAO,CAAC;CAC/B;AAED;yDACyD;AACzD,eAAO,MAAM,kBAAkB,qBAAqB,CAAC;AAErD;6DAC6D;AAC7D,eAAO,MAAM,sBAAsB,uBAAuB,CAAC;AAE3D;uEACuE;AACvE,eAAO,MAAM,yBAAyB,kBAAkB,CAAC;AAEzD;0EAC0E;AAC1E,eAAO,MAAM,2BAA2B,oBAAoB,CAAC;AAE7D;;;;;;;;;;;;GAYG;AACH,eAAO,MAAM,yBAAyB,EAAE,SAAS,MAAM,EAKtD,CAAC;AAEF,iFAAiF;AACjF,wBAAgB,sBAAsB,CAAC,GAAG,EAAE,eAAe,GAAG,SAAS,GAAG,OAAO,CAMhF;AAED,gEAAgE;AAChE,wBAAgB,YAAY,CAAC,GAAG,EAAE,eAAe,GAAG,SAAS,GAAG,OAAO,CAEtE;AAED,+DAA+D;AAC/D,wBAAgB,kBAAkB,CAAC,GAAG,EAAE,eAAe,GAAG,SAAS,GAAG,OAAO,CAE5E;AAED;;;;;;;;;;GAUG;AACH,wBAAgB,cAAc,CAAC,GAAG,EAAE,eAAe,GAAG,SAAS,GAAG,OAAO,CAOxE"}
1
+ {"version":3,"file":"saidByPerson.d.ts","sourceRoot":"","sources":["../../../src/lib/saidByPerson.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA2DG;AAEH;;;;;;;;GAQG;AACH,MAAM,WAAW,eAAe;IAC9B,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAC;IACtB,QAAQ,CAAC,OAAO,EAAE,MAAM,CAAC;IACzB,QAAQ,CAAC,UAAU,CAAC,EAAE,OAAO,CAAC;CAC/B;AAED;yDACyD;AACzD,eAAO,MAAM,kBAAkB,qBAAqB,CAAC;AAErD;6DAC6D;AAC7D,eAAO,MAAM,sBAAsB,uBAAuB,CAAC;AAE3D;uEACuE;AACvE,eAAO,MAAM,yBAAyB,kBAAkB,CAAC;AAEzD;0EAC0E;AAC1E,eAAO,MAAM,2BAA2B,oBAAoB,CAAC;AAE7D;;+BAE+B;AAC/B,eAAO,MAAM,oBAAoB,sBAAsB,CAAC;AAExD;;gCAEgC;AAChC,eAAO,MAAM,uBAAuB,iBAAiB,CAAC;AAEtD;;;;;;;;;;;;;;;;;;GAkBG;AACH,eAAO,MAAM,yBAAyB,EAAE,SAAS,MAAM,EAOrD,CAAC;AAEH,iFAAiF;AACjF,wBAAgB,sBAAsB,CAAC,GAAG,EAAE,eAAe,GAAG,SAAS,GAAG,OAAO,CAMhF;AAED,gEAAgE;AAChE,wBAAgB,YAAY,CAAC,GAAG,EAAE,eAAe,GAAG,SAAS,GAAG,OAAO,CAEtE;AAED,+DAA+D;AAC/D,wBAAgB,kBAAkB,CAAC,GAAG,EAAE,eAAe,GAAG,SAAS,GAAG,OAAO,CAE5E;AAED;;;;;;;;;;GAUG;AACH,wBAAgB,cAAc,CAAC,GAAG,EAAE,eAAe,GAAG,SAAS,GAAG,OAAO,CAOxE"}
@@ -0,0 +1,53 @@
1
+ /**
2
+ * A set a model-facing sentence is allowed to NAME, after the role filter has
3
+ * run over it (9.86.0) — and the one fact a filtered list cannot be written
4
+ * without.
5
+ *
6
+ * ── OMIT, NEVER DENY ────────────────────────────────────────────────────
7
+ *
8
+ * A narrowing may take a name off a sentence. It may not turn that name's
9
+ * absence into a claim that the thing is gone: the graph, the dispatch map and
10
+ * the menu are all still holding it, and a model told "no skill was reachable"
11
+ * stops asking for the one it may not be told about. Omission costs nothing and
12
+ * is always true; the negative sentence is a denial of what the run holds.
13
+ *
14
+ * Every composer took plain arrays and branched on `length > 0`, so "the set
15
+ * was empty" and "the filter emptied it" produced the SAME sentence — one
16
+ * shape, two facts, in three separate places. `held` is that missing fact, and
17
+ * it is REQUIRED rather than optional on purpose: the compiler now asks every
18
+ * caller the question the call sites each forgot to answer.
19
+ *
20
+ * ── WHY THIS IS A LEAF AND NOT A HELPER IN THE GATE ─────────────────────
21
+ *
22
+ * It lived in `core/agent/stages/toolCalls.ts`, which put it on the wrong side
23
+ * of the skill-graph fence: `read_skill`'s DESCRIPTION is composed inside
24
+ * `src/lib/injection-engine/`, which may not import the agent loop, so the one
25
+ * surface the model reads to CHOOSE a skill could not use the fact its own
26
+ * refusals were being repaired with — and it went on printing "Nothing is
27
+ * reachable from here" over a graph whose only hop the role filter had removed.
28
+ * The same reason `src/lib/saidByPerson.ts` is a leaf: the writer and the
29
+ * recogniser share one rule, so they cannot drift.
30
+ *
31
+ * @example
32
+ * ```ts
33
+ * const hidden = new Set(['beta']);
34
+ * const hops = spoken(['beta'], (id) => !hidden.has(id));
35
+ * // → { named: [], held: true } — the clause is DROPPED, not negated.
36
+ * ```
37
+ */
38
+ export interface SpokenIds {
39
+ /** The members this sentence may name — what survived the filter. */
40
+ readonly named: readonly string[];
41
+ /** Did the UNFILTERED set hold anything? `true` with an empty `named` is the
42
+ * filtered-to-empty case: the clause is omitted rather than negated. */
43
+ readonly held: boolean;
44
+ }
45
+ /**
46
+ * Apply the role filter to one set and keep both halves (9.86.0).
47
+ *
48
+ * `mayName` is the caller's visibility predicate — skill ids test membership of
49
+ * `scope.hiddenSkillIds`, tool names test whether every skill declaring them is
50
+ * hidden. Both questions have one answer shape, and this is it.
51
+ */
52
+ export declare function spoken(all: readonly string[], mayName: (id: string) => boolean): SpokenIds;
53
+ //# sourceMappingURL=spokenIds.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"spokenIds.d.ts","sourceRoot":"","sources":["../../../src/lib/spokenIds.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAoCG;AACH,MAAM,WAAW,SAAS;IACxB,qEAAqE;IACrE,QAAQ,CAAC,KAAK,EAAE,SAAS,MAAM,EAAE,CAAC;IAClC;6EACyE;IACzE,QAAQ,CAAC,IAAI,EAAE,OAAO,CAAC;CACxB;AAED;;;;;;GAMG;AACH,wBAAgB,MAAM,CAAC,GAAG,EAAE,SAAS,MAAM,EAAE,EAAE,OAAO,EAAE,CAAC,EAAE,EAAE,MAAM,KAAK,OAAO,GAAG,SAAS,CAE1F"}
@@ -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;AAypEX;;;;;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;AAgqEX;;;;;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 +1 @@
1
- {"version":3,"file":"parkCard.d.ts","sourceRoot":"","sources":["../../../../src/maps/engagement/parkCard.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA+BG;AAEH,OAAO,KAAK,EAAE,cAAc,EAAE,aAAa,EAAmC,MAAM,YAAY,CAAC;AAkBjG;;;;;GAKG;AACH,wBAAgB,QAAQ,CACtB,IAAI,EAAE,cAAc,EACpB,UAAU,EAAE,aAAa,GAAG,SAAS,GACpC,MAAM,GAAG,SAAS,CA8BpB;AAED;;;;;;GAMG;AACH,eAAO,MAAM,YAAY,8BAA8B,CAAC"}
1
+ {"version":3,"file":"parkCard.d.ts","sourceRoot":"","sources":["../../../../src/maps/engagement/parkCard.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA+BG;AAEH,OAAO,KAAK,EAAE,cAAc,EAAE,aAAa,EAAmC,MAAM,YAAY,CAAC;AAkBjG;;;;;GAKG;AACH,wBAAgB,QAAQ,CACtB,IAAI,EAAE,cAAc,EACpB,UAAU,EAAE,aAAa,GAAG,SAAS,GACpC,MAAM,GAAG,SAAS,CAoCpB;AAED;;;;;;GAMG;AACH,eAAO,MAAM,YAAY,8BAA8B,CAAC"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "agentfootprint",
3
- "version": "9.84.0",
3
+ "version": "9.86.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",