Skip to content

v0.2.2 — the max_completion_tokens fix reaches PyPI

Choose a tag to compare

@theo-titonis theo-titonis released this 23 Aug 02:57
· 19 commits to main since this release

If you installed offpeak from PyPI, this is the release you want.

0.2.1 — the previous latest — does not contain #16. Every gpt-5.x OpenAI batch
job it submits comes back HTTP 400: Unsupported parameter: 'max_tokens' is not supported with this model. Use 'max_completion_tokens' instead. The failure
arrives hours after submission, once per job, and the sync fallback does not
rescue it: the fallback covers jobs that never came back, not jobs that came
back failed.

0.2.2 puts the fix on the wire. It is the only src/ change since v0.2.1.

What changed

  • openai: send max_completion_tokens where the model demands it (#16) —
    body_params() renders a job's params in the venue's own dialect. o1/o3/
    o4/gpt-5.x get max_completion_tokens; older families keep max_tokens;
    an explicit provider spelling always wins; the caller's Job is never
    mutated, so a retry at another venue still carries what they wrote. The sync
    fallback goes through the same translation.

Also on main since 0.2.1, none of it shipping code: the reasoning-ceiling
documentation (#17), the settled ledger (#18), a shared push queue for
board-data (#19), the mechanics runner (#20), and the board becoming a
projection of its records (#21).

Upgrading

pip install -U offpeak

Nothing to change in your code. If you have been setting
max_completion_tokens yourself to work around 0.2.1, you can keep doing so —
an explicit spelling still wins — or drop back to max_tokens and let the
driver translate.