feat(web): show cache hit rates in request logs - #618
Conversation
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Organization UI Review profile: QUIET Plan: Advanced Run ID: 📒 Files selected for processing (4)
Included review availability: Your plan provides up to 8 included reviews per hour; 7 remain after this review. 📝 WalkthroughWalkthrough更新日志列表的缓存详情按钮位置。按钮从 Merge Risk: ⚪ Minimal · up to This adds inline cache hit rates to request logs without changing API, storage, or cache calculations. The change is ready to merge with no current merge-blocking risk. 🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
关联 Issue / Related Issue
Closes #583
变更内容 / Change Content
请求日志的 Token 单元格现在直接显示缓存命中率,不需要先悬停。百分比放在输入/输出 Token 下方,沿用现有的
formatCacheHitRate;缓存读写明细仍可通过悬停或键盘聚焦查看。无缓存或缺少用量的记录不增加缓存行;只有缓存写入时显示 0%,无法计算比例时沿用
—。三份 README 同步说明这项显示能力。没有修改 API、存储或缓存率计算方式。验证:
make check通过(Go 1.27.1、Node 24.20.0、pnpm 11.17.0;断网测试容器,提供 Docker Compose CLI 与 jq,仅验证配置,不连接 Docker daemon)。LogsTab和合成请求日志检查英文、中文、日文,以及管理员和 AccessKey 视图;1360/1024/390px 布局内百分比可见,详细提示仍可通过悬停与键盘聚焦打开。涵盖缓存读取、仅写入、无缓存、零输入、partial/missing/not applicable 和大整数。自查清单 / Checklist
make check,或在说明中写明无法运行的原因和未验证范围。 / I ranmake check, or documented why it could not run and what remains unverified.