Skip to content

fix(pricing): commit the codex fallback snapshot from its real path - #1510

Merged
ryoppippi merged 2 commits into
mainfrom
fix/pricing-codex-snapshot-path
Jul 28, 2026
Merged

ryoppippi merged 2 commits into
mainfrom
fix/pricing-codex-snapshot-path

Conversation

@ryoppippi

@ryoppippi ryoppippi commented Jul 28, 2026 •

Copy link
Copy Markdown
Member

Summary

The models.dev half of update-pricing.yaml has failed on every hourly run since #1428 split the workspace and moved the adapter crates:

fatal: pathspec 'rust/crates/ccusage-adapter-codex/src/codex-auto-review-fallbacks.json' did not match any files

The tracked file is at rust/adapters/codex/src/codex-auto-review-fallbacks.json. So models.dev pricing has not been refreshed since that move — only the LiteLLM half of the workflow still worked. Caught by pullfrog on #1509; the wrong path predates that PR, which carried it over unchanged.

What Changed

  • The path is corrected in .github/scripts/update-models-dev-lock.nu.
  • The path list is no longer duplicated. It lived in both the script and the workflow's matrix, which is how it drifted from the Rust tree: the script now reports the files it owns via GITHUB_OUTPUT, and the workflow passes steps.update.outputs.paths straight to the push action.
  • The script asserts up front that every snapshot path exists, so the next move fails immediately with a clear message instead of after a full regenerate-and-validate cycle.

Testing

  • nu-check passes on both scripts.
  • Ran git checkout -- flake.lock <snapshots> with the corrected list against a clean tree: the revert arm the job could never reach before is now a no-op instead of a fatal pathspec error.
  • Ran update-litellm-lock.nu end to end: bumped 34561482 to f2cda740 and reported changed=true / paths=flake.lock. Lock restored afterwards.
  • just fmt (actionlint, zizmor, nufmt) passes.

View with [code]smith
Need help on this PR? Tag @codesmith-bot with what you need. Autofix is enabled.


Summary by cubic

Fixes the models.dev pricing job by committing the codex fallback snapshot from its real path and removing duplicated path lists, restoring hourly updates.

  • Bug Fixes

    • Corrected snapshot path to rust/adapters/codex/src/codex-auto-review-fallbacks.json.
    • Assert snapshot paths exist before regenerate to fail fast with a clear error.
  • Refactors

    • Extracted shared report helper to .github/scripts/pricing-lock.nu; both lock scripts import it to emit changed and paths via GITHUB_OUTPUT.
    • Workflow uses steps.update.outputs.paths instead of hardcoded lists to prevent drift.

Written for commit e138a1e. Summary will update on new commits.

Review in cubic

Summary by CodeRabbit

  • Bug Fixes

    • Improved pricing update workflows by validating required snapshot files before making changes.
    • Corrected the snapshot location for Codex fallback data.
  • Chores

    • Automated workflows now commit only files actually changed by update scripts.
    • Standardized reporting of changed files and update status across pricing workflows.

The models.dev job has failed on every hourly run since #1428 moved the
adapter crates:

  fatal: pathspec
  'rust/crates/ccusage-adapter-codex/src/codex-auto-review-fallbacks.json'
  did not match any files

The file lives at rust/adapters/codex/src/codex-auto-review-fallbacks.json,
so models.dev pricing has not been refreshed since that move; only the
LiteLLM half of the workflow still worked.

The path was duplicated between the update script and the workflow, which is
how it drifted from the Rust tree in the first place. The script now reports
the paths it owns through GITHUB_OUTPUT and the workflow passes that straight
to the push action, so there is one list. The script also asserts up front
that the snapshots exist, so the next move fails immediately instead of
after a full regenerate-and-validate cycle.
Copilot AI review requested due to automatic review settings July 28, 2026 01:09

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot was unable to review this pull request because the user who requested the review has reached their quota limit.

@coderabbitai

coderabbitai Bot commented Jul 28, 2026 •

Copy link
Copy Markdown

Review Change Stack

📝 Walkthrough

Walkthrough

Pricing update scripts now validate snapshot paths and report both change status and affected files. The GitHub Actions workflow consumes those reported paths when committing updates, removing the duplicated models-dev path list.

Changes

Pricing update output ownership

Layer / File(s) Summary
Script validation and output reporting
.github/scripts/pricing-lock.nu, .github/scripts/update-models-dev-lock.nu, .github/scripts/update-litellm-lock.nu
The scripts share output reporting, validate snapshot locations where applicable, and write changed plus space-separated paths values to GITHUB_OUTPUT.
Workflow consumption of reported paths
.github/workflows/update-pricing.yaml
The models-dev matrix entry drops its hardcoded paths, and the commit step uses steps.update.outputs.paths.

Estimated code review effort: 3 (Moderate) | ~20 minutes

Sequence Diagram(s)

sequenceDiagram
  participant UpdateScript
  participant ReportHelper
  participant GitHubActions
  participant Git
  UpdateScript->>ReportHelper: report changed status and owned paths
  ReportHelper->>GitHubActions: write changed and paths outputs
  GitHubActions->>Git: commit reported paths
Loading

Possibly related PRs

Suggested reviewers: copilot

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title clearly reflects the main change: fixing the Codex fallback snapshot path in the pricing workflow.
✨ Finishing Touches
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch fix/pricing-codex-snapshot-path

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.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@cloudflare-workers-and-pages

cloudflare-workers-and-pages Bot commented Jul 28, 2026 •

Copy link
Copy Markdown

Deploying with  Cloudflare Workers  Cloudflare Workers

The latest updates on your project. Learn more about integrating Git with Workers.

Status Name Latest Commit Preview URL Updated (UTC)
✅ Deployment successful!
View logs
ccusage-guide e138a1e Commit Preview URL

Branch Preview URL
Jul 28 2026, 01:24 AM

@pullfrog pullfrog Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

✅ No new issues found.

Reviewed changes — corrects the codex fallback snapshot path broken by the crate split in #1428, and centralizes path reporting so the file list can't drift again.

  • Fix SNAPSHOTS path in update-models-dev-lock.nu — the committed fallback snapshot moved from rust/crates/ccusage-adapter-codex/ to rust/adapters/codex/ in #1428 but the CI script was never updated, causing the models.dev leg to fail on every hourly run.
  • Add fail-fast path assertion — update-models-dev-lock.nu now checks that every snapshot path exists before doing any work, so the next directory move fails immediately with a clear error.
  • Centralize path reporting — both update scripts now emit paths alongside changed via GITHUB_OUTPUT, and the workflow reads steps.update.outputs.paths instead of duplicating the file list in the matrix.

Pullfrog  | ⚠️ this action is pinned to a commit SHA, which freezes the cleanup step — switch to @v0 or keep the SHA fresh with Dependabot | View workflow run | Using DeepSeek Pro (free via Pullfrog for OSS) | 𝕏

@cubic-dev-ai cubic-dev-ai Bot left a comment •

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

All reported issues were addressed across 3 files

Reply with feedback, questions, or to request a fix.

Re-trigger cubic

Comment thread .github/scripts/update-models-dev-lock.nu Outdated
@pkg-pr-new

pkg-pr-new Bot commented Jul 28, 2026 •

Copy link
Copy Markdown

Open in StackBlitz

ccusage

npx https://pkg.pr.new/ccusage@1510

@ccusage/ccusage-darwin-arm64

npx https://pkg.pr.new/@ccusage/ccusage-darwin-arm64@1510

@ccusage/ccusage-darwin-x64

npx https://pkg.pr.new/@ccusage/ccusage-darwin-x64@1510

@ccusage/ccusage-linux-arm64

npx https://pkg.pr.new/@ccusage/ccusage-linux-arm64@1510

@ccusage/ccusage-linux-x64

npx https://pkg.pr.new/@ccusage/ccusage-linux-x64@1510

@ccusage/ccusage-win32-x64

npx https://pkg.pr.new/@ccusage/ccusage-win32-x64@1510

commit: e138a1e

@github-actions

Copy link
Copy Markdown
Contributor

ccusage performance comparison

PR SHA: 30b629d5e034
Base SHA: b184bdce4daf

This compares the Rust PR release binary against the configured base package on the same CI runner.

Package runtime diagnostics

Compares the PR package wrapper, the installed native optional dependency binary, and the workspace release binary on the same large fixture. This identifies whether slow package results come from JavaScript wrapper overhead, the published native binary build, or the Rust core itself.

Fixtures: Claude /home/runner/_work/_temp/ccusage-large-fixture (1.01 GiB, 2597 files), Codex /home/runner/_work/_temp/ccusage-large-codex-fixture (1.01 GiB, 2597 files)
All rows run --offline --json, measured by hyperfine with 0 warmups and 1 runs. This isolates wrapper overhead from the installed native optional dependency and the workspace release binary built on the runner.

