mirror of
https://github.com/BerriAI/litellm.git
synced 2026-11-14 09:03:16 +00:00
Merge 96b7647e5e into 3f4dc93b40
This commit is contained in:
commit
a0c95e2ca9
10 changed files with 1354 additions and 6 deletions
|
|
@ -1093,6 +1093,7 @@ openai_compatible_endpoints: Final[list[str]] = [
|
|||
"https://api.scx.ai/v1",
|
||||
"https://api.prisminference.com/v1",
|
||||
"https://api.reka.ai/v1",
|
||||
"https://api.iteracompute.com/v1",
|
||||
"https://inference.runanywhere.ai/v1",
|
||||
"https://gigachat.devices.sberbank.ru/api/v1",
|
||||
"https://api.openinfer.ai/v1",
|
||||
|
|
@ -1181,6 +1182,7 @@ openai_compatible_providers: Final[list[str]] = [
|
|||
"sail",
|
||||
"reka",
|
||||
"streamlake",
|
||||
"iteracompute",
|
||||
"wally",
|
||||
]
|
||||
|
||||
|
|
|
|||
|
|
@ -265,6 +265,11 @@
|
|||
},
|
||||
"supported_endpoints": ["/v1/chat/completions", "/v1/responses", "/v1/messages"]
|
||||
},
|
||||
"iteracompute": {
|
||||
"base_url": "https://api.iteracompute.com/v1",
|
||||
"api_key_env": "ITERACOMPUTE_API_KEY",
|
||||
"api_base_env": "ITERACOMPUTE_API_BASE"
|
||||
},
|
||||
"inferenceapis": {
|
||||
"base_url": "https://api.inferenceapis.com/v1",
|
||||
"api_key_env": "INFERENCEAPIS_API_KEY",
|
||||
|
|
|
|||
|
|
@ -2788,14 +2788,18 @@ def _complete_custom_openai(
|
|||
|
||||
# for deepinfra/perplexity/anyscale/groq/friendliai we check in get_llm_provider and pass in the api base from there
|
||||
api_base = _resolve_openai_api_base(api_base)
|
||||
if custom_llm_provider == "bigmodel" and not api_key:
|
||||
if custom_llm_provider in ("bigmodel", "iteracompute") and not api_key:
|
||||
raise litellm.AuthenticationError(
|
||||
message="Set BIGMODEL_API_KEY or pass api_key", llm_provider="bigmodel", model=model
|
||||
message=f"Set {custom_llm_provider.upper()}_API_KEY or pass api_key",
|
||||
llm_provider=custom_llm_provider,
|
||||
model=model,
|
||||
)
|
||||
organization = (
|
||||
organization
|
||||
or (None if custom_llm_provider == "bigmodel" else litellm.organization or get_secret("OPENAI_ORGANIZATION"))
|
||||
or None # default - https://github.com/openai/openai-python/blob/284c1799070c723c6a553337134148a7ab088dd8/openai/util.py#L105
|
||||
organization = organization or (
|
||||
""
|
||||
if custom_llm_provider == "iteracompute"
|
||||
else None
|
||||
if custom_llm_provider == "bigmodel"
|
||||
else litellm.organization or get_secret("OPENAI_ORGANIZATION") or None
|
||||
)
|
||||
openai.organization = organization
|
||||
# set API KEY
|
||||
|
|
|
|||
|
|
@ -35200,6 +35200,521 @@
|
|||
"supports_video_input": true,
|
||||
"supports_vision": true
|
||||
},
|
||||
"iteracompute/anthropic/claude-fable-5-1": {
|
||||
"search_context_cost_per_query": {
|
||||
"search_context_size_low": 0.005,
|
||||
"search_context_size_high": 0.005,
|
||||
"search_context_size_medium": 0.005
|
||||
},
|
||||
"input_cost_per_token": 5e-06,
|
||||
"output_cost_per_token_batches": 1.25e-05,
|
||||
"cache_creation_input_token_cost": 6.25e-06,
|
||||
"provider_specific_entry": {
|
||||
"us": 1.1
|
||||
},
|
||||
"cache_creation_input_token_cost_above_1hr": 1e-05,
|
||||
"output_cost_per_token": 2.5e-05,
|
||||
"cache_read_input_token_cost": 1.25e-07,
|
||||
"input_cost_per_token_batches": 2.5e-06,
|
||||
"litellm_provider": "iteracompute",
|
||||
"mode": "chat",
|
||||
"max_input_tokens": 1000000,
|
||||
"max_output_tokens": 128000
|
||||
},
|
||||
"iteracompute/anthropic/claude-haiku-5-5": {
|
||||
"search_context_cost_per_query": {
|
||||
"search_context_size_low": 0.005,
|
||||
"search_context_size_high": 0.005,
|
||||
"search_context_size_medium": 0.005
|
||||
},
|
||||
"tiered_pricing": [
|
||||
{
|
||||
"range": [
|
||||
0,
|
||||
100000
|
||||
],
|
||||
"input_cost_per_token": 5e-08,
|
||||
"output_cost_per_token": 2.5e-07,
|
||||
"cache_read_input_token_cost": 5e-09,
|
||||
"cache_creation_input_token_cost": 6.25e-08,
|
||||
"cache_creation_input_token_cost_above_1hr": 1e-07
|
||||
},
|
||||
{
|
||||
"range": [
|
||||
100000,
|
||||
1000000
|
||||
],
|
||||
"input_cost_per_token": 2.5e-07,
|
||||
"output_cost_per_token": 1.25e-06,
|
||||
"cache_read_input_token_cost": 2.5e-08,
|
||||
"cache_creation_input_token_cost": 3.125e-07,
|
||||
"cache_creation_input_token_cost_above_1hr": 5e-07
|
||||
}
|
||||
],
|
||||
"input_cost_per_token": 5e-08,
|
||||
"output_cost_per_token_batches": 1.25e-07,
|
||||
"cache_creation_input_token_cost": 6.25e-08,
|
||||
"provider_specific_entry": {
|
||||
"us": 1.1
|
||||
},
|
||||
"cache_creation_input_token_cost_above_1hr": 1e-07,
|
||||
"output_cost_per_token": 2.5e-07,
|
||||
"cache_read_input_token_cost": 5e-09,
|
||||
"input_cost_per_token_batches": 2.5e-08,
|
||||
"litellm_provider": "iteracompute",
|
||||
"mode": "chat",
|
||||
"max_input_tokens": 1000000,
|
||||
"max_output_tokens": 128000
|
||||
},
|
||||
"iteracompute/anthropic/claude-opus-5-5": {
|
||||
"search_context_cost_per_query": {
|
||||
"search_context_size_low": 0.005,
|
||||
"search_context_size_high": 0.005,
|
||||
"search_context_size_medium": 0.005
|
||||
},
|
||||
"input_cost_per_token": 2e-06,
|
||||
"output_cost_per_token_batches": 5e-06,
|
||||
"cache_creation_input_token_cost": 2.5e-06,
|
||||
"provider_specific_entry": {
|
||||
"us": 1.1,
|
||||
"fast": 2
|
||||
},
|
||||
"cache_creation_input_token_cost_above_1hr": 4e-06,
|
||||
"output_cost_per_token": 1e-05,
|
||||
"cache_read_input_token_cost": 1e-07,
|
||||
"input_cost_per_token_batches": 1e-06,
|
||||
"litellm_provider": "iteracompute",
|
||||
"mode": "chat",
|
||||
"max_input_tokens": 1000000,
|
||||
"max_output_tokens": 128000
|
||||
},
|
||||
"iteracompute/anthropic/claude-sonnet-5-5": {
|
||||
"search_context_cost_per_query": {
|
||||
"search_context_size_low": 0.005,
|
||||
"search_context_size_high": 0.005,
|
||||
"search_context_size_medium": 0.005
|
||||
},
|
||||
"input_cost_per_token": 1e-06,
|
||||
"output_cost_per_token_batches": 2.5e-06,
|
||||
"cache_creation_input_token_cost": 1.25e-06,
|
||||
"provider_specific_entry": {
|
||||
"us": 1.1
|
||||
},
|
||||
"cache_creation_input_token_cost_above_1hr": 2e-06,
|
||||
"output_cost_per_token": 5e-06,
|
||||
"cache_read_input_token_cost": 5e-08,
|
||||
"input_cost_per_token_batches": 5e-07,
|
||||
"litellm_provider": "iteracompute",
|
||||
"mode": "chat",
|
||||
"max_input_tokens": 1000000,
|
||||
"max_output_tokens": 128000
|
||||
},
|
||||
"iteracompute/deepseek/deepseek-v4-pro-0813": {
|
||||
"input_cost_per_token": 6e-07,
|
||||
"off_peak_pricing": {
|
||||
"windows": [
|
||||
{
|
||||
"weekdays": [
|
||||
1,
|
||||
2,
|
||||
3,
|
||||
4,
|
||||
5
|
||||
],
|
||||
"hours_utc": [
|
||||
"00:00-01:00",
|
||||
"04:00-06:00",
|
||||
"10:00-00:00"
|
||||
]
|
||||
},
|
||||
{
|
||||
"weekdays": [
|
||||
6,
|
||||
7
|
||||
],
|
||||
"hours_utc": "00:00-00:00"
|
||||
}
|
||||
],
|
||||
"input_cost_per_token": 5.012658227848101e-07,
|
||||
"output_cost_per_token": 1.4891596638655463e-06,
|
||||
"cache_read_input_token_cost": 3.7230769230769236e-08
|
||||
},
|
||||
"output_cost_per_token": 1.79e-06,
|
||||
"cache_read_input_token_cost": 4.4e-08,
|
||||
"litellm_provider": "iteracompute",
|
||||
"mode": "chat",
|
||||
"max_input_tokens": 1048576,
|
||||
"max_output_tokens": 393216
|
||||
},
|
||||
"iteracompute/deepseek/deepseek-v4.1-flash": {
|
||||
"input_cost_per_token": 1.4e-07,
|
||||
"output_cost_per_token": 5.5e-07,
|
||||
"cache_read_input_token_cost": 6e-09,
|
||||
"litellm_provider": "iteracompute",
|
||||
"mode": "chat",
|
||||
"max_input_tokens": 1048576,
|
||||
"max_output_tokens": 393216
|
||||
},
|
||||
"iteracompute/deepseek/deepseek-v4.1-flash-1017": {
|
||||
"input_cost_per_token": 1.4e-07,
|
||||
"output_cost_per_token": 5.5e-07,
|
||||
"cache_read_input_token_cost": 6e-09,
|
||||
"litellm_provider": "iteracompute",
|
||||
"mode": "chat",
|
||||
"max_input_tokens": 1048576,
|
||||
"max_output_tokens": 393216
|
||||
},
|
||||
"iteracompute/gemini/gemini-3.8-flash": {
|
||||
"search_context_cost_per_query": {
|
||||
"search_context_size_low": 0.0112,
|
||||
"search_context_size_high": 0.0112,
|
||||
"search_context_size_medium": 0.0112
|
||||
},
|
||||
"cache_read_input_token_cost_flex": 3e-08,
|
||||
"google_maps_grounding_cost_per_query": 0.0112,
|
||||
"output_cost_per_reasoning_token": 3e-06,
|
||||
"input_cost_per_token": 6e-07,
|
||||
"web_search_billing_unit": "per_query",
|
||||
"input_cost_per_token_flex": 3e-07,
|
||||
"output_cost_per_token_batches": 1.5e-06,
|
||||
"cache_read_input_token_cost_priority": 1.08e-07,
|
||||
"output_cost_per_token_flex": 1.5e-06,
|
||||
"output_cost_per_token_priority": 5.4e-06,
|
||||
"output_cost_per_reasoning_token_priority": 5.4e-06,
|
||||
"output_cost_per_reasoning_token_flex": 1.5e-06,
|
||||
"output_cost_per_token": 3e-06,
|
||||
"cache_read_input_token_cost": 6e-08,
|
||||
"input_cost_per_token_priority": 1.08e-06,
|
||||
"input_cost_per_token_batches": 3e-07,
|
||||
"litellm_provider": "iteracompute",
|
||||
"mode": "chat",
|
||||
"max_input_tokens": 1048576,
|
||||
"max_output_tokens": 65536
|
||||
},
|
||||
"iteracompute/gemini/gemini-4-argon": {
|
||||
"search_context_cost_per_query": {
|
||||
"search_context_size_low": 0.0112,
|
||||
"search_context_size_high": 0.0112,
|
||||
"search_context_size_medium": 0.0112
|
||||
},
|
||||
"cache_read_input_token_cost_flex": 4e-08,
|
||||
"google_maps_grounding_cost_per_query": 0.0112,
|
||||
"output_cost_per_reasoning_token": 8e-06,
|
||||
"input_cost_per_token": 1.6e-06,
|
||||
"web_search_billing_unit": "per_query",
|
||||
"input_cost_per_token_flex": 8e-07,
|
||||
"cache_read_input_token_cost_priority": 1.4400000000000002e-07,
|
||||
"output_cost_per_token_flex": 4e-06,
|
||||
"output_cost_per_token_priority": 1.44e-05,
|
||||
"output_cost_per_reasoning_token_priority": 1.44e-05,
|
||||
"output_cost_per_reasoning_token_flex": 4e-06,
|
||||
"output_cost_per_token": 8e-06,
|
||||
"cache_read_input_token_cost": 8e-08,
|
||||
"input_cost_per_token_priority": 2.88e-06,
|
||||
"litellm_provider": "iteracompute",
|
||||
"mode": "chat",
|
||||
"max_input_tokens": 1048576,
|
||||
"max_output_tokens": 65536
|
||||
},
|
||||
"iteracompute/gemini/gemini-nano-banana-2.1": {
|
||||
"search_context_cost_per_query": {
|
||||
"search_context_size_low": 0.0112,
|
||||
"search_context_size_high": 0.0112,
|
||||
"search_context_size_medium": 0.0112
|
||||
},
|
||||
"cache_read_input_token_cost_flex": 6e-08,
|
||||
"output_cost_per_reasoning_token": 6e-06,
|
||||
"input_cost_per_token": 1.2e-06,
|
||||
"web_search_billing_unit": "per_query",
|
||||
"input_cost_per_token_flex": 6e-07,
|
||||
"output_cost_per_token_batches": 3e-06,
|
||||
"cache_read_input_token_cost_priority": 2.16e-07,
|
||||
"output_cost_per_token_flex": 3e-06,
|
||||
"output_cost_per_token_priority": 1.08e-05,
|
||||
"input_cost_per_video_token": 1.2e-06,
|
||||
"input_cost_per_image_token": 1.2e-06,
|
||||
"input_cost_per_image": 0.001344,
|
||||
"output_cost_per_token": 6e-06,
|
||||
"output_cost_per_image_token": 2.4e-05,
|
||||
"output_cost_per_image": 0.02688,
|
||||
"cache_read_input_token_cost": 1.2e-07,
|
||||
"input_cost_per_token_priority": 2.16e-06,
|
||||
"input_cost_per_token_batches": 6e-07,
|
||||
"litellm_provider": "iteracompute",
|
||||
"mode": "image_generation",
|
||||
"max_input_tokens": 131072,
|
||||
"max_output_tokens": 32768
|
||||
},
|
||||
"iteracompute/minimax/minimax-m2.5": {
|
||||
"input_cost_per_token": 2.7e-07,
|
||||
"output_cost_per_token": 1.03e-06,
|
||||
"cache_read_input_token_cost": 3e-08,
|
||||
"litellm_provider": "iteracompute",
|
||||
"mode": "chat",
|
||||
"max_input_tokens": 204800,
|
||||
"max_output_tokens": 16384
|
||||
},
|
||||
"iteracompute/minimax/minimax-m2.7": {
|
||||
"input_cost_per_token": 3.8e-07,
|
||||
"output_cost_per_token": 1.48e-06,
|
||||
"cache_read_input_token_cost": 3e-08,
|
||||
"litellm_provider": "iteracompute",
|
||||
"mode": "chat",
|
||||
"max_input_tokens": 204800,
|
||||
"max_output_tokens": 16384
|
||||
},
|
||||
"iteracompute/minimax/minimax-m3": {
|
||||
"input_cost_per_token": 3e-07,
|
||||
"output_cost_per_token": 1.19e-06,
|
||||
"cache_read_input_token_cost": 5e-08,
|
||||
"litellm_provider": "iteracompute",
|
||||
"mode": "chat",
|
||||
"max_input_tokens": 1048576,
|
||||
"max_output_tokens": 524288
|
||||
},
|
||||
"iteracompute/moonshotai/kimi-k2.5": {
|
||||
"input_cost_per_token": 5.4e-07,
|
||||
"output_cost_per_token": 2.78e-06,
|
||||
"cache_read_input_token_cost": 6e-08,
|
||||
"litellm_provider": "iteracompute",
|
||||
"mode": "chat",
|
||||
"max_input_tokens": 262144,
|
||||
"max_output_tokens": 16384
|
||||
},
|
||||
"iteracompute/moonshotai/kimi-k2.6": {
|
||||
"input_cost_per_token": 8.7e-07,
|
||||
"output_cost_per_token": 3.51e-06,
|
||||
"cache_read_input_token_cost": 7e-08,
|
||||
"litellm_provider": "iteracompute",
|
||||
"mode": "chat",
|
||||
"max_input_tokens": 262144,
|
||||
"max_output_tokens": 16384
|
||||
},
|
||||
"iteracompute/moonshotai/kimi-k2.7-code": {
|
||||
"input_cost_per_token": 6.9e-07,
|
||||
"output_cost_per_token": 3.29e-06,
|
||||
"cache_read_input_token_cost": 1.5e-07,
|
||||
"litellm_provider": "iteracompute",
|
||||
"mode": "chat",
|
||||
"max_input_tokens": 262144,
|
||||
"max_output_tokens": 262144
|
||||
},
|
||||
"iteracompute/moonshotai/kimi-k3": {
|
||||
"input_cost_per_token": 2.35e-06,
|
||||
"output_cost_per_token": 1.176e-05,
|
||||
"cache_read_input_token_cost": 2.3e-07,
|
||||
"litellm_provider": "iteracompute",
|
||||
"mode": "chat",
|
||||
"max_input_tokens": 1048576,
|
||||
"max_output_tokens": 1048576
|
||||
},
|
||||
"iteracompute/openai/gpt-6-astra": {
|
||||
"cache_read_input_token_cost_ultrafast": 4.8e-06,
|
||||
"search_context_cost_per_query": {
|
||||
"search_context_size_low": 0.008,
|
||||
"search_context_size_high": 0.008,
|
||||
"search_context_size_medium": 0.008
|
||||
},
|
||||
"cache_read_input_token_cost_flex": 4e-07,
|
||||
"input_cost_per_token_ultrafast": 4.8e-05,
|
||||
"output_cost_per_token_above_272k_tokens_priority": 0.00012,
|
||||
"cache_read_input_token_cost_above_272k_tokens_priority": 3.2e-06,
|
||||
"input_cost_per_token": 8e-06,
|
||||
"input_cost_per_token_flex": 4e-06,
|
||||
"output_cost_per_token_batches": 2e-05,
|
||||
"cache_creation_input_token_cost_above_272k_tokens_flex": 1e-05,
|
||||
"cache_read_input_token_cost_priority": 1.6e-06,
|
||||
"regional_processing_uplift_multiplier_us": 1.1,
|
||||
"cache_creation_input_token_cost": 1e-05,
|
||||
"regional_processing_uplift_multiplier_eu": 1.1,
|
||||
"cache_read_input_token_cost_above_272k_tokens_flex": 8e-07,
|
||||
"output_cost_per_token_flex": 2e-05,
|
||||
"cache_creation_input_token_cost_ultrafast": 6e-05,
|
||||
"output_cost_per_token_above_272k_tokens": 6e-05,
|
||||
"output_cost_per_token_above_272k_tokens_ultrafast": 0.00036,
|
||||
"input_cost_per_token_above_272k_tokens_ultrafast": 9.6e-05,
|
||||
"input_cost_per_token_above_272k_tokens_flex": 8e-06,
|
||||
"output_cost_per_token_ultrafast": 0.00024,
|
||||
"output_cost_per_token_priority": 8e-05,
|
||||
"input_cost_per_token_above_272k_tokens_priority": 3.2e-05,
|
||||
"cache_creation_input_token_cost_above_272k_tokens_priority": 4e-05,
|
||||
"output_cost_per_token": 4e-05,
|
||||
"cache_read_input_token_cost_above_272k_tokens": 1.6e-06,
|
||||
"cache_creation_input_token_cost_above_272k_tokens_ultrafast": 0.00012,
|
||||
"cache_creation_input_token_cost_flex": 5e-06,
|
||||
"cache_creation_input_token_cost_priority": 2e-05,
|
||||
"cache_read_input_token_cost_above_272k_tokens_ultrafast": 9.6e-06,
|
||||
"output_cost_per_token_above_272k_tokens_flex": 3e-05,
|
||||
"cache_read_input_token_cost": 8e-07,
|
||||
"input_cost_per_token_priority": 1.6e-05,
|
||||
"input_cost_per_token_batches": 4e-06,
|
||||
"cache_creation_input_token_cost_above_272k_tokens": 2e-05,
|
||||
"input_cost_per_token_above_272k_tokens": 1.6e-05,
|
||||
"litellm_provider": "iteracompute",
|
||||
"mode": "chat",
|
||||
"max_input_tokens": 1050000,
|
||||
"max_output_tokens": 128000
|
||||
},
|
||||
"iteracompute/openai/gpt-6-luna": {
|
||||
"search_context_cost_per_query": {
|
||||
"search_context_size_low": 0.008,
|
||||
"search_context_size_high": 0.008,
|
||||
"search_context_size_medium": 0.008
|
||||
},
|
||||
"cache_read_input_token_cost_flex": 4e-09,
|
||||
"output_cost_per_token_above_272k_tokens_priority": 1.2e-06,
|
||||
"cache_read_input_token_cost_above_272k_tokens_priority": 3.2e-08,
|
||||
"input_cost_per_token": 8e-08,
|
||||
"input_cost_per_token_flex": 4e-08,
|
||||
"output_cost_per_token_batches": 2e-07,
|
||||
"cache_creation_input_token_cost_above_272k_tokens_flex": 1e-07,
|
||||
"cache_read_input_token_cost_priority": 1.6e-08,
|
||||
"regional_processing_uplift_multiplier_us": 1.1,
|
||||
"cache_creation_input_token_cost": 1e-07,
|
||||
"regional_processing_uplift_multiplier_eu": 1.1,
|
||||
"cache_read_input_token_cost_above_272k_tokens_flex": 8e-09,
|
||||
"output_cost_per_token_flex": 2e-07,
|
||||
"output_cost_per_token_above_272k_tokens": 6e-07,
|
||||
"input_cost_per_token_above_272k_tokens_flex": 8e-08,
|
||||
"output_cost_per_token_priority": 8e-07,
|
||||
"input_cost_per_token_above_272k_tokens_priority": 3.2e-07,
|
||||
"cache_creation_input_token_cost_above_272k_tokens_priority": 4e-07,
|
||||
"output_cost_per_token": 4e-07,
|
||||
"cache_read_input_token_cost_above_272k_tokens": 1.6e-08,
|
||||
"cache_creation_input_token_cost_flex": 5e-08,
|
||||
"cache_creation_input_token_cost_priority": 2e-07,
|
||||
"output_cost_per_token_above_272k_tokens_flex": 3e-07,
|
||||
"cache_read_input_token_cost": 8e-09,
|
||||
"input_cost_per_token_priority": 1.6e-07,
|
||||
"input_cost_per_token_batches": 4e-08,
|
||||
"cache_creation_input_token_cost_above_272k_tokens": 2e-07,
|
||||
"input_cost_per_token_above_272k_tokens": 1.6e-07,
|
||||
"litellm_provider": "iteracompute",
|
||||
"mode": "chat",
|
||||
"max_input_tokens": 1050000,
|
||||
"max_output_tokens": 128000
|
||||
},
|
||||
"iteracompute/openai/gpt-6.1-sol": {
|
||||
"cache_read_input_token_cost_ultrafast": 4.8e-07,
|
||||
"search_context_cost_per_query": {
|
||||
"search_context_size_low": 0.008,
|
||||
"search_context_size_high": 0.008,
|
||||
"search_context_size_medium": 0.008
|
||||
},
|
||||
"cache_read_input_token_cost_flex": 4e-08,
|
||||
"input_cost_per_token_ultrafast": 9.6e-06,
|
||||
"output_cost_per_token_above_272k_tokens_priority": 2.4e-05,
|
||||
"cache_read_input_token_cost_above_272k_tokens_priority": 3.2e-07,
|
||||
"input_cost_per_token": 1.6e-06,
|
||||
"input_cost_per_token_flex": 8e-07,
|
||||
"output_cost_per_token_batches": 4e-06,
|
||||
"cache_creation_input_token_cost_above_272k_tokens_flex": 2e-06,
|
||||
"cache_read_input_token_cost_priority": 1.6e-07,
|
||||
"regional_processing_uplift_multiplier_us": 1.1,
|
||||
"cache_creation_input_token_cost": 2e-06,
|
||||
"regional_processing_uplift_multiplier_eu": 1.1,
|
||||
"cache_read_input_token_cost_above_272k_tokens_flex": 8e-08,
|
||||
"output_cost_per_token_flex": 4e-06,
|
||||
"cache_creation_input_token_cost_ultrafast": 1.2e-05,
|
||||
"output_cost_per_token_above_272k_tokens": 1.2e-05,
|
||||
"output_cost_per_token_above_272k_tokens_ultrafast": 7.2e-05,
|
||||
"input_cost_per_token_above_272k_tokens_ultrafast": 1.92e-05,
|
||||
"input_cost_per_token_above_272k_tokens_flex": 1.6e-06,
|
||||
"output_cost_per_token_ultrafast": 4.8e-05,
|
||||
"output_cost_per_token_priority": 1.6e-05,
|
||||
"input_cost_per_token_above_272k_tokens_priority": 6.4e-06,
|
||||
"cache_creation_input_token_cost_above_272k_tokens_priority": 8e-06,
|
||||
"output_cost_per_token": 8e-06,
|
||||
"cache_read_input_token_cost_above_272k_tokens": 1.6e-07,
|
||||
"cache_creation_input_token_cost_above_272k_tokens_ultrafast": 2.4e-05,
|
||||
"cache_creation_input_token_cost_flex": 1e-06,
|
||||
"cache_creation_input_token_cost_priority": 4e-06,
|
||||
"cache_read_input_token_cost_above_272k_tokens_ultrafast": 9.6e-07,
|
||||
"output_cost_per_token_above_272k_tokens_flex": 6e-06,
|
||||
"cache_read_input_token_cost": 8e-08,
|
||||
"input_cost_per_token_priority": 3.2e-06,
|
||||
"input_cost_per_token_batches": 8e-07,
|
||||
"cache_creation_input_token_cost_above_272k_tokens": 4e-06,
|
||||
"input_cost_per_token_above_272k_tokens": 3.2e-06,
|
||||
"litellm_provider": "iteracompute",
|
||||
"mode": "chat",
|
||||
"max_input_tokens": 1050000,
|
||||
"max_output_tokens": 128000
|
||||
},
|
||||
"iteracompute/openai/gpt-image-2.5-flare": {
|
||||
"input_cost_per_token": 4e-06,
|
||||
"input_cost_per_image_token": 6.4e-06,
|
||||
"output_cost_per_token": 0.0,
|
||||
"output_cost_per_image_token": 2.4e-05,
|
||||
"cache_read_input_token_cost": 1e-06,
|
||||
"input_cost_per_token_batches": 2e-06,
|
||||
"litellm_provider": "iteracompute",
|
||||
"mode": "image_generation"
|
||||
},
|
||||
"iteracompute/openai/gpt-image-2.5-sunburst": {
|
||||
"input_cost_per_token": 4e-06,
|
||||
"input_cost_per_image_token": 6.4e-06,
|
||||
"output_cost_per_token": 0.0,
|
||||
"output_cost_per_image_token": 2.4e-05,
|
||||
"cache_read_input_token_cost": 1e-06,
|
||||
"input_cost_per_token_batches": 2e-06,
|
||||
"litellm_provider": "iteracompute",
|
||||
"mode": "image_generation"
|
||||
},
|
||||
"iteracompute/qwen/qwen3.8-27b": {
|
||||
"input_cost_per_token": 0.0,
|
||||
"output_cost_per_token": 0.0,
|
||||
"cache_read_input_token_cost": 0.0,
|
||||
"litellm_provider": "iteracompute",
|
||||
"mode": "chat",
|
||||
"max_input_tokens": 262144,
|
||||
"max_output_tokens": 8192
|
||||
},
|
||||
"iteracompute/qwen/qwen3.8-flash": {
|
||||
"input_cost_per_token": 1.1e-07,
|
||||
"output_cost_per_token": 3.8e-07,
|
||||
"cache_read_input_token_cost": 1.6e-08,
|
||||
"litellm_provider": "iteracompute",
|
||||
"mode": "chat",
|
||||
"max_input_tokens": 1048576,
|
||||
"max_output_tokens": 131072
|
||||
},
|
||||
"iteracompute/qwen/qwen3.8-max": {
|
||||
"input_cost_per_token": 1.95e-06,
|
||||
"output_cost_per_token": 5.7e-06,
|
||||
"cache_read_input_token_cost": 2.5e-07,
|
||||
"litellm_provider": "iteracompute",
|
||||
"mode": "chat",
|
||||
"max_input_tokens": 1048576,
|
||||
"max_output_tokens": 131072
|
||||
},
|
||||
"iteracompute/z-ai/glm-5.2": {
|
||||
"input_cost_per_token": 5.3e-07,
|
||||
"output_cost_per_token": 1.72e-06,
|
||||
"cache_read_input_token_cost": 1.2e-07,
|
||||
"litellm_provider": "iteracompute",
|
||||
"mode": "chat",
|
||||
"max_input_tokens": 1048576,
|
||||
"max_output_tokens": 131072
|
||||
},
|
||||
"iteracompute/z-ai/glm-5.3": {
|
||||
"input_cost_per_token": 8.2e-07,
|
||||
"output_cost_per_token": 2.88e-06,
|
||||
"cache_read_input_token_cost": 2e-07,
|
||||
"litellm_provider": "iteracompute",
|
||||
"mode": "chat",
|
||||
"max_input_tokens": 1048576,
|
||||
"max_output_tokens": 131072
|
||||
},
|
||||
"iteracompute/z-ai/glm-5.3-flash": {
|
||||
"input_cost_per_token": 8e-08,
|
||||
"output_cost_per_token": 2.8e-07,
|
||||
"cache_read_input_token_cost": 2.3e-08,
|
||||
"litellm_provider": "iteracompute",
|
||||
"mode": "chat",
|
||||
"max_input_tokens": 1048576,
|
||||
"max_output_tokens": 131072
|
||||
},
|
||||
"gpt-3.5-turbo": {
|
||||
"deprecation_date": "2026-10-23",
|
||||
"deprecation_source": "https://developers.openai.com/api/docs/deprecations",
|
||||
|
|
|
|||
|
|
@ -33,6 +33,36 @@
|
|||
}
|
||||
},
|
||||
"providers": {
|
||||
"iteracompute": {
|
||||
"display_name": "IteraCompute (`iteracompute`)",
|
||||
"url": "https://docs.litellm.ai/docs/providers/iteracompute",
|
||||
"endpoints": {
|
||||
"chat_completions": true,
|
||||
"systemone": false,
|
||||
"messages": true,
|
||||
"responses": true,
|
||||
"embeddings": false,
|
||||
"image_generations": false,
|
||||
"audio_transcriptions": false,
|
||||
"audio_speech": false,
|
||||
"moderations": false,
|
||||
"batches": false,
|
||||
"rerank": false,
|
||||
"ocr": false,
|
||||
"search": false,
|
||||
"skills": false,
|
||||
"interactions": false,
|
||||
"a2a_(Agent Gateway)": false,
|
||||
"container": false,
|
||||
"container_file": false,
|
||||
"compact": false,
|
||||
"files": false,
|
||||
"image_edits": false,
|
||||
"vector_stores_create": false,
|
||||
"vector_stores_search": false,
|
||||
"video_generations": false
|
||||
}
|
||||
},
|
||||
"refuseless": {
|
||||
"display_name": "Refuseless (`refuseless`)",
|
||||
"url": "https://docs.litellm.ai/docs/providers/refuseless",
|
||||
|
|
|
|||
|
|
@ -4508,5 +4508,33 @@
|
|||
}
|
||||
],
|
||||
"default_model_placeholder": "bigmodel/glm-5.3"
|
||||
},
|
||||
{
|
||||
"provider": "ITERACOMPUTE",
|
||||
"provider_display_name": "IteraCompute",
|
||||
"litellm_provider": "iteracompute",
|
||||
"credential_fields": [
|
||||
{
|
||||
"key": "api_base",
|
||||
"label": "API Base",
|
||||
"placeholder": "https://api.iteracompute.com/v1",
|
||||
"tooltip": null,
|
||||
"required": false,
|
||||
"field_type": "text",
|
||||
"options": null,
|
||||
"default_value": null
|
||||
},
|
||||
{
|
||||
"key": "api_key",
|
||||
"label": "API Key",
|
||||
"placeholder": null,
|
||||
"tooltip": null,
|
||||
"required": true,
|
||||
"field_type": "password",
|
||||
"options": null,
|
||||
"default_value": null
|
||||
}
|
||||
],
|
||||
"default_model_placeholder": "iteracompute/qwen/qwen3.8-27b"
|
||||
}
|
||||
]
|
||||
|
|
|
|||
|
|
@ -4780,6 +4780,7 @@ class LlmProviders(str, Enum):
|
|||
SAIL = "sail"
|
||||
REKA = "reka"
|
||||
STREAMLAKE = "streamlake"
|
||||
ITERACOMPUTE = "iteracompute"
|
||||
WALLY = "wally"
|
||||
LITELLM_AGENT = "litellm_agent"
|
||||
CURSOR = "cursor"
|
||||
|
|
|
|||
|
|
@ -35200,6 +35200,521 @@
|
|||
"supports_video_input": true,
|
||||
"supports_vision": true
|
||||
},
|
||||
"iteracompute/anthropic/claude-fable-5-1": {
|
||||
"search_context_cost_per_query": {
|
||||
"search_context_size_low": 0.005,
|
||||
"search_context_size_high": 0.005,
|
||||
"search_context_size_medium": 0.005
|
||||
},
|
||||
"input_cost_per_token": 5e-06,
|
||||
"output_cost_per_token_batches": 1.25e-05,
|
||||
"cache_creation_input_token_cost": 6.25e-06,
|
||||
"provider_specific_entry": {
|
||||
"us": 1.1
|
||||
},
|
||||
"cache_creation_input_token_cost_above_1hr": 1e-05,
|
||||
"output_cost_per_token": 2.5e-05,
|
||||
"cache_read_input_token_cost": 1.25e-07,
|
||||
"input_cost_per_token_batches": 2.5e-06,
|
||||
"litellm_provider": "iteracompute",
|
||||
"mode": "chat",
|
||||
"max_input_tokens": 1000000,
|
||||
"max_output_tokens": 128000
|
||||
},
|
||||
"iteracompute/anthropic/claude-haiku-5-5": {
|
||||
"search_context_cost_per_query": {
|
||||
"search_context_size_low": 0.005,
|
||||
"search_context_size_high": 0.005,
|
||||
"search_context_size_medium": 0.005
|
||||
},
|
||||
"tiered_pricing": [
|
||||
{
|
||||
"range": [
|
||||
0,
|
||||
100000
|
||||
],
|
||||
"input_cost_per_token": 5e-08,
|
||||
"output_cost_per_token": 2.5e-07,
|
||||
"cache_read_input_token_cost": 5e-09,
|
||||
"cache_creation_input_token_cost": 6.25e-08,
|
||||
"cache_creation_input_token_cost_above_1hr": 1e-07
|
||||
},
|
||||
{
|
||||
"range": [
|
||||
100000,
|
||||
1000000
|
||||
],
|
||||
"input_cost_per_token": 2.5e-07,
|
||||
"output_cost_per_token": 1.25e-06,
|
||||
"cache_read_input_token_cost": 2.5e-08,
|
||||
"cache_creation_input_token_cost": 3.125e-07,
|
||||
"cache_creation_input_token_cost_above_1hr": 5e-07
|
||||
}
|
||||
],
|
||||
"input_cost_per_token": 5e-08,
|
||||
"output_cost_per_token_batches": 1.25e-07,
|
||||
"cache_creation_input_token_cost": 6.25e-08,
|
||||
"provider_specific_entry": {
|
||||
"us": 1.1
|
||||
},
|
||||
"cache_creation_input_token_cost_above_1hr": 1e-07,
|
||||
"output_cost_per_token": 2.5e-07,
|
||||
"cache_read_input_token_cost": 5e-09,
|
||||
"input_cost_per_token_batches": 2.5e-08,
|
||||
"litellm_provider": "iteracompute",
|
||||
"mode": "chat",
|
||||
"max_input_tokens": 1000000,
|
||||
"max_output_tokens": 128000
|
||||
},
|
||||
"iteracompute/anthropic/claude-opus-5-5": {
|
||||
"search_context_cost_per_query": {
|
||||
"search_context_size_low": 0.005,
|
||||
"search_context_size_high": 0.005,
|
||||
"search_context_size_medium": 0.005
|
||||
},
|
||||
"input_cost_per_token": 2e-06,
|
||||
"output_cost_per_token_batches": 5e-06,
|
||||
"cache_creation_input_token_cost": 2.5e-06,
|
||||
"provider_specific_entry": {
|
||||
"us": 1.1,
|
||||
"fast": 2
|
||||
},
|
||||
"cache_creation_input_token_cost_above_1hr": 4e-06,
|
||||
"output_cost_per_token": 1e-05,
|
||||
"cache_read_input_token_cost": 1e-07,
|
||||
"input_cost_per_token_batches": 1e-06,
|
||||
"litellm_provider": "iteracompute",
|
||||
"mode": "chat",
|
||||
"max_input_tokens": 1000000,
|
||||
"max_output_tokens": 128000
|
||||
},
|
||||
"iteracompute/anthropic/claude-sonnet-5-5": {
|
||||
"search_context_cost_per_query": {
|
||||
"search_context_size_low": 0.005,
|
||||
"search_context_size_high": 0.005,
|
||||
"search_context_size_medium": 0.005
|
||||
},
|
||||
"input_cost_per_token": 1e-06,
|
||||
"output_cost_per_token_batches": 2.5e-06,
|
||||
"cache_creation_input_token_cost": 1.25e-06,
|
||||
"provider_specific_entry": {
|
||||
"us": 1.1
|
||||
},
|
||||
"cache_creation_input_token_cost_above_1hr": 2e-06,
|
||||
"output_cost_per_token": 5e-06,
|
||||
"cache_read_input_token_cost": 5e-08,
|
||||
"input_cost_per_token_batches": 5e-07,
|
||||
"litellm_provider": "iteracompute",
|
||||
"mode": "chat",
|
||||
"max_input_tokens": 1000000,
|
||||
"max_output_tokens": 128000
|
||||
},
|
||||
"iteracompute/deepseek/deepseek-v4-pro-0813": {
|
||||
"input_cost_per_token": 6e-07,
|
||||
"off_peak_pricing": {
|
||||
"windows": [
|
||||
{
|
||||
"weekdays": [
|
||||
1,
|
||||
2,
|
||||
3,
|
||||
4,
|
||||
5
|
||||
],
|
||||
"hours_utc": [
|
||||
"00:00-01:00",
|
||||
"04:00-06:00",
|
||||
"10:00-00:00"
|
||||
]
|
||||
},
|
||||
{
|
||||
"weekdays": [
|
||||
6,
|
||||
7
|
||||
],
|
||||
"hours_utc": "00:00-00:00"
|
||||
}
|
||||
],
|
||||
"input_cost_per_token": 5.012658227848101e-07,
|
||||
"output_cost_per_token": 1.4891596638655463e-06,
|
||||
"cache_read_input_token_cost": 3.7230769230769236e-08
|
||||
},
|
||||
"output_cost_per_token": 1.79e-06,
|
||||
"cache_read_input_token_cost": 4.4e-08,
|
||||
"litellm_provider": "iteracompute",
|
||||
"mode": "chat",
|
||||
"max_input_tokens": 1048576,
|
||||
"max_output_tokens": 393216
|
||||
},
|
||||
"iteracompute/deepseek/deepseek-v4.1-flash": {
|
||||
"input_cost_per_token": 1.4e-07,
|
||||
"output_cost_per_token": 5.5e-07,
|
||||
"cache_read_input_token_cost": 6e-09,
|
||||
"litellm_provider": "iteracompute",
|
||||
"mode": "chat",
|
||||
"max_input_tokens": 1048576,
|
||||
"max_output_tokens": 393216
|
||||
},
|
||||
"iteracompute/deepseek/deepseek-v4.1-flash-1017": {
|
||||
"input_cost_per_token": 1.4e-07,
|
||||
"output_cost_per_token": 5.5e-07,
|
||||
"cache_read_input_token_cost": 6e-09,
|
||||
"litellm_provider": "iteracompute",
|
||||
"mode": "chat",
|
||||
"max_input_tokens": 1048576,
|
||||
"max_output_tokens": 393216
|
||||
},
|
||||
"iteracompute/gemini/gemini-3.8-flash": {
|
||||
"search_context_cost_per_query": {
|
||||
"search_context_size_low": 0.0112,
|
||||
"search_context_size_high": 0.0112,
|
||||
"search_context_size_medium": 0.0112
|
||||
},
|
||||
"cache_read_input_token_cost_flex": 3e-08,
|
||||
"google_maps_grounding_cost_per_query": 0.0112,
|
||||
"output_cost_per_reasoning_token": 3e-06,
|
||||
"input_cost_per_token": 6e-07,
|
||||
"web_search_billing_unit": "per_query",
|
||||
"input_cost_per_token_flex": 3e-07,
|
||||
"output_cost_per_token_batches": 1.5e-06,
|
||||
"cache_read_input_token_cost_priority": 1.08e-07,
|
||||
"output_cost_per_token_flex": 1.5e-06,
|
||||
"output_cost_per_token_priority": 5.4e-06,
|
||||
"output_cost_per_reasoning_token_priority": 5.4e-06,
|
||||
"output_cost_per_reasoning_token_flex": 1.5e-06,
|
||||
"output_cost_per_token": 3e-06,
|
||||
"cache_read_input_token_cost": 6e-08,
|
||||
"input_cost_per_token_priority": 1.08e-06,
|
||||
"input_cost_per_token_batches": 3e-07,
|
||||
"litellm_provider": "iteracompute",
|
||||
"mode": "chat",
|
||||
"max_input_tokens": 1048576,
|
||||
"max_output_tokens": 65536
|
||||
},
|
||||
"iteracompute/gemini/gemini-4-argon": {
|
||||
"search_context_cost_per_query": {
|
||||
"search_context_size_low": 0.0112,
|
||||
"search_context_size_high": 0.0112,
|
||||
"search_context_size_medium": 0.0112
|
||||
},
|
||||
"cache_read_input_token_cost_flex": 4e-08,
|
||||
"google_maps_grounding_cost_per_query": 0.0112,
|
||||
"output_cost_per_reasoning_token": 8e-06,
|
||||
"input_cost_per_token": 1.6e-06,
|
||||
"web_search_billing_unit": "per_query",
|
||||
"input_cost_per_token_flex": 8e-07,
|
||||
"cache_read_input_token_cost_priority": 1.4400000000000002e-07,
|
||||
"output_cost_per_token_flex": 4e-06,
|
||||
"output_cost_per_token_priority": 1.44e-05,
|
||||
"output_cost_per_reasoning_token_priority": 1.44e-05,
|
||||
"output_cost_per_reasoning_token_flex": 4e-06,
|
||||
"output_cost_per_token": 8e-06,
|
||||
"cache_read_input_token_cost": 8e-08,
|
||||
"input_cost_per_token_priority": 2.88e-06,
|
||||
"litellm_provider": "iteracompute",
|
||||
"mode": "chat",
|
||||
"max_input_tokens": 1048576,
|
||||
"max_output_tokens": 65536
|
||||
},
|
||||
"iteracompute/gemini/gemini-nano-banana-2.1": {
|
||||
"search_context_cost_per_query": {
|
||||
"search_context_size_low": 0.0112,
|
||||
"search_context_size_high": 0.0112,
|
||||
"search_context_size_medium": 0.0112
|
||||
},
|
||||
"cache_read_input_token_cost_flex": 6e-08,
|
||||
"output_cost_per_reasoning_token": 6e-06,
|
||||
"input_cost_per_token": 1.2e-06,
|
||||
"web_search_billing_unit": "per_query",
|
||||
"input_cost_per_token_flex": 6e-07,
|
||||
"output_cost_per_token_batches": 3e-06,
|
||||
"cache_read_input_token_cost_priority": 2.16e-07,
|
||||
"output_cost_per_token_flex": 3e-06,
|
||||
"output_cost_per_token_priority": 1.08e-05,
|
||||
"input_cost_per_video_token": 1.2e-06,
|
||||
"input_cost_per_image_token": 1.2e-06,
|
||||
"input_cost_per_image": 0.001344,
|
||||
"output_cost_per_token": 6e-06,
|
||||
"output_cost_per_image_token": 2.4e-05,
|
||||
"output_cost_per_image": 0.02688,
|
||||
"cache_read_input_token_cost": 1.2e-07,
|
||||
"input_cost_per_token_priority": 2.16e-06,
|
||||
"input_cost_per_token_batches": 6e-07,
|
||||
"litellm_provider": "iteracompute",
|
||||
"mode": "image_generation",
|
||||
"max_input_tokens": 131072,
|
||||
"max_output_tokens": 32768
|
||||
},
|
||||
"iteracompute/minimax/minimax-m2.5": {
|
||||
"input_cost_per_token": 2.7e-07,
|
||||
"output_cost_per_token": 1.03e-06,
|
||||
"cache_read_input_token_cost": 3e-08,
|
||||
"litellm_provider": "iteracompute",
|
||||
"mode": "chat",
|
||||
"max_input_tokens": 204800,
|
||||
"max_output_tokens": 16384
|
||||
},
|
||||
"iteracompute/minimax/minimax-m2.7": {
|
||||
"input_cost_per_token": 3.8e-07,
|
||||
"output_cost_per_token": 1.48e-06,
|
||||
"cache_read_input_token_cost": 3e-08,
|
||||
"litellm_provider": "iteracompute",
|
||||
"mode": "chat",
|
||||
"max_input_tokens": 204800,
|
||||
"max_output_tokens": 16384
|
||||
},
|
||||
"iteracompute/minimax/minimax-m3": {
|
||||
"input_cost_per_token": 3e-07,
|
||||
"output_cost_per_token": 1.19e-06,
|
||||
"cache_read_input_token_cost": 5e-08,
|
||||
"litellm_provider": "iteracompute",
|
||||
"mode": "chat",
|
||||
"max_input_tokens": 1048576,
|
||||
"max_output_tokens": 524288
|
||||
},
|
||||
"iteracompute/moonshotai/kimi-k2.5": {
|
||||
"input_cost_per_token": 5.4e-07,
|
||||
"output_cost_per_token": 2.78e-06,
|
||||
"cache_read_input_token_cost": 6e-08,
|
||||
"litellm_provider": "iteracompute",
|
||||
"mode": "chat",
|
||||
"max_input_tokens": 262144,
|
||||
"max_output_tokens": 16384
|
||||
},
|
||||
"iteracompute/moonshotai/kimi-k2.6": {
|
||||
"input_cost_per_token": 8.7e-07,
|
||||
"output_cost_per_token": 3.51e-06,
|
||||
"cache_read_input_token_cost": 7e-08,
|
||||
"litellm_provider": "iteracompute",
|
||||
"mode": "chat",
|
||||
"max_input_tokens": 262144,
|
||||
"max_output_tokens": 16384
|
||||
},
|
||||
"iteracompute/moonshotai/kimi-k2.7-code": {
|
||||
"input_cost_per_token": 6.9e-07,
|
||||
"output_cost_per_token": 3.29e-06,
|
||||
"cache_read_input_token_cost": 1.5e-07,
|
||||
"litellm_provider": "iteracompute",
|
||||
"mode": "chat",
|
||||
"max_input_tokens": 262144,
|
||||
"max_output_tokens": 262144
|
||||
},
|
||||
"iteracompute/moonshotai/kimi-k3": {
|
||||
"input_cost_per_token": 2.35e-06,
|
||||
"output_cost_per_token": 1.176e-05,
|
||||
"cache_read_input_token_cost": 2.3e-07,
|
||||
"litellm_provider": "iteracompute",
|
||||
"mode": "chat",
|
||||
"max_input_tokens": 1048576,
|
||||
"max_output_tokens": 1048576
|
||||
},
|
||||
"iteracompute/openai/gpt-6-astra": {
|
||||
"cache_read_input_token_cost_ultrafast": 4.8e-06,
|
||||
"search_context_cost_per_query": {
|
||||
"search_context_size_low": 0.008,
|
||||
"search_context_size_high": 0.008,
|
||||
"search_context_size_medium": 0.008
|
||||
},
|
||||
"cache_read_input_token_cost_flex": 4e-07,
|
||||
"input_cost_per_token_ultrafast": 4.8e-05,
|
||||
"output_cost_per_token_above_272k_tokens_priority": 0.00012,
|
||||
"cache_read_input_token_cost_above_272k_tokens_priority": 3.2e-06,
|
||||
"input_cost_per_token": 8e-06,
|
||||
"input_cost_per_token_flex": 4e-06,
|
||||
"output_cost_per_token_batches": 2e-05,
|
||||
"cache_creation_input_token_cost_above_272k_tokens_flex": 1e-05,
|
||||
"cache_read_input_token_cost_priority": 1.6e-06,
|
||||
"regional_processing_uplift_multiplier_us": 1.1,
|
||||
"cache_creation_input_token_cost": 1e-05,
|
||||
"regional_processing_uplift_multiplier_eu": 1.1,
|
||||
"cache_read_input_token_cost_above_272k_tokens_flex": 8e-07,
|
||||
"output_cost_per_token_flex": 2e-05,
|
||||
"cache_creation_input_token_cost_ultrafast": 6e-05,
|
||||
"output_cost_per_token_above_272k_tokens": 6e-05,
|
||||
"output_cost_per_token_above_272k_tokens_ultrafast": 0.00036,
|
||||
"input_cost_per_token_above_272k_tokens_ultrafast": 9.6e-05,
|
||||
"input_cost_per_token_above_272k_tokens_flex": 8e-06,
|
||||
"output_cost_per_token_ultrafast": 0.00024,
|
||||
"output_cost_per_token_priority": 8e-05,
|
||||
"input_cost_per_token_above_272k_tokens_priority": 3.2e-05,
|
||||
"cache_creation_input_token_cost_above_272k_tokens_priority": 4e-05,
|
||||
"output_cost_per_token": 4e-05,
|
||||
"cache_read_input_token_cost_above_272k_tokens": 1.6e-06,
|
||||
"cache_creation_input_token_cost_above_272k_tokens_ultrafast": 0.00012,
|
||||
"cache_creation_input_token_cost_flex": 5e-06,
|
||||
"cache_creation_input_token_cost_priority": 2e-05,
|
||||
"cache_read_input_token_cost_above_272k_tokens_ultrafast": 9.6e-06,
|
||||
"output_cost_per_token_above_272k_tokens_flex": 3e-05,
|
||||
"cache_read_input_token_cost": 8e-07,
|
||||
"input_cost_per_token_priority": 1.6e-05,
|
||||
"input_cost_per_token_batches": 4e-06,
|
||||
"cache_creation_input_token_cost_above_272k_tokens": 2e-05,
|
||||
"input_cost_per_token_above_272k_tokens": 1.6e-05,
|
||||
"litellm_provider": "iteracompute",
|
||||
"mode": "chat",
|
||||
"max_input_tokens": 1050000,
|
||||
"max_output_tokens": 128000
|
||||
},
|
||||
"iteracompute/openai/gpt-6-luna": {
|
||||
"search_context_cost_per_query": {
|
||||
"search_context_size_low": 0.008,
|
||||
"search_context_size_high": 0.008,
|
||||
"search_context_size_medium": 0.008
|
||||
},
|
||||
"cache_read_input_token_cost_flex": 4e-09,
|
||||
"output_cost_per_token_above_272k_tokens_priority": 1.2e-06,
|
||||
"cache_read_input_token_cost_above_272k_tokens_priority": 3.2e-08,
|
||||
"input_cost_per_token": 8e-08,
|
||||
"input_cost_per_token_flex": 4e-08,
|
||||
"output_cost_per_token_batches": 2e-07,
|
||||
"cache_creation_input_token_cost_above_272k_tokens_flex": 1e-07,
|
||||
"cache_read_input_token_cost_priority": 1.6e-08,
|
||||
"regional_processing_uplift_multiplier_us": 1.1,
|
||||
"cache_creation_input_token_cost": 1e-07,
|
||||
"regional_processing_uplift_multiplier_eu": 1.1,
|
||||
"cache_read_input_token_cost_above_272k_tokens_flex": 8e-09,
|
||||
"output_cost_per_token_flex": 2e-07,
|
||||
"output_cost_per_token_above_272k_tokens": 6e-07,
|
||||
"input_cost_per_token_above_272k_tokens_flex": 8e-08,
|
||||
"output_cost_per_token_priority": 8e-07,
|
||||
"input_cost_per_token_above_272k_tokens_priority": 3.2e-07,
|
||||
"cache_creation_input_token_cost_above_272k_tokens_priority": 4e-07,
|
||||
"output_cost_per_token": 4e-07,
|
||||
"cache_read_input_token_cost_above_272k_tokens": 1.6e-08,
|
||||
"cache_creation_input_token_cost_flex": 5e-08,
|
||||
"cache_creation_input_token_cost_priority": 2e-07,
|
||||
"output_cost_per_token_above_272k_tokens_flex": 3e-07,
|
||||
"cache_read_input_token_cost": 8e-09,
|
||||
"input_cost_per_token_priority": 1.6e-07,
|
||||
"input_cost_per_token_batches": 4e-08,
|
||||
"cache_creation_input_token_cost_above_272k_tokens": 2e-07,
|
||||
"input_cost_per_token_above_272k_tokens": 1.6e-07,
|
||||
"litellm_provider": "iteracompute",
|
||||
"mode": "chat",
|
||||
"max_input_tokens": 1050000,
|
||||
"max_output_tokens": 128000
|
||||
},
|
||||
"iteracompute/openai/gpt-6.1-sol": {
|
||||
"cache_read_input_token_cost_ultrafast": 4.8e-07,
|
||||
"search_context_cost_per_query": {
|
||||
"search_context_size_low": 0.008,
|
||||
"search_context_size_high": 0.008,
|
||||
"search_context_size_medium": 0.008
|
||||
},
|
||||
"cache_read_input_token_cost_flex": 4e-08,
|
||||
"input_cost_per_token_ultrafast": 9.6e-06,
|
||||
"output_cost_per_token_above_272k_tokens_priority": 2.4e-05,
|
||||
"cache_read_input_token_cost_above_272k_tokens_priority": 3.2e-07,
|
||||
"input_cost_per_token": 1.6e-06,
|
||||
"input_cost_per_token_flex": 8e-07,
|
||||
"output_cost_per_token_batches": 4e-06,
|
||||
"cache_creation_input_token_cost_above_272k_tokens_flex": 2e-06,
|
||||
"cache_read_input_token_cost_priority": 1.6e-07,
|
||||
"regional_processing_uplift_multiplier_us": 1.1,
|
||||
"cache_creation_input_token_cost": 2e-06,
|
||||
"regional_processing_uplift_multiplier_eu": 1.1,
|
||||
"cache_read_input_token_cost_above_272k_tokens_flex": 8e-08,
|
||||
"output_cost_per_token_flex": 4e-06,
|
||||
"cache_creation_input_token_cost_ultrafast": 1.2e-05,
|
||||
"output_cost_per_token_above_272k_tokens": 1.2e-05,
|
||||
"output_cost_per_token_above_272k_tokens_ultrafast": 7.2e-05,
|
||||
"input_cost_per_token_above_272k_tokens_ultrafast": 1.92e-05,
|
||||
"input_cost_per_token_above_272k_tokens_flex": 1.6e-06,
|
||||
"output_cost_per_token_ultrafast": 4.8e-05,
|
||||
"output_cost_per_token_priority": 1.6e-05,
|
||||
"input_cost_per_token_above_272k_tokens_priority": 6.4e-06,
|
||||
"cache_creation_input_token_cost_above_272k_tokens_priority": 8e-06,
|
||||
"output_cost_per_token": 8e-06,
|
||||
"cache_read_input_token_cost_above_272k_tokens": 1.6e-07,
|
||||
"cache_creation_input_token_cost_above_272k_tokens_ultrafast": 2.4e-05,
|
||||
"cache_creation_input_token_cost_flex": 1e-06,
|
||||
"cache_creation_input_token_cost_priority": 4e-06,
|
||||
"cache_read_input_token_cost_above_272k_tokens_ultrafast": 9.6e-07,
|
||||
"output_cost_per_token_above_272k_tokens_flex": 6e-06,
|
||||
"cache_read_input_token_cost": 8e-08,
|
||||
"input_cost_per_token_priority": 3.2e-06,
|
||||
"input_cost_per_token_batches": 8e-07,
|
||||
"cache_creation_input_token_cost_above_272k_tokens": 4e-06,
|
||||
"input_cost_per_token_above_272k_tokens": 3.2e-06,
|
||||
"litellm_provider": "iteracompute",
|
||||
"mode": "chat",
|
||||
"max_input_tokens": 1050000,
|
||||
"max_output_tokens": 128000
|
||||
},
|
||||
"iteracompute/openai/gpt-image-2.5-flare": {
|
||||
"input_cost_per_token": 4e-06,
|
||||
"input_cost_per_image_token": 6.4e-06,
|
||||
"output_cost_per_token": 0.0,
|
||||
"output_cost_per_image_token": 2.4e-05,
|
||||
"cache_read_input_token_cost": 1e-06,
|
||||
"input_cost_per_token_batches": 2e-06,
|
||||
"litellm_provider": "iteracompute",
|
||||
"mode": "image_generation"
|
||||
},
|
||||
"iteracompute/openai/gpt-image-2.5-sunburst": {
|
||||
"input_cost_per_token": 4e-06,
|
||||
"input_cost_per_image_token": 6.4e-06,
|
||||
"output_cost_per_token": 0.0,
|
||||
"output_cost_per_image_token": 2.4e-05,
|
||||
"cache_read_input_token_cost": 1e-06,
|
||||
"input_cost_per_token_batches": 2e-06,
|
||||
"litellm_provider": "iteracompute",
|
||||
"mode": "image_generation"
|
||||
},
|
||||
"iteracompute/qwen/qwen3.8-27b": {
|
||||
"input_cost_per_token": 0.0,
|
||||
"output_cost_per_token": 0.0,
|
||||
"cache_read_input_token_cost": 0.0,
|
||||
"litellm_provider": "iteracompute",
|
||||
"mode": "chat",
|
||||
"max_input_tokens": 262144,
|
||||
"max_output_tokens": 8192
|
||||
},
|
||||
"iteracompute/qwen/qwen3.8-flash": {
|
||||
"input_cost_per_token": 1.1e-07,
|
||||
"output_cost_per_token": 3.8e-07,
|
||||
"cache_read_input_token_cost": 1.6e-08,
|
||||
"litellm_provider": "iteracompute",
|
||||
"mode": "chat",
|
||||
"max_input_tokens": 1048576,
|
||||
"max_output_tokens": 131072
|
||||
},
|
||||
"iteracompute/qwen/qwen3.8-max": {
|
||||
"input_cost_per_token": 1.95e-06,
|
||||
"output_cost_per_token": 5.7e-06,
|
||||
"cache_read_input_token_cost": 2.5e-07,
|
||||
"litellm_provider": "iteracompute",
|
||||
"mode": "chat",
|
||||
"max_input_tokens": 1048576,
|
||||
"max_output_tokens": 131072
|
||||
},
|
||||
"iteracompute/z-ai/glm-5.2": {
|
||||
"input_cost_per_token": 5.3e-07,
|
||||
"output_cost_per_token": 1.72e-06,
|
||||
"cache_read_input_token_cost": 1.2e-07,
|
||||
"litellm_provider": "iteracompute",
|
||||
"mode": "chat",
|
||||
"max_input_tokens": 1048576,
|
||||
"max_output_tokens": 131072
|
||||
},
|
||||
"iteracompute/z-ai/glm-5.3": {
|
||||
"input_cost_per_token": 8.2e-07,
|
||||
"output_cost_per_token": 2.88e-06,
|
||||
"cache_read_input_token_cost": 2e-07,
|
||||
"litellm_provider": "iteracompute",
|
||||
"mode": "chat",
|
||||
"max_input_tokens": 1048576,
|
||||
"max_output_tokens": 131072
|
||||
},
|
||||
"iteracompute/z-ai/glm-5.3-flash": {
|
||||
"input_cost_per_token": 8e-08,
|
||||
"output_cost_per_token": 2.8e-07,
|
||||
"cache_read_input_token_cost": 2.3e-08,
|
||||
"litellm_provider": "iteracompute",
|
||||
"mode": "chat",
|
||||
"max_input_tokens": 1048576,
|
||||
"max_output_tokens": 131072
|
||||
},
|
||||
"gpt-3.5-turbo": {
|
||||
"deprecation_date": "2026-10-23",
|
||||
"deprecation_source": "https://developers.openai.com/api/docs/deprecations",
|
||||
|
|
|
|||
|
|
@ -33,6 +33,36 @@
|
|||
}
|
||||
},
|
||||
"providers": {
|
||||
"iteracompute": {
|
||||
"display_name": "IteraCompute (`iteracompute`)",
|
||||
"url": "https://docs.litellm.ai/docs/providers/iteracompute",
|
||||
"endpoints": {
|
||||
"chat_completions": true,
|
||||
"systemone": false,
|
||||
"messages": true,
|
||||
"responses": true,
|
||||
"embeddings": false,
|
||||
"image_generations": false,
|
||||
"audio_transcriptions": false,
|
||||
"audio_speech": false,
|
||||
"moderations": false,
|
||||
"batches": false,
|
||||
"rerank": false,
|
||||
"ocr": false,
|
||||
"search": false,
|
||||
"skills": false,
|
||||
"interactions": false,
|
||||
"a2a_(Agent Gateway)": false,
|
||||
"container": false,
|
||||
"container_file": false,
|
||||
"compact": false,
|
||||
"files": false,
|
||||
"image_edits": false,
|
||||
"vector_stores_create": false,
|
||||
"vector_stores_search": false,
|
||||
"video_generations": false
|
||||
}
|
||||
},
|
||||
"refuseless": {
|
||||
"display_name": "Refuseless (`refuseless`)",
|
||||
"url": "https://docs.litellm.ai/docs/providers/refuseless",
|
||||
|
|
|
|||
218
tests/unit/llms/openai_like/test_iteracompute_provider.py
Normal file
218
tests/unit/llms/openai_like/test_iteracompute_provider.py
Normal file
|
|
@ -0,0 +1,218 @@
|
|||
import json
|
||||
from typing import Final
|
||||
|
||||
import pytest
|
||||
import respx
|
||||
|
||||
import litellm
|
||||
from litellm.caching.llm_caching_handler import LLMClientCache
|
||||
from litellm.litellm_core_utils.get_llm_provider_logic import get_llm_provider
|
||||
|
||||
_COMPLETION: Final = {
|
||||
"id": "chatcmpl_test",
|
||||
"object": "chat.completion",
|
||||
"created": 1_790_000_000,
|
||||
"model": "qwen/qwen3.8-27b",
|
||||
"choices": [
|
||||
{
|
||||
"index": 0,
|
||||
"message": {"role": "assistant", "content": "Hello"},
|
||||
"finish_reason": "stop",
|
||||
}
|
||||
],
|
||||
"usage": {"prompt_tokens": 4, "completion_tokens": 3, "total_tokens": 7},
|
||||
}
|
||||
|
||||
|
||||
@pytest.mark.parametrize(
|
||||
"model,custom_provider,api_base",
|
||||
(
|
||||
("iteracompute/qwen/qwen3.8-27b", None, None),
|
||||
("qwen/qwen3.8-27b", "iteracompute", None),
|
||||
("qwen/qwen3.8-27b", None, "https://api.iteracompute.com/v1"),
|
||||
),
|
||||
)
|
||||
def test_provider_resolution_preserves_model_namespace(
|
||||
monkeypatch: pytest.MonkeyPatch,
|
||||
model: str,
|
||||
custom_provider: str | None,
|
||||
api_base: str | None,
|
||||
) -> None:
|
||||
monkeypatch.setenv("ITERACOMPUTE_API_KEY", "test-key")
|
||||
monkeypatch.delenv("ITERACOMPUTE_API_BASE", raising=False)
|
||||
|
||||
assert get_llm_provider(
|
||||
model=model,
|
||||
custom_llm_provider=custom_provider,
|
||||
api_base=api_base,
|
||||
api_key=None,
|
||||
) == (
|
||||
"qwen/qwen3.8-27b",
|
||||
"iteracompute",
|
||||
"test-key",
|
||||
"https://api.iteracompute.com/v1",
|
||||
)
|
||||
|
||||
|
||||
@pytest.mark.parametrize("explicit", (False, True))
|
||||
def test_credentials_respect_explicit_arguments_before_environment(
|
||||
monkeypatch: pytest.MonkeyPatch, explicit: bool
|
||||
) -> None:
|
||||
monkeypatch.setenv("ITERACOMPUTE_API_KEY", "env-key")
|
||||
monkeypatch.setenv("ITERACOMPUTE_API_BASE", "https://env.example/v1")
|
||||
|
||||
assert get_llm_provider(
|
||||
model="iteracompute/qwen/qwen3.8-27b",
|
||||
custom_llm_provider=None,
|
||||
api_base="https://explicit.example/v1" if explicit else None,
|
||||
api_key="explicit-key" if explicit else None,
|
||||
) == (
|
||||
"qwen/qwen3.8-27b",
|
||||
"iteracompute",
|
||||
"explicit-key" if explicit else "env-key",
|
||||
"https://explicit.example/v1" if explicit else "https://env.example/v1",
|
||||
)
|
||||
|
||||
|
||||
def test_completion_sends_model_and_bearer_key_without_provider_prefix() -> None:
|
||||
with respx.mock() as upstream:
|
||||
route: Final = upstream.post("https://api.iteracompute.com/v1/chat/completions").respond(200, json=_COMPLETION)
|
||||
response: Final = litellm.completion(
|
||||
model="iteracompute/qwen/qwen3.8-27b",
|
||||
messages=[{"role": "user", "content": "Hello"}],
|
||||
api_key="test-key",
|
||||
max_tokens=512,
|
||||
)
|
||||
|
||||
request: Final = route.calls.last.request
|
||||
assert request.headers["authorization"] == "Bearer test-key"
|
||||
assert json.loads(request.content) == {
|
||||
"model": "qwen/qwen3.8-27b",
|
||||
"messages": [{"role": "user", "content": "Hello"}],
|
||||
"max_tokens": 512,
|
||||
}
|
||||
assert response.choices[0].message.content == "Hello"
|
||||
assert response.usage.total_tokens == 7
|
||||
|
||||
|
||||
def test_streaming_returns_text_and_usage() -> None:
|
||||
event: Final = {
|
||||
"id": "chatcmpl_test",
|
||||
"object": "chat.completion.chunk",
|
||||
"created": 1_790_000_000,
|
||||
"model": "qwen/qwen3.8-27b",
|
||||
"choices": [
|
||||
{
|
||||
"index": 0,
|
||||
"delta": {"role": "assistant", "content": "Hello"},
|
||||
"finish_reason": "stop",
|
||||
}
|
||||
],
|
||||
"usage": {"prompt_tokens": 4, "completion_tokens": 3, "total_tokens": 7},
|
||||
}
|
||||
with respx.mock() as upstream:
|
||||
route: Final = upstream.post("https://api.iteracompute.com/v1/chat/completions").respond(
|
||||
200,
|
||||
text=f"data: {json.dumps(event)}\n\ndata: [DONE]\n\n",
|
||||
headers={"content-type": "text/event-stream"},
|
||||
)
|
||||
chunks: Final = tuple(
|
||||
litellm.completion(
|
||||
model="iteracompute/qwen/qwen3.8-27b",
|
||||
messages=[{"role": "user", "content": "Hello"}],
|
||||
api_key="test-key",
|
||||
stream=True,
|
||||
stream_options={"include_usage": True},
|
||||
)
|
||||
)
|
||||
|
||||
body: Final = json.loads(route.calls.last.request.content)
|
||||
assert body["model"] == "qwen/qwen3.8-27b"
|
||||
assert body["stream_options"] == {"include_usage": True}
|
||||
assert "".join(chunk.choices[0].delta.content or "" for chunk in chunks if chunk.choices) == "Hello"
|
||||
assert next(chunk.usage for chunk in chunks if getattr(chunk, "usage", None) is not None).total_tokens == 7
|
||||
|
||||
|
||||
def test_invalid_key_surfaces_authentication_error() -> None:
|
||||
with respx.mock() as upstream:
|
||||
upstream.post("https://api.iteracompute.com/v1/chat/completions").respond(
|
||||
401,
|
||||
json={"error": {"message": "Invalid API key", "type": "authentication_error"}},
|
||||
)
|
||||
with pytest.raises(litellm.AuthenticationError, match="Invalid API key"):
|
||||
litellm.completion(
|
||||
model="iteracompute/qwen/qwen3.8-27b",
|
||||
messages=[{"role": "user", "content": "Hello"}],
|
||||
api_key="invalid-test-key",
|
||||
)
|
||||
|
||||
|
||||
@pytest.mark.parametrize("global_openai_key", (None, "unrelated-global-openai-key"))
|
||||
@pytest.mark.parametrize("stream", (False, True))
|
||||
def test_missing_provider_key_never_sends_openai_credentials(
|
||||
monkeypatch: pytest.MonkeyPatch, global_openai_key: str | None, stream: bool
|
||||
) -> None:
|
||||
monkeypatch.delenv("ITERACOMPUTE_API_KEY", raising=False)
|
||||
monkeypatch.setenv("OPENAI_API_KEY", "unrelated-env-openai-key")
|
||||
monkeypatch.setattr(litellm, "openai_key", global_openai_key)
|
||||
monkeypatch.setattr(litellm, "api_key", None)
|
||||
with respx.mock(assert_all_called=False) as upstream:
|
||||
route: Final = upstream.post("https://api.iteracompute.com/v1/chat/completions").respond(200, json=_COMPLETION)
|
||||
with pytest.raises(litellm.AuthenticationError, match="ITERACOMPUTE_API_KEY"):
|
||||
litellm.completion(
|
||||
model="iteracompute/qwen/qwen3.8-27b",
|
||||
messages=[{"role": "user", "content": "Hello"}],
|
||||
stream=stream,
|
||||
)
|
||||
assert not route.called
|
||||
|
||||
|
||||
@pytest.mark.parametrize("organization", (None, "provider-organization"))
|
||||
def test_provider_key_wins_over_openai_credentials(
|
||||
monkeypatch: pytest.MonkeyPatch, organization: str | None
|
||||
) -> None:
|
||||
monkeypatch.setenv("ITERACOMPUTE_API_KEY", "provider-key")
|
||||
monkeypatch.setenv("OPENAI_API_KEY", "unrelated-openai-key")
|
||||
monkeypatch.setattr(litellm, "openai_key", "unrelated-global-openai-key")
|
||||
monkeypatch.setenv("OPENAI_ORGANIZATION", "unrelated-organization")
|
||||
monkeypatch.setattr(litellm, "organization", "unrelated-global-organization")
|
||||
with respx.mock() as upstream:
|
||||
route: Final = upstream.post("https://api.iteracompute.com/v1/chat/completions").respond(200, json=_COMPLETION)
|
||||
litellm.completion(
|
||||
model="iteracompute/qwen/qwen3.8-27b",
|
||||
messages=[{"role": "user", "content": "Hello"}],
|
||||
organization=organization,
|
||||
)
|
||||
assert route.calls.last.request.headers["authorization"] == "Bearer provider-key"
|
||||
if organization is None:
|
||||
assert not route.calls.last.request.headers.get("openai-organization")
|
||||
else:
|
||||
assert route.calls.last.request.headers["openai-organization"] == organization
|
||||
|
||||
|
||||
def test_responses_bridge_keeps_model_namespace() -> None:
|
||||
with respx.mock() as upstream:
|
||||
route: Final = upstream.post("https://api.iteracompute.com/v1/chat/completions").respond(200, json=_COMPLETION)
|
||||
response: Final = litellm.responses(model="iteracompute/qwen/qwen3.8-27b", input="Hello", api_key="test-key")
|
||||
|
||||
assert json.loads(route.calls.last.request.content)["model"] == "qwen/qwen3.8-27b"
|
||||
assert response.output[0].content[0].text == "Hello"
|
||||
|
||||
|
||||
@pytest.mark.asyncio
|
||||
async def test_messages_bridge_keeps_model_namespace(
|
||||
monkeypatch: pytest.MonkeyPatch,
|
||||
) -> None:
|
||||
monkeypatch.setattr(litellm, "disable_aiohttp_transport", True)
|
||||
monkeypatch.setattr(litellm, "in_memory_llm_clients_cache", LLMClientCache())
|
||||
with respx.mock() as upstream:
|
||||
route: Final = upstream.post("https://api.iteracompute.com/v1/chat/completions").respond(200, json=_COMPLETION)
|
||||
response: Final = await litellm.anthropic.messages.acreate(
|
||||
model="iteracompute/qwen/qwen3.8-27b",
|
||||
messages=[{"role": "user", "content": "Hello"}],
|
||||
max_tokens=512,
|
||||
api_key="test-key",
|
||||
)
|
||||
|
||||
assert json.loads(route.calls.last.request.content)["model"] == "qwen/qwen3.8-27b"
|
||||
assert response["content"][0]["text"] == "Hello"
|
||||
Loading…
Add table
Reference in a new issue