open-code-review/internal/llm
Ayrton 44ef6d7fc7
feat: enhance token usage resolution for OpenAI and Anthropic compati… (#223)
* feat: enhance token usage resolution for OpenAI and Anthropic compatibility

Recognize OpenAI cached_tokens and wrapped proxy response paths, add tests
for path priority and provider-specific total token fallback semantics.

Co-authored-by: Cursor <cursoragent@cursor.com>

* style: format

* chore: Add tests and improve comments

* fix: Remove provider specific protocol

---------

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-07-09 14:35:47 +08:00
..
bpe_data feat: init 2026-05-20 22:03:52 +08:00
client.go fix: add configurable HTTP timeout for LLM API calls (#238) 2026-06-30 11:22:24 +08:00
client_test.go test: expand unit test coverage for agent, llm, llmloop, and tool packages 2026-06-26 23:09:11 +08:00
embedded_loader.go feat: init 2026-05-20 22:03:52 +08:00
embedded_loader_test.go test: add coverage tests for agent, llm, llmloop, and scan packages 2026-06-27 00:15:28 +08:00
message_test.go test: fix golangci-lint errcheck/staticcheck issues in test code (#323) 2026-07-08 22:46:18 +08:00
providers.go feat(llm): add z-ai-coding provider for GLM Coding Plan endpoint (#258) 2026-07-02 19:23:17 +08:00
providers_test.go feat(llm): add z-ai-coding provider for GLM Coding Plan endpoint (#258) 2026-07-02 19:23:17 +08:00
resolver.go fix(tui): persist official-tab models and refine saved secret hint (#260) 2026-07-06 20:38:39 +08:00
resolver_test.go test: fix golangci-lint errcheck/staticcheck issues in test code (#323) 2026-07-08 22:46:18 +08:00
usage_resolver.go feat: enhance token usage resolution for OpenAI and Anthropic compati… (#223) 2026-07-09 14:35:47 +08:00
usage_resolver_test.go feat: enhance token usage resolution for OpenAI and Anthropic compati… (#223) 2026-07-09 14:35:47 +08:00