Command Runtime Input Median Throughput Samples
claude --offline --json Package wrapper 1.01 GiB 326.6ms 3.08 GiB/s 1
claude --offline --json Installed native binary 1.01 GiB 301.0ms 3.35 GiB/s 1
codex --offline --json Package wrapper 1.01 GiB 119.2ms 8.45 GiB/s 1
codex --offline --json Installed native binary 1.01 GiB 99.9ms 10.07 GiB/s 1

Committed fixture performance

Committed small fixtures for stable PR-to-PR feedback and explicit Claude/Codex command coverage.

Fixtures: Claude apps/ccusage/test/fixtures/claude (0.00 MiB, 2 files), Codex apps/ccusage/test/fixtures/codex (0.00 MiB, 1 files)
Base runs the published ccusage package from pkg.pr.new, installed before measurement; PR runs the published native ccusage binary from pkg.pr.new, installed before measurement. Both run --offline --json, measured by hyperfine with 2 warmups and 7 runs.
Peak RSS is measured separately with /usr/bin/time using 1 runs. Lower RSS ratios are better.

Command Input Base median PR median PR vs base Base peak RSS PR peak RSS PR/base RSS Base throughput PR throughput
claude daily --offline --json 0.00 MiB 33.6ms 6.5ms 5.15x 55.00 MiB 12.45 MiB 0.23x 0.05 MiB/s 0.24 MiB/s
claude session --offline --json 0.00 MiB 29.7ms 3.9ms 7.65x 55.25 MiB 12.45 MiB 0.23x 0.05 MiB/s 0.40 MiB/s
codex daily --offline --json 0.00 MiB 30.4ms 2.9ms 10.41x 55.25 MiB 10.44 MiB 0.19x 0.03 MiB/s 0.29 MiB/s
codex session --offline --json 0.00 MiB 29.6ms 3.2ms 9.31x 55.25 MiB 10.44 MiB 0.19x 0.03 MiB/s 0.27 MiB/s

Large real-world-shaped fixture performance

Generated fixtures shaped from aggregate local log statistics: thousands of JSONL files, many small sessions, and a long tail of larger sessions. No real prompts, paths, or outputs are stored in the fixtures.

Fixtures: Claude /home/runner/_work/_temp/ccusage-large-fixture (1.01 GiB, 2597 files), Codex /home/runner/_work/_temp/ccusage-large-codex-fixture (1.01 GiB, 2597 files)
Base runs the published ccusage package from pkg.pr.new, installed before measurement; PR runs the published native ccusage binary from pkg.pr.new, installed before measurement. Both run --offline --json, measured by hyperfine with 0 warmups and 1 runs.
Peak RSS is measured separately with /usr/bin/time using 1 runs. Lower RSS ratios are better.

Command Input Base median PR median PR vs base Base peak RSS PR peak RSS PR/base RSS Base throughput PR throughput
claude --offline --json 1.01 GiB 347.1ms 297.5ms 1.17x 946.58 MiB 952.58 MiB 1.01x 2.90 GiB/s 3.38 GiB/s
codex --offline --json 1.01 GiB 124.5ms 100.7ms 1.24x 408.65 MiB 418.64 MiB 1.02x 8.09 GiB/s 10.00 GiB/s

Artifact size

Artifact Base PR Delta Ratio
packed ccusage-*.tgz 18.78 KiB 18.78 KiB +0.00 KiB 1.00x
installed native package binary 4156.78 KiB 4156.78 KiB +0.00 KiB 1.00x

Lower medians and smaller artifacts are better. CI runner noise still applies; use same-run ratios as directional PR feedback, not release guarantees.

@github-actions

Copy link
Copy Markdown
Contributor

ccusage performance comparison

PR SHA: 30b629d5e034
Base SHA: b184bdce4daf

This compares the PR package against the configured base package on the same CI runner.

Package runtime diagnostics

Compares the PR package wrapper, the installed native optional dependency binary, and the workspace release binary on the same large fixture. This identifies whether slow package results come from JavaScript wrapper overhead, the published native binary build, or the Rust core itself.

Fixtures: Claude /home/runner/_work/_temp/ccusage-large-fixture (1.01 GiB, 2597 files), Codex /home/runner/_work/_temp/ccusage-large-codex-fixture (1.01 GiB, 2597 files)
All rows run --offline --json, measured by hyperfine with 0 warmups and 1 runs. This isolates wrapper overhead from the installed native optional dependency and the workspace release binary built on the runner.

