forked from phoenix/litellm-mirror
(docs) upperbound_key_generate_params
This commit is contained in:
parent
f8380c638f
commit
d09aa560f3
2 changed files with 18 additions and 2 deletions
|
@ -352,6 +352,22 @@ Request Params:
|
||||||
}
|
}
|
||||||
```
|
```
|
||||||
|
|
||||||
|
## Upperbound /key/generate params
|
||||||
|
Use this, if you need to control the upperbound that users can use for `max_budget`, `budget_duration` or any `key/generate` param per key.
|
||||||
|
|
||||||
|
Set `litellm_settings:upperbound_key_generate_params`:
|
||||||
|
```yaml
|
||||||
|
litellm_settings:
|
||||||
|
upperbound_key_generate_params:
|
||||||
|
max_budget: 100 # upperbound of $100, for all /key/generate requests
|
||||||
|
duration: "30d" # upperbound of 30 days for all /key/generate requests
|
||||||
|
```
|
||||||
|
|
||||||
|
** Expected Behavior **
|
||||||
|
|
||||||
|
- Send a `/key/generate` request with `max_budget=200`
|
||||||
|
- Key will be created with `max_budget=100` since 100 is the upper bound
|
||||||
|
|
||||||
## Default /key/generate params
|
## Default /key/generate params
|
||||||
Use this, if you need to control the default `max_budget` or any `key/generate` param per key.
|
Use this, if you need to control the default `max_budget` or any `key/generate` param per key.
|
||||||
|
|
||||||
|
|
|
@ -156,8 +156,8 @@
|
||||||
"max_tokens": 4097,
|
"max_tokens": 4097,
|
||||||
"max_input_tokens": 4097,
|
"max_input_tokens": 4097,
|
||||||
"max_output_tokens": 4096,
|
"max_output_tokens": 4096,
|
||||||
"input_cost_per_token": 0.000012,
|
"input_cost_per_token": 0.000003,
|
||||||
"output_cost_per_token": 0.000016,
|
"output_cost_per_token": 0.000006,
|
||||||
"litellm_provider": "openai",
|
"litellm_provider": "openai",
|
||||||
"mode": "chat"
|
"mode": "chat"
|
||||||
},
|
},
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue