What's Changed
- [Docs] Show how to use litellm GHCR as a base image by @ishaan-jaff in #2019
- ✨ Allow to configure scopes in generic SSO by @Lunik in #2020
- [FEAT] Generic SSO - allow user to specify attribute names by @ishaan-jaff in #2021
- fix(utils.py): support image gen logging to langfuse by @krrishdholakia in #2025
- [FEAT] Track spend per tag by @ishaan-jaff in #2004
- [FEAT] View spend per tag by @ishaan-jaff in #2012
Usage - Tracking Spend Per Tag
Step 1. Tag your /chat/completions request to litellm proxy
curl --location 'http://0.0.0.0:8000/chat/completions' \
--header 'Content-Type: application/json' \
--data '{
"model": "gpt-3.5-turbo",
"messages": [
{
"role": "user",
"content": "what llm are you"
}
],
"metadata": {"tags": ["model-anthropic-claude-v2.1", "app-ishaan-prod"]}
}'
Step 2. View spend per tag
curl -X GET "http://0.0.0.0:4000/spend/tags" \
-H "Authorization: Bearer sk-1234"
[
{
"individual_request_tag": "model-anthropic-claude-v2.1",
"log_count": 6,
"total_spend": 0.000672
},
{
"individual_request_tag": "app-ishaan-local",
"log_count": 4,
"total_spend": 0.000448
},
{
"individual_request_tag": "app-ishaan-prod",
"log_count": 2,
"total_spend": 0.000224
}
]
New Contributors
Full Changelog: v1.24.5...v1.24.6