Command Runtime Input Median Throughput Samples
claude --offline --json Package wrapper 1.01 GiB 359.9ms 2.80 GiB/s 1
claude --offline --json Installed native binary 1.01 GiB 334.2ms 3.01 GiB/s 1
codex --offline --json Package wrapper 1.01 GiB 119.3ms 8.44 GiB/s 1
codex --offline --json Installed native binary 1.01 GiB 97.6ms 10.31 GiB/s 1

Committed fixture performance

Committed small fixtures for stable PR-to-PR feedback and explicit Claude/Codex command coverage.

Fixtures: Claude apps/ccusage/test/fixtures/claude (0.00 MiB, 2 files), Codex apps/ccusage/test/fixtures/codex (0.00 MiB, 1 files)
Base runs the published ccusage package from pkg.pr.new, installed before measurement; PR runs the published ccusage package from pkg.pr.new, installed before measurement. Both run --offline --json, measured by hyperfine with 2 warmups and 7 runs.
Peak RSS is measured separately with /usr/bin/time using 1 runs. Lower RSS ratios are better.

Command Input Base median PR median PR vs base Base peak RSS PR peak RSS PR/base RSS Base throughput PR throughput
claude daily --offline --json 0.00 MiB 28.0ms 29.9ms 0.93x 55.00 MiB 55.25 MiB 1.00x 0.06 MiB/s 0.05 MiB/s
claude session --offline --json 0.00 MiB 28.5ms 24.3ms 1.17x 55.00 MiB 55.25 MiB 1.00x 0.05 MiB/s 0.06 MiB/s
codex daily --offline --json 0.00 MiB 23.5ms 24.9ms 0.95x 55.00 MiB 55.00 MiB 1.00x 0.04 MiB/s 0.03 MiB/s
codex session --offline --json 0.00 MiB 25.0ms 23.1ms 1.09x 55.00 MiB 55.00 MiB 1.00x 0.03 MiB/s 0.04 MiB/s

Large real-world-shaped fixture performance

Generated fixtures shaped from aggregate local log statistics: thousands of JSONL files, many small sessions, and a long tail of larger sessions. No real prompts, paths, or outputs are stored in the fixtures.

Fixtures: Claude /home/runner/_work/_temp/ccusage-large-fixture (1.01 GiB, 2597 files), Codex /home/runner/_work/_temp/ccusage-large-codex-fixture (1.01 GiB, 2597 files)
Base runs the published ccusage package from pkg.pr.new, installed before measurement; PR runs the published ccusage package from pkg.pr.new, installed before measurement. Both run --offline --json, measured by hyperfine with 0 warmups and 1 runs.
Peak RSS is measured separately with /usr/bin/time using 1 runs. Lower RSS ratios are better.

Command Input Base median PR median PR vs base Base peak RSS PR peak RSS PR/base RSS Base throughput PR throughput
claude --offline --json 1.01 GiB 389.8ms 378.3ms 1.03x 948.58 MiB 932.57 MiB 0.98x 2.58 GiB/s 2.66 GiB/s
codex --offline --json 1.01 GiB 119.9ms 120.0ms 1.00x 416.89 MiB 436.66 MiB 1.05x 8.39 GiB/s 8.39 GiB/s

Artifact size

Artifact Base PR Delta Ratio
packed ccusage-*.tgz 18.78 KiB 18.78 KiB +0.00 KiB 1.00x
installed native package binary 4156.78 KiB 4156.78 KiB +0.00 KiB 1.00x

Lower medians and smaller artifacts are better. CI runner noise still applies; use same-run ratios as directional PR feedback, not release guarantees.

… scripts

Both update scripts carried a byte-identical `report` definition, so any change
to the GITHUB_OUTPUT format had to be made twice. Move it to a
`.github/scripts/pricing-lock.nu` module both scripts import.

Nushell resolves relative `use` paths against the importing file, so the module
loads regardless of the workflow's working directory.

Co-authored-by: Codesmith <[email protected]>
Copilot AI review requested due to automatic review settings July 28, 2026 01:22

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot was unable to review this pull request because the user who requested the review has reached their quota limit.

@github-actions

Copy link
Copy Markdown
Contributor

ccusage performance comparison

PR SHA: e138a1e74cf6
Base SHA: b184bdce4daf

This compares the Rust PR release binary against the configured base package on the same CI runner.

Package runtime diagnostics

