diff options
| author | T <t@tjp.lol> | 2026-05-27 06:25:52 -0600 |
|---|---|---|
| committer | T <t@tjp.lol> | 2026-05-27 07:02:47 -0600 |
| commit | eddebe4e8131b7d2112b067fed07e7493d8b1984 (patch) | |
| tree | 21cc58822aa4e99d55d082444c2347c15101bfe1 /libpanto/src/agent.zig | |
| parent | 1f0915edbe0213e8bc134922f10933468d35a172 (diff) | |
Stream OpenAI tool_use as discrete blocks; drop BlockMeta
Close each tool_use on next-index delta (and at finalize) so receivers
see one start/delta/complete trio per tool, matching Anthropic. Log+drop
fragments for already-closed indices.
Remove BlockMeta from the Receiver interface: tool id/name can't be
reliably known at onBlockStart under OpenAI's streaming model. Receivers
get identity from the assembled ContentBlock at onBlockComplete. CLI
renders 'tool: {args} : (name)' accordingly.
Diffstat (limited to 'libpanto/src/agent.zig')
| -rw-r--r-- | libpanto/src/agent.zig | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/libpanto/src/agent.zig b/libpanto/src/agent.zig index 55396d1..6c970ad 100644 --- a/libpanto/src/agent.zig +++ b/libpanto/src/agent.zig @@ -586,7 +586,7 @@ const NoopReceiver = struct { .onError = noop6, }; fn noop1(_: *anyopaque, _: conversation.MessageRole) anyerror!void {} - fn noop2(_: *anyopaque, _: provider_mod.ContentBlockType, _: usize, _: ?provider_mod.BlockMeta) anyerror!void {} + fn noop2(_: *anyopaque, _: provider_mod.ContentBlockType, _: usize) anyerror!void {} fn noop3(_: *anyopaque, _: usize, _: []const u8) anyerror!void {} fn noop4(_: *anyopaque, _: usize, _: conversation.ContentBlock) anyerror!void {} fn noop5(_: *anyopaque, _: conversation.Message) anyerror!void {} |
