litellm icon indicating copy to clipboard operation
litellm copied to clipboard

Fix incorrect cost calculation when creation cached input tokens in Anthropic

Open Gullesnuffs opened this issue 1 year ago • 1 comments

Fix incorrect cost calculation when creation cached input tokens in Anthropic

Relevant issues

Fixes #6575

Type

🐛 Bug Fix

Changes

Stopped double counting the tokens.

[REQUIRED] Testing - Attach a screenshot of any new tests passing locall

There don't seem to be any tests of this function? Seems out of scope for this bug fix to add them.

Gullesnuffs avatar Nov 04 '24 12:11 Gullesnuffs

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
litellm ✅ Ready (Inspect) Visit Preview 💬 Add feedback Nov 4, 2024 0:25am

vercel[bot] avatar Nov 04 '24 12:11 vercel[bot]

Is there an update?

mrgomdev avatar Dec 18 '24 00:12 mrgomdev

I think it has been fixed recently. How about closing the PR and the issue?

mrgomdev avatar Dec 30 '24 06:12 mrgomdev

CLA assistant check
Thank you for your submission! We really appreciate it. Like many open source projects, we ask that you sign our Contributor License Agreement before we can accept your contribution.
You have signed the CLA already but the status is still pending? Let us recheck it.

CLAassistant avatar Apr 22 '25 22:04 CLAassistant

This pull request has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs.

github-actions[bot] avatar Jul 22 '25 00:07 github-actions[bot]