Compares the PR package wrapper, the installed native optional dependency binary, and the workspace release binary on the same large fixture. This identifies whether slow package results come from JavaScript wrapper overhead, the published native binary build, or the Rust core itself.

Fixtures: Claude /home/runner/_work/_temp/ccusage-large-fixture (1.01 GiB, 2597 files), Codex /home/runner/_work/_temp/ccusage-large-codex-fixture (1.01 GiB, 2597 files)
All rows run --offline --json, measured by hyperfine with 0 warmups and 1 runs. This isolates wrapper overhead from the installed native optional dependency and the workspace release binary built on the runner.

Command Runtime Input Median Throughput Samples
claude --offline --json Package wrapper 1.01 GiB 333.8ms 3.02 GiB/s 1
claude --offline --json Installed native binary 1.01 GiB 313.8ms 3.21 GiB/s 1
codex --offline --json Package wrapper 1.01 GiB 119.5ms 8.43 GiB/s 1
codex --offline --json Installed native binary 1.01 GiB 114.8ms 8.77 GiB/s 1

Committed fixture performance

Committed small fixtures for stable PR-to-PR feedback and explicit Claude/Codex command coverage.

Fixtures: Claude apps/ccusage/test/fixtures/claude (0.00 MiB, 2 files), Codex apps/ccusage/test/fixtures/codex (0.00 MiB, 1 files)
Base runs the published ccusage package from pkg.pr.new, installed before measurement; PR runs the published native ccusage binary from pkg.pr.new, installed before measurement. Both run --offline --json, measured by hyperfine with 2 warmups and 7 runs.
Peak RSS is measured separately with /usr/bin/time using 1 runs. Lower RSS ratios are better.

Command Input Base median PR median PR vs base Base peak RSS PR peak RSS PR/base RSS Base throughput PR throughput
claude daily --offline --json 0.00 MiB 30.9ms 4.2ms 7.30x 55.00 MiB 12.44 MiB 0.23x 0.05 MiB/s 0.36 MiB/s
claude session --offline --json 0.00 MiB 23.8ms 4.6ms 5.16x 55.00 MiB 12.45 MiB 0.23x 0.06 MiB/s 0.34 MiB/s
codex daily --offline --json 0.00 MiB 24.3ms 2.3ms 10.42x 55.00 MiB 10.45 MiB 0.19x 0.04 MiB/s 0.37 MiB/s
codex session --offline --json 0.00 MiB 22.1ms 2.4ms 9.37x 55.25 MiB 10.44 MiB 0.19x 0.04 MiB/s 0.36 MiB/s

Large real-world-shaped fixture performance

Generated fixtures shaped from aggregate local log statistics: thousands of JSONL files, many small sessions, and a long tail of larger sessions. No real prompts, paths, or outputs are stored in the fixtures.

Fixtures: Claude /home/runner/_work/_temp/ccusage-large-fixture (1.01 GiB, 2597 files), Codex /home/runner/_work/_temp/ccusage-large-codex-fixture (1.01 GiB, 2597 files)
Base runs the published ccusage package from pkg.pr.new, installed before measurement; PR runs the published native ccusage binary from pkg.pr.new, installed before measurement. Both run --offline --json, measured by hyperfine with 0 warmups and 1 runs.
Peak RSS is measured separately with /usr/bin/time using 1 runs. Lower RSS ratios are better.

Command Input Base median PR median PR vs base Base peak RSS PR peak RSS PR/base RSS Base throughput PR throughput
claude --offline --json 1.01 GiB 384.8ms 319.4ms 1.20x 958.58 MiB 950.58 MiB 0.99x 2.62 GiB/s 3.15 GiB/s
codex --offline --json 1.01 GiB 117.6ms 117.7ms 1.00x 416.64 MiB 408.64 MiB 0.98x 8.56 GiB/s 8.55 GiB/s

Artifact size

Artifact Base PR Delta Ratio
packed ccusage-*.tgz 18.78 KiB 18.78 KiB -0.00 KiB 1.00x
installed native package binary 4156.78 KiB 4156.78 KiB +0.00 KiB 1.00x

Lower medians and smaller artifacts are better. CI runner noise still applies; use same-run ratios as directional PR feedback, not release guarantees.

@github-actions

Copy link
Copy Markdown
Contributor

ccusage performance comparison

PR SHA: e138a1e74cf6
Base SHA: b184bdce4daf

This compares the PR package against the configured base package on the same CI runner.

Package runtime diagnostics

