Skip to content

💶 fix: Price Mistral Large 3 at $0.50 / $1.50 per MTok - #16675

Merged
danny-avila merged 1 commit into
LibreChat-AI:devfrom
Alan-Billi:fix/mistral-large-3-pricing
Oct 5, 2026
Merged

danny-avila merged 1 commit into
LibreChat-AI:devfrom
Alan-Billi:fix/mistral-large-3-pricing

Conversation

@Alan-Billi

@Alan-Billi Alan-Billi commented Oct 2, 2026 •

Copy link
Copy Markdown
Contributor

Summary

Closes #16676. Opened as a draft until the issue is assigned.

mistral-large-2512 (Mistral Large 3) has no entry in tokenValues, so findMatchingPattern falls back to the generic mistral-large key and bills it at Mistral Large 2 rates ($2 / $6 per MTok). Mistral Large 3 is priced at $0.50 / $1.50, so its transactions — and any spend reporting built on them — are overstated 4x. mistral-large-latest now resolves to Large 3 as well.

Changes in packages/data-schemas/src/methods/tx.ts:

  • Add mistral-large-2512 and mistral-large-3 at $0.50 / $1.50.
  • Point the generic mistral-large fallback (used by mistral-large-latest) to the current model's price.
  • Pin mistral-large-2411 (Large 2.1) to its $2 / $6 rate so it keeps its existing pricing.
  • Remove the Sonnet 5 "introductory pricing through 2026-08-31; revert to $3 / $15 after" comments. Anthropic made $2 / $10 the standard price and the scheduled increase will not occur (pricing, footnote 3), so the comments would invite an incorrect revert. Rates are unchanged.

Pricing sources: Mistral Large 3 2512 on OpenRouter, Anthropic pricing.

Change Type

  • Bug fix (non-breaking change which fixes an issue)

Testing

Added a Mistral Large Pricing suite to tx.spec.ts covering mistral-large-2512, mistral-large-3, mistral-large-latest and a provider-prefixed name ($0.50 / $1.50), mistral-large-2411 ($2 / $6), and the legacy 2402 / 2407 Bedrock rates.

cd packages/data-schemas && npx jest src/methods/tx.spec.ts

Test Configuration:

What was run, and what was not:

  • Ran: npx jest src/methods/tx.spec.ts in packages/data-schemas, on Node v24, against a dependency install older than current upstream. Result: all 3 new tests pass. 9 pre-existing tests fail (getValueKey / getMultiplier GPT cases such as "should return "4k" for model name containing "gpt-3.5""). The same 9 fail on unmodified upstream with that install, so they come from the stale dependencies, not this change.
  • Ran: npx prettier --check on both files: clean.
  • Not run: npm run test:api, npm run lint, npm run static-checks, and a clean reinstall.

Checklist

  • My code adheres to this project's style guidelines
  • I have performed a self-review of my own code
  • I have written tests demonstrating that my changes are effective or that my feature works
  • Local unit tests pass with my changes (only tx.spec.ts was run; see Testing)

🤖 Generated with Claude Code

`mistral-large-2512` (and `mistral-large-latest`, which now points to it)
had no dedicated entry and fell back to the generic `mistral-large` key,
billing at Mistral Large 2 rates ($2 / $6), 4x the actual price.

- Add `mistral-large-2512` and `mistral-large-3` at $0.50 / $1.50
- Point the generic `mistral-large` fallback to the current model's price
- Pin `mistral-large-2411` to its $2 / $6 rate
- Drop the stale Sonnet 5 "revert after 2026-08-31" comments: Anthropic
  made the $2 / $10 pricing standard, so the scheduled increase won't happen

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
@github-actions
github-actions Bot changed the base branch from main to dev October 2, 2026 15:28
@github-actions

github-actions Bot commented Oct 2, 2026

Copy link
Copy Markdown
Contributor

👋 Thanks for the contribution! LibreChat merges all changes into dev first — main only moves at release time — so this pull request's base branch was switched from main to dev automatically.

Nothing is needed from you; your commits, reviews and discussion are unchanged. If the diff now shows files you did not touch, rebase onto dev:

git remote add upstream https://github.com/LibreChat-AI/LibreChat.git
git fetch upstream dev
git rebase upstream/dev
git push --force-with-lease

Maintainers: apply the target: main label and restore the base branch if this one genuinely belongs on main.

@codegraph-librechat codegraph-librechat Bot added the 🗺️ Backend Platform codegraph: the taxonomy area this belongs to (classifier, confidence ≥ 0.9) label Oct 2, 2026
@Alan-Billi
Alan-Billi marked this pull request as draft October 2, 2026 15:49
@codegraph-librechat codegraph-librechat Bot added the 🗺️ Billing Engine codegraph: the taxonomy area this belongs to (classifier, confidence ≥ 0.9) label Oct 4, 2026
@danny-avila
danny-avila marked this pull request as ready for review October 5, 2026 01:44
@danny-avila
danny-avila merged commit bfbf527 into LibreChat-AI:dev Oct 5, 2026
30 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

🗺️ Backend Platform codegraph: the taxonomy area this belongs to (classifier, confidence ≥ 0.9) 🗺️ Billing Engine codegraph: the taxonomy area this belongs to (classifier, confidence ≥ 0.9)

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Bug]: Mistral Large 3 (mistral-large-2512) billed at Mistral Large 2 rates (4x actual price)

2 participants