mirror of
https://github.com/BerriAI/litellm.git
synced 2026-10-08 03:08:45 +00:00
docs: add documentation for additional cost-related keys in custom pricing (#14949)
Co-authored-by: aider (openrouter/anthropic/claude-sonnet-4) <aider@aider.chat>
This commit is contained in:
parent
360befa216
commit
6fe8c33448
1 changed files with 18 additions and 0 deletions
|
|
@ -83,6 +83,24 @@ model_list:
|
|||
cache_read_input_token_cost: 0.0000006
|
||||
```
|
||||
|
||||
### Additional Cost Keys
|
||||
|
||||
There are other keys you can use to specify costs for different scenarios and modalities:
|
||||
|
||||
- `input_cost_per_token_above_200k_tokens` - Cost for input tokens when context exceeds 200k tokens
|
||||
- `output_cost_per_token_above_200k_tokens` - Cost for output tokens when context exceeds 200k tokens
|
||||
- `cache_creation_input_token_cost_above_200k_tokens` - Cache creation cost for large contexts
|
||||
- `cache_read_input_token_cost_above_200k_token` - Cache read cost for large contexts
|
||||
- `input_cost_per_image` - Cost per image in multimodal requests
|
||||
- `output_cost_per_reasoning_token` - Cost for reasoning tokens (e.g., OpenAI o1 models)
|
||||
- `input_cost_per_audio_token` - Cost for audio input tokens
|
||||
- `output_cost_per_audio_token` - Cost for audio output tokens
|
||||
- `input_cost_per_video_per_second` - Cost per second of video input
|
||||
- `input_cost_per_video_per_second_above_128k_tokens` - Video cost for large contexts
|
||||
- `input_cost_per_character` - Character-based pricing for some providers
|
||||
|
||||
These keys evolve based on how new models handle multimodality. The latest version can be found at [https://github.com/BerriAI/litellm/blob/main/model_prices_and_context_window.json](https://github.com/BerriAI/litellm/blob/main/model_prices_and_context_window.json).
|
||||
|
||||
## Set 'base_model' for Cost Tracking (e.g. Azure deployments)
|
||||
|
||||
**Problem**: Azure returns `gpt-4` in the response when `azure/gpt-4-1106-preview` is used. This leads to inaccurate cost tracking
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue