Export displayed metrics in inference CSV downloads / 在推理 CSV 下载中导出当前显示指标 - #712
Merged
Merged
Conversation
Include the selected Y-axis metric and current X-axis value in inference CSV downloads for official and unofficial overlay rows.\n\n中文:在推理 CSV 下载中加入表格当前显示的 Y 轴指标和 X 轴值,同时支持官方数据与 unofficial run overlay 数据。
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
Oseltamivir
marked this pull request as ready for review
August 10, 2026 02:36
There was a problem hiding this comment.
Cursor Bugbot has reviewed your changes using default effort and found 1 potential issue.
❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.
Reviewed by Cursor Bugbot for commit 942b6bf. Configure here.
Skip displayed metric columns whose headers already exist in the fixed inference CSV schema, and cover the agentic P99 case.\n\n中文:当当前显示指标的表头已存在于固定推理 CSV schema 中时不再重复插入,并新增 agentic P99 场景的回归测试。
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.

Summary
costh.y, so CSV fields match the table view?unofficialrun=overlay rowsRoot cause
The inference table resolved the selected metric dynamically from chart data, while the CSV helper exported only a fixed set of raw benchmark fields. Derived metrics such as cost per million total tokens were therefore visible in the table but absent from downloads.
Validation
bun run typecheckbun run fmtcd packages/app && bun --env-file=../../.env vitest run src/lib/csv-export-helpers.test.ts(32 tests passed)git diff --check?unofficialrun=overlays (covered by the regression test)中文说明
costh.y等嵌套派生指标,使 CSV 字段与表格视图保持一致?unofficialrun=overlay 数据都会导出相同的当前显示字段根本原因
推理表格会根据图表数据动态解析当前选择的指标,而 CSV helper 仅导出一组固定的原始基准测试字段。因此,每百万总 token 成本等派生指标虽然会显示在表格中,却不会出现在下载文件里。
验证
bun run typecheckbun run fmtcd packages/app && bun --env-file=../../.env vitest run src/lib/csv-export-helpers.test.ts(32 项测试通过)git diff --check?unofficialrun=overlay 数据均受支持(已通过回归测试覆盖)Note
Low Risk
Export-only change with optional API parameter; existing callers without displayedMetrics behave as before, covered by new unit tests.
Overview
Inference chart CSV downloads now include the same Y and X values the table shows, not only the fixed benchmark summary columns.
ChartDisplaypasses the selected axis labels and the chart definition path (e.g.costh.y) intoinferenceChartToCsv, which inserts those columns after Date and resolves nested derived metrics vianestedMetric. Official rows and visible unofficial-run overlay rows get the same displayed fields. Columns are skipped when the header already exists in the export schema (e.g. agentic P99 Interactivity), so headers stay unique.Reviewed by Cursor Bugbot for commit cddb154. Bugbot is set up for automated code reviews on this repo. Configure here.