litellm
litellm copied to clipboard
feat(utils.py): emit response cost as part of logs
Addresses - https://github.com/BerriAI/litellm/issues/1547
Changes:
- New
response_cost
kwarg to the Logging object on success (sync + async). - Supports completion + embedding responses
- Moves proxy spend tracking to use this (prev. if/else branch for streaming/non-streaming)
Needs further testing:
- image generation support
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 | Jan 23, 2024 4:40am |