feat(usage): 在 CanonicalUsage 中追加缓存 token 字段并在标准化流程透传

- 扩展 CanonicalUsage 支持 cache_creation/cache_read 及 5m/1h 明细
- OpenAI/Claude/Gemini 解析器提取缓存 token 并计入 total
- usage_mapper 补齐 Claude 缓存字段映射
- 新增 gateway pricing 集成测试覆盖三家同步/流式缓存计费
This commit is contained in:
fawney19
2026-04-19 03:55:55 +08:00
parent 2f487fda66
commit 0329b7b784
7 changed files with 1443 additions and 7 deletions

View File

@@ -178,4 +178,5 @@ pub(super) fn sample_local_openai_key() -> StoredProviderCatalogKey {
mod direct;
mod local;
mod pricing;
mod wallet;

File diff suppressed because it is too large Load Diff