Skip to content

Add Codex Reconciled Token Usage script - #66

Open
QingJunXue wants to merge 1 commit into
BigPizzaV3:mainfrom
QingJunXue:feature/reconciled-token-usage
Open

Add Codex Reconciled Token Usage script#66
QingJunXue wants to merge 1 commit into
BigPizzaV3:mainfrom
QingJunXue:feature/reconciled-token-usage

Conversation

@QingJunXue

Copy link
Copy Markdown

Summary

  • publish Codex Reconciled Token Usage version 1.0.0 by QingJunXue
  • combine MessagePort real-time accounting with startup rollout rebuilding and 60-second incremental reconciliation
  • account for subagent usage and proxy request statuses without reading relay CSV or provider billing APIs
  • use empty default prices, multiplier 1, and no built-in price source, model alias, or long-context threshold
  • preserve request-level short/long context buckets
  • migrate legacy local state once and avoid focus/visibility-triggered disk scans
  • replace matching live/rollout records with richer proxy Usage instead of double counting

Requires the /token-usage/events bridge from: BigPizzaV3/CodexPlusPlus#1688

Verification

  • node --check scripts/codex-reconciled-token-usage.js
  • 9/9 Node tests passed
  • index.json parses successfully
  • script SHA-256 matches the market entry:

c5b6dedcfbc1212b45075e9bad899486cc84014aa94d12ea75ff0a03a3cddd43

Publish the 1.0.0 companion script for the Codex++ token usage bridge with empty local pricing defaults, request-level context tiers, one-to-one MessagePort/rollout/proxy reconciliation, and regression tests.
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.

1 participant