@animalabs/agent-framework 0.23.3 → 0.24.1
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/README.md +212 -42
- package/dist/src/agent.d.ts +65 -9
- package/dist/src/agent.d.ts.map +1 -1
- package/dist/src/agent.js +98 -12
- package/dist/src/agent.js.map +1 -1
- package/dist/src/api/server.d.ts.map +1 -1
- package/dist/src/api/server.js +14 -12
- package/dist/src/api/server.js.map +1 -1
- package/dist/src/clock-rows.d.ts +115 -0
- package/dist/src/clock-rows.d.ts.map +1 -0
- package/dist/src/clock-rows.js +222 -0
- package/dist/src/clock-rows.js.map +1 -0
- package/dist/src/code-execution/engine.d.ts +177 -0
- package/dist/src/code-execution/engine.d.ts.map +1 -0
- package/dist/src/code-execution/engine.js +494 -0
- package/dist/src/code-execution/engine.js.map +1 -0
- package/dist/src/code-execution/index.d.ts +5 -10
- package/dist/src/code-execution/index.d.ts.map +1 -1
- package/dist/src/code-execution/index.js +5 -9
- package/dist/src/code-execution/index.js.map +1 -1
- package/dist/src/code-execution/isolate/calls.d.ts +114 -0
- package/dist/src/code-execution/isolate/calls.d.ts.map +1 -0
- package/dist/src/code-execution/isolate/calls.js +145 -0
- package/dist/src/code-execution/isolate/calls.js.map +1 -0
- package/dist/src/code-execution/isolate/child-entry.d.ts +2 -0
- package/dist/src/code-execution/isolate/child-entry.d.ts.map +1 -0
- package/dist/src/code-execution/isolate/child-entry.js +5 -0
- package/dist/src/code-execution/isolate/child-entry.js.map +1 -0
- package/dist/src/code-execution/isolate/child-main.d.ts +26 -0
- package/dist/src/code-execution/isolate/child-main.d.ts.map +1 -0
- package/dist/src/code-execution/isolate/child-main.js +132 -0
- package/dist/src/code-execution/isolate/child-main.js.map +1 -0
- package/dist/src/code-execution/isolate/child.d.ts +44 -0
- package/dist/src/code-execution/isolate/child.d.ts.map +1 -0
- package/dist/src/code-execution/isolate/child.js +315 -0
- package/dist/src/code-execution/isolate/child.js.map +1 -0
- package/dist/src/code-execution/isolate/frames.d.ts +80 -0
- package/dist/src/code-execution/isolate/frames.d.ts.map +1 -0
- package/dist/src/code-execution/isolate/frames.js +210 -0
- package/dist/src/code-execution/isolate/frames.js.map +1 -0
- package/dist/src/code-execution/isolate/output.d.ts +68 -0
- package/dist/src/code-execution/isolate/output.d.ts.map +1 -0
- package/dist/src/code-execution/isolate/output.js +143 -0
- package/dist/src/code-execution/isolate/output.js.map +1 -0
- package/dist/src/code-execution/isolate/prelude.d.ts +109 -0
- package/dist/src/code-execution/isolate/prelude.d.ts.map +1 -0
- package/dist/src/code-execution/isolate/prelude.js +401 -0
- package/dist/src/code-execution/isolate/prelude.js.map +1 -0
- package/dist/src/code-execution/isolate/protocol.d.ts +151 -0
- package/dist/src/code-execution/isolate/protocol.d.ts.map +1 -0
- package/dist/src/code-execution/isolate/protocol.js +150 -0
- package/dist/src/code-execution/isolate/protocol.js.map +1 -0
- package/dist/src/code-execution/isolate/render.d.ts +57 -0
- package/dist/src/code-execution/isolate/render.d.ts.map +1 -0
- package/dist/src/code-execution/isolate/render.js +214 -0
- package/dist/src/code-execution/isolate/render.js.map +1 -0
- package/dist/src/code-execution/isolate/runner.d.ts +250 -0
- package/dist/src/code-execution/isolate/runner.d.ts.map +1 -0
- package/dist/src/code-execution/isolate/runner.js +854 -0
- package/dist/src/code-execution/isolate/runner.js.map +1 -0
- package/dist/src/code-execution/isolate/scripts.d.ts +175 -0
- package/dist/src/code-execution/isolate/scripts.d.ts.map +1 -0
- package/dist/src/code-execution/isolate/scripts.js +357 -0
- package/dist/src/code-execution/isolate/scripts.js.map +1 -0
- package/dist/src/code-execution/quickjs.wasm +0 -0
- package/dist/src/code-execution/tool-definition.d.ts +93 -43
- package/dist/src/code-execution/tool-definition.d.ts.map +1 -1
- package/dist/src/code-execution/tool-definition.js +176 -142
- package/dist/src/code-execution/tool-definition.js.map +1 -1
- package/dist/src/deadline-timer.d.ts +3 -0
- package/dist/src/deadline-timer.d.ts.map +1 -1
- package/dist/src/deadline-timer.js +1 -1
- package/dist/src/deadline-timer.js.map +1 -1
- package/dist/src/framework.d.ts +1120 -457
- package/dist/src/framework.d.ts.map +1 -1
- package/dist/src/framework.js +4635 -2505
- package/dist/src/framework.js.map +1 -1
- package/dist/src/gate/event-gate.d.ts +28 -4
- package/dist/src/gate/event-gate.d.ts.map +1 -1
- package/dist/src/gate/event-gate.js +89 -13
- package/dist/src/gate/event-gate.js.map +1 -1
- package/dist/src/held-writes.d.ts +16 -3
- package/dist/src/held-writes.d.ts.map +1 -1
- package/dist/src/held-writes.js +16 -3
- package/dist/src/held-writes.js.map +1 -1
- package/dist/src/index.d.ts +8 -6
- package/dist/src/index.d.ts.map +1 -1
- package/dist/src/index.js +10 -8
- package/dist/src/index.js.map +1 -1
- package/dist/src/mcpl/channel-registry.d.ts +483 -115
- package/dist/src/mcpl/channel-registry.d.ts.map +1 -1
- package/dist/src/mcpl/channel-registry.js +1735 -425
- package/dist/src/mcpl/channel-registry.js.map +1 -1
- package/dist/src/mcpl/conversation-router.d.ts +19 -39
- package/dist/src/mcpl/conversation-router.d.ts.map +1 -1
- package/dist/src/mcpl/conversation-router.js +27 -59
- package/dist/src/mcpl/conversation-router.js.map +1 -1
- package/dist/src/mcpl/convert-block.d.ts.map +1 -1
- package/dist/src/mcpl/convert-block.js +9 -5
- package/dist/src/mcpl/convert-block.js.map +1 -1
- package/dist/src/mcpl/inbound-source.d.ts +50 -0
- package/dist/src/mcpl/inbound-source.d.ts.map +1 -1
- package/dist/src/mcpl/inbound-source.js +130 -0
- package/dist/src/mcpl/inbound-source.js.map +1 -1
- package/dist/src/mcpl/index.d.ts +2 -1
- package/dist/src/mcpl/index.d.ts.map +1 -1
- package/dist/src/mcpl/index.js +3 -2
- package/dist/src/mcpl/index.js.map +1 -1
- package/dist/src/mcpl/log-value.d.ts +6 -0
- package/dist/src/mcpl/log-value.d.ts.map +1 -1
- package/dist/src/mcpl/log-value.js +8 -0
- package/dist/src/mcpl/log-value.js.map +1 -1
- package/dist/src/mcpl/modern-connection.d.ts +15 -6
- package/dist/src/mcpl/modern-connection.d.ts.map +1 -1
- package/dist/src/mcpl/modern-connection.js +168 -53
- package/dist/src/mcpl/modern-connection.js.map +1 -1
- package/dist/src/mcpl/prose-grammar.d.ts +4 -5
- package/dist/src/mcpl/prose-grammar.d.ts.map +1 -1
- package/dist/src/mcpl/prose-grammar.js +4 -5
- package/dist/src/mcpl/prose-grammar.js.map +1 -1
- package/dist/src/mcpl/protocol-family.d.ts +97 -10
- package/dist/src/mcpl/protocol-family.d.ts.map +1 -1
- package/dist/src/mcpl/protocol-family.js +174 -17
- package/dist/src/mcpl/protocol-family.js.map +1 -1
- package/dist/src/mcpl/push-coalescer.d.ts +132 -14
- package/dist/src/mcpl/push-coalescer.d.ts.map +1 -1
- package/dist/src/mcpl/push-coalescer.js +227 -50
- package/dist/src/mcpl/push-coalescer.js.map +1 -1
- package/dist/src/mcpl/push-handler.d.ts +9 -20
- package/dist/src/mcpl/push-handler.d.ts.map +1 -1
- package/dist/src/mcpl/push-handler.js +7 -49
- package/dist/src/mcpl/push-handler.js.map +1 -1
- package/dist/src/mcpl/reference-fetcher.d.ts +2 -2
- package/dist/src/mcpl/reference-fetcher.d.ts.map +1 -1
- package/dist/src/mcpl/reference-fetcher.js +4 -4
- package/dist/src/mcpl/reference-fetcher.js.map +1 -1
- package/dist/src/mcpl/server-connection.d.ts +50 -21
- package/dist/src/mcpl/server-connection.d.ts.map +1 -1
- package/dist/src/mcpl/server-connection.js +158 -74
- package/dist/src/mcpl/server-connection.js.map +1 -1
- package/dist/src/mcpl/tags.d.ts +24 -0
- package/dist/src/mcpl/tags.d.ts.map +1 -1
- package/dist/src/mcpl/tags.js +33 -0
- package/dist/src/mcpl/tags.js.map +1 -1
- package/dist/src/mcpl/tool-result-normalize.d.ts +2 -1
- package/dist/src/mcpl/tool-result-normalize.d.ts.map +1 -1
- package/dist/src/mcpl/tool-result-normalize.js.map +1 -1
- package/dist/src/mcpl/transport.d.ts +55 -7
- package/dist/src/mcpl/transport.d.ts.map +1 -1
- package/dist/src/mcpl/transport.js +163 -34
- package/dist/src/mcpl/transport.js.map +1 -1
- package/dist/src/mcpl/types.d.ts +22 -6
- package/dist/src/mcpl/types.d.ts.map +1 -1
- package/dist/src/mcpl/types.js.map +1 -1
- package/dist/src/module-registry.d.ts +4 -2
- package/dist/src/module-registry.d.ts.map +1 -1
- package/dist/src/module-registry.js +100 -13
- package/dist/src/module-registry.js.map +1 -1
- package/dist/src/modules/discord/index.d.ts.map +1 -1
- package/dist/src/modules/discord/index.js +8 -13
- package/dist/src/modules/discord/index.js.map +1 -1
- package/dist/src/modules/history/index.d.ts.map +1 -1
- package/dist/src/modules/history/index.js +27 -4
- package/dist/src/modules/history/index.js.map +1 -1
- package/dist/src/modules/history/semantic.d.ts +15 -3
- package/dist/src/modules/history/semantic.d.ts.map +1 -1
- package/dist/src/modules/history/semantic.js +27 -5
- package/dist/src/modules/history/semantic.js.map +1 -1
- package/dist/src/modules/index.d.ts +1 -1
- package/dist/src/modules/index.d.ts.map +1 -1
- package/dist/src/modules/index.js.map +1 -1
- package/dist/src/modules/unknown-tool.d.ts +4 -1
- package/dist/src/modules/unknown-tool.d.ts.map +1 -1
- package/dist/src/modules/unknown-tool.js +4 -1
- package/dist/src/modules/unknown-tool.js.map +1 -1
- package/dist/src/modules/workspace/branch-intent.d.ts +3 -1
- package/dist/src/modules/workspace/branch-intent.d.ts.map +1 -1
- package/dist/src/modules/workspace/branch-intent.js +3 -1
- package/dist/src/modules/workspace/branch-intent.js.map +1 -1
- package/dist/src/modules/workspace/edit-plan.d.ts +265 -0
- package/dist/src/modules/workspace/edit-plan.d.ts.map +1 -0
- package/dist/src/modules/workspace/edit-plan.js +794 -0
- package/dist/src/modules/workspace/edit-plan.js.map +1 -0
- package/dist/src/modules/workspace/edit-text.d.ts +117 -0
- package/dist/src/modules/workspace/edit-text.d.ts.map +1 -0
- package/dist/src/modules/workspace/edit-text.js +584 -0
- package/dist/src/modules/workspace/edit-text.js.map +1 -0
- package/dist/src/modules/workspace/effects.d.ts +5 -4
- package/dist/src/modules/workspace/effects.d.ts.map +1 -1
- package/dist/src/modules/workspace/effects.js +78 -25
- package/dist/src/modules/workspace/effects.js.map +1 -1
- package/dist/src/modules/workspace/index.d.ts +493 -62
- package/dist/src/modules/workspace/index.d.ts.map +1 -1
- package/dist/src/modules/workspace/index.js +2216 -652
- package/dist/src/modules/workspace/index.js.map +1 -1
- package/dist/src/modules/workspace/observe.d.ts +213 -38
- package/dist/src/modules/workspace/observe.d.ts.map +1 -1
- package/dist/src/modules/workspace/observe.js +416 -36
- package/dist/src/modules/workspace/observe.js.map +1 -1
- package/dist/src/modules/workspace/reconcile.d.ts.map +1 -1
- package/dist/src/modules/workspace/reconcile.js +15 -8
- package/dist/src/modules/workspace/reconcile.js.map +1 -1
- package/dist/src/modules/workspace/text.d.ts +32 -0
- package/dist/src/modules/workspace/text.d.ts.map +1 -0
- package/dist/src/modules/workspace/text.js +67 -0
- package/dist/src/modules/workspace/text.js.map +1 -0
- package/dist/src/modules/workspace/types.d.ts +210 -6
- package/dist/src/modules/workspace/types.d.ts.map +1 -1
- package/dist/src/modules/workspace/types.js.map +1 -1
- package/dist/src/modules/workspace/watcher.d.ts +3 -2
- package/dist/src/modules/workspace/watcher.d.ts.map +1 -1
- package/dist/src/modules/workspace/watcher.js.map +1 -1
- package/dist/src/operator-log.d.ts +52 -24
- package/dist/src/operator-log.d.ts.map +1 -1
- package/dist/src/operator-log.js.map +1 -1
- package/dist/src/recovery/discord-awareness-outbox.d.ts +496 -72
- package/dist/src/recovery/discord-awareness-outbox.d.ts.map +1 -1
- package/dist/src/recovery/discord-awareness-outbox.js +1196 -289
- package/dist/src/recovery/discord-awareness-outbox.js.map +1 -1
- package/dist/src/recovery/offline-branch.d.ts +26 -1
- package/dist/src/recovery/offline-branch.d.ts.map +1 -1
- package/dist/src/recovery/offline-branch.js +164 -39
- package/dist/src/recovery/offline-branch.js.map +1 -1
- package/dist/src/recovery/recover-cli.js +23 -4
- package/dist/src/recovery/recover-cli.js.map +1 -1
- package/dist/src/send-tools.d.ts +11 -0
- package/dist/src/send-tools.d.ts.map +1 -0
- package/dist/src/send-tools.js +11 -0
- package/dist/src/send-tools.js.map +1 -0
- package/dist/src/timezone.d.ts +4 -2
- package/dist/src/timezone.d.ts.map +1 -1
- package/dist/src/timezone.js +4 -2
- package/dist/src/timezone.js.map +1 -1
- package/dist/src/tool-image-ledger.d.ts +46 -7
- package/dist/src/tool-image-ledger.d.ts.map +1 -1
- package/dist/src/tool-image-ledger.js +60 -7
- package/dist/src/tool-image-ledger.js.map +1 -1
- package/dist/src/tool-result-guard.d.ts +14 -11
- package/dist/src/tool-result-guard.d.ts.map +1 -1
- package/dist/src/tool-result-guard.js +17 -14
- package/dist/src/tool-result-guard.js.map +1 -1
- package/dist/src/tool-result-history.d.ts +3 -2
- package/dist/src/tool-result-history.d.ts.map +1 -1
- package/dist/src/tool-result-history.js +3 -2
- package/dist/src/tool-result-history.js.map +1 -1
- package/dist/src/tune-out/coordinator.d.ts +21 -0
- package/dist/src/tune-out/coordinator.d.ts.map +1 -1
- package/dist/src/tune-out/coordinator.js +142 -40
- package/dist/src/tune-out/coordinator.js.map +1 -1
- package/dist/src/types/agent.d.ts +31 -6
- package/dist/src/types/agent.d.ts.map +1 -1
- package/dist/src/types/events.d.ts +66 -9
- package/dist/src/types/events.d.ts.map +1 -1
- package/dist/src/types/framework.d.ts +69 -62
- package/dist/src/types/framework.d.ts.map +1 -1
- package/dist/src/types/module.d.ts +40 -8
- package/dist/src/types/module.d.ts.map +1 -1
- package/dist/src/types/trace.d.ts +111 -10
- package/dist/src/types/trace.d.ts.map +1 -1
- package/dist/src/usage/types.d.ts +16 -0
- package/dist/src/usage/types.d.ts.map +1 -1
- package/dist/src/usage/usage-tracker.d.ts +14 -1
- package/dist/src/usage/usage-tracker.d.ts.map +1 -1
- package/dist/src/usage/usage-tracker.js +81 -41
- package/dist/src/usage/usage-tracker.js.map +1 -1
- package/package.json +6 -8
- package/src/agent.ts +99 -12
- package/src/api/server.ts +14 -12
- package/src/clock-rows.ts +302 -0
- package/src/code-execution/engine.ts +595 -0
- package/src/code-execution/index.ts +5 -17
- package/src/code-execution/isolate/calls.ts +199 -0
- package/src/code-execution/isolate/child-entry.ts +5 -0
- package/src/code-execution/isolate/child-main.ts +132 -0
- package/src/code-execution/isolate/child.ts +327 -0
- package/src/code-execution/isolate/frames.ts +209 -0
- package/src/code-execution/isolate/output.ts +161 -0
- package/src/code-execution/isolate/prelude.ts +409 -0
- package/src/code-execution/isolate/protocol.ts +240 -0
- package/src/code-execution/isolate/render.ts +230 -0
- package/src/code-execution/isolate/runner.ts +911 -0
- package/src/code-execution/isolate/scripts.ts +479 -0
- package/src/code-execution/quickjs.wasm +0 -0
- package/src/code-execution/quickjs.wasm.LICENSES +149 -0
- package/src/code-execution/tool-definition.ts +236 -167
- package/src/deadline-timer.ts +1 -1
- package/src/framework.ts +4978 -2671
- package/src/gate/event-gate.ts +79 -17
- package/src/held-writes.ts +17 -3
- package/src/index.ts +32 -22
- package/src/mcpl/channel-registry.ts +1892 -471
- package/src/mcpl/conversation-router.ts +26 -72
- package/src/mcpl/convert-block.ts +9 -5
- package/src/mcpl/inbound-source.ts +131 -0
- package/src/mcpl/index.ts +4 -2
- package/src/mcpl/log-value.ts +9 -0
- package/src/mcpl/modern-connection.ts +162 -53
- package/src/mcpl/prose-grammar.ts +4 -5
- package/src/mcpl/protocol-family.ts +200 -22
- package/src/mcpl/push-coalescer.ts +306 -62
- package/src/mcpl/push-handler.ts +12 -54
- package/src/mcpl/reference-fetcher.ts +4 -4
- package/src/mcpl/server-connection.ts +180 -79
- package/src/mcpl/tags.ts +36 -0
- package/src/mcpl/tool-result-normalize.ts +2 -1
- package/src/mcpl/transport.ts +162 -33
- package/src/mcpl/types.ts +23 -6
- package/src/module-registry.ts +92 -13
- package/src/modules/discord/index.ts +8 -13
- package/src/modules/history/index.ts +25 -3
- package/src/modules/history/semantic.ts +29 -6
- package/src/modules/index.ts +1 -0
- package/src/modules/unknown-tool.ts +4 -1
- package/src/modules/workspace/branch-intent.ts +3 -1
- package/src/modules/workspace/edit-plan.ts +954 -0
- package/src/modules/workspace/edit-text.ts +618 -0
- package/src/modules/workspace/effects.ts +70 -19
- package/src/modules/workspace/index.ts +2293 -650
- package/src/modules/workspace/observe.ts +465 -56
- package/src/modules/workspace/reconcile.ts +14 -7
- package/src/modules/workspace/text.ts +68 -0
- package/src/modules/workspace/types.ts +211 -6
- package/src/modules/workspace/watcher.ts +3 -2
- package/src/operator-log.ts +47 -19
- package/src/recovery/discord-awareness-outbox.ts +1500 -356
- package/src/recovery/offline-branch.ts +189 -55
- package/src/recovery/recover-cli.ts +25 -4
- package/src/send-tools.ts +11 -0
- package/src/timezone.ts +4 -2
- package/src/tool-image-ledger.ts +62 -8
- package/src/tool-result-guard.ts +18 -15
- package/src/tool-result-history.ts +3 -2
- package/src/tune-out/coordinator.ts +166 -45
- package/src/types/agent.ts +32 -6
- package/src/types/events.ts +66 -9
- package/src/types/framework.ts +69 -62
- package/src/types/module.ts +40 -8
- package/src/types/trace.ts +121 -15
- package/src/usage/types.ts +16 -0
- package/src/usage/usage-tracker.ts +86 -43
- package/dist/src/code-execution/py-runner.d.ts +0 -191
- package/dist/src/code-execution/py-runner.d.ts.map +0 -1
- package/dist/src/code-execution/py-runner.js +0 -655
- package/dist/src/code-execution/py-runner.js.map +0 -1
- package/dist/src/code-execution/runtime-py.d.ts +0 -50
- package/dist/src/code-execution/runtime-py.d.ts.map +0 -1
- package/dist/src/code-execution/runtime-py.js +0 -677
- package/dist/src/code-execution/runtime-py.js.map +0 -1
- package/dist/src/mcpl/prose-stream-router.d.ts +0 -88
- package/dist/src/mcpl/prose-stream-router.d.ts.map +0 -1
- package/dist/src/mcpl/prose-stream-router.js +0 -291
- package/dist/src/mcpl/prose-stream-router.js.map +0 -1
- package/src/code-execution/py-runner.ts +0 -791
- package/src/code-execution/runtime-py.ts +0 -677
- package/src/mcpl/prose-stream-router.ts +0 -268
|
@@ -196,6 +196,33 @@ export interface AgentConfig {
|
|
|
196
196
|
* content-free system receipt is stored instead. Default false.
|
|
197
197
|
*/
|
|
198
198
|
toolWrapperProseGuard?: boolean;
|
|
199
|
+
/**
|
|
200
|
+
* Clock rows (off when left out): when a boundary of this interval on the
|
|
201
|
+
* agent's local wall clock (counted from local midnight, in the
|
|
202
|
+
* framework's `timeZone`) has passed since the last clock row, the window
|
|
203
|
+
* takes one more — `Clock: 10:50 Europe/Berlin (UTC+02:00)`, with the date
|
|
204
|
+
* when the day has changed — before the next thing it takes: an incoming
|
|
205
|
+
* event, a turn's start, or, mid-turn, after a tool round's results, where
|
|
206
|
+
* it also joins the live stream. Only the latest boundary is written, and
|
|
207
|
+
* a window that holds no clock row yet takes one at the next of these. A
|
|
208
|
+
* clock reads the boundary's time where its tick would have stood, else
|
|
209
|
+
* the time it is written (after a tool's results, say), so it never
|
|
210
|
+
* reads earlier than a row before it. A clock wakes no one. See
|
|
211
|
+
* src/clock-rows.ts.
|
|
212
|
+
*
|
|
213
|
+
* - A stream that can't carry injected messages (membrane's XML prefill
|
|
214
|
+
* path) takes no mid-turn clock: the next event or turn start writes it.
|
|
215
|
+
* - On some models a clock after a tool's results drops the loop's
|
|
216
|
+
* earlier thinking from the request, as any message heard while acting
|
|
217
|
+
* does there: at most once an interval.
|
|
218
|
+
* - Residents share one window, so every resident reads the clock rows any
|
|
219
|
+
* of them writes, a resident with no `clock` of its own included. Each
|
|
220
|
+
* writes one when a boundary of its own interval has passed since the
|
|
221
|
+
* window's last clock, whichever resident wrote that. The subconscious
|
|
222
|
+
* takes none of its own: it reads the residents' through its merged
|
|
223
|
+
* view.
|
|
224
|
+
*/
|
|
225
|
+
clock?: import('../clock-rows.js').ClockConfig;
|
|
199
226
|
}
|
|
200
227
|
/** The intentionally small set of agent settings that may change in-process. */
|
|
201
228
|
export interface AgentRuntimeSettingsPatch {
|
|
@@ -355,6 +382,10 @@ export interface InferenceRequest {
|
|
|
355
382
|
* all of them without materializing content, the turn has no cause left
|
|
356
383
|
* and does not run. */
|
|
357
384
|
coalescingBatchSubjects?: string[];
|
|
385
|
+
/** Host-owned: this wake's sole cause is reading this deferred write, a
|
|
386
|
+
* coalesced render placed in its agent's queue (wakeToRead). Once the
|
|
387
|
+
* agent has read the write, or it was removed, the wake starts no turn. */
|
|
388
|
+
readsDeferredWrite?: string;
|
|
358
389
|
agentName: string;
|
|
359
390
|
reason: string;
|
|
360
391
|
source: string;
|
|
@@ -370,12 +401,6 @@ export interface InferenceRequest {
|
|
|
370
401
|
* ephemeral run's (a subagent's), which takes no global fallback.
|
|
371
402
|
*/
|
|
372
403
|
channelId?: string;
|
|
373
|
-
/**
|
|
374
|
-
* Host-owned: the MCPL server whose message set `channelId`. A turn's
|
|
375
|
-
* replies to that channel go out through this server only. Unset where the
|
|
376
|
-
* wake's channel came from no one server's message.
|
|
377
|
-
*/
|
|
378
|
-
serverId?: string;
|
|
379
404
|
/**
|
|
380
405
|
* True when the triggering message explicitly addressed the agent (mention,
|
|
381
406
|
* reply-to-bot, DM — `chat:addressed` in MCPL RFC-001 terms). When a wake
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"agent.d.ts","sourceRoot":"","sources":["../../../src/types/agent.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,YAAY,EAAE,cAAc,EAAE,MAAM,qBAAqB,CAAC;AACxE,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,4BAA4B,CAAC;AAClE,OAAO,KAAK,EAAE,UAAU,EAAE,UAAU,EAAE,QAAQ,EAAE,MAAM,aAAa,CAAC;AACpE,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,wBAAwB,CAAC;AAElE,MAAM,MAAM,wBAAwB,GAAG,QAAQ,GAAG,SAAS,CAAC;AAC5D,MAAM,MAAM,8BAA8B,GACtC,kBAAkB,GAClB,QAAQ,GACR,uBAAu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AAI,EAAE,MAAM,CAAC;IACb,KAAK,EAAE,OAAO,CAAC;IACf,SAAS,EAAE,MAAM,CAAC;CACnB;AAED;;GAEG;AACH,MAAM,WAAW,iBAAiB;IAChC,EAAE,EAAE,UAAU,CAAC;IACf,IAAI,EAAE,MAAM,CAAC;IACb,KAAK,EAAE,OAAO,CAAC;IACf,MAAM,EAAE,UAAU,CAAC;IACnB,UAAU,EAAE,MAAM,CAAC;CACpB;AAED;;GAEG;AACH,MAAM,WAAW,gBAAgB;IAC/B,0EAA0E;IAC1E,iBAAiB,CAAC,EAAE,MAAM,CAAC;IAC3B,iBAAiB,CAAC,EAAE,MAAM,CAAC;IAC3B;4EACwE;IACxE,eAAe,CAAC,EAAE,OAAO,CAAC;IAC1B;;;4BAGwB;IACxB,uBAAuB,CAAC,EAAE,MAAM,EAAE,CAAC;IACnC;;gFAE4E;IAC5E,kBAAkB,CAAC,EAAE,MAAM,CAAC;IAC5B,SAAS,EAAE,MAAM,CAAC;IAClB,MAAM,EAAE,MAAM,CAAC;IACf,MAAM,EAAE,MAAM,CAAC;IACf,SAAS,EAAE,MAAM,CAAC;IAClB;;;;;;;;;OASG;IACH,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB;;;;;;OAMG;IACH,SAAS,CAAC,EAAE,OAAO,CAAC;IACpB;;;;;;OAMG;IACH,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB;;;;;;;;OAQG;IACH,aAAa,CAAC,EAAE,MAAM,CAAC;IACvB,sEAAsE;IACtE,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB;mFAC+E;IAC/E,aAAa,CAAC,EAAE,OAAO,CAAC;IACxB;;;;6DAIyD;IACzD,eAAe,CAAC,EAAE,mBAAmB,CAAC;CACvC"}
|
|
@@ -165,11 +165,32 @@ export interface ToolResult {
|
|
|
165
165
|
/** Whether this was an error (for LLM) */
|
|
166
166
|
isError?: boolean;
|
|
167
167
|
/**
|
|
168
|
-
*
|
|
169
|
-
*
|
|
170
|
-
*
|
|
171
|
-
*
|
|
172
|
-
*
|
|
168
|
+
* The dispatcher refused the call before it opened, RFC-007's refusal, so
|
|
169
|
+
* nothing ran and the call certainly had no effect. Only the dispatcher's
|
|
170
|
+
* path, the model's calls and a script's, sets it: the caller may not use
|
|
171
|
+
* the tool (allowedTools), a `skip_reply` wake was refused, the call's MCPL
|
|
172
|
+
* server is absent or still connecting, the host's policy for that server
|
|
173
|
+
* denies the tool, or a fork reached outside its channel. RFC-007's
|
|
174
|
+
* lifecycle refuses the call from the same place, so observers see no
|
|
175
|
+
* events for it. A check made after the call opened, such as a module's
|
|
176
|
+
* answer for a name it has no tool for or arguments that don't fit a
|
|
177
|
+
* schema, is a failure whose text says nothing was done, as is an MCPL
|
|
178
|
+
* request that couldn't be written. A programmatic call (`executeToolCall`,
|
|
179
|
+
* `ModuleContext.callTool`) opens no RFC-007 call, so it's never refused:
|
|
180
|
+
* the allowedTools check answers it with a failure saying the call didn't
|
|
181
|
+
* run, and the other checks it gets, such as the module registry's, answer
|
|
182
|
+
* as they do once a call has opened. A module's result never carries it. A script's call refused so reaches the script as an
|
|
183
|
+
* Error, where any other failure is a result with `isError`.
|
|
184
|
+
*/
|
|
185
|
+
refused?: boolean;
|
|
186
|
+
/**
|
|
187
|
+
* The result's machine-readable form, beside `data`. Programs read it: a
|
|
188
|
+
* script gets it in its result object, and a host in the tool result
|
|
189
|
+
* event. The model never reads this field: it sees the value only where an
|
|
190
|
+
* MCP conversion put it in the content as JSON, which happens only when the
|
|
191
|
+
* server sent no text. An MCP tool's is its `structuredContent`, present
|
|
192
|
+
* exactly when the server sent one, so `false`, `0` and `null` are values
|
|
193
|
+
* here, not absence. Any other tool can set one too.
|
|
173
194
|
*/
|
|
174
195
|
structured?: unknown;
|
|
175
196
|
/**
|
|
@@ -208,15 +229,51 @@ export interface ToolCall {
|
|
|
208
229
|
* The turn the call was made in, the same id as that turn's
|
|
209
230
|
* `SpeechContext.turnId`. Set by the framework dispatch layer, beside
|
|
210
231
|
* `callerAgentName`: a model's call carries the turn whose stream made it, a
|
|
211
|
-
*
|
|
212
|
-
*
|
|
213
|
-
*
|
|
214
|
-
* none. Ids increase, so a later turn's is larger, and they're unique only
|
|
232
|
+
* script's call the turn of the code_execution call watching the script when
|
|
233
|
+
* the call reaches the host, and a utility run its `utils` call's. A script left
|
|
234
|
+
* running, which no call watches, runs apart from any turn, so its calls
|
|
235
|
+
* carry none. Ids increase, so a later turn's is larger, and they're unique only
|
|
215
236
|
* within one run of the process. A call made with `executeToolCall` or a
|
|
216
237
|
* module's `callTool` skips that layer and carries whatever turn its caller
|
|
217
238
|
* put on the call, usually none.
|
|
218
239
|
*/
|
|
219
240
|
callerTurnId?: number;
|
|
241
|
+
/**
|
|
242
|
+
* How long this call's result may be and still reach its caller whole,
|
|
243
|
+
* measured as the framework stores it: an error's text, or a success's data
|
|
244
|
+
* as JSON (a content array as its text). For a model's call it is the
|
|
245
|
+
* agent's inline cap, past which the framework spills the result to a
|
|
246
|
+
* workspace file and sends a preview. A result that long is stored whole
|
|
247
|
+
* unless its round's results together pass the readers' per-message bound,
|
|
248
|
+
* or a save_recent_image in the round counted it by its share: then each
|
|
249
|
+
* result of the round takes an equal share of that bound, and one past its
|
|
250
|
+
* share spills. For a call from a running
|
|
251
|
+
* code_execution script it is the longest result that reaches the script
|
|
252
|
+
* whole whatever its characters, from the script's memory: the script
|
|
253
|
+
* takes an answer of up to a third of its memoryMaxBytes, in which a
|
|
254
|
+
* character of the result takes at most six bytes (a control character,
|
|
255
|
+
* escaped as `\u0000`), so the figure is that third, less the 80 bytes of a
|
|
256
|
+
* text answer's envelope, over six: 7,456,527 at the default 128 MiB. On
|
|
257
|
+
* Node, past about 1.5 GiB, the host's longest string bounds it instead.
|
|
258
|
+
* A result with a `structured` value reaches a script as its content's
|
|
259
|
+
* blocks as they are, beside that value as JSON, and the figure counts
|
|
260
|
+
* neither the value nor what the blocks carry past their text, such as each
|
|
261
|
+
* further block's keys or an image's data, so a tool that returns one
|
|
262
|
+
* leaves room for them; and a result nested past 2,000 levels, or whose parse
|
|
263
|
+
* needs more of the script's memory than is free, doesn't reach the script
|
|
264
|
+
* whatever its length. A result that doesn't reach it is answered
|
|
265
|
+
* ResultTooLarge, the call having taken effect. Nothing is cut or saved to
|
|
266
|
+
* a file. A tool that pages or budgets its answer can stay under it. The
|
|
267
|
+
* framework sets it on a model's, a script's and the operator's puppet's
|
|
268
|
+
* call to a module, a utility run through `utils` included. A call
|
|
269
|
+
* made in process with ModuleContext.callTool or executeToolCall carries
|
|
270
|
+
* what its caller put on it, as the puppet's does; the framework's own
|
|
271
|
+
* read_image tool passes a model's call to the workspace without it; and a
|
|
272
|
+
* utility run through `utils` carries what its `utils` call carried.
|
|
273
|
+
* Without it, a module holds its answer to a bound of its own, if any: the
|
|
274
|
+
* workspace's is the house default, 24,000.
|
|
275
|
+
*/
|
|
276
|
+
resultMaxChars?: number;
|
|
220
277
|
}
|
|
221
278
|
/**
|
|
222
279
|
* Push event from an MCPL server (Section 9).
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"events.d.ts","sourceRoot":"","sources":["../../../src/types/events.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,YAAY,EAAE,cAAc,IAAI,sBAAsB,EAAE,MAAM,qBAAqB,CAAC;AAClG,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,4BAA4B,CAAC;AAE5D;;GAEG;AACH,MAAM,MAAM,UAAU,GAAG,MAAM,CAAC;AAEhC;;GAEG;AACH,MAAM,MAAM,cAAc,GAAG,sBAAsB,CAAC;AAEpD;;;;;;;GAOG;AACH,MAAM,MAAM,YAAY,GACpB,oBAAoB,GACpB,aAAa,GACb,eAAe,GACf,eAAe,GACf,qBAAqB,GACrB,kBAAkB,GAClB,mBAAmB,GACnB,WAAW,GACX,eAAe,GACf,wBAAwB,GACxB,aAAa,GACb,wBAAwB,GACxB,WAAW,CAAC;AAEhB;;GAEG;AACH,MAAM,WAAW,eAAe;IAC9B,I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CAAC;IAClB,MAAM,EAAE;QAAE,EAAE,EAAE,MAAM,CAAC;QAAC,IAAI,EAAE,MAAM,CAAA;KAAE,CAAC;IACrC,OAAO,EAAE,YAAY,EAAE,CAAC;IACxB,SAAS,EAAE,MAAM,CAAC;IAClB,QAAQ,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;IACnC,gBAAgB,CAAC,EAAE,OAAO,CAAC;IAC3B,YAAY,CAAC,EAAE,MAAM,EAAE,CAAC;IACxB,8EAA8E;IAC9E,UAAU,CAAC,EAAE,MAAM,CAAC;CACrB"}
|
|
@@ -26,66 +26,66 @@ export interface ProcessLoggingConfig {
|
|
|
26
26
|
*/
|
|
27
27
|
/**
|
|
28
28
|
* Client-side programmatic tool calling: a synthesized `code_execution` tool
|
|
29
|
-
* that runs model-authored
|
|
30
|
-
*
|
|
31
|
-
*
|
|
29
|
+
* that runs model-authored JavaScript in QuickJS compiled to WebAssembly, in a
|
|
30
|
+
* child process of its own per script, with the agent's tools as async
|
|
31
|
+
* functions. Mirrors the trained surface of Anthropic's server-side PTC;
|
|
32
|
+
* inner tool results never enter the model context.
|
|
32
33
|
*
|
|
33
|
-
*
|
|
34
|
-
*
|
|
34
|
+
* A script adds nothing to what its agent's tools allow, provided the host
|
|
35
|
+
* runtime's WebAssembly engine and the glue around it are right. It claims no
|
|
36
|
+
* containment beyond that: the child runs as the host's user, with an empty
|
|
37
|
+
* environment and no operating-system sandbox around it.
|
|
35
38
|
*/
|
|
36
39
|
export interface CodeExecutionConfig {
|
|
37
40
|
/** Master switch — only `true` synthesizes the tool. `create()` refuses a
|
|
38
41
|
* value that isn't a boolean, a quoted "false" included; `null` or leaving
|
|
39
42
|
* it out counts as off. */
|
|
40
43
|
enabled: boolean;
|
|
41
|
-
/**
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
*
|
|
46
|
-
|
|
44
|
+
/** How long a run or a wait waits for its script before it yields, unless
|
|
45
|
+
* the agent asks otherwise with `yield_time_ms` (default 30_000 ms). */
|
|
46
|
+
yieldMs?: number;
|
|
47
|
+
/** The most an agent may ask a run or a wait to wait (default 600_000 ms).
|
|
48
|
+
* At least `yieldMs`. */
|
|
49
|
+
maxYieldMs?: number;
|
|
50
|
+
/** A script's limit: a script still running this long after it started is
|
|
51
|
+
* stopped, as "stopped at its limit" (default 86_400_000 ms, a day). */
|
|
52
|
+
scriptLifetimeMs?: number;
|
|
53
|
+
/** Scripts one agent may have running at once, yielded ones included
|
|
54
|
+
* (default 3). */
|
|
55
|
+
maxRunningScripts?: number;
|
|
56
|
+
/** Script processes the host runs at once, every agent's together
|
|
57
|
+
* (default 16). A run past it is refused at once, and nothing runs. */
|
|
58
|
+
maxScriptChildren?: number;
|
|
59
|
+
/** How long one of a script's tool calls may go unanswered before the
|
|
60
|
+
* script is told it timed out; the tool may still take effect
|
|
61
|
+
* (default 270_000 ms). */
|
|
47
62
|
toolCallTimeoutMs?: number;
|
|
48
|
-
/** Whole-script deadline: cancel → grace → SIGKILL (default 600_000 ms). */
|
|
49
|
-
scriptTimeoutMs?: number;
|
|
50
|
-
/**
|
|
51
|
-
* Longest deadline an agent may ask for on one call with `time_limit_ms`
|
|
52
|
-
* (default: `scriptTimeoutMs`, so agents can only shorten it until this is
|
|
53
|
-
* raised). Longer requests are capped, and the result says so.
|
|
54
|
-
*/
|
|
55
|
-
maxScriptTimeoutMs?: number;
|
|
56
|
-
/**
|
|
57
|
-
* Idle interpreter reclaim — script globals are lost after this much
|
|
58
|
-
* inactivity (default 300_000 ms, mirroring ~5-minute container reclaim).
|
|
59
|
-
* 0 disables reclaim.
|
|
60
|
-
*/
|
|
61
|
-
idleReclaimMs?: number;
|
|
62
|
-
/** Max concurrent background (daemon) scripts per agent (default 3). */
|
|
63
|
-
maxBackgroundScripts?: number;
|
|
64
|
-
/** Background script lifetime ceiling, ms (default 86_400_000 = 24h). */
|
|
65
|
-
backgroundMaxLifetimeMs?: number;
|
|
66
63
|
/** Minimum interval between wake_agent() deliveries, ms (default 60_000).
|
|
67
|
-
* Early wakes are delayed, not dropped
|
|
64
|
+
* Early wakes are delayed, not dropped. */
|
|
68
65
|
wakeMinIntervalMs?: number;
|
|
69
|
-
/** Max wake_agent() calls per
|
|
70
|
-
*
|
|
66
|
+
/** Max wake_agent() calls per script (default 100); further calls are
|
|
67
|
+
* refused in the script. */
|
|
71
68
|
maxWakesPerScript?: number;
|
|
72
|
-
/**
|
|
73
|
-
*
|
|
74
|
-
*
|
|
75
|
-
*
|
|
76
|
-
*
|
|
77
|
-
*
|
|
78
|
-
*
|
|
79
|
-
*
|
|
80
|
-
*
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
*
|
|
84
|
-
*
|
|
85
|
-
*
|
|
86
|
-
*
|
|
87
|
-
*
|
|
88
|
-
|
|
69
|
+
/**
|
|
70
|
+
* The WebAssembly memory's maximum for each script, its budget: a whole
|
|
71
|
+
* number of 64 KiB pages from 4 MiB to 2 GiB (default 128 MiB). A script's
|
|
72
|
+
* process stays within about its runtime's base plus 2.7 times this, plus
|
|
73
|
+
* what its calls take as they go out: up to about 200 MiB under Node and
|
|
74
|
+
* 410 MiB under Bun. The host holds at most about 6 times this, plus 653 MiB,
|
|
75
|
+
* plus 128 KiB for each wake maxWakesPerScript allows, for a script: about
|
|
76
|
+
* 1.4 GiB at the defaults.
|
|
77
|
+
* That's its 16 calls out at once, each with at most 4 MiB of JSON
|
|
78
|
+
* arguments, timed-out ones whose tools still run included, up to 16 more
|
|
79
|
+
* waiting as their text for those to end, up to 16 answers until the child
|
|
80
|
+
* takes them, each at most a third of this, the frame from the child being
|
|
81
|
+
* read, and its waiting wakes. A tool's
|
|
82
|
+
* own result, and the one serialization the bridge makes of it to check its
|
|
83
|
+
* size, are the tool's, beside this. Size a host by both. A call past the 16
|
|
84
|
+
* the script waits on waits in the script, in this memory. A tool result too large for
|
|
85
|
+
* it reaches the script as ResultTooLarge; how much fits depends on the
|
|
86
|
+
* result's shape (see `IsolateSettings.memoryMaxBytes`).
|
|
87
|
+
*/
|
|
88
|
+
memoryMaxBytes?: number;
|
|
89
89
|
}
|
|
90
90
|
/** See `FrameworkConfig.providerHold`. */
|
|
91
91
|
export interface ProviderHold {
|
|
@@ -107,17 +107,19 @@ export interface FrameworkConfig {
|
|
|
107
107
|
*/
|
|
108
108
|
subconscious?: import('../tune-out/tools.js').SubconsciousConfig;
|
|
109
109
|
/**
|
|
110
|
-
* IANA zone
|
|
111
|
-
*
|
|
112
|
-
*
|
|
110
|
+
* IANA zone of the agent's wall clock: it renders wall-clock times for the
|
|
111
|
+
* agent, and it sets where clock rows' boundaries fall (AgentConfig.clock,
|
|
112
|
+
* counted from local midnight here). Stored/protocol timestamps remain
|
|
113
|
+
* epoch/UTC. Defaults to AGENT_TIMEZONE, then the process zone.
|
|
113
114
|
*/
|
|
114
115
|
timeZone?: string;
|
|
115
116
|
/** Path to Chronicle store */
|
|
116
117
|
storePath?: string;
|
|
117
118
|
/**
|
|
118
|
-
* Branch-independent Discord awareness
|
|
119
|
+
* Branch-independent Discord awareness ledger. Defaults to
|
|
119
120
|
* `<storePath>/recovery/discord-awareness-outbox.json`. Set explicitly when
|
|
120
|
-
* providing an app-owned `store` without `storePath`;
|
|
121
|
+
* providing an app-owned `store` without `storePath`; with neither, the
|
|
122
|
+
* framework has no ledger and refuses a marks choice.
|
|
121
123
|
*/
|
|
122
124
|
discordAwarenessOutboxPath?: string;
|
|
123
125
|
/**
|
|
@@ -198,25 +200,27 @@ export interface FrameworkConfig {
|
|
|
198
200
|
mcplServers?: McplServerConfig[];
|
|
199
201
|
/**
|
|
200
202
|
* Client-side programmatic tool calling (`code_execution` tool). Omitted or
|
|
201
|
-
* `enabled: false` → tool absent, no
|
|
203
|
+
* `enabled: false` → tool absent, and no script's process is ever started. At runtime,
|
|
202
204
|
* untyped configs may also use `null` or `false` to omit this setting.
|
|
203
205
|
* Other values that aren't objects are refused at `create()`.
|
|
204
206
|
*/
|
|
205
207
|
codeExecution?: CodeExecutionConfig;
|
|
206
208
|
/**
|
|
207
209
|
* Durable inline cap (chars) for tool results — successes AND errors — and
|
|
208
|
-
*
|
|
210
|
+
* script wake payloads (wake_agent()). Content over the cap is written to a
|
|
209
211
|
* workspace file under `tool-results/` (deterministic `<date>-<callId>.txt`
|
|
210
212
|
* name, overwritten on collision, retained until the workspace owner
|
|
211
213
|
* deletes it — never auto-GC'd) and replaced inline by a bounded preview
|
|
212
|
-
* plus the file reference; with no writable
|
|
213
|
-
* explicit plain truncation. Default 24000 (house-safe; issue #89). Must be
|
|
214
|
+
* plus the file reference; with no writable mount without an include, the
|
|
215
|
+
* fallback is explicit plain truncation. Default 24000 (house-safe; issue #89). Must be
|
|
214
216
|
* >= 1000. A resident's own agent_settings value
|
|
215
217
|
* `tool_result_inline_max_chars` (durable, persisted in framework state)
|
|
216
218
|
* takes precedence over this for that agent; the EFFECTIVE cap for every
|
|
217
219
|
* source is min(desired, strategy bound) — desired values above the
|
|
218
220
|
* strategy-derived bound (maxMessageTokens * 4) are hard-clamped to it,
|
|
219
|
-
* with the clamp reported via agent_settings get.
|
|
221
|
+
* with the clamp reported via agent_settings get. For an ordinary resident
|
|
222
|
+
* the bound is the smallest among the agents that read the shared slot,
|
|
223
|
+
* reported as clamped by `reader-bound` when another reader's sets it.
|
|
220
224
|
*/
|
|
221
225
|
toolResultInlineMaxChars?: number;
|
|
222
226
|
/**
|
|
@@ -410,13 +414,16 @@ export interface InferenceLogEntry {
|
|
|
410
414
|
stopReason?: string;
|
|
411
415
|
}
|
|
412
416
|
/**
|
|
413
|
-
* Entry in the process log - records a processed event with
|
|
417
|
+
* Entry in the process log - records a processed event with the module
|
|
418
|
+
* responses that applied.
|
|
414
419
|
*/
|
|
415
420
|
export interface ProcessLogEntry {
|
|
416
421
|
timestamp: number;
|
|
417
422
|
/** The process event that was handled */
|
|
418
423
|
processEvent: ProcessEvent;
|
|
419
|
-
/**
|
|
424
|
+
/** The modules' responses that applied, or blob ID if large. A response
|
|
425
|
+
* refused for content context-manager won't store is left out; its stderr
|
|
426
|
+
* line and process:response-refused trace name it. */
|
|
420
427
|
responses: ModuleProcessResponse[] | {
|
|
421
428
|
blobId: string;
|
|
422
429
|
};
|
|
@@ -427,7 +434,7 @@ export interface ProcessLogEntry {
|
|
|
427
434
|
export interface ProcessLogQuery {
|
|
428
435
|
/** Filter by process event type */
|
|
429
436
|
eventType?: string;
|
|
430
|
-
/** Filter by module name (modules
|
|
437
|
+
/** Filter by module name (modules whose responses applied) */
|
|
431
438
|
moduleName?: string;
|
|
432
439
|
/** Max number of logs to return */
|
|
433
440
|
limit?: number;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"framework.d.ts","sourceRoot":"","sources":["../../../src/types/framework.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,sBAAsB,CAAC;AACpD,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,qBAAqB,CAAC;AACpD,OAAO,KAAK,EAAE,MAAM,EAAE,aAAa,EAAE,MAAM,aAAa,CAAC;AACzD,OAAO,KAAK,EAAE,WAAW,EAAE,gBAAgB,EAAE,MAAM,YAAY,CAAC;AAChE,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,aAAa,CAAC;AAChD,OAAO,KAAK,EAAE,gBAAgB,EAAE,sBAAsB,EAAE,MAAM,kBAAkB,CAAC;AACjF,OAAO,KAAK,EAAE,wBAAwB,EAAE,MAAM,gCAAgC,CAAC;AAC/E,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,kBAAkB,CAAC;AAGpD,YAAY,EAAE,UAAU,EAAE,kBAAkB,EAAE,MAAM,YAAY,CAAC;AAEjE;;GAEG;AACH,MAAM,WAAW,qBAAqB;IACpC,UAAU,EAAE,MAAM,CAAC;IACnB,QAAQ,EAAE,aAAa,CAAC;CACzB;AAED;;GAEG;AACH,MAAM,WAAW,oBAAoB;IACnC,yDAAyD;IACzD,OAAO,CAAC,EAAE,OAAO,CAAC;C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AC;CAC7B;AAED;;GAEG;AACH,MAAM,WAAW,iBAAiB;IAChC,SAAS,EAAE,MAAM,CAAC;IAClB,SAAS,EAAE,MAAM,CAAC;IAClB,WAAW,EAAE,MAAM,CAAC;IACpB,uCAAuC;IACvC,0BAA0B,EAAE,MAAM,EAAE,CAAC;IACrC,kCAAkC;IAClC,qBAAqB,EAAE,MAAM,EAAE,CAAC;IAChC,2CAA2C;IAC3C,eAAe,EAAE,OAAO,CAAC;CAC1B"}
|
|
@@ -20,7 +20,8 @@ export interface MessageQuery {
|
|
|
20
20
|
}
|
|
21
21
|
/**
|
|
22
22
|
* A message as a module context's reads answer it: a stored row, or a row
|
|
23
|
-
* for a write the framework holds (`held`).
|
|
23
|
+
* for a write the framework holds (`held`). Either is marked
|
|
24
|
+
* `heldFromResidents` when a tune-out holds it from the residents.
|
|
24
25
|
*/
|
|
25
26
|
export type ModuleMessage = StoredMessage & {
|
|
26
27
|
/**
|
|
@@ -32,9 +33,31 @@ export type ModuleMessage = StoredMessage & {
|
|
|
32
33
|
* and `timestamp` are provisional: the sequence comes after every stored
|
|
33
34
|
* row's, the timestamp is when the framework held the write (for a write
|
|
34
35
|
* an older release held, when its queue was read back), and both change
|
|
35
|
-
* when it lands.
|
|
36
|
+
* when it lands. A held write whose earlier write may already be stored
|
|
37
|
+
* is looked up first, and answered as the stored row it is when the store
|
|
38
|
+
* holds it. Absent on a stored row.
|
|
36
39
|
*/
|
|
37
40
|
held?: true;
|
|
41
|
+
/**
|
|
42
|
+
* True on a message a tune-out holds from the residents: one that arrived
|
|
43
|
+
* in a tuned-out channel, stamped `metadata.tuneOut` as it came in. The
|
|
44
|
+
* store keeps it, but no resident is shown the row itself: no resident's
|
|
45
|
+
* compiled view includes it, during the tune-out or after it, and a tool
|
|
46
|
+
* boundary of a turn alive when it arrived stores it without injecting it
|
|
47
|
+
* into the live turn. The subconscious reads it. Its text can still reach
|
|
48
|
+
* a resident in rows of their own, which aren't marked, such as the
|
|
49
|
+
* cancel's `<tuned-out-backlog>` row, with the text of the tune-out's newest
|
|
50
|
+
* messages, up to `backlogCap` of them and as many as fit in one of the
|
|
51
|
+
* residents' messages, the stored ones first and then those still held;
|
|
52
|
+
* what the subconscious says of it, in its report or its note; and the
|
|
53
|
+
* result of a tool that reads history on request, such as a
|
|
54
|
+
* channel's `fetch_history` or the history module's `extract`. A module
|
|
55
|
+
* that builds on what the residents see, such as one choosing from the
|
|
56
|
+
* recent conversation, leaves a marked row out, and one that matches
|
|
57
|
+
* what's stored, such as a sync's dedupe, keeps it. A held write (`held`)
|
|
58
|
+
* is marked too when it carries the stamp. Absent on every other row.
|
|
59
|
+
*/
|
|
60
|
+
heldFromResidents?: true;
|
|
38
61
|
};
|
|
39
62
|
/**
|
|
40
63
|
* Result of a message query.
|
|
@@ -251,12 +274,16 @@ export interface ModuleContext {
|
|
|
251
274
|
}): MessageId;
|
|
252
275
|
/**
|
|
253
276
|
* Edit a message, by its id or a held write's handle. A held write is
|
|
254
|
-
* stored with the new content.
|
|
277
|
+
* stored with the new content. One whose earlier write may already be
|
|
278
|
+
* stored, where the store can't be searched to tell, throws with nothing
|
|
279
|
+
* changed.
|
|
255
280
|
*/
|
|
256
281
|
editMessage(id: MessageId, content: ContentBlock[]): void;
|
|
257
282
|
/**
|
|
258
283
|
* Remove a message, by its id or a held write's handle. A held write is
|
|
259
|
-
* dropped, so the agent never reads it.
|
|
284
|
+
* dropped, so the agent never reads it. One whose earlier write may
|
|
285
|
+
* already be stored, where the store can't be searched to tell, throws
|
|
286
|
+
* with nothing changed.
|
|
260
287
|
*/
|
|
261
288
|
removeMessage(id: MessageId): void;
|
|
262
289
|
/**
|
|
@@ -270,7 +297,9 @@ export interface ModuleContext {
|
|
|
270
297
|
*/
|
|
271
298
|
findMessageByExternalId(source: string, externalId: string): MessageId | null;
|
|
272
299
|
/**
|
|
273
|
-
* Get a message by its id or a held write's handle
|
|
300
|
+
* Get a message by its id or a held write's handle, marked
|
|
301
|
+
* `heldFromResidents` when a tune-out holds it from the residents
|
|
302
|
+
* (ModuleMessage).
|
|
274
303
|
*/
|
|
275
304
|
getMessage(id: MessageId): ModuleMessage | null;
|
|
276
305
|
/**
|
|
@@ -279,7 +308,9 @@ export interface ModuleContext {
|
|
|
279
308
|
* The rows of writes the framework holds come after the stored rows, as
|
|
280
309
|
* the newest, or before them in a reversed query, marked `held`
|
|
281
310
|
* (ModuleMessage). Those the last process held show once create() has
|
|
282
|
-
* restored them, after every module's start() (addMessage).
|
|
311
|
+
* restored them, after every module's start() (addMessage). A message a
|
|
312
|
+
* tune-out holds from the residents is among the rows, marked
|
|
313
|
+
* `heldFromResidents` (ModuleMessage).
|
|
283
314
|
*/
|
|
284
315
|
queryMessages(filter: MessageQuery): MessageQueryResult;
|
|
285
316
|
/**
|
|
@@ -492,8 +523,9 @@ export interface SpeechContext {
|
|
|
492
523
|
thoughts?: ContentBlock[];
|
|
493
524
|
/**
|
|
494
525
|
* The turn this speech ends: the same id as `ToolCall.callerTurnId` on the
|
|
495
|
-
* calls made in it (its model's calls and
|
|
496
|
-
*
|
|
526
|
+
* calls made in it (its model's calls, and a script's calls that reach the
|
|
527
|
+
* host while a code_execution call of the turn watches the script), kept across the
|
|
528
|
+
* turn's streams (a context-budget restart or a
|
|
497
529
|
* retry), and larger for the agent's next turn. Unique only within one run
|
|
498
530
|
* of the process.
|
|
499
531
|
*/
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"module.d.ts","sourceRoot":"","sources":["../../../src/types/module.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,qBAAqB,CAAC;AACxD,OAAO,KAAK,EACV,SAAS,EACT,eAAe,EACf,aAAa,EACb,gBAAgB,EACjB,MAAM,4BAA4B,CAAC;AACpC,OAAO,KAAK,EAAE,YAAY,EAAE,cAAc,EAAE,QAAQ,EAAE,UAAU,EAAE,MAAM,aAAa,CAAC;AACtF,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,YA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