@animalabs/agent-framework 0.32.0 → 0.34.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/README.md +340 -22
- package/dist/src/admission/admit.d.ts +18 -0
- package/dist/src/admission/admit.d.ts.map +1 -1
- package/dist/src/admission/admit.js +16 -3
- package/dist/src/admission/admit.js.map +1 -1
- package/dist/src/agent.d.ts +208 -80
- package/dist/src/agent.d.ts.map +1 -1
- package/dist/src/agent.js +345 -113
- package/dist/src/agent.js.map +1 -1
- package/dist/src/api/mcp-server-core.d.ts.map +1 -1
- package/dist/src/api/mcp-server-core.js +50 -12
- package/dist/src/api/mcp-server-core.js.map +1 -1
- package/dist/src/api/server.d.ts.map +1 -1
- package/dist/src/api/server.js +4 -20
- package/dist/src/api/server.js.map +1 -1
- package/dist/src/append-all.d.ts +5 -0
- package/dist/src/append-all.d.ts.map +1 -0
- package/dist/src/append-all.js +8 -0
- package/dist/src/append-all.js.map +1 -0
- package/dist/src/code-execution/isolate/scripts.d.ts +12 -8
- package/dist/src/code-execution/isolate/scripts.d.ts.map +1 -1
- package/dist/src/code-execution/isolate/scripts.js +24 -0
- package/dist/src/code-execution/isolate/scripts.js.map +1 -1
- package/dist/src/config-checks.d.ts +7 -0
- package/dist/src/config-checks.d.ts.map +1 -1
- package/dist/src/config-checks.js +14 -0
- package/dist/src/config-checks.js.map +1 -1
- package/dist/src/context-manager-errors.d.ts +25 -0
- package/dist/src/context-manager-errors.d.ts.map +1 -0
- package/dist/src/context-manager-errors.js +31 -0
- package/dist/src/context-manager-errors.js.map +1 -0
- package/dist/src/context-options.d.ts +70 -0
- package/dist/src/context-options.d.ts.map +1 -0
- package/dist/src/context-options.js +90 -0
- package/dist/src/context-options.js.map +1 -0
- package/dist/src/cut-off-round.js +4 -4
- package/dist/src/deferred-import.d.ts +93 -0
- package/dist/src/deferred-import.d.ts.map +1 -0
- package/dist/src/deferred-import.js +177 -0
- package/dist/src/deferred-import.js.map +1 -0
- package/dist/src/dendrite/audience.d.ts +223 -0
- package/dist/src/dendrite/audience.d.ts.map +1 -0
- package/dist/src/dendrite/audience.js +202 -0
- package/dist/src/dendrite/audience.js.map +1 -0
- package/dist/src/dendrite/index.d.ts +5 -3
- package/dist/src/dendrite/index.d.ts.map +1 -1
- package/dist/src/dendrite/index.js +2 -1
- package/dist/src/dendrite/index.js.map +1 -1
- package/dist/src/dendrite/presets.d.ts +10 -5
- package/dist/src/dendrite/presets.d.ts.map +1 -1
- package/dist/src/dendrite/presets.js +17 -5
- package/dist/src/dendrite/presets.js.map +1 -1
- package/dist/src/dendrite/registry.d.ts +62 -7
- package/dist/src/dendrite/registry.d.ts.map +1 -1
- package/dist/src/dendrite/registry.js +183 -12
- package/dist/src/dendrite/registry.js.map +1 -1
- package/dist/src/dendrite/types.d.ts +91 -8
- package/dist/src/dendrite/types.d.ts.map +1 -1
- package/dist/src/failure-text.d.ts +36 -0
- package/dist/src/failure-text.d.ts.map +1 -0
- package/dist/src/failure-text.js +89 -0
- package/dist/src/failure-text.js.map +1 -0
- package/dist/src/foreign-rounds.d.ts +69 -0
- package/dist/src/foreign-rounds.d.ts.map +1 -0
- package/dist/src/foreign-rounds.js +152 -0
- package/dist/src/foreign-rounds.js.map +1 -0
- package/dist/src/framework.d.ts +2064 -842
- package/dist/src/framework.d.ts.map +1 -1
- package/dist/src/framework.js +8586 -3739
- package/dist/src/framework.js.map +1 -1
- package/dist/src/gate/event-gate.d.ts +125 -21
- package/dist/src/gate/event-gate.d.ts.map +1 -1
- package/dist/src/gate/event-gate.js +487 -72
- package/dist/src/gate/event-gate.js.map +1 -1
- package/dist/src/gate/index.d.ts +1 -1
- package/dist/src/gate/index.d.ts.map +1 -1
- package/dist/src/gate/index.js.map +1 -1
- package/dist/src/gate/reply-judge.d.ts +4 -0
- package/dist/src/gate/reply-judge.d.ts.map +1 -1
- package/dist/src/gate/reply-judge.js +12 -3
- package/dist/src/gate/reply-judge.js.map +1 -1
- package/dist/src/gate/rule-scope.d.ts +30 -0
- package/dist/src/gate/rule-scope.d.ts.map +1 -0
- package/dist/src/gate/rule-scope.js +41 -0
- package/dist/src/gate/rule-scope.js.map +1 -0
- package/dist/src/gate/suppress-script-worker.d.ts +2 -0
- package/dist/src/gate/suppress-script-worker.d.ts.map +1 -0
- package/dist/src/gate/suppress-script-worker.js +103 -0
- package/dist/src/gate/suppress-script-worker.js.map +1 -0
- package/dist/src/gate/suppress-scripts.d.ts +105 -0
- package/dist/src/gate/suppress-scripts.d.ts.map +1 -0
- package/dist/src/gate/suppress-scripts.js +403 -0
- package/dist/src/gate/suppress-scripts.js.map +1 -0
- package/dist/src/gate/suppression-review.d.ts +143 -0
- package/dist/src/gate/suppression-review.d.ts.map +1 -0
- package/dist/src/gate/suppression-review.js +463 -0
- package/dist/src/gate/suppression-review.js.map +1 -0
- package/dist/src/gate/suppression-stats.d.ts +125 -0
- package/dist/src/gate/suppression-stats.d.ts.map +1 -0
- package/dist/src/gate/suppression-stats.js +214 -0
- package/dist/src/gate/suppression-stats.js.map +1 -0
- package/dist/src/gate/types.d.ts +142 -7
- package/dist/src/gate/types.d.ts.map +1 -1
- package/dist/src/gate/wake-onboarding.d.ts +119 -0
- package/dist/src/gate/wake-onboarding.d.ts.map +1 -0
- package/dist/src/gate/wake-onboarding.js +277 -0
- package/dist/src/gate/wake-onboarding.js.map +1 -0
- package/dist/src/heartbeat/heartbeat.js +1 -1
- package/dist/src/heartbeat/heartbeat.js.map +1 -1
- package/dist/src/held-writes.d.ts +31 -23
- package/dist/src/held-writes.d.ts.map +1 -1
- package/dist/src/held-writes.js +44 -59
- package/dist/src/held-writes.js.map +1 -1
- package/dist/src/index.d.ts +6 -2
- package/dist/src/index.d.ts.map +1 -1
- package/dist/src/index.js +4 -0
- package/dist/src/index.js.map +1 -1
- package/dist/src/inference-bounds.d.ts +2 -1
- package/dist/src/inference-bounds.d.ts.map +1 -1
- package/dist/src/inference-bounds.js +9 -6
- package/dist/src/inference-bounds.js.map +1 -1
- package/dist/src/jsonrpc-envelope.d.ts +69 -0
- package/dist/src/jsonrpc-envelope.d.ts.map +1 -0
- package/dist/src/jsonrpc-envelope.js +66 -0
- package/dist/src/jsonrpc-envelope.js.map +1 -0
- package/dist/src/mcpl/channel-registry.d.ts +188 -28
- package/dist/src/mcpl/channel-registry.d.ts.map +1 -1
- package/dist/src/mcpl/channel-registry.js +426 -70
- package/dist/src/mcpl/channel-registry.js.map +1 -1
- package/dist/src/mcpl/checkpoint-manager.d.ts +2 -4
- package/dist/src/mcpl/checkpoint-manager.d.ts.map +1 -1
- package/dist/src/mcpl/checkpoint-manager.js.map +1 -1
- package/dist/src/mcpl/feature-set-manager.d.ts +2 -4
- package/dist/src/mcpl/feature-set-manager.d.ts.map +1 -1
- package/dist/src/mcpl/feature-set-manager.js.map +1 -1
- package/dist/src/mcpl/inbound-source.d.ts +2 -1
- package/dist/src/mcpl/inbound-source.d.ts.map +1 -1
- package/dist/src/mcpl/inbound-source.js +2 -1
- package/dist/src/mcpl/inbound-source.js.map +1 -1
- package/dist/src/mcpl/inference-router.d.ts +6 -6
- package/dist/src/mcpl/inference-router.d.ts.map +1 -1
- package/dist/src/mcpl/inference-router.js.map +1 -1
- package/dist/src/mcpl/modern-connection.d.ts +109 -15
- package/dist/src/mcpl/modern-connection.d.ts.map +1 -1
- package/dist/src/mcpl/modern-connection.js +593 -86
- package/dist/src/mcpl/modern-connection.js.map +1 -1
- package/dist/src/mcpl/protocol-family.d.ts +3 -1
- package/dist/src/mcpl/protocol-family.d.ts.map +1 -1
- package/dist/src/mcpl/protocol-family.js +15 -9
- package/dist/src/mcpl/protocol-family.js.map +1 -1
- package/dist/src/mcpl/push-coalescer.d.ts +132 -22
- package/dist/src/mcpl/push-coalescer.d.ts.map +1 -1
- package/dist/src/mcpl/push-coalescer.js +105 -15
- package/dist/src/mcpl/push-coalescer.js.map +1 -1
- package/dist/src/mcpl/push-handler.d.ts +9 -7
- package/dist/src/mcpl/push-handler.d.ts.map +1 -1
- package/dist/src/mcpl/push-handler.js.map +1 -1
- package/dist/src/mcpl/server-connection.d.ts +50 -28
- package/dist/src/mcpl/server-connection.d.ts.map +1 -1
- package/dist/src/mcpl/server-connection.js +165 -72
- package/dist/src/mcpl/server-connection.js.map +1 -1
- package/dist/src/mcpl/tool-classes.d.ts.map +1 -1
- package/dist/src/mcpl/tool-classes.js +3 -0
- package/dist/src/mcpl/tool-classes.js.map +1 -1
- package/dist/src/mcpl/tool-presence.d.ts.map +1 -1
- package/dist/src/mcpl/tool-presence.js +10 -6
- package/dist/src/mcpl/tool-presence.js.map +1 -1
- package/dist/src/mcpl/toolset-host.d.ts.map +1 -1
- package/dist/src/mcpl/toolset-host.js +7 -6
- package/dist/src/mcpl/toolset-host.js.map +1 -1
- package/dist/src/mcpl/toolsets-module.d.ts.map +1 -1
- package/dist/src/mcpl/toolsets-module.js +2 -1
- package/dist/src/mcpl/toolsets-module.js.map +1 -1
- package/dist/src/mcpl/types.d.ts +33 -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 +24 -1
- package/dist/src/module-registry.d.ts.map +1 -1
- package/dist/src/module-registry.js +68 -18
- package/dist/src/module-registry.js.map +1 -1
- package/dist/src/modules/discord/index.d.ts +45 -8
- package/dist/src/modules/discord/index.d.ts.map +1 -1
- package/dist/src/modules/discord/index.js +238 -87
- package/dist/src/modules/discord/index.js.map +1 -1
- package/dist/src/modules/health/index.js +2 -2
- package/dist/src/modules/health/index.js.map +1 -1
- package/dist/src/modules/history/index.d.ts +59 -0
- package/dist/src/modules/history/index.d.ts.map +1 -1
- package/dist/src/modules/history/index.js +432 -67
- package/dist/src/modules/history/index.js.map +1 -1
- package/dist/src/modules/history/semantic.d.ts +6 -5
- package/dist/src/modules/history/semantic.d.ts.map +1 -1
- package/dist/src/modules/history/semantic.js +18 -25
- package/dist/src/modules/history/semantic.js.map +1 -1
- package/dist/src/modules/workspace/disk-agreement.d.ts +1 -1
- package/dist/src/modules/workspace/disk-agreement.js +1 -1
- package/dist/src/modules/workspace/index.d.ts +28 -7
- package/dist/src/modules/workspace/index.d.ts.map +1 -1
- package/dist/src/modules/workspace/index.js +80 -25
- package/dist/src/modules/workspace/index.js.map +1 -1
- package/dist/src/modules/workspace/observe.d.ts.map +1 -1
- package/dist/src/modules/workspace/observe.js +2 -1
- 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 +3 -2
- package/dist/src/modules/workspace/reconcile.js.map +1 -1
- package/dist/src/notice-tags.d.ts +20 -9
- package/dist/src/notice-tags.d.ts.map +1 -1
- package/dist/src/notice-tags.js +20 -9
- package/dist/src/notice-tags.js.map +1 -1
- package/dist/src/operator-log.d.ts +36 -3
- package/dist/src/operator-log.d.ts.map +1 -1
- package/dist/src/operator-log.js +2 -2
- package/dist/src/operator-log.js.map +1 -1
- package/dist/src/presentation.d.ts +747 -0
- package/dist/src/presentation.d.ts.map +1 -0
- package/dist/src/presentation.js +1437 -0
- package/dist/src/presentation.js.map +1 -0
- package/dist/src/prose-drafts.d.ts +15 -11
- package/dist/src/prose-drafts.d.ts.map +1 -1
- package/dist/src/prose-drafts.js +16 -12
- package/dist/src/prose-drafts.js.map +1 -1
- package/dist/src/read-marks.d.ts +192 -0
- package/dist/src/read-marks.d.ts.map +1 -0
- package/dist/src/read-marks.js +242 -0
- package/dist/src/read-marks.js.map +1 -0
- package/dist/src/reasoning-loss.d.ts +5 -0
- package/dist/src/reasoning-loss.d.ts.map +1 -0
- package/dist/src/reasoning-loss.js +8 -0
- package/dist/src/reasoning-loss.js.map +1 -0
- package/dist/src/recovery/offline-branch.d.ts +91 -6
- package/dist/src/recovery/offline-branch.d.ts.map +1 -1
- package/dist/src/recovery/offline-branch.js +277 -32
- package/dist/src/recovery/offline-branch.js.map +1 -1
- package/dist/src/recovery/recover-cli.js +24 -4
- package/dist/src/recovery/recover-cli.js.map +1 -1
- package/dist/src/send-tools.d.ts +5 -9
- package/dist/src/send-tools.d.ts.map +1 -1
- package/dist/src/send-tools.js +40 -7
- package/dist/src/send-tools.js.map +1 -1
- package/dist/src/sent-rows.js +1 -1
- package/dist/src/stored-injections.d.ts +2 -2
- package/dist/src/stored-injections.js +2 -2
- package/dist/src/stored-removal.d.ts +17 -4
- package/dist/src/stored-removal.d.ts.map +1 -1
- package/dist/src/stored-removal.js +29 -5
- package/dist/src/stored-removal.js.map +1 -1
- package/dist/src/supplied-text.d.ts +1 -1
- package/dist/src/supplied-text.js +3 -3
- package/dist/src/supplied-text.js.map +1 -1
- package/dist/src/thinking-drops.d.ts +2 -0
- package/dist/src/thinking-drops.d.ts.map +1 -1
- package/dist/src/thinking-drops.js.map +1 -1
- package/dist/src/tool-presentation.d.ts.map +1 -1
- package/dist/src/tool-presentation.js +38 -9
- package/dist/src/tool-presentation.js.map +1 -1
- package/dist/src/tool-result-guard.d.ts +12 -1
- package/dist/src/tool-result-guard.d.ts.map +1 -1
- package/dist/src/tool-result-guard.js +42 -8
- package/dist/src/tool-result-guard.js.map +1 -1
- package/dist/src/tune-out/coordinator.d.ts +1170 -81
- package/dist/src/tune-out/coordinator.d.ts.map +1 -1
- package/dist/src/tune-out/coordinator.js +3732 -369
- package/dist/src/tune-out/coordinator.js.map +1 -1
- package/dist/src/tune-out/tools.d.ts +114 -17
- package/dist/src/tune-out/tools.d.ts.map +1 -1
- package/dist/src/tune-out/tools.js +89 -28
- package/dist/src/tune-out/tools.js.map +1 -1
- package/dist/src/tune-out/window-anchor.d.ts +143 -0
- package/dist/src/tune-out/window-anchor.d.ts.map +1 -0
- package/dist/src/tune-out/window-anchor.js +202 -0
- package/dist/src/tune-out/window-anchor.js.map +1 -0
- package/dist/src/types/agent.d.ts +121 -25
- package/dist/src/types/agent.d.ts.map +1 -1
- package/dist/src/types/events.d.ts +2 -0
- package/dist/src/types/events.d.ts.map +1 -1
- package/dist/src/types/framework.d.ts +72 -17
- package/dist/src/types/framework.d.ts.map +1 -1
- package/dist/src/types/inference-log.d.ts +1 -0
- package/dist/src/types/inference-log.d.ts.map +1 -1
- package/dist/src/types/module.d.ts +180 -69
- package/dist/src/types/module.d.ts.map +1 -1
- package/dist/src/types/trace.d.ts +573 -39
- package/dist/src/types/trace.d.ts.map +1 -1
- package/package.json +4 -4
- package/src/admission/admit.ts +32 -3
- package/src/agent.ts +392 -132
- package/src/api/mcp-server-core.ts +54 -17
- package/src/api/server.ts +4 -23
- package/src/append-all.ts +6 -0
- package/src/code-execution/isolate/scripts.ts +28 -3
- package/src/config-checks.ts +14 -0
- package/src/context-manager-errors.ts +37 -0
- package/src/context-options.ts +106 -0
- package/src/cut-off-round.ts +4 -4
- package/src/deferred-import.ts +239 -0
- package/src/dendrite/audience.ts +315 -0
- package/src/dendrite/index.ts +14 -2
- package/src/dendrite/presets.ts +18 -6
- package/src/dendrite/registry.ts +213 -14
- package/src/dendrite/types.ts +92 -8
- package/src/failure-text.ts +88 -0
- package/src/foreign-rounds.ts +199 -0
- package/src/framework.ts +8796 -3813
- package/src/gate/event-gate.ts +518 -91
- package/src/gate/index.ts +3 -0
- package/src/gate/reply-judge.ts +12 -3
- package/src/gate/rule-scope.ts +45 -0
- package/src/gate/suppress-script-worker.ts +89 -0
- package/src/gate/suppress-scripts.ts +414 -0
- package/src/gate/suppression-review.ts +517 -0
- package/src/gate/suppression-stats.ts +314 -0
- package/src/gate/types.ts +148 -7
- package/src/gate/wake-onboarding.ts +309 -0
- package/src/heartbeat/heartbeat.ts +1 -1
- package/src/held-writes.ts +49 -60
- package/src/index.ts +10 -2
- package/src/inference-bounds.ts +11 -6
- package/src/jsonrpc-envelope.ts +81 -0
- package/src/mcpl/channel-registry.ts +513 -116
- package/src/mcpl/checkpoint-manager.ts +3 -2
- package/src/mcpl/feature-set-manager.ts +2 -1
- package/src/mcpl/inbound-source.ts +2 -1
- package/src/mcpl/inference-router.ts +7 -4
- package/src/mcpl/modern-connection.ts +629 -91
- package/src/mcpl/protocol-family.ts +15 -9
- package/src/mcpl/push-coalescer.ts +193 -34
- package/src/mcpl/push-handler.ts +10 -5
- package/src/mcpl/server-connection.ts +169 -75
- package/src/mcpl/tool-classes.ts +3 -0
- package/src/mcpl/tool-presence.ts +10 -5
- package/src/mcpl/toolset-host.ts +7 -6
- package/src/mcpl/toolsets-module.ts +2 -1
- package/src/mcpl/types.ts +33 -6
- package/src/module-registry.ts +73 -17
- package/src/modules/discord/index.ts +230 -82
- package/src/modules/health/index.ts +2 -2
- package/src/modules/history/index.ts +439 -70
- package/src/modules/history/semantic.ts +18 -24
- package/src/modules/workspace/disk-agreement.ts +1 -1
- package/src/modules/workspace/index.ts +89 -26
- package/src/modules/workspace/observe.ts +2 -1
- package/src/modules/workspace/reconcile.ts +3 -2
- package/src/notice-tags.ts +21 -9
- package/src/operator-log.ts +36 -3
- package/src/presentation.ts +1678 -0
- package/src/prose-drafts.ts +16 -12
- package/src/read-marks.ts +328 -0
- package/src/reasoning-loss.ts +7 -0
- package/src/recovery/offline-branch.ts +350 -35
- package/src/recovery/recover-cli.ts +23 -4
- package/src/send-tools.ts +40 -7
- package/src/sent-rows.ts +1 -1
- package/src/stored-injections.ts +2 -2
- package/src/stored-removal.ts +31 -7
- package/src/supplied-text.ts +3 -3
- package/src/thinking-drops.ts +2 -0
- package/src/tool-presentation.ts +34 -9
- package/src/tool-result-guard.ts +41 -7
- package/src/tune-out/coordinator.ts +4121 -472
- package/src/tune-out/tools.ts +162 -44
- package/src/tune-out/window-anchor.ts +277 -0
- package/src/types/agent.ts +122 -25
- package/src/types/events.ts +2 -0
- package/src/types/framework.ts +73 -17
- package/src/types/inference-log.ts +1 -0
- package/src/types/module.ts +181 -68
- package/src/types/trace.ts +607 -43
|
@@ -0,0 +1,202 @@
|
|
|
1
|
+
/** The subconscious's window start, set by sequence in legacy mode and by a fixed ordinal once its window is presented. */
|
|
2
|
+
export class SubconsciousWindowAnchor {
|
|
3
|
+
host;
|
|
4
|
+
/**
|
|
5
|
+
* The starts whose ordinal isn't set and kept yet, the one in force
|
|
6
|
+
* (`inForce`) first if it is among them: some row older than a start is
|
|
7
|
+
* still out of the window, or setting or keeping the ordinal it was fixed
|
|
8
|
+
* at (`ordinal`) failed, which the next presentation tries again. A start
|
|
9
|
+
* set by an ordinal already known (`known`) waits only for its setting and
|
|
10
|
+
* keeping: kept for `keep` (none for a start in force only) and as the
|
|
11
|
+
* start in force, traced when clamped (`clampedFrom`, the ordinal kept
|
|
12
|
+
* before).
|
|
13
|
+
*/
|
|
14
|
+
pending = [];
|
|
15
|
+
constructor(host) {
|
|
16
|
+
this.host = host;
|
|
17
|
+
}
|
|
18
|
+
/**
|
|
19
|
+
* Set the window start (the coordinator's setSubconsciousAnchor). In
|
|
20
|
+
* legacy mode by its sequence, as before the index. In presented mode by
|
|
21
|
+
* its ordinal when one was fixed, clamped to the window's index length
|
|
22
|
+
* and traced when past it, the clamped ordinal kept as the start; the
|
|
23
|
+
* strategy's persisted anchor where it is earlier, or, with no ordinal
|
|
24
|
+
* known, where it has one, at a resume that asks for it
|
|
25
|
+
* (keepEarlierAnchor); else by its sequence for now, converted as
|
|
26
|
+
* the strategy converts one, and the ordinal is fixed (see the module
|
|
27
|
+
* doc) as soon as no row the subconscious is owed stored before the start
|
|
28
|
+
* is out of its window, now or at a later presentation (presented). An
|
|
29
|
+
* ordinal set is kept as the start in force once it is set, and tried
|
|
30
|
+
* again at the next presentation until both succeed. The starts of
|
|
31
|
+
* `others`, the other active tune-outs' whose ordinal isn't kept yet, are
|
|
32
|
+
* fixed the same way, without moving the window to them. Never throws: a
|
|
33
|
+
* set that fails is logged, and the anchor stays where it was.
|
|
34
|
+
*/
|
|
35
|
+
set(start, others = []) {
|
|
36
|
+
try {
|
|
37
|
+
const strategy = this.host.strategy();
|
|
38
|
+
if (!strategy)
|
|
39
|
+
return;
|
|
40
|
+
if (!this.host.presents()) {
|
|
41
|
+
this.pending = [];
|
|
42
|
+
strategy.setAnchor(start.sequence);
|
|
43
|
+
return;
|
|
44
|
+
}
|
|
45
|
+
const was = this.pending;
|
|
46
|
+
const carried = (wanted, inForce) => ({
|
|
47
|
+
...(was.find((p) => !p.known && sameStart(p.start, wanted)) ?? { start: wanted }),
|
|
48
|
+
inForce,
|
|
49
|
+
});
|
|
50
|
+
this.pending = others.map((other) => carried(other, false));
|
|
51
|
+
let known = start.ordinal;
|
|
52
|
+
let inForceOnly = start.inForceOnly === true;
|
|
53
|
+
if (start.keepEarlierAnchor) {
|
|
54
|
+
const persisted = persistedOrdinal(strategy);
|
|
55
|
+
if (persisted === null) {
|
|
56
|
+
// Whether the strategy holds an earlier start (a cancelled
|
|
57
|
+
// tune-out's, set and never kept) can't be told: the kept one set
|
|
58
|
+
// over it would drop the rows it held from the window, and be kept
|
|
59
|
+
// in force. The window stays where it was, nothing set or kept in
|
|
60
|
+
// force; the next enter or restart sets it. The others are fixed,
|
|
61
|
+
// and so is the start itself where no ordinal is kept for it,
|
|
62
|
+
// without moving the window to it.
|
|
63
|
+
if (known === undefined)
|
|
64
|
+
this.pending.push(carried(start, false));
|
|
65
|
+
this.tryFix();
|
|
66
|
+
return;
|
|
67
|
+
}
|
|
68
|
+
// With no ordinal kept (one fixed and set whose keeping failed), the
|
|
69
|
+
// persisted anchor is the start this window had, wherever it is: the
|
|
70
|
+
// sequence converted again could give a later one, leaving out a
|
|
71
|
+
// row presented out of record order (AF #844 review 5, #47). The
|
|
72
|
+
// start's own ordinal is fixed beside it, unmoved to.
|
|
73
|
+
if (persisted !== undefined && (known === undefined || persisted < known)) {
|
|
74
|
+
if (known === undefined)
|
|
75
|
+
this.pending.push(carried(start, false));
|
|
76
|
+
known = persisted;
|
|
77
|
+
inForceOnly = true;
|
|
78
|
+
}
|
|
79
|
+
}
|
|
80
|
+
if (known !== undefined) {
|
|
81
|
+
const length = this.host.cm()?.indexLength() ?? 0;
|
|
82
|
+
const ordinal = Math.min(known, length);
|
|
83
|
+
this.pending.unshift({
|
|
84
|
+
start,
|
|
85
|
+
ordinal,
|
|
86
|
+
inForce: true,
|
|
87
|
+
known: { keep: inForceOnly ? [] : start.epochIds, ...(ordinal !== known ? { clampedFrom: known } : {}) },
|
|
88
|
+
});
|
|
89
|
+
}
|
|
90
|
+
else {
|
|
91
|
+
this.pending.unshift(carried(start, true));
|
|
92
|
+
strategy.setAnchor(start.sequence);
|
|
93
|
+
}
|
|
94
|
+
this.tryFix();
|
|
95
|
+
}
|
|
96
|
+
catch (error) {
|
|
97
|
+
console.error(`[tune-out] the subconscious's window start couldn't be set, so it stays where it was:`, error);
|
|
98
|
+
}
|
|
99
|
+
}
|
|
100
|
+
/**
|
|
101
|
+
* The store's branch moved (the framework's followBranchMove, before the
|
|
102
|
+
* agents follow it): an ordinal is a place on the branch it was fixed on,
|
|
103
|
+
* so a start pending at one (its setting or keeping failed), or set by one
|
|
104
|
+
* kept there (`known`), waits again to be fixed, from the window it
|
|
105
|
+
* presents on now, as a start never fixed does (tryFix): one for a
|
|
106
|
+
* tune-out still active (`active`, the coordinator's, where the framework
|
|
107
|
+
* says). One fixed for tune-outs none of which is active any more, and
|
|
108
|
+
* the start in force only (a cancelled tune-out's, set by its kept
|
|
109
|
+
* ordinal: fixed again, it would be the active one's start), are dropped,
|
|
110
|
+
* as every start fixed at an ordinal was before (AF #844 review 3, #30
|
|
111
|
+
* and #44): the anchor the destination's strategy keeps stands until the
|
|
112
|
+
* next enter or restart sets one.
|
|
113
|
+
*/
|
|
114
|
+
branchMoved(active) {
|
|
115
|
+
const holds = active === undefined ? undefined : new Set(active);
|
|
116
|
+
this.pending = this.pending
|
|
117
|
+
.filter((p) => {
|
|
118
|
+
if (p.known && p.known.keep.length === 0)
|
|
119
|
+
return false;
|
|
120
|
+
const fixedThere = p.ordinal !== undefined || p.known !== undefined;
|
|
121
|
+
return !fixedThere || holds === undefined || p.start.epochIds.some((id) => holds.has(id));
|
|
122
|
+
})
|
|
123
|
+
.map((p) => ({ start: p.start, inForce: p.inForce }));
|
|
124
|
+
}
|
|
125
|
+
/** Rows entered the subconscious's window (the presentation index's onPresented): a start waiting to be fixed may be fixable now. */
|
|
126
|
+
presented() {
|
|
127
|
+
if (this.pending.length === 0)
|
|
128
|
+
return;
|
|
129
|
+
try {
|
|
130
|
+
this.tryFix();
|
|
131
|
+
}
|
|
132
|
+
catch (error) {
|
|
133
|
+
console.error(`[tune-out] the subconscious's window start couldn't be fixed at this presentation; the next one tries again:`, error);
|
|
134
|
+
}
|
|
135
|
+
}
|
|
136
|
+
/**
|
|
137
|
+
* Fix each pending start's ordinal, once no row owed and stored before it
|
|
138
|
+
* is out of the window, then set it (the start in force) and keep it;
|
|
139
|
+
* until both succeed a start stays pending at that ordinal. A start set by
|
|
140
|
+
* an ordinal known is set and kept the same way, and traced only when
|
|
141
|
+
* clamped.
|
|
142
|
+
*/
|
|
143
|
+
tryFix() {
|
|
144
|
+
if (this.pending.length === 0 || !this.host.presents())
|
|
145
|
+
return;
|
|
146
|
+
const cm = this.host.cm();
|
|
147
|
+
const strategy = this.host.strategy();
|
|
148
|
+
if (!cm || !strategy)
|
|
149
|
+
return;
|
|
150
|
+
// Read once, and only for a start still to be fixed.
|
|
151
|
+
let owed;
|
|
152
|
+
for (const entry of [...this.pending]) {
|
|
153
|
+
if (entry.ordinal === undefined) {
|
|
154
|
+
owed ??= this.host.owed();
|
|
155
|
+
if (owed.some((row) => row.sequence < entry.start.sequence))
|
|
156
|
+
continue;
|
|
157
|
+
// Just past the last row in the window stored before the start.
|
|
158
|
+
let ordinal = 0;
|
|
159
|
+
for (const row of cm.getPresentedMessages()) {
|
|
160
|
+
if (row.sequence >= entry.start.sequence)
|
|
161
|
+
continue;
|
|
162
|
+
const at = cm.ordinalOf(row.id);
|
|
163
|
+
if (at !== undefined && at + 1 > ordinal)
|
|
164
|
+
ordinal = at + 1;
|
|
165
|
+
}
|
|
166
|
+
entry.ordinal = ordinal;
|
|
167
|
+
}
|
|
168
|
+
const ordinal = entry.ordinal;
|
|
169
|
+
if (entry.inForce)
|
|
170
|
+
strategy.setAnchorOrdinal(ordinal);
|
|
171
|
+
if (!this.host.fixed(entry.known ? entry.known.keep : entry.start.epochIds, ordinal, entry.inForce))
|
|
172
|
+
continue;
|
|
173
|
+
this.pending = this.pending.filter((p) => p !== entry);
|
|
174
|
+
if (!entry.known) {
|
|
175
|
+
this.host.emitTrace({
|
|
176
|
+
type: 'tune-out:subconscious-window', agentName: this.host.agentName,
|
|
177
|
+
epochIds: [...entry.start.epochIds], how: 'fixed', ordinal,
|
|
178
|
+
});
|
|
179
|
+
}
|
|
180
|
+
else if (entry.known.clampedFrom !== undefined) {
|
|
181
|
+
this.host.emitTrace({
|
|
182
|
+
type: 'tune-out:subconscious-window', agentName: this.host.agentName,
|
|
183
|
+
epochIds: [...entry.start.epochIds], how: 'clamped', ordinal, kept: entry.known.clampedFrom,
|
|
184
|
+
});
|
|
185
|
+
}
|
|
186
|
+
}
|
|
187
|
+
}
|
|
188
|
+
}
|
|
189
|
+
/** The anchor the strategy persisted, as an ordinal: undefined where it persisted none, null where it can't be read. */
|
|
190
|
+
function persistedOrdinal(strategy) {
|
|
191
|
+
try {
|
|
192
|
+
return strategy.getAnchorOrdinal();
|
|
193
|
+
}
|
|
194
|
+
catch (error) {
|
|
195
|
+
console.error(`[tune-out] the subconscious's persisted window start couldn't be read, so the window start stays where it was; the next enter or restart sets it:`, error);
|
|
196
|
+
return null;
|
|
197
|
+
}
|
|
198
|
+
}
|
|
199
|
+
function sameStart(a, b) {
|
|
200
|
+
return a.sequence === b.sequence && a.epochIds.length === b.epochIds.length && a.epochIds.every((id) => b.epochIds.includes(id));
|
|
201
|
+
}
|
|
202
|
+
//# sourceMappingURL=window-anchor.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"window-anchor.js","sourceRoot":"","sources":["../../../src/tune-out/window-anchor.ts"],"names":[],"mappings":"AAoFA,2HAA2H;AAC3H,MAAM,OAAO,wBAAwB;IAkBN,IAAI;IAjBjC;;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,EAAE,GAAG,EAAE,SAAS,EAAE,OAAO,EAAE,IAAI,EAAE,KAAK,CAAC,KAAK,CAAC,WAAW;iBAC5F,CAAC,CAAC;YACL,CAAC;QACH,CAAC;IACH,CAAC;CACF;AAED,wHAAwH;AACxH,SAAS,gBAAgB,CAAC,QAA0B;IAClD,IAAI,CAAC;QACH,OAAO,QAAQ,CAAC,gBAAgB,EAAE,CAAC;IACrC,CAAC;IAAC,OAAO,KAAK,EAAE,CAAC;QACf,OAAO,CAAC,KAAK,CAAC,mJAAmJ,EAAE,KAAK,CAAC,CAAC;QAC1K,OAAO,IAAI,CAAC;IACd,CAAC;AACH,CAAC;AAED,SAAS,SAAS,CAAC,CAA0B,EAAE,CAA0B;IACvE,OAAO,CAAC,CAAC,QAAQ,KAAK,CAAC,CAAC,QAAQ,IAAI,CAAC,CAAC,QAAQ,CAAC,MAAM,KAAK,CAAC,CAAC,QAAQ,CAAC,MAAM,IAAI,CAAC,CAAC,QAAQ,CAAC,KAAK,CAAC,CAAC,EAAE,EAAE,EAAE,CAAC,CAAC,CAAC,QAAQ,CAAC,QAAQ,CAAC,EAAE,CAAC,CAAC,CAAC;AACnI,CAAC"}
|
|
@@ -200,11 +200,15 @@ export interface AgentConfig {
|
|
|
200
200
|
* counts it. After a fold, each block after the stretch it rewrote is
|
|
201
201
|
* bound to a conversation the request no longer holds. Where the context
|
|
202
202
|
* strategy still sends such a block, the provider drops it on every call
|
|
203
|
-
* until a later fold takes it out of the context,
|
|
204
|
-
*
|
|
205
|
-
*
|
|
206
|
-
*
|
|
207
|
-
*
|
|
203
|
+
* until a later fold takes it out of the context, or, with `binds` set
|
|
204
|
+
* too, until the next compile after a note lands: the stream tells the
|
|
205
|
+
* context manager which stored reply's thinking was dropped
|
|
206
|
+
* (`noteThinkingDropped`), and once a note lands, the next compile sends
|
|
207
|
+
* that reply without it. While such blocks are sent,
|
|
208
|
+
* no stream gives a sample and the calibration keeps the value it had. A
|
|
209
|
+
* strategy that leaves that thinking out at the fold sends none to drop.
|
|
210
|
+
* The direct API carries the control too, but reads no report: it traces
|
|
211
|
+
* no usage, feeds no calibration and notes nothing.
|
|
208
212
|
*
|
|
209
213
|
* Default false: nothing is sent, and the account's default applies.
|
|
210
214
|
*/
|
|
@@ -228,6 +232,11 @@ export interface AgentConfig {
|
|
|
228
232
|
* thinking is kept at the next compile. The direct API
|
|
229
233
|
* (`runInference`) notes nothing, so each of its replies' thinking is
|
|
230
234
|
* left out at the compile after it's stored;
|
|
235
|
+
* - with `dropBlock` set too, each framework stream tells the context
|
|
236
|
+
* manager which stored replies' thinking the provider reports dropping
|
|
237
|
+
* (`noteThinkingDropped`), naming the compile it was built from, so
|
|
238
|
+
* once a note lands, the next compile sends those replies without their
|
|
239
|
+
* thinking;
|
|
231
240
|
* - with `physicalWindowTokens` set too, `maxStreamTokens` no longer
|
|
232
241
|
* starts a new stream mid-turn, since the new stream's compile can take
|
|
233
242
|
* the turn's earlier reasoning out of the request;
|
|
@@ -307,8 +316,28 @@ export interface AgentConfig {
|
|
|
307
316
|
* - 'disabled': generated prose is never published. Only explicit tools may
|
|
308
317
|
* send externally; prose remains in Chronicle, and a turn that wrote plain
|
|
309
318
|
* speech ends with a private `[delivered] plain speech → no channel` receipt.
|
|
319
|
+
* - 'locked': unprefixed prose goes to one destination the agent chose, on
|
|
320
|
+
* every turn, and nothing moves it automatically: not the channel that
|
|
321
|
+
* woke the turn, not an addressed message, a heartbeat or channel_open.
|
|
322
|
+
* Only the `prose_locus` tool moves it, to a channel or to drafts (held,
|
|
323
|
+
* never posted unless the agent resends them). The choice persists
|
|
324
|
+
* across turns and restarts. Until the agent first makes one,
|
|
325
|
+
* `proseLock` is the destination. It governs routing through the channel
|
|
326
|
+
* registry: a module that handles final speech itself (`onAgentSpeech`,
|
|
327
|
+
* such as the in-process Discord module) receives it in every mode, this
|
|
328
|
+
* one included. See docs/locked-prose-routing.md.
|
|
310
329
|
*/
|
|
311
|
-
proseRouting?: 'locus' | 'explicit' | 'hybrid' | 'disabled';
|
|
330
|
+
proseRouting?: 'locus' | 'explicit' | 'hybrid' | 'disabled' | 'locked';
|
|
331
|
+
/**
|
|
332
|
+
* Locked mode's destination until the agent chooses one with `prose_locus`:
|
|
333
|
+
* `"#channel"`, `"@person"`, a channel id, or `"drafts"`. Resolved as a
|
|
334
|
+
* `>>` target is, at each turn's start, so a channel its server hasn't
|
|
335
|
+
* registered yet resolves once it has; until it resolves, plain speech is
|
|
336
|
+
* held as drafts. Left out, plain speech is held as drafts until the agent
|
|
337
|
+
* chooses. The agent's own choice, once made, takes its place. Ignored in
|
|
338
|
+
* the other modes.
|
|
339
|
+
*/
|
|
340
|
+
proseLock?: string;
|
|
312
341
|
/**
|
|
313
342
|
* Stored participants that are this agent's own voice, in addition to its
|
|
314
343
|
* name: their turns are presented to the model as this agent's assistant
|
|
@@ -395,6 +424,52 @@ export interface AgentConfig {
|
|
|
395
424
|
* view.
|
|
396
425
|
*/
|
|
397
426
|
clock?: import('../clock-rows.js').ClockConfig;
|
|
427
|
+
/**
|
|
428
|
+
* Keep the rows that open a turn raw for the whole turn (on when left out):
|
|
429
|
+
* at a start that opens a turn, the framework pins raw the rows of the
|
|
430
|
+
* agent's window after its newest own message and its consumed mark
|
|
431
|
+
* (`pinRange`, named `agent-framework:turn-inputs`; the README says
|
|
432
|
+
* which rows exactly), and removes the pin when the turn ends, so the
|
|
433
|
+
* strategy doesn't compress the rows the turn opened with while it runs,
|
|
434
|
+
* unless a committing compile refuses as over budget with it held: the
|
|
435
|
+
* pin is then removed and the compile runs once more (README). `false` places no pin:
|
|
436
|
+
* the turn's opening rows are compressed as any others, and a pin of the
|
|
437
|
+
* name left from before (a crash's) is removed at the next start that opens
|
|
438
|
+
* a turn, as a silent start removes one.
|
|
439
|
+
*/
|
|
440
|
+
turnInputsPin?: boolean;
|
|
441
|
+
/**
|
|
442
|
+
* The other configured agents whose own rows this agent's window takes
|
|
443
|
+
* (none when left out). Residents share one slot, and each is shown only
|
|
444
|
+
* its own rows and the rows meant for it: another resident's rounds,
|
|
445
|
+
* replies, tool results and notes stay out of its window (#291, decision
|
|
446
|
+
* 1; rows an earlier release stored carry no stamp and stay in the window
|
|
447
|
+
* written down from the record: 291-presentation-mandatory). A name here
|
|
448
|
+
* is an observe edge in this agent's registry record, on
|
|
449
|
+
* that agent (`{ agent: name }`, the path the subconscious's edge takes),
|
|
450
|
+
* and the presentation index presents that agent's own rows to this one
|
|
451
|
+
* at its points, as it does any arrival (bearingOf); the history tools
|
|
452
|
+
* leave them in for its calls (ModuleContext.observes). That agent's own
|
|
453
|
+
* rows this one's window doesn't hold yet, those stored before the edge
|
|
454
|
+
* was declared included, enter it at its next presentation point, after
|
|
455
|
+
* what it holds: an edge declared on a store with history hands the
|
|
456
|
+
* observer that agent's earlier rows at once, at the end of its window
|
|
457
|
+
* (`ObserveEdge.fromMessageId`, which would start the edge at a row, is
|
|
458
|
+
* read by nothing yet). Only own rows: mail and channel traffic meant for that agent, and its stored
|
|
459
|
+
* context injections, stay out. One way: `nova` observing `mira` shows
|
|
460
|
+
* nova mira's rows, not mira nova's. `create()` refuses a name that is
|
|
461
|
+
* this agent's own or no configured agent's. Read when a configured agent
|
|
462
|
+
* is created; a derived agent's spec carries its own edges.
|
|
463
|
+
*/
|
|
464
|
+
observes?: string[];
|
|
465
|
+
/**
|
|
466
|
+
* How the rounds of an agent it observes (`observes`) go out in this
|
|
467
|
+
* agent's requests, as `PersistentReaderConfig.foreignRounds` for the
|
|
468
|
+
* persistent subconscious: `'transcript'` (the default), a line per tool
|
|
469
|
+
* call and per result and none of their thinking, or `'raw'`, as stored.
|
|
470
|
+
* Unread for an agent that observes no one.
|
|
471
|
+
*/
|
|
472
|
+
foreignRounds?: 'transcript' | 'raw';
|
|
398
473
|
}
|
|
399
474
|
/** The intentionally small set of agent settings that may change in-process. */
|
|
400
475
|
export interface AgentRuntimeSettingsPatch {
|
|
@@ -555,22 +630,19 @@ export interface InferenceRequest {
|
|
|
555
630
|
* all of them without materializing content, the turn has no cause left
|
|
556
631
|
* and does not run. */
|
|
557
632
|
coalescingBatchSubjects?: string[];
|
|
558
|
-
/** Host-owned: this wake's sole cause is this
|
|
559
|
-
*
|
|
633
|
+
/** Host-owned: this wake's sole cause is this row, by the stored row's
|
|
634
|
+
* id: one stored for its agent as it arrived, or one stored and not
|
|
635
|
+
* presented to its agent at its write, because a turn of the agent's was
|
|
636
|
+
* alive: a coalesced render its turn being assembled doesn't read
|
|
560
637
|
* (wakeToRead), or a message, notice or event whose wake was queued with
|
|
561
|
-
* it. Once a request that carried the
|
|
562
|
-
*
|
|
563
|
-
*
|
|
564
|
-
*
|
|
565
|
-
*
|
|
566
|
-
|
|
567
|
-
|
|
568
|
-
|
|
569
|
-
* request that carried the message was answered and, for a wake that
|
|
570
|
-
* carries a channel and isn't marked `ambient`, the agent has since
|
|
571
|
-
* published into that channel having read it, or once the message isn't
|
|
572
|
-
* on its store's current branch, the wake starts no turn. */
|
|
573
|
-
readsStoredMessage?: string;
|
|
638
|
+
* it. Once a request that carried the row was answered (an answered
|
|
639
|
+
* request's consumed watermark covers it, in the agent's window once its
|
|
640
|
+
* context presents rows) and, for a wake that carries a channel and isn't
|
|
641
|
+
* marked `ambient`, the agent has since published into that channel
|
|
642
|
+
* having read it, or once the row is not on its store's current branch,
|
|
643
|
+
* the wake starts no turn. A row stored and not yet presented to the
|
|
644
|
+
* agent keeps its wake. */
|
|
645
|
+
readsRow?: string;
|
|
574
646
|
agentName: string;
|
|
575
647
|
reason: string;
|
|
576
648
|
source: string;
|
|
@@ -630,10 +702,9 @@ export interface InferenceRequest {
|
|
|
630
702
|
* (`chat:ambient`). A coalesced push's wake carries it only to read a
|
|
631
703
|
* render, and only when every notice the render stands for was. Such a
|
|
632
704
|
* message asked nothing of the agent, so a wake for it that carries
|
|
633
|
-
* `
|
|
634
|
-
*
|
|
635
|
-
*
|
|
636
|
-
* addressed one.
|
|
705
|
+
* `readsRow` is dropped once a request that carried the message
|
|
706
|
+
* was answered, with no publish asked of the agent. A message with neither
|
|
707
|
+
* tag is in doubt, and is judged as an addressed one.
|
|
637
708
|
*/
|
|
638
709
|
ambient?: true;
|
|
639
710
|
/**
|
|
@@ -664,6 +735,31 @@ export interface InferenceRequest {
|
|
|
664
735
|
* channel (ambient-only batches leave it unset).
|
|
665
736
|
*/
|
|
666
737
|
wakeChannelId?: string;
|
|
738
|
+
/**
|
|
739
|
+
* Framework-set on a gate wake whose batch held no message that addressed
|
|
740
|
+
* the agent, and which so took no route: the channels its messages came
|
|
741
|
+
* from (a `chat:system` notice names none, unless it's a coalesced
|
|
742
|
+
* render's latest occurrence), each once. A start merged from several
|
|
743
|
+
* requests carries every one's channels, or, when any of them comes from
|
|
744
|
+
* outside the framework, isn't a silent heartbeat tick and brought
|
|
745
|
+
* channels, only those requests' channels. A request a quiesce keeps in
|
|
746
|
+
* another's place, and one a provider hold takes another into, carry both
|
|
747
|
+
* requests' channels.
|
|
748
|
+
* The framework's own wakes that continue a
|
|
749
|
+
* turn (a restart, a re-inference, a continuation, a retry, a bounce, a
|
|
750
|
+
* re-arm), unless its own wake named a channel that resolves to none,
|
|
751
|
+
* carry the channels the turn's starts gathered, whether or not the turn
|
|
752
|
+
* had a locus, so a turn's trigger can name channels from several batches,
|
|
753
|
+
* and a turn they open with no locus can name them too.
|
|
754
|
+
* When such a turn's plain speech, or a sleep's announcement, is routed
|
|
755
|
+
* with no locus, the agent is told these channels, unless the turn's own
|
|
756
|
+
* wake named a channel that resolves to none, or the turn is an ephemeral
|
|
757
|
+
* run's, which is told nothing.
|
|
758
|
+
*/
|
|
759
|
+
wakeChannels?: Array<{
|
|
760
|
+
serverId: string;
|
|
761
|
+
channelId: string;
|
|
762
|
+
}>;
|
|
667
763
|
/** Timestamp of the event the wake provenance was taken from (ms). */
|
|
668
764
|
wakeAt?: number;
|
|
669
765
|
/** Batched-wake lines the gate handed to this wake rather than wrote
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"agent.d.ts","sourceRoot":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a,CAAC,EAAE,OAAO,CAAC;IACxB;;;;;;OAMG;IACH,SAAS,CAAC,EAAE,OAAO,CAAC;IACpB;;;;;;;;OAQG;IACH,OAAO,CAAC,EAAE,IAAI,CAAC;IACf;;;;;;;;OAQG;IACH,YAAY,CAAC,EAAE,IAAI,CAAC;IACpB;;;;;;OAMG;IACH,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB;;;;;;;;OAQG;IACH,aAAa,CAAC,EAAE,MAAM,CAAC;IACvB;;;;;;;;;;;;;;;;;;;;OAoBG;IACH,YAAY,CAAC,EAAE,KAAK,CAAC;QAAE,QAAQ,EAAE,MAAM,CAAC;QAAC,SAAS,EAAE,MAAM,CAAA;KAAE,CAAC,CAAC;IAC9D,sEAAsE;IACtE,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB;;;;wBAIoB;IACpB,SAAS,CAAC,EAAE,QAAQ,EAAE,CAAC;IACvB;mFAC+E;IAC/E,aAAa,CAAC,EAAE,OAAO,CAAC;IACxB;;;;6DAIyD;IACzD,eAAe,CAAC,EAAE,mBAAmB,CAAC;CACvC"}
|
|
@@ -315,6 +315,8 @@ export interface ToolCall {
|
|
|
315
315
|
* Converted from wire-format McplContentBlock to membrane ContentBlock.
|
|
316
316
|
*/
|
|
317
317
|
export interface McplPushEvent {
|
|
318
|
+
/** The occurrence's suppression, when a coalesced push's wake decided it (CoalescedOccurrence.suppressionDecision). */
|
|
319
|
+
suppressionDecision?: string | null;
|
|
318
320
|
type: 'mcpl:push-event';
|
|
319
321
|
serverId: string;
|
|
320
322
|
featureSet: string;
|
|
@@ -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,MA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AAE,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"}
|
|
@@ -163,16 +163,14 @@ export interface FrameworkConfig {
|
|
|
163
163
|
*/
|
|
164
164
|
subconscious?: import('../tune-out/tools.js').SubconsciousConfig;
|
|
165
165
|
/**
|
|
166
|
-
* Tune-out
|
|
167
|
-
*
|
|
168
|
-
*
|
|
169
|
-
*
|
|
170
|
-
* a reader
|
|
171
|
-
*
|
|
166
|
+
* Tune-out settings. Residents are offered `tune_out` only with a reader
|
|
167
|
+
* (`subconscious`), or while a hold a failed release left is still on
|
|
168
|
+
* record to check or cancel: a hold nothing summarizes would hand the resident an
|
|
169
|
+
* undated backlog all at once when it ends. `enabled`, which offered one
|
|
170
|
+
* without a reader, was removed in 0.33.0: `enabled: true` is refused at
|
|
171
|
+
* `create` (`false` is still accepted, from JavaScript, and does nothing).
|
|
172
172
|
*/
|
|
173
173
|
tuneOut?: {
|
|
174
|
-
/** Offer `tune_out` without a subconscious. Default: only with one. */
|
|
175
|
-
enabled?: boolean;
|
|
176
174
|
/**
|
|
177
175
|
* Announce the all-except scope in the excepted channel: one bracketed
|
|
178
176
|
* line under the resident's name when it opens (who, for how long) and
|
|
@@ -186,16 +184,23 @@ export interface FrameworkConfig {
|
|
|
186
184
|
* (architecture channel, 2026-10-06: the §3 carve-out accepted by the
|
|
187
185
|
* residents).
|
|
188
186
|
*
|
|
189
|
-
* - `'delivery'` (default): the locus comes
|
|
190
|
-
*
|
|
191
|
-
*
|
|
192
|
-
*
|
|
193
|
-
*
|
|
187
|
+
* - `'delivery'` (default): the locus comes from the delivery that woke
|
|
188
|
+
* the turn, a conversation fork's home channel, or a channel the agent
|
|
189
|
+
* opened during the turn, and past those only from an open all-except
|
|
190
|
+
* hold's channel or `unpromptedChannel` (below), each for the turns that
|
|
191
|
+
* take it. Incoming traffic never moves it — not between turns, not
|
|
192
|
+
* mid-turn. A turn with no such locus keeps its prose private, and says
|
|
193
|
+
* so in a `[routing]` notice.
|
|
194
194
|
* - `'latest-inbound'`: the previous rule. The most recent delivered
|
|
195
195
|
* inbound message is a global fallback locus for turns without one, and
|
|
196
196
|
* an addressed message injected mid-turn re-pins the turn's locus.
|
|
197
197
|
*
|
|
198
|
-
* Held traffic never moves the locus under either rule.
|
|
198
|
+
* Held traffic never moves the locus under either rule. Under either, a
|
|
199
|
+
* turn the agent's own timer starts takes `unpromptedChannel` where it's
|
|
200
|
+
* set, after an all-except hold's channel and before both rules' own
|
|
201
|
+
* fallbacks. Neither rule applies to an agent under locked prose routing
|
|
202
|
+
* (AgentConfig.proseRouting 'locked'): its turns speak at its lock,
|
|
203
|
+
* whatever arrives.
|
|
199
204
|
*/
|
|
200
205
|
speech?: {
|
|
201
206
|
locus?: 'delivery' | 'latest-inbound';
|
|
@@ -227,9 +232,29 @@ export interface FrameworkConfig {
|
|
|
227
232
|
*/
|
|
228
233
|
hostModePath?: string;
|
|
229
234
|
/**
|
|
230
|
-
*
|
|
231
|
-
*
|
|
232
|
-
*
|
|
235
|
+
* Where a release before #291 kept its durable queue of deferred context
|
|
236
|
+
* writes. Defaults to `<storePath>/recovery/deferred-writes.json`; without
|
|
237
|
+
* either, the store's `framework/deferred-writes` slot. This release keeps
|
|
238
|
+
* no durable queue: a write is stored when it is made, and enters each
|
|
239
|
+
* agent's window at that agent's presentation points. Two holds keep a
|
|
240
|
+
* write in memory instead, and a crash loses it: a live operator surgery
|
|
241
|
+
* (a rollback, a suppression, a branch switch), until its release stores
|
|
242
|
+
* it, and an agent's context manager refusing its work after a failed
|
|
243
|
+
* re-initialization, until a branch move (switchBranch, a rollback or a
|
|
244
|
+
* suppression) re-initializes it.
|
|
245
|
+
*
|
|
246
|
+
* create() reads the record once and stores its writes. A write for an
|
|
247
|
+
* agent no longer registered goes to the primary when it is a failed
|
|
248
|
+
* reply, a channel notice its reader could act on, or a module's write
|
|
249
|
+
* for a run or a fork, and is dropped otherwise, logged. It then rewrites
|
|
250
|
+
* the record with what it left for the next boot: a write it couldn't
|
|
251
|
+
* store, or couldn't tell had already landed, with that agent's later
|
|
252
|
+
* writes. A write the store refuses as malformed is dropped, logged, as an
|
|
253
|
+
* earlier release's flush dropped it. When the store doesn't sync after
|
|
254
|
+
* the import, the record is left as it was.
|
|
255
|
+
*
|
|
256
|
+
* @deprecated Read once at boot by the deferred-write importer; removed in
|
|
257
|
+
* the next release.
|
|
233
258
|
*/
|
|
234
259
|
deferredWritesPath?: string;
|
|
235
260
|
/**
|
|
@@ -446,6 +471,34 @@ export interface FrameworkConfig {
|
|
|
446
471
|
* `default`) refuses that request the same way, naming the feature set.
|
|
447
472
|
*/
|
|
448
473
|
inferenceRouting?: InferenceRoutingPolicy;
|
|
474
|
+
/**
|
|
475
|
+
* The channel for a turn the agent's own timer starts, which no message
|
|
476
|
+
* prompted: the wake `skip_reply` schedules, or the end of a `sleep`. Plain
|
|
477
|
+
* speech in locus or hybrid prose routing goes there, and so does
|
|
478
|
+
* `channel_publish` naming no channel in any prose routing mode but locked,
|
|
479
|
+
* which servers are told as the turn's default outgoing channel. An
|
|
480
|
+
* all-except hold's channel still comes first while one is open, and without
|
|
481
|
+
* the setting such a turn follows `speech.locus`. A turn the framework opens
|
|
482
|
+
* to continue such a turn that had no locus of its own, as in explicit or
|
|
483
|
+
* disabled routing, takes it too: a `!` continuation, autoContinue's next
|
|
484
|
+
* turn, or a bounced reply's wake. No other turn takes it: not one a message
|
|
485
|
+
* prompted, from a channel, a module, a person at a console or another agent;
|
|
486
|
+
* not a heartbeat's or a reminder's (its plain speech is held as drafts); not
|
|
487
|
+
* a conversation fork's or an ephemeral run's; not a locked agent's, which
|
|
488
|
+
* speaks at its lock or holds its speech as drafts; and not a start merged
|
|
489
|
+
* from a timer's wake and any other cause. One value, for every agent on the
|
|
490
|
+
* framework. A registered channel's id, e.g. `discord:{guildId}:{channelId}`,
|
|
491
|
+
* or, to pick one server's where two register that id,
|
|
492
|
+
* `{serverId}:{channelId}`. `create()` refuses a value that is neither a
|
|
493
|
+
* string nor null, or is blank; null reads as not set. A value that names no
|
|
494
|
+
* registered channel, several, or one its server declared inbound-only, when
|
|
495
|
+
* a turn would take it, is logged, and logged again only after a turn has
|
|
496
|
+
* used it since; the turn takes what it would without the setting.
|
|
497
|
+
* `channel_publish`'s description adds a default for such turns only on a
|
|
498
|
+
* framework with an event gate, the only one with such turns; on any other
|
|
499
|
+
* the description is as it is without the setting.
|
|
500
|
+
*/
|
|
501
|
+
unpromptedChannel?: string | null;
|
|
449
502
|
/** EventGate config. If omitted, all events trigger inference (unchanged default). */
|
|
450
503
|
gate?: GateOptions;
|
|
451
504
|
/**
|
|
@@ -602,6 +655,8 @@ export interface InferenceLogEntry {
|
|
|
602
655
|
success: boolean;
|
|
603
656
|
/** Why it didn't succeed: the failure's message, or what stopped it */
|
|
604
657
|
error?: string;
|
|
658
|
+
/** `error` in the framework's words, with no provider's text: what an agent may be shown of it */
|
|
659
|
+
errorWords?: string;
|
|
605
660
|
/** Request data or blob ID if large. A stream the framework ended at a
|
|
606
661
|
* tool boundary (stopReason 'turn_ended', 'context_budget' or
|
|
607
662
|
* 'physical_window') records a note in place of the body. */
|