agentfootprint 9.85.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.
- package/CHANGELOG.md +376 -24
- package/dist/core/Agent.js +15 -4
- package/dist/core/Agent.js.map +1 -1
- package/dist/core/agent/AgentBuilder.js.map +1 -1
- package/dist/core/agent/buildAgentChart.js +5 -0
- package/dist/core/agent/buildAgentChart.js.map +1 -1
- package/dist/core/agent/buildDynamicAgentChart.js +22 -4
- package/dist/core/agent/buildDynamicAgentChart.js.map +1 -1
- package/dist/core/agent/buildToolRegistry.js +12 -1
- package/dist/core/agent/buildToolRegistry.js.map +1 -1
- package/dist/core/agent/selfCallNotice.js +20 -7
- package/dist/core/agent/selfCallNotice.js.map +1 -1
- package/dist/core/agent/skillBrains.js +3 -2
- package/dist/core/agent/skillBrains.js.map +1 -1
- package/dist/core/agent/stages/stepNudge.js +13 -4
- package/dist/core/agent/stages/stepNudge.js.map +1 -1
- package/dist/core/agent/stages/toolCalls.js +389 -58
- package/dist/core/agent/stages/toolCalls.js.map +1 -1
- package/dist/core/agent/stages/wrapUp.js +43 -6
- package/dist/core/agent/stages/wrapUp.js.map +1 -1
- package/dist/core/agent/window/currentRequest.js +4 -2
- package/dist/core/agent/window/currentRequest.js.map +1 -1
- package/dist/core/slots/buildToolsSlot.js +20 -4
- package/dist/core/slots/buildToolsSlot.js.map +1 -1
- package/dist/doors/skill-graph.js +4 -1
- package/dist/doors/skill-graph.js.map +1 -1
- package/dist/esm/core/Agent.js +15 -4
- package/dist/esm/core/Agent.js.map +1 -1
- package/dist/esm/core/agent/AgentBuilder.d.ts +2 -1
- package/dist/esm/core/agent/AgentBuilder.js.map +1 -1
- package/dist/esm/core/agent/buildAgentChart.js +5 -0
- package/dist/esm/core/agent/buildAgentChart.js.map +1 -1
- package/dist/esm/core/agent/buildDynamicAgentChart.js +22 -4
- package/dist/esm/core/agent/buildDynamicAgentChart.js.map +1 -1
- package/dist/esm/core/agent/buildToolRegistry.d.ts +20 -0
- package/dist/esm/core/agent/buildToolRegistry.js +12 -1
- package/dist/esm/core/agent/buildToolRegistry.js.map +1 -1
- package/dist/esm/core/agent/selfCallNotice.d.ts +20 -7
- package/dist/esm/core/agent/selfCallNotice.js +20 -7
- package/dist/esm/core/agent/selfCallNotice.js.map +1 -1
- package/dist/esm/core/agent/skillBrains.d.ts +12 -4
- package/dist/esm/core/agent/skillBrains.js +3 -2
- package/dist/esm/core/agent/skillBrains.js.map +1 -1
- package/dist/esm/core/agent/stages/stepNudge.d.ts +13 -4
- package/dist/esm/core/agent/stages/stepNudge.js +13 -4
- package/dist/esm/core/agent/stages/stepNudge.js.map +1 -1
- package/dist/esm/core/agent/stages/toolCalls.d.ts +171 -0
- package/dist/esm/core/agent/stages/toolCalls.js +385 -57
- package/dist/esm/core/agent/stages/toolCalls.js.map +1 -1
- package/dist/esm/core/agent/stages/wrapUp.d.ts +33 -2
- package/dist/esm/core/agent/stages/wrapUp.js +41 -5
- package/dist/esm/core/agent/stages/wrapUp.js.map +1 -1
- package/dist/esm/core/agent/types.d.ts +21 -4
- package/dist/esm/core/agent/window/currentRequest.d.ts +4 -2
- package/dist/esm/core/agent/window/currentRequest.js +4 -2
- package/dist/esm/core/agent/window/currentRequest.js.map +1 -1
- package/dist/esm/core/slots/buildToolsSlot.d.ts +1 -1
- package/dist/esm/core/slots/buildToolsSlot.js +20 -4
- package/dist/esm/core/slots/buildToolsSlot.js.map +1 -1
- package/dist/esm/doors/skill-graph.d.ts +1 -1
- package/dist/esm/doors/skill-graph.js +4 -1
- package/dist/esm/doors/skill-graph.js.map +1 -1
- package/dist/esm/events/payloads.d.ts +26 -2
- package/dist/esm/index.js +6 -5
- package/dist/esm/index.js.map +1 -1
- package/dist/esm/lib/injection-engine/index.d.ts +1 -1
- package/dist/esm/lib/injection-engine/index.js +4 -1
- package/dist/esm/lib/injection-engine/index.js.map +1 -1
- package/dist/esm/lib/injection-engine/skillGraph.d.ts +56 -0
- package/dist/esm/lib/injection-engine/skillGraph.js +29 -3
- package/dist/esm/lib/injection-engine/skillGraph.js.map +1 -1
- package/dist/esm/lib/injection-engine/skillSteps.d.ts +20 -1
- package/dist/esm/lib/injection-engine/skillSteps.js +24 -3
- package/dist/esm/lib/injection-engine/skillSteps.js.map +1 -1
- package/dist/esm/lib/injection-engine/skillToolDescriptors.d.ts +18 -0
- package/dist/esm/lib/injection-engine/skillToolDescriptors.js +103 -10
- package/dist/esm/lib/injection-engine/skillToolDescriptors.js.map +1 -1
- package/dist/esm/lib/injection-engine/types.d.ts +12 -10
- package/dist/esm/lib/injection-engine/types.js +5 -4
- package/dist/esm/lib/injection-engine/types.js.map +1 -1
- package/dist/esm/lib/saidByPerson.d.ts +48 -15
- package/dist/esm/lib/saidByPerson.js +52 -17
- package/dist/esm/lib/saidByPerson.js.map +1 -1
- package/dist/esm/lib/spokenIds.d.ts +52 -0
- package/dist/esm/lib/spokenIds.js +11 -0
- package/dist/esm/lib/spokenIds.js.map +1 -0
- package/dist/esm/lib/trace-toolpack/traceToolpack.js +12 -5
- package/dist/esm/lib/trace-toolpack/traceToolpack.js.map +1 -1
- package/dist/index.js +6 -5
- package/dist/index.js.map +1 -1
- package/dist/lib/injection-engine/index.js +5 -2
- package/dist/lib/injection-engine/index.js.map +1 -1
- package/dist/lib/injection-engine/skillGraph.js +31 -4
- package/dist/lib/injection-engine/skillGraph.js.map +1 -1
- package/dist/lib/injection-engine/skillSteps.js +24 -3
- package/dist/lib/injection-engine/skillSteps.js.map +1 -1
- package/dist/lib/injection-engine/skillToolDescriptors.js +103 -10
- package/dist/lib/injection-engine/skillToolDescriptors.js.map +1 -1
- package/dist/lib/injection-engine/types.js +5 -4
- package/dist/lib/injection-engine/types.js.map +1 -1
- package/dist/lib/saidByPerson.js +53 -18
- package/dist/lib/saidByPerson.js.map +1 -1
- package/dist/lib/spokenIds.js +15 -0
- package/dist/lib/spokenIds.js.map +1 -0
- package/dist/lib/trace-toolpack/traceToolpack.js +12 -5
- package/dist/lib/trace-toolpack/traceToolpack.js.map +1 -1
- package/dist/types/core/Agent.d.ts.map +1 -1
- package/dist/types/core/agent/AgentBuilder.d.ts +2 -1
- package/dist/types/core/agent/AgentBuilder.d.ts.map +1 -1
- package/dist/types/core/agent/buildAgentChart.d.ts.map +1 -1
- package/dist/types/core/agent/buildDynamicAgentChart.d.ts.map +1 -1
- package/dist/types/core/agent/buildToolRegistry.d.ts +20 -0
- package/dist/types/core/agent/buildToolRegistry.d.ts.map +1 -1
- package/dist/types/core/agent/selfCallNotice.d.ts +20 -7
- package/dist/types/core/agent/selfCallNotice.d.ts.map +1 -1
- package/dist/types/core/agent/skillBrains.d.ts +12 -4
- package/dist/types/core/agent/skillBrains.d.ts.map +1 -1
- package/dist/types/core/agent/stages/stepNudge.d.ts +13 -4
- package/dist/types/core/agent/stages/stepNudge.d.ts.map +1 -1
- package/dist/types/core/agent/stages/toolCalls.d.ts +171 -0
- package/dist/types/core/agent/stages/toolCalls.d.ts.map +1 -1
- package/dist/types/core/agent/stages/wrapUp.d.ts +33 -2
- package/dist/types/core/agent/stages/wrapUp.d.ts.map +1 -1
- package/dist/types/core/agent/types.d.ts +21 -4
- package/dist/types/core/agent/types.d.ts.map +1 -1
- package/dist/types/core/agent/window/currentRequest.d.ts +4 -2
- package/dist/types/core/agent/window/currentRequest.d.ts.map +1 -1
- package/dist/types/core/slots/buildToolsSlot.d.ts +1 -1
- package/dist/types/core/slots/buildToolsSlot.d.ts.map +1 -1
- package/dist/types/doors/skill-graph.d.ts +1 -1
- package/dist/types/doors/skill-graph.d.ts.map +1 -1
- package/dist/types/events/payloads.d.ts +26 -2
- package/dist/types/events/payloads.d.ts.map +1 -1
- package/dist/types/index.d.ts.map +1 -1
- package/dist/types/lib/injection-engine/index.d.ts +1 -1
- package/dist/types/lib/injection-engine/index.d.ts.map +1 -1
- package/dist/types/lib/injection-engine/skillGraph.d.ts +56 -0
- package/dist/types/lib/injection-engine/skillGraph.d.ts.map +1 -1
- package/dist/types/lib/injection-engine/skillSteps.d.ts +20 -1
- package/dist/types/lib/injection-engine/skillSteps.d.ts.map +1 -1
- package/dist/types/lib/injection-engine/skillToolDescriptors.d.ts +18 -0
- package/dist/types/lib/injection-engine/skillToolDescriptors.d.ts.map +1 -1
- package/dist/types/lib/injection-engine/types.d.ts +12 -10
- package/dist/types/lib/injection-engine/types.d.ts.map +1 -1
- package/dist/types/lib/saidByPerson.d.ts +48 -15
- package/dist/types/lib/saidByPerson.d.ts.map +1 -1
- package/dist/types/lib/spokenIds.d.ts +53 -0
- package/dist/types/lib/spokenIds.d.ts.map +1 -0
- package/dist/types/lib/trace-toolpack/traceToolpack.d.ts.map +1 -1
- package/package.json +1 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"skillSteps.d.ts","sourceRoot":"","sources":["../../../../src/lib/injection-engine/skillSteps.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAuCG;
|
|
1
|
+
{"version":3,"file":"skillSteps.d.ts","sourceRoot":"","sources":["../../../../src/lib/injection-engine/skillSteps.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAuCG;AAGH,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,mBAAmB,CAAC;AAE7D,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,YAAY,CAAC;AAI5C,wCAAwC;AACxC,MAAM,WAAW,SAAS;IACxB;;iDAE6C;IAC7C,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAC;IACtB;;oEAEgE;IAChE,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAC;IACtB;;;;;;OAMG;IACH,QAAQ,CAAC,QAAQ,CAAC,EAAE,SAAS,MAAM,EAAE,CAAC;IACtC;;;;;;OAMG;IACH,QAAQ,CAAC,QAAQ,CAAC,EAAE,SAAS,MAAM,EAAE,CAAC;CACvC;AAED;;;;;;;GAOG;AAC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AAM,CAU3E;AAED,yEAAyE;AACzE,wBAAgB,mBAAmB,CACjC,YAAY,EAAE,MAAM,EACpB,MAAM,EAAE,MAAM,EACd,IAAI,EAAE,WAAW,EACjB,IAAI,EAAE,QAAQ,GACb,MAAM,CAYR;AAED,sEAAsE;AACtE,wBAAgB,gBAAgB,CAAC,GAAG,EAAE,WAAW,EAAE,MAAM,EAAE,MAAM,EAAE,IAAI,EAAE,QAAQ,GAAG,MAAM,CAMzF;AAED,uEAAuE;AACvE,wBAAgB,uBAAuB,IAAI,MAAM,CAKhD;AAED,2EAA2E;AAC3E,wBAAgB,yBAAyB,IAAI,MAAM,CAKlD;AAED;;+CAE+C;AAC/C,wBAAgB,gBAAgB,CAC9B,GAAG,EAAE,WAAW,EAChB,IAAI,EAAE,QAAQ,GACb,aAAa,CAAC;IAAE,QAAQ,CAAC,KAAK,EAAE,MAAM,CAAC;IAAC,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAC;IAAC,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAA;CAAE,CAAC,CAKzF;AAED;;;;;;;;;;;;;;;;;;;GAmBG;AACH,wBAAgB,oBAAoB,CAAC,GAAG,EAAE,WAAW,EAAE,IAAI,EAAE,QAAQ,GAAG,MAAM,CAY7E"}
|
|
@@ -101,6 +101,24 @@ export interface ReadSkillOffer {
|
|
|
101
101
|
/** STAY spelled out as a first-class option (mid-conversation menus). */
|
|
102
102
|
readonly stay?: boolean;
|
|
103
103
|
};
|
|
104
|
+
/**
|
|
105
|
+
* The mounted graph is a decision `tree()` (9.86.0).
|
|
106
|
+
*
|
|
107
|
+
* A tree routes by predicate on every iteration and keeps no cursor, so
|
|
108
|
+
* `reachableSkills()` is empty from every position and EVERY routing pick is
|
|
109
|
+
* refused by construction. Offering `read_skill` anyway asked the model to
|
|
110
|
+
* choose from a menu the library knew it would reject — the same defect
|
|
111
|
+
* 8.5.0 fixed for the flat graph's unreachable ids, left standing for the
|
|
112
|
+
* one shape where it is total.
|
|
113
|
+
*
|
|
114
|
+
* With no open skill left after {@link ReadSkillOffer.hiddenIds}, the tool is
|
|
115
|
+
* not offered at all ({@link readSkillDescriptor} returns `undefined`); with
|
|
116
|
+
* open skills, the description says a tree has no cursor to move and names
|
|
117
|
+
* exactly the skills a pick CAN open. Either way the name stays dispatchable
|
|
118
|
+
* — position governs the offer, never dispatch — so a model that calls it
|
|
119
|
+
* from a restored transcript still reads the gate's own refusal.
|
|
120
|
+
*/
|
|
121
|
+
readonly treeRouted?: boolean;
|
|
104
122
|
}
|
|
105
123
|
/**
|
|
106
124
|
* Describe the `list_skills` tool — a no-arg tool that returns the registered
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"skillToolDescriptors.d.ts","sourceRoot":"","sources":["../../../../src/lib/injection-engine/skillToolDescriptors.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;GAsBG;AAEH,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,mBAAmB,CAAC;
|
|
1
|
+
{"version":3,"file":"skillToolDescriptors.d.ts","sourceRoot":"","sources":["../../../../src/lib/injection-engine/skillToolDescriptors.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;GAsBG;AAEH,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,mBAAmB,CAAC;AAG7D,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,YAAY,CAAC;AAE5C;;;;;;;;GAQG;AACH,MAAM,WAAW,cAAc;IAC7B;;;;OAIG;IACH,QAAQ,CAAC,SAAS,CAAC,EAAE,SAAS,MAAM,EAAE,CAAC;IACvC;;mFAE+E;IAC/E,QAAQ,CAAC,aAAa,CAAC,EAAE,OAAO,CAAC;IACjC;;;;;;;;;;;;;;;OAeG;IACH,QAAQ,CAAC,SAAS,CAAC,EAAE,SAAS,MAAM,EAAE,CAAC;IACvC;;;;;;;;;;;;;;;OAeG;IACH,QAAQ,CAAC,QAAQ,CAAC,EAAE,MAAM,CAAC;IAC3B;;;;;;;;;;;;;OAaG;IACH,QAAQ,CAAC,IAAI,CAAC,EAAE;QACd,QAAQ,CAAC,UAAU,EAAE,aAAa,CAAC;YAAE,QAAQ,CAAC,EAAE,EAAE,MAAM,CAAC;YAAC,QAAQ,CAAC,SAAS,CAAC,EAAE,MAAM,CAAA;SAAE,CAAC,CAAC;QACzF,2EAA2E;QAC3E,QAAQ,CAAC,QAAQ,CAAC,EAAE,MAAM,CAAC;QAC3B,yEAAyE;QACzE,QAAQ,CAAC,IAAI,CAAC,EAAE,OAAO,CAAC;KACzB,CAAC;IACF;;;;;;;;;;;;;;;;OAgBG;IACH,QAAQ,CAAC,UAAU,CAAC,EAAE,OAAO,CAAC;CAC/B;AA4RD;;;;;;;;;GASG;AACH,wBAAgB,oBAAoB,CAClC,MAAM,EAAE,SAAS,SAAS,EAAE,GAC3B,mBAAmB,CAAC,MAAM,CAAC,MAAM,EAAE,KAAK,CAAC,EAAE,MAAM,CAAC,GAAG,SAAS,CAqBhE;AAED;;;;;;;;;;;;;;;;;GAiBG;AACH,wBAAgB,mBAAmB,CACjC,MAAM,EAAE,SAAS,SAAS,EAAE,EAC5B,KAAK,CAAC,EAAE,cAAc,GACrB,mBAAmB,CAAC;IAAE,EAAE,EAAE,MAAM,CAAA;CAAE,EAAE,MAAM,CAAC,GAAG,SAAS,CAqEzD;AAED;;;;;;;;;;GAUG;AACH,wBAAgB,2BAA2B,CAAC,EAAE,EAAE,MAAM,GAAG,MAAM,CAE9D"}
|
|
@@ -136,13 +136,14 @@ export interface InjectionContext {
|
|
|
136
136
|
* iteration's LLM call. Includes prior iterations within the same turn.
|
|
137
137
|
*
|
|
138
138
|
* **Not everything with `role: 'user'` here was said by a person.** This
|
|
139
|
-
* library writes
|
|
139
|
+
* library writes seven kinds of user-role message itself — a compaction
|
|
140
140
|
* frame, a drop notice (whose text NAMES TOOLS), a schema-check correction,
|
|
141
|
-
* an evidence-check correction (which QUOTES the model's own values),
|
|
142
|
-
*
|
|
143
|
-
*
|
|
144
|
-
*
|
|
145
|
-
*
|
|
141
|
+
* an evidence-check correction (which QUOTES the model's own values), the
|
|
142
|
+
* out-of-budget wrap-up instruction, the stepped-skill nudge (which names a
|
|
143
|
+
* skill id and every unrun step's TOOL NAME), and a message an Injection
|
|
144
|
+
* delivered — and all seven sit in this list beside the real ones. Read the
|
|
145
|
+
* person's messages with {@link saidByPerson}; a predicate that scans raw
|
|
146
|
+
* `history` for a phrase will sooner or later match our own bookkeeping.
|
|
146
147
|
*/
|
|
147
148
|
readonly history: ReadonlyArray<{
|
|
148
149
|
readonly role: ContextRole;
|
|
@@ -349,11 +350,12 @@ export declare function toolResultsOf(ctx: InjectionContext): ReadonlyArray<{
|
|
|
349
350
|
* The messages in `ctx.history` a PERSON actually wrote, in order (9.84.0).
|
|
350
351
|
* THE one reader for a predicate that judges what was said.
|
|
351
352
|
*
|
|
352
|
-
*
|
|
353
|
+
* Seven kinds of `role: 'user'` message in that list came from this library,
|
|
353
354
|
* not from anybody: a compaction frame, a drop notice, the two in-loop
|
|
354
|
-
* corrections,
|
|
355
|
-
*
|
|
356
|
-
*
|
|
355
|
+
* corrections, the out-of-budget wrap-up instruction, the stepped-skill nudge,
|
|
356
|
+
* and a message an Injection delivered. They are ours, they are in the
|
|
357
|
+
* person's voice, two of them name tools and two quote text the model or a
|
|
358
|
+
* validator produced — so a rule written as
|
|
357
359
|
*
|
|
358
360
|
* ```ts
|
|
359
361
|
* activeWhen: (ctx) => ctx.history.some((m) => m.content.includes('refund'))
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../../src/lib/injection-engine/types.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;GAiBG;AAEH,OAAO,KAAK,EAAE,WAAW,EAAE,aAAa,EAAE,MAAM,uBAAuB,CAAC;AACxE,OAAO,KAAK,EAAE,gBAAgB,EAAE,SAAS,EAAE,eAAe,EAAE,MAAM,mBAAmB,CAAC;AACtF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window's refusal engine (`currentRequest.ts`,
|
|
9
|
-
* which will not let a strategy drop the request), the
|
|
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
|
-
*
|
|
13
|
-
*
|
|
14
|
-
*
|
|
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
|
|
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,
|
|
22
|
-
*
|
|
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
|
|
36
|
-
*
|
|
37
|
-
*
|
|
38
|
-
*
|
|
39
|
-
*
|
|
40
|
-
*
|
|
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
|
|
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;
|
|
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"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "agentfootprint",
|
|
3
|
-
"version": "9.
|
|
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",
|