Commit 78d4036
committed
fix(parsers): codex/gemini/opencode parsers emit ToolCall/ToolResult from native wire shapes (v0.1.11)
The codex, gemini, and opencode session-backend parsers accepted the
upstream wire shapes for tool calls but silently dropped them. Real
users running tool-using agents through these provider plugins saw no
ToolCall/ToolResult events in the daemon or UI even though the calls
were happening.
This fix wires each parser to translate the native wire shape into
SessionEvent::ToolCall / SessionEvent::ToolResult:
- codex: item.added / item.delta / item.completed for function_call
items, with arguments-string accumulation across deltas; function
call output items translate to ToolResult. Parser is now per-session
stateful (CodexParser struct) so streaming-arg accumulation is
isolated between concurrent sessions.
- gemini: top-level functionCall / functionResponse events, plus
partialResult.candidates[..].content.parts[..].functionCall|response
for the streaming candidate-parts shape.
- opencode: tool_use / tool_result events.
Tests added (11 new, all green): per-provider coverage of the basic
tool_call shape, the result shape, parallel tool calls (codex),
streaming-arg accumulation (codex), candidate-parts extraction
(gemini), and the existing text path stays unchanged (opencode).
v0.1.10 -> v0.1.11. Workspace + all path-dep pins bumped. Purely
additive: existing SessionEvent variants are unchanged; the parsers
just emit more of them now.1 parent 653a8a8 commit 78d4036
13 files changed
Lines changed: 552 additions & 64 deletions
File tree
- animus-control-protocol
- animus-log-storage-protocol
- animus-plugin-runtime
- animus-provider-protocol
- animus-session-backend
- src/session
- codex
- gemini
- opencode
- animus-subject-protocol
- animus-transport-protocol
- animus-trigger-protocol
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
13 | 13 | | |
14 | 14 | | |
15 | 15 | | |
16 | | - | |
| 16 | + | |
17 | 17 | | |
18 | 18 | | |
19 | 19 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
18 | 18 | | |
19 | 19 | | |
20 | 20 | | |
21 | | - | |
22 | | - | |
23 | | - | |
24 | | - | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
25 | 25 | | |
26 | 26 | | |
27 | 27 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
10 | 10 | | |
11 | 11 | | |
12 | 12 | | |
13 | | - | |
| 13 | + | |
14 | 14 | | |
15 | 15 | | |
16 | 16 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
10 | 10 | | |
11 | 11 | | |
12 | 12 | | |
13 | | - | |
14 | | - | |
15 | | - | |
16 | | - | |
17 | | - | |
18 | | - | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
19 | 19 | | |
20 | 20 | | |
21 | 21 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
10 | 10 | | |
11 | 11 | | |
12 | 12 | | |
13 | | - | |
| 13 | + | |
14 | 14 | | |
15 | 15 | | |
16 | 16 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
10 | 10 | | |
11 | 11 | | |
12 | 12 | | |
13 | | - | |
| 13 | + | |
14 | 14 | | |
15 | 15 | | |
16 | 16 | | |
| |||
0 commit comments