diff options
| author | t <t@tjp.lol> | 2026-07-02 10:29:53 -0600 |
|---|---|---|
| committer | t <t@tjp.lol> | 2026-07-03 12:10:09 -0600 |
| commit | c4d7f70ff831cfcdad0f2a6224f9a14f86905de6 (patch) | |
| tree | 89dac8fb213dc6dcd2612a5ff6974d5013dcdb63 /src/main.zig | |
| parent | 800b2c4b6115845f6bf15d90484b3e80e81a606f (diff) | |
Stage and apply event-field overrides at tool lifecycle boundaries
Stage writable event-field overrides by tool call id so they can be applied at the correct point in the turn lifecycle. Capture input overrides from tool_call_complete, capture output overrides from tool_result, and clear staged overrides defensively at turn start and shutdown.
Also honor user_message text overrides when starting a turn, add the helper that applies staged overrides to the agent at dispatch boundaries, and cover the behavior with tests for staged input/output overrides.
Diffstat (limited to 'src/main.zig')
| -rw-r--r-- | src/main.zig | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/main.zig b/src/main.zig index 86f1cb1..02c0045 100644 --- a/src/main.zig +++ b/src/main.zig @@ -383,6 +383,10 @@ pub fn main(init: std.process.Init) !void { // any extension loads (which `require('panto')`). try rt.installPantoModule(); + // Hand extensions the live session agent (`panto.ext.agent`) so an + // `activate()` can act on the session directly (add_system_messageā¦). + try rt.setExtAgent(agent); + // luv is installed (or already present) at this point; wire the // libuv-driven coroutine scheduler before any extensions get a // chance to register tools that might want to yield. |