Compares the PR package wrapper, the installed native optional dependency binary, and the workspace release binary on the same large fixture. This identifies whether slow package results come from JavaScript wrapper overhead, the published native binary build, or the Rust core itself.

Fixtures: Claude /home/runner/_work/_temp/ccusage-large-fixture (1.01 GiB, 2597 files), Codex /home/runner/_work/_temp/ccusage-large-codex-fixture (1.01 GiB, 2597 files)
All rows run --offline --json, measured by hyperfine with 0 warmups and 1 runs. This isolates wrapper overhead from the installed native optional dependency and the workspace release binary built on the runner.

Command Runtime Input Median Throughput Samples
claude --offline --json Package wrapper 1.01 GiB 335.7ms 3.00 GiB/s 1
claude --offline --json Installed native binary 1.01 GiB 316.0ms 3.19 GiB/s 1
codex --offline --json Package wrapper 1.01 GiB 116.6ms 8.63 GiB/s 1
codex --offline --json Installed native binary 1.01 GiB 93.0ms 10.82 GiB/s 1

Committed fixture performance

Committed small fixtures for stable PR-to-PR feedback and explicit Claude/Codex command coverage.

Fixtures: Claude apps/ccusage/test/fixtures/claude (0.00 MiB, 2 files), Codex apps/ccusage/test/fixtures/codex (0.00 MiB, 1 files)
Base runs the published ccusage package from pkg.pr.new, installed before measurement; PR runs the published ccusage package from pkg.pr.new, installed before measurement. Both run --offline --json, measured by hyperfine with 2 warmups and 7 runs.
Peak RSS is measured separately with /usr/bin/time using 1 runs. Lower RSS ratios are better.

Command Input Base median PR median PR vs base Base peak RSS PR peak RSS PR/base RSS Base throughput PR throughput
claude daily --offline --json 0.00 MiB 31.2ms 26.2ms 1.19x 55.00 MiB 55.00 MiB 1.00x 0.05 MiB/s 0.06 MiB/s
claude session --offline --json 0.00 MiB 23.8ms 24.5ms 0.97x 55.00 MiB 55.50 MiB 1.01x 0.06 MiB/s 0.06 MiB/s
codex daily --offline --json 0.00 MiB 21.4ms 23.2ms 0.92x 55.00 MiB 55.25 MiB 1.00x 0.04 MiB/s 0.04 MiB/s
codex session --offline --json 0.00 MiB 23.0ms 22.3ms 1.03x 55.25 MiB 55.00 MiB 1.00x 0.04 MiB/s 0.04 MiB/s

Large real-world-shaped fixture performance

Generated fixtures shaped from aggregate local log statistics: thousands of JSONL files, many small sessions, and a long tail of larger sessions. No real prompts, paths, or outputs are stored in the fixtures.

Fixtures: Claude /home/runner/_work/_temp/ccusage-large-fixture (1.01 GiB, 2597 files), Codex /home/runner/_work/_temp/ccusage-large-codex-fixture (1.01 GiB, 2597 files)
Base runs the published ccusage package from pkg.pr.new, installed before measurement; PR runs the published ccusage package from pkg.pr.new, installed before measurement. Both run --offline --json, measured by hyperfine with 0 warmups and 1 runs.
Peak RSS is measured separately with /usr/bin/time using 1 runs. Lower RSS ratios are better.

Command Input Base median PR median PR vs base Base peak RSS PR peak RSS PR/base RSS Base throughput PR throughput
claude --offline --json 1.01 GiB 361.7ms 337.6ms 1.07x 958.58 MiB 978.57 MiB 1.02x 2.78 GiB/s 2.98 GiB/s
codex --offline --json 1.01 GiB 118.1ms 123.6ms 0.96x 408.90 MiB 400.64 MiB 0.98x 8.52 GiB/s 8.15 GiB/s

Artifact size

Artifact Base PR Delta Ratio
packed ccusage-*.tgz 18.78 KiB 18.78 KiB -0.00 KiB 1.00x
installed native package binary 4156.78 KiB 4156.78 KiB +0.00 KiB 1.00x

Lower medians and smaller artifacts are better. CI runner noise still applies; use same-run ratios as directional PR feedback, not release guarantees.

@ryoppippi
ryoppippi merged commit abca396 into main Jul 28, 2026
36 checks passed
@ryoppippi
ryoppippi deleted the fix/pricing-codex-snapshot-path branch July 28, 2026 01:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants