Skip to content

Cost you can check, a step-by-step guide, and scripts safe to edit mid-run - #20

Merged
svemyh merged 2 commits into
mainfrom
cost-accuracy-and-guide
Nov 2, 2026
Merged

svemyh merged 2 commits into
mainfrom
cost-accuracy-and-guide

Conversation

@svemyh

@svemyh svemyh commented Nov 2, 2026

Copy link
Copy Markdown
Contributor

From an end-to-end audit of a six-task smoke run (gpt-6-luna xhigh, adapter 0.3.44, Harbor 0.25):

Verified

  • Trajectory tokens equal the Session's totals, Harbor's agent_result and the Reason API's Session usage on every attempt.
  • Each attempt's model calls equal the calls the inference gateway served (24/24, 86/86, 2/2, 18/18).
  • score.py cost equals the gateway's provider cost.
  • For all of 2026-10-31, the gateway's gpt-6-luna tokens match OpenAI's usage API within 0.5% and its cost matches OpenAI's cost API within 0.6%.
  • PRICES matches OpenAI's published price page.
  • The first request's prompt tokens match the exported prompt and tools.

Fixed here

  • Harbor's cost_usd (what Hub shows) is Reason's charge, list price plus 25% on Reason-paid models, but the docs said Reason bills at list. score.py now lists both, and the methodology says which is which.
  • Anthropic one-hour cache writes (release 1.3 on direct Anthropic) are now priced at 2× input, once the trajectory reports them (monorepo#31058).
  • run.sh / run-pass.sh are wrapped in main(). Editing the checkout during a run made bash resume at a stale offset and run the wrong lines; reproduced, and fixed with a fake harbor while rewriting the file mid-run.
  • New docs/GUIDE.md, linked from the README.

Related monorepo fixes: #31055 (trajectories named the reason tool codemode), #31058 (one-hour cache writes in exports), #31063 (adapter shows every error code, Harbor 0.3.45).

Tests: 22 pass; shellcheck clean.

🤖 Generated with Claude Code

Sven Myhre and others added 2 commits November 1, 2026 18:08
…d-run

- score.py lists what Reason charged per attempt (the cost_usd Harbor uploads:
  list price + 25% on Reason-paid models) beside the list-price cost, labels
  its fallback as Reason's charge, and prices Anthropic one-hour cache writes
  at 2x input. The price table's comment no longer claims Reason bills at
  list price.
- METHODOLOGY 1.10: both costs, and how tokens and cost were checked against
  the inference gateway and OpenAI's usage and cost APIs; tool names in
  trajectories.
- docs/GUIDE.md: how a run works, step by step, what each file does, the
  decisions and why, and the cost checks.
- run.sh and run-pass.sh run as one function, so pulling or editing the repo
  during a run can't change what it executes.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…hows its count

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@svemyh
svemyh merged commit 4daad94 into main Nov 2, 2026
4 checks passed
@svemyh
svemyh deleted the cost-accuracy-and-guide branch November 2, 2026 02:10
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