Commit 3a24274
committed
fix(providers): Sakana streaming usage + filtered-tools stream guard
- Pass stream_options: { include_usage: true } on both streaming calls so
token/cost data is captured (the shared OpenAI-compatible stream helper
only fills usage from chunk usage, which the API omits without the flag).
- Include !hasActiveTools in the early-stream guard so requests whose tools
are all filtered out (e.g. usageControl 'none') still take the fast
streaming path instead of the tool-loop path. Mirrors LiteLLM.1 parent 8d4acba commit 3a24274
1 file changed
Lines changed: 3 additions & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
130 | 130 | | |
131 | 131 | | |
132 | 132 | | |
133 | | - | |
| 133 | + | |
134 | 134 | | |
135 | 135 | | |
136 | 136 | | |
137 | 137 | | |
138 | 138 | | |
139 | 139 | | |
| 140 | + | |
140 | 141 | | |
141 | 142 | | |
142 | 143 | | |
| |||
452 | 453 | | |
453 | 454 | | |
454 | 455 | | |
| 456 | + | |
455 | 457 | | |
456 | 458 | | |
457 | 459 | | |
| |||
0 commit comments