claw-code-parity/rust/crates
Yeachan-Heo 5f1eddf03a Preserve usage accounting on OpenAI SSE streams
OpenAI chat-completions streams can emit a final usage chunk when the\nclient opts in, but the Rust transport was not requesting it. This\nkeeps provider config on the client and adds stream_options.include_usage\nonly for OpenAI streams so normalized message_delta usage reflects the\ntransport without changing xAI request bodies.\n\nConstraint: Keep xAI request bodies unchanged because provider-specific streaming knobs may differ\nRejected: Enable stream_options for every OpenAI-compatible provider | risks sending unsupported params to xAI-style endpoints\nConfidence: high\nScope-risk: narrow\nDirective: Keep provider-specific streaming flags tied to OpenAiCompatConfig instead of inferring provider behavior from URLs\nTested: cargo clippy -p api --tests -- -D warnings\nTested: cargo test -p api openai_streaming_requests -- --nocapture\nTested: cargo test -p api xai_streaming_requests_skip_openai_specific_usage_opt_in -- --nocapture\nTested: cargo test -p api request_translation_uses_openai_compatible_shape -- --nocapture\nTested: cargo test -p api stream_message_normalizes_text_and_multiple_tool_calls -- --exact --nocapture\nNot-tested: Live OpenAI or xAI network calls
2026-04-02 10:04:14 +00:00
..
api Preserve usage accounting on OpenAI SSE streams 2026-04-02 10:04:14 +00:00
commands Merge branch 'dori/commands-parity' into main 2026-04-02 18:37:00 +09:00
compat-harness wip: plugins progress 2026-04-01 07:09:06 +00:00
plugins Merge branch 'dori/hooks-parity' into main 2026-04-02 18:36:37 +09:00
runtime Merge branch 'dori/hooks-parity' into main 2026-04-02 18:36:37 +09:00
rusty-claude-cli fix: suppress WIP dead_code/clippy warnings in rusty-claude-cli 2026-04-02 18:38:47 +09:00
telemetry feat: anthropic SDK header matching + request profile 2026-04-01 05:55:25 +00:00
tools feat(tools): error propagation, REPL timeout, edge-case validation 2026-04-02 18:24:39 +09:00