lm-deluge 0.0.34__py3-none-any.whl → 0.0.36__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Potentially problematic release.
This version of lm-deluge might be problematic. Click here for more details.
- lm_deluge/api_requests/anthropic.py +1 -1
- lm_deluge/api_requests/gemini.py +4 -2
- lm_deluge/api_requests/openai.py +17 -4
- lm_deluge/api_requests/response.py +4 -3
- lm_deluge/cli.py +300 -0
- lm_deluge/client.py +22 -73
- lm_deluge/models/__init__.py +144 -0
- lm_deluge/models/anthropic.py +124 -0
- lm_deluge/models/bedrock.py +99 -0
- lm_deluge/models/cerebras.py +57 -0
- lm_deluge/models/cohere.py +98 -0
- lm_deluge/models/deepseek.py +27 -0
- lm_deluge/models/fireworks.py +16 -0
- lm_deluge/models/google.py +153 -0
- lm_deluge/models/grok.py +38 -0
- lm_deluge/models/groq.py +74 -0
- lm_deluge/models/meta.py +65 -0
- lm_deluge/models/mistral.py +110 -0
- lm_deluge/models/openai.py +318 -0
- lm_deluge/models/openrouter.py +1 -0
- lm_deluge/models/together.py +112 -0
- lm_deluge/prompt.py +2 -2
- lm_deluge/util/harmony.py +47 -0
- {lm_deluge-0.0.34.dist-info → lm_deluge-0.0.36.dist-info}/METADATA +1 -1
- {lm_deluge-0.0.34.dist-info → lm_deluge-0.0.36.dist-info}/RECORD +28 -12
- lm_deluge/models.py +0 -1305
- {lm_deluge-0.0.34.dist-info → lm_deluge-0.0.36.dist-info}/WHEEL +0 -0
- {lm_deluge-0.0.34.dist-info → lm_deluge-0.0.36.dist-info}/licenses/LICENSE +0 -0
- {lm_deluge-0.0.34.dist-info → lm_deluge-0.0.36.dist-info}/top_level.txt +0 -0
|
@@ -0,0 +1,144 @@
|
|
|
1
|
+
from __future__ import annotations
|
|
2
|
+
|
|
3
|
+
import random
|
|
4
|
+
from dataclasses import dataclass, field
|
|
5
|
+
|
|
6
|
+
from ..request_context import RequestContext
|
|
7
|
+
|
|
8
|
+
# Import and register all provider models
|
|
9
|
+
from .anthropic import ANTHROPIC_MODELS
|
|
10
|
+
from .bedrock import BEDROCK_MODELS
|
|
11
|
+
from .cerebras import CEREBRAS_MODELS
|
|
12
|
+
from .cohere import COHERE_MODELS
|
|
13
|
+
from .deepseek import DEEPSEEK_MODELS
|
|
14
|
+
from .fireworks import FIREWORKS_MODELS
|
|
15
|
+
from .google import GOOGLE_MODELS
|
|
16
|
+
from .grok import XAI_MODELS
|
|
17
|
+
from .groq import GROQ_MODELS
|
|
18
|
+
from .meta import META_MODELS
|
|
19
|
+
from .mistral import MISTRAL_MODELS
|
|
20
|
+
from .openai import OPENAI_MODELS
|
|
21
|
+
from .openrouter import OPENROUTER_MODELS
|
|
22
|
+
from .together import TOGETHER_MODELS
|
|
23
|
+
|
|
24
|
+
|
|
25
|
+
@dataclass
|
|
26
|
+
class APIModel:
|
|
27
|
+
id: str
|
|
28
|
+
name: str
|
|
29
|
+
api_base: str
|
|
30
|
+
api_key_env_var: str
|
|
31
|
+
api_spec: str
|
|
32
|
+
cached_input_cost: float | None = 0
|
|
33
|
+
input_cost: float | None = 0 # $ per million input tokens
|
|
34
|
+
output_cost: float | None = 0 # $ per million output tokens
|
|
35
|
+
supports_json: bool = False
|
|
36
|
+
supports_logprobs: bool = False
|
|
37
|
+
supports_responses: bool = False
|
|
38
|
+
reasoning_model: bool = False
|
|
39
|
+
regions: list[str] | dict[str, int] = field(default_factory=list)
|
|
40
|
+
tokens_per_minute: int | None = None
|
|
41
|
+
requests_per_minute: int | None = None
|
|
42
|
+
gpus: list[str] | None = None
|
|
43
|
+
|
|
44
|
+
@classmethod
|
|
45
|
+
def from_registry(cls, name: str):
|
|
46
|
+
if name not in registry:
|
|
47
|
+
raise ValueError(f"Model {name} not found in registry")
|
|
48
|
+
cfg = registry[name]
|
|
49
|
+
if isinstance(cfg, APIModel):
|
|
50
|
+
return cfg
|
|
51
|
+
return cls(**cfg)
|
|
52
|
+
|
|
53
|
+
def sample_region(self):
|
|
54
|
+
if isinstance(self.regions, list):
|
|
55
|
+
regions = self.regions
|
|
56
|
+
weights = [1] * len(regions)
|
|
57
|
+
elif isinstance(self.regions, dict):
|
|
58
|
+
regions = list(self.regions.keys())
|
|
59
|
+
weights = self.regions.values()
|
|
60
|
+
else:
|
|
61
|
+
raise ValueError("no regions to sample")
|
|
62
|
+
random.sample(regions, 1, counts=weights)[0]
|
|
63
|
+
|
|
64
|
+
def make_request(self, context: RequestContext): # -> "APIRequestBase"
|
|
65
|
+
from ..api_requests.common import CLASSES
|
|
66
|
+
|
|
67
|
+
api_spec = self.api_spec
|
|
68
|
+
if (
|
|
69
|
+
context.use_responses_api
|
|
70
|
+
and self.supports_responses
|
|
71
|
+
and api_spec == "openai"
|
|
72
|
+
):
|
|
73
|
+
api_spec = "openai-responses"
|
|
74
|
+
|
|
75
|
+
request_class = CLASSES.get(api_spec, None)
|
|
76
|
+
if request_class is None:
|
|
77
|
+
raise ValueError(f"Unsupported API spec: {api_spec}")
|
|
78
|
+
return request_class(context=context)
|
|
79
|
+
|
|
80
|
+
|
|
81
|
+
registry: dict[str, APIModel] = {}
|
|
82
|
+
|
|
83
|
+
|
|
84
|
+
def register_model(
|
|
85
|
+
id: str,
|
|
86
|
+
name: str,
|
|
87
|
+
api_base: str,
|
|
88
|
+
api_key_env_var: str,
|
|
89
|
+
api_spec: str,
|
|
90
|
+
input_cost: float | None = 0, # $ per million input tokens
|
|
91
|
+
cached_input_cost: float | None = 0,
|
|
92
|
+
output_cost: float | None = 0, # $ per million output tokens
|
|
93
|
+
supports_json: bool = False,
|
|
94
|
+
supports_logprobs: bool = False,
|
|
95
|
+
supports_responses: bool = False,
|
|
96
|
+
reasoning_model: bool = False,
|
|
97
|
+
regions: list[str] | dict[str, int] = field(default_factory=list),
|
|
98
|
+
tokens_per_minute: int | None = None,
|
|
99
|
+
requests_per_minute: int | None = None,
|
|
100
|
+
) -> APIModel:
|
|
101
|
+
"""Register a model configuration and return the created APIModel."""
|
|
102
|
+
model = APIModel(
|
|
103
|
+
id=id,
|
|
104
|
+
name=name,
|
|
105
|
+
api_base=api_base,
|
|
106
|
+
api_key_env_var=api_key_env_var,
|
|
107
|
+
api_spec=api_spec,
|
|
108
|
+
cached_input_cost=cached_input_cost,
|
|
109
|
+
input_cost=input_cost,
|
|
110
|
+
output_cost=output_cost,
|
|
111
|
+
supports_json=supports_json,
|
|
112
|
+
supports_logprobs=supports_logprobs,
|
|
113
|
+
supports_responses=supports_responses,
|
|
114
|
+
reasoning_model=reasoning_model,
|
|
115
|
+
regions=regions,
|
|
116
|
+
tokens_per_minute=tokens_per_minute,
|
|
117
|
+
requests_per_minute=requests_per_minute,
|
|
118
|
+
)
|
|
119
|
+
registry[model.id] = model
|
|
120
|
+
return model
|
|
121
|
+
|
|
122
|
+
|
|
123
|
+
# Register all models from all providers
|
|
124
|
+
for model_dict in [
|
|
125
|
+
ANTHROPIC_MODELS,
|
|
126
|
+
BEDROCK_MODELS,
|
|
127
|
+
COHERE_MODELS,
|
|
128
|
+
DEEPSEEK_MODELS,
|
|
129
|
+
FIREWORKS_MODELS,
|
|
130
|
+
GOOGLE_MODELS,
|
|
131
|
+
XAI_MODELS,
|
|
132
|
+
META_MODELS,
|
|
133
|
+
MISTRAL_MODELS,
|
|
134
|
+
OPENAI_MODELS,
|
|
135
|
+
OPENROUTER_MODELS,
|
|
136
|
+
TOGETHER_MODELS,
|
|
137
|
+
GROQ_MODELS,
|
|
138
|
+
CEREBRAS_MODELS,
|
|
139
|
+
]:
|
|
140
|
+
for cfg in model_dict.values():
|
|
141
|
+
register_model(**cfg)
|
|
142
|
+
|
|
143
|
+
|
|
144
|
+
# print("Valid models:", registry.keys())
|
|
@@ -0,0 +1,124 @@
|
|
|
1
|
+
ANTHROPIC_MODELS = {
|
|
2
|
+
# █████████ █████ █████ ███
|
|
3
|
+
# ███░░░░░███ ░░███ ░░███ ░░░
|
|
4
|
+
# ░███ ░███ ████████ ███████ ░███████ ████████ ██████ ████████ ████ ██████
|
|
5
|
+
# ░███████████ ░░███░░███ ░░░███░ ░███░░███ ░░███░░███ ███░░███░░███░░███░░███ ███░░███
|
|
6
|
+
# ░███░░░░░███ ░███ ░███ ░███ ░███ ░███ ░███ ░░░ ░███ ░███ ░███ ░███ ░███ ░███ ░░░
|
|
7
|
+
# ░███ ░███ ░███ ░███ ░███ ███ ░███ ░███ ░███ ░███ ░███ ░███ ░███ ░███ ░███ ███
|
|
8
|
+
# █████ █████ ████ █████ ░░█████ ████ █████ █████ ░░██████ ░███████ █████░░██████
|
|
9
|
+
# ░░░░░ ░░░░░ ░░░░ ░░░░░ ░░░░░ ░░░░ ░░░░░ ░░░░░ ░░░░░░ ░███░░░ ░░░░░ ░░░░░░
|
|
10
|
+
# ░███
|
|
11
|
+
# █████
|
|
12
|
+
#
|
|
13
|
+
"claude-4.1-opus": {
|
|
14
|
+
"id": "claude-4.1-opus",
|
|
15
|
+
"name": "claude-opus-4-1-20250805",
|
|
16
|
+
"api_base": "https://api.anthropic.com/v1",
|
|
17
|
+
"api_key_env_var": "ANTHROPIC_API_KEY",
|
|
18
|
+
"supports_json": False,
|
|
19
|
+
"api_spec": "anthropic",
|
|
20
|
+
"input_cost": 15.0,
|
|
21
|
+
"output_cost": 75.0,
|
|
22
|
+
"requests_per_minute": 4_000,
|
|
23
|
+
"tokens_per_minute": 400_000,
|
|
24
|
+
"reasoning_model": True,
|
|
25
|
+
},
|
|
26
|
+
"claude-4-opus": {
|
|
27
|
+
"id": "claude-4-opus",
|
|
28
|
+
"name": "claude-opus-4-20250514",
|
|
29
|
+
"api_base": "https://api.anthropic.com/v1",
|
|
30
|
+
"api_key_env_var": "ANTHROPIC_API_KEY",
|
|
31
|
+
"supports_json": False,
|
|
32
|
+
"api_spec": "anthropic",
|
|
33
|
+
"input_cost": 15.0,
|
|
34
|
+
"output_cost": 75.0,
|
|
35
|
+
"requests_per_minute": 4_000,
|
|
36
|
+
"tokens_per_minute": 400_000,
|
|
37
|
+
"reasoning_model": True,
|
|
38
|
+
},
|
|
39
|
+
"claude-4-sonnet": {
|
|
40
|
+
"id": "claude-4-sonnet",
|
|
41
|
+
"name": "claude-sonnet-4-20250514",
|
|
42
|
+
"api_base": "https://api.anthropic.com/v1",
|
|
43
|
+
"api_key_env_var": "ANTHROPIC_API_KEY",
|
|
44
|
+
"supports_json": False,
|
|
45
|
+
"api_spec": "anthropic",
|
|
46
|
+
"input_cost": 3.0,
|
|
47
|
+
"output_cost": 15.0,
|
|
48
|
+
"requests_per_minute": 4_000,
|
|
49
|
+
"tokens_per_minute": 400_000,
|
|
50
|
+
},
|
|
51
|
+
"claude-3.7-sonnet": {
|
|
52
|
+
"id": "claude-3.7-sonnet",
|
|
53
|
+
"name": "claude-3-7-sonnet-20250219",
|
|
54
|
+
"api_base": "https://api.anthropic.com/v1",
|
|
55
|
+
"api_key_env_var": "ANTHROPIC_API_KEY",
|
|
56
|
+
"supports_json": False,
|
|
57
|
+
"api_spec": "anthropic",
|
|
58
|
+
"input_cost": 3.0,
|
|
59
|
+
"output_cost": 15.0,
|
|
60
|
+
"requests_per_minute": 4_000,
|
|
61
|
+
"tokens_per_minute": 400_000,
|
|
62
|
+
"reasoning_model": True,
|
|
63
|
+
},
|
|
64
|
+
"claude-3.6-sonnet": {
|
|
65
|
+
"id": "claude-3.6-sonnet",
|
|
66
|
+
"name": "claude-3-5-sonnet-20241022",
|
|
67
|
+
"api_base": "https://api.anthropic.com/v1",
|
|
68
|
+
"api_key_env_var": "ANTHROPIC_API_KEY",
|
|
69
|
+
"supports_json": False,
|
|
70
|
+
"api_spec": "anthropic",
|
|
71
|
+
"input_cost": 3.0,
|
|
72
|
+
"output_cost": 15.0,
|
|
73
|
+
"requests_per_minute": 4_000,
|
|
74
|
+
"tokens_per_minute": 400_000,
|
|
75
|
+
},
|
|
76
|
+
"claude-3.5-sonnet": {
|
|
77
|
+
"id": "claude-3.5-sonnet",
|
|
78
|
+
"name": "claude-3-5-sonnet-20240620",
|
|
79
|
+
"api_base": "https://api.anthropic.com/v1",
|
|
80
|
+
"api_key_env_var": "ANTHROPIC_API_KEY",
|
|
81
|
+
"supports_json": False,
|
|
82
|
+
"api_spec": "anthropic",
|
|
83
|
+
"input_cost": 3.0,
|
|
84
|
+
"output_cost": 15.0,
|
|
85
|
+
"requests_per_minute": 4_000,
|
|
86
|
+
"tokens_per_minute": 400_000,
|
|
87
|
+
},
|
|
88
|
+
"claude-3-opus": {
|
|
89
|
+
"id": "claude-3-opus",
|
|
90
|
+
"name": "claude-3-opus-20240229",
|
|
91
|
+
"api_base": "https://api.anthropic.com/v1",
|
|
92
|
+
"api_key_env_var": "ANTHROPIC_API_KEY",
|
|
93
|
+
"supports_json": False,
|
|
94
|
+
"api_spec": "anthropic",
|
|
95
|
+
"input_cost": 15.0,
|
|
96
|
+
"output_cost": 75.0,
|
|
97
|
+
"requests_per_minute": 4_000,
|
|
98
|
+
"tokens_per_minute": 400_000,
|
|
99
|
+
},
|
|
100
|
+
"claude-3.5-haiku": {
|
|
101
|
+
"id": "claude-3.5-haiku",
|
|
102
|
+
"name": "claude-3-5-haiku-20241022",
|
|
103
|
+
"api_base": "https://api.anthropic.com/v1",
|
|
104
|
+
"api_key_env_var": "ANTHROPIC_API_KEY",
|
|
105
|
+
"supports_json": False,
|
|
106
|
+
"api_spec": "anthropic",
|
|
107
|
+
"input_cost": 1.00,
|
|
108
|
+
"output_cost": 5.00,
|
|
109
|
+
"requests_per_minute": 20_000,
|
|
110
|
+
"tokens_per_minute": 4_000_000, # supposed to be this but they fucked up
|
|
111
|
+
},
|
|
112
|
+
"claude-3-haiku": {
|
|
113
|
+
"id": "claude-3-haiku",
|
|
114
|
+
"name": "claude-3-haiku-20240307",
|
|
115
|
+
"api_base": "https://api.anthropic.com/v1",
|
|
116
|
+
"api_key_env_var": "ANTHROPIC_API_KEY",
|
|
117
|
+
"supports_json": False,
|
|
118
|
+
"api_spec": "anthropic",
|
|
119
|
+
"input_cost": 0.25,
|
|
120
|
+
"output_cost": 1.25,
|
|
121
|
+
"requests_per_minute": 10_000,
|
|
122
|
+
"tokens_per_minute": 4_000_000, # supposed to be this but they fucked up
|
|
123
|
+
},
|
|
124
|
+
}
|
|
@@ -0,0 +1,99 @@
|
|
|
1
|
+
BEDROCK_MODELS = {
|
|
2
|
+
# ███████████ █████ █████
|
|
3
|
+
# ░░███░░░░░███ ░░███ ░░███
|
|
4
|
+
# ░███ ░███ ██████ ███████ ████████ ██████ ██████ ░███ █████
|
|
5
|
+
# ░██████████ ███░░███ ███░░███ ░░███░░███ ███░░███ ███░░███ ░███░░███
|
|
6
|
+
# ░███░░░░░███░███████ ░███ ░███ ░███ ░░░ ░███ ░███░███ ░░░ ░██████░
|
|
7
|
+
# ░███ ░███░███░░░ ░███ ░███ ░███ ░███ ░███░███ ███ ░███░░███
|
|
8
|
+
# ███████████ ░░██████ ░░████████ █████ ░░██████ ░░██████ ████ █████
|
|
9
|
+
# ░░░░░░░░░░░ ░░░░░░ ░░░░░░░░ ░░░░░ ░░░░░░ ░░░░░░ ░░░░ ░░░░░
|
|
10
|
+
"claude-3-haiku-bedrock": {
|
|
11
|
+
"id": "claude-3-haiku-bedrock",
|
|
12
|
+
"name": "us.anthropic.claude-3-haiku-20240307-v1:0",
|
|
13
|
+
"regions": ["us-east-1", "us-west-2", "ap-southeast-2", "eu-west-3"],
|
|
14
|
+
"api_base": "",
|
|
15
|
+
"api_key_env_var": "",
|
|
16
|
+
"api_spec": "bedrock",
|
|
17
|
+
"input_cost": 0.25,
|
|
18
|
+
"output_cost": 1.25,
|
|
19
|
+
"requests_per_minute": 4_000,
|
|
20
|
+
"tokens_per_minute": 8_000_000,
|
|
21
|
+
},
|
|
22
|
+
"claude-3.5-haiku-bedrock": {
|
|
23
|
+
"id": "claude-3.5-haiku-bedrock",
|
|
24
|
+
"name": "us.anthropic.claude-3-5-haiku-20241022-v1:0",
|
|
25
|
+
"regions": ["us-east-1", "us-west-2", "ap-southeast-2", "eu-west-3"],
|
|
26
|
+
"api_base": "",
|
|
27
|
+
"api_key_env_var": "",
|
|
28
|
+
"api_spec": "bedrock",
|
|
29
|
+
"input_cost": 0.25,
|
|
30
|
+
"output_cost": 1.25,
|
|
31
|
+
"requests_per_minute": 4_000,
|
|
32
|
+
"tokens_per_minute": 8_000_000,
|
|
33
|
+
},
|
|
34
|
+
"claude-3.5-sonnet-bedrock": {
|
|
35
|
+
"id": "claude-3.5-sonnet-bedrock",
|
|
36
|
+
"name": "us.anthropic.claude-3-5-sonnet-20240620-v1:0",
|
|
37
|
+
"regions": ["us-east-1", "us-west-2"],
|
|
38
|
+
"api_base": "",
|
|
39
|
+
"api_key_env_var": "",
|
|
40
|
+
"api_spec": "bedrock",
|
|
41
|
+
"input_cost": 3.0,
|
|
42
|
+
"output_cost": 15.0,
|
|
43
|
+
"requests_per_minute": 4_000,
|
|
44
|
+
"tokens_per_minute": 400_000,
|
|
45
|
+
"reasoning_model": False,
|
|
46
|
+
},
|
|
47
|
+
"claude-3.6-sonnet-bedrock": {
|
|
48
|
+
"id": "claude-3.6-sonnet-bedrock",
|
|
49
|
+
"name": "us.anthropic.claude-3-5-sonnet-20241022-v2:0",
|
|
50
|
+
"regions": ["us-east-1", "us-west-2", "us-east-2"],
|
|
51
|
+
"api_base": "",
|
|
52
|
+
"api_key_env_var": "",
|
|
53
|
+
"api_spec": "bedrock",
|
|
54
|
+
"input_cost": 3.0,
|
|
55
|
+
"output_cost": 15.0,
|
|
56
|
+
"requests_per_minute": 4_000,
|
|
57
|
+
"tokens_per_minute": 400_000,
|
|
58
|
+
"reasoning_model": False,
|
|
59
|
+
},
|
|
60
|
+
"claude-3.7-sonnet-bedrock": {
|
|
61
|
+
"id": "claude-3.7-sonnet-bedrock",
|
|
62
|
+
"name": "us.anthropic.claude-3-7-sonnet-20250219-v1:0",
|
|
63
|
+
"regions": ["us-east-1", "us-west-2", "eu-west-1"],
|
|
64
|
+
"api_base": "",
|
|
65
|
+
"api_key_env_var": "",
|
|
66
|
+
"api_spec": "bedrock",
|
|
67
|
+
"input_cost": 3.0,
|
|
68
|
+
"output_cost": 15.0,
|
|
69
|
+
"requests_per_minute": 4_000,
|
|
70
|
+
"tokens_per_minute": 400_000,
|
|
71
|
+
"reasoning_model": True,
|
|
72
|
+
},
|
|
73
|
+
"claude-4-sonnet-bedrock": {
|
|
74
|
+
"id": "claude-4-sonnet-bedrock",
|
|
75
|
+
"name": "us.anthropic.claude-sonnet-4-20250514-v1:0",
|
|
76
|
+
"regions": ["us-east-1", "us-west-2", "us-east-2"],
|
|
77
|
+
"api_base": "",
|
|
78
|
+
"api_key_env_var": "",
|
|
79
|
+
"api_spec": "bedrock",
|
|
80
|
+
"input_cost": 3.0,
|
|
81
|
+
"output_cost": 15.0,
|
|
82
|
+
"requests_per_minute": 4_000,
|
|
83
|
+
"tokens_per_minute": 400_000,
|
|
84
|
+
"reasoning_model": True,
|
|
85
|
+
},
|
|
86
|
+
"claude-4-opus-bedrock": {
|
|
87
|
+
"id": "claude-4-opus-bedrock",
|
|
88
|
+
"name": "us.anthropic.claude-opus-4-20250514-v1:0",
|
|
89
|
+
"regions": ["us-east-1", "us-west-2", "us-east-2"],
|
|
90
|
+
"api_base": "",
|
|
91
|
+
"api_key_env_var": "",
|
|
92
|
+
"api_spec": "bedrock",
|
|
93
|
+
"input_cost": 3.0,
|
|
94
|
+
"output_cost": 15.0,
|
|
95
|
+
"requests_per_minute": 4_000,
|
|
96
|
+
"tokens_per_minute": 400_000,
|
|
97
|
+
"reasoning_model": True,
|
|
98
|
+
},
|
|
99
|
+
}
|
|
@@ -0,0 +1,57 @@
|
|
|
1
|
+
CEREBRAS_MODELS = {
|
|
2
|
+
"gpt-oss-120b-cerebras": {
|
|
3
|
+
"id": "gpt-oss-120b-cerebras",
|
|
4
|
+
"name": "gpt-oss-120b",
|
|
5
|
+
"api_base": "https://api.cerebras.ai/v1",
|
|
6
|
+
"api_key_env_var": "CEREBRAS_API_KEY",
|
|
7
|
+
},
|
|
8
|
+
"llama-4-scout-cerebras": {
|
|
9
|
+
"id": "llama-4-scout-cerebras",
|
|
10
|
+
"name": "llama-4-scout-17b-16e-instruct",
|
|
11
|
+
"api_base": "https://api.cerebras.ai/v1",
|
|
12
|
+
"api_key_env_var": "CEREBRAS_API_KEY",
|
|
13
|
+
},
|
|
14
|
+
"llama-3.1-8b-cerebras": {
|
|
15
|
+
"id": "llama-3.1-8b-cerebras",
|
|
16
|
+
"name": "llama-3.1-8b",
|
|
17
|
+
"api_base": "https://api.cerebras.ai/v1",
|
|
18
|
+
"api_key_env_var": "CEREBRAS_API_KEY",
|
|
19
|
+
},
|
|
20
|
+
"llama-3.3-70b-cerebras": {
|
|
21
|
+
"id": "llama-3.3-70b-cerebras",
|
|
22
|
+
"name": "llama-3.3-70b",
|
|
23
|
+
"api_base": "https://api.cerebras.ai/v1",
|
|
24
|
+
"api_key_env_var": "CEREBRAS_API_KEY",
|
|
25
|
+
},
|
|
26
|
+
"qwen-3-32b-cerebras": {
|
|
27
|
+
"id": "qwen-3-32b-cerebras",
|
|
28
|
+
"name": "qwen-3-32b",
|
|
29
|
+
"api_base": "https://api.cerebras.ai/v1",
|
|
30
|
+
"api_key_env_var": "CEREBRAS_API_KEY",
|
|
31
|
+
},
|
|
32
|
+
# preview models
|
|
33
|
+
"llama-4-maverick-cerebras": {
|
|
34
|
+
"id": "llama-4-maverick-cerebras",
|
|
35
|
+
"name": "llama-4-maverick-17b-128e-instruct",
|
|
36
|
+
"api_base": "https://api.cerebras.ai/v1",
|
|
37
|
+
"api_key_env_var": "CEREBRAS_API_KEY",
|
|
38
|
+
},
|
|
39
|
+
"qwen-3-235b-instruct-cerebras": {
|
|
40
|
+
"id": "qwen-3-235b-instruct-cerebras",
|
|
41
|
+
"name": "qwen-3-235b-a22b-instruct-2507",
|
|
42
|
+
"api_base": "https://api.cerebras.ai/v1",
|
|
43
|
+
"api_key_env_var": "CEREBRAS_API_KEY",
|
|
44
|
+
},
|
|
45
|
+
"qwen-3-235b-thinking-cerebras": {
|
|
46
|
+
"id": "qwen-3-235b-thinking-cerebras",
|
|
47
|
+
"name": "qwen-3-235b-a22b-thinking-2507",
|
|
48
|
+
"api_base": "https://api.cerebras.ai/v1",
|
|
49
|
+
"api_key_env_var": "CEREBRAS_API_KEY",
|
|
50
|
+
},
|
|
51
|
+
"qwen-3-coder-cerebras": {
|
|
52
|
+
"id": "qwen-3-coder-cerebras",
|
|
53
|
+
"name": "qwen-3-coder-480b",
|
|
54
|
+
"api_base": "https://api.cerebras.ai/v1",
|
|
55
|
+
"api_key_env_var": "CEREBRAS_API_KEY",
|
|
56
|
+
},
|
|
57
|
+
}
|
|
@@ -0,0 +1,98 @@
|
|
|
1
|
+
COHERE_MODELS = {
|
|
2
|
+
# █████████ █████
|
|
3
|
+
# ███░░░░░███ ░░███
|
|
4
|
+
# ███ ░░░ ██████ ░███████ ██████ ████████ ██████
|
|
5
|
+
# ░███ ███░░███ ░███░░███ ███░░███░░███░░███ ███░░███
|
|
6
|
+
# ░███ ░███ ░███ ░███ ░███ ░███████ ░███ ░░░ ░███████
|
|
7
|
+
# ░░███ ███░███ ░███ ░███ ░███ ░███░░░ ░███ ░███░░░
|
|
8
|
+
# ░░█████████ ░░██████ ████ █████░░██████ █████ ░░██████
|
|
9
|
+
# ░░░░░░░░░ ░░░░░░ ░░░░ ░░░░░ ░░░░░░ ░░░░░ ░░░░░░
|
|
10
|
+
"aya-expanse-8b": {
|
|
11
|
+
"id": "aya-expanse-8b",
|
|
12
|
+
"name": "c4ai-aya-expanse-8b",
|
|
13
|
+
"api_base": "https://api.cohere.ai/compatibility/v1",
|
|
14
|
+
"api_key_env_var": "COHERE_API_KEY",
|
|
15
|
+
"api_spec": "openai",
|
|
16
|
+
"input_cost": 0.5,
|
|
17
|
+
"output_cost": 1.5,
|
|
18
|
+
"requests_per_minute": 10_000,
|
|
19
|
+
"tokens_per_minute": None,
|
|
20
|
+
},
|
|
21
|
+
"aya-expanse-32b": {
|
|
22
|
+
"id": "aya-expanse-32b",
|
|
23
|
+
"name": "c4ai-aya-expanse-32b",
|
|
24
|
+
"api_base": "https://api.cohere.ai/compatibility/v1",
|
|
25
|
+
"api_key_env_var": "COHERE_API_KEY",
|
|
26
|
+
"api_spec": "openai",
|
|
27
|
+
"input_cost": 0.5,
|
|
28
|
+
"output_cost": 1.5,
|
|
29
|
+
"requests_per_minute": 10_000,
|
|
30
|
+
"tokens_per_minute": None,
|
|
31
|
+
},
|
|
32
|
+
"aya-vision-8b": {
|
|
33
|
+
"id": "aya-vision-8b",
|
|
34
|
+
"name": "c4ai-aya-vision-8b",
|
|
35
|
+
"api_base": "https://api.cohere.ai/compatibility/v1",
|
|
36
|
+
"api_key_env_var": "COHERE_API_KEY",
|
|
37
|
+
"api_spec": "openai",
|
|
38
|
+
"input_cost": 0.5,
|
|
39
|
+
"output_cost": 1.5,
|
|
40
|
+
"requests_per_minute": 10_000,
|
|
41
|
+
"tokens_per_minute": None,
|
|
42
|
+
},
|
|
43
|
+
"aya-vision-32b": {
|
|
44
|
+
"id": "aya-vision-32b",
|
|
45
|
+
"name": "c4ai-aya-vision-32b",
|
|
46
|
+
"api_base": "https://api.cohere.ai/compatibility/v1",
|
|
47
|
+
"api_key_env_var": "COHERE_API_KEY",
|
|
48
|
+
"api_spec": "openai",
|
|
49
|
+
"input_cost": 0.5,
|
|
50
|
+
"output_cost": 1.5,
|
|
51
|
+
"requests_per_minute": 10_000,
|
|
52
|
+
"tokens_per_minute": None,
|
|
53
|
+
},
|
|
54
|
+
"command-a": {
|
|
55
|
+
"id": "command-a",
|
|
56
|
+
"name": "command-a-03-2025",
|
|
57
|
+
"api_base": "https://api.cohere.ai/compatibility/v1",
|
|
58
|
+
"api_key_env_var": "COHERE_API_KEY",
|
|
59
|
+
"api_spec": "openai",
|
|
60
|
+
"input_cost": 0.5,
|
|
61
|
+
"output_cost": 1.5,
|
|
62
|
+
"requests_per_minute": 10_000,
|
|
63
|
+
"tokens_per_minute": None,
|
|
64
|
+
},
|
|
65
|
+
"command-r-7b": {
|
|
66
|
+
"id": "command-r-cohere",
|
|
67
|
+
"name": "command-r7b-12-2024",
|
|
68
|
+
"api_base": "https://api.cohere.ai/compatibility/v1",
|
|
69
|
+
"api_key_env_var": "COHERE_API_KEY",
|
|
70
|
+
"api_spec": "openai",
|
|
71
|
+
"input_cost": 0.5,
|
|
72
|
+
"output_cost": 1.5,
|
|
73
|
+
"requests_per_minute": 10_000,
|
|
74
|
+
"tokens_per_minute": None,
|
|
75
|
+
},
|
|
76
|
+
"command-r": {
|
|
77
|
+
"id": "command-r",
|
|
78
|
+
"name": "command-r-08-2024",
|
|
79
|
+
"api_base": "https://api.cohere.ai/compatibility/v1",
|
|
80
|
+
"api_key_env_var": "COHERE_API_KEY",
|
|
81
|
+
"api_spec": "openai",
|
|
82
|
+
"input_cost": 0.5,
|
|
83
|
+
"output_cost": 1.5,
|
|
84
|
+
"requests_per_minute": 10_000,
|
|
85
|
+
"tokens_per_minute": None,
|
|
86
|
+
},
|
|
87
|
+
"command-r-plus": {
|
|
88
|
+
"id": "command-r-plus",
|
|
89
|
+
"name": "command-r-plus-04-2024",
|
|
90
|
+
"api_base": "https://api.cohere.ai/compatibility/v1",
|
|
91
|
+
"api_key_env_var": "COHERE_API_KEY",
|
|
92
|
+
"api_spec": "openai",
|
|
93
|
+
"input_cost": 3.0,
|
|
94
|
+
"output_cost": 15.0,
|
|
95
|
+
"requests_per_minute": 10_000,
|
|
96
|
+
"tokens_per_minute": None,
|
|
97
|
+
},
|
|
98
|
+
}
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
DEEPSEEK_MODELS = {
|
|
2
|
+
# ______ _
|
|
3
|
+
# (______) | |
|
|
4
|
+
# _ _ _____ _____ ____ ___ _____ _____| | _
|
|
5
|
+
# | | | | ___ | ___ | _ \ /___) ___ | ___ | |_/ )
|
|
6
|
+
# | |__/ /| ____| ____| |_| |___ | ____| ____| _ (
|
|
7
|
+
# |_____/ |_____)_____) __/(___/|_____)_____)_| \_)
|
|
8
|
+
# |_|
|
|
9
|
+
"deepseek-chat": {
|
|
10
|
+
"id": "deepseek-chat",
|
|
11
|
+
"name": "deepseek-chat",
|
|
12
|
+
"api_base": "https://api.deepseek.com/v1",
|
|
13
|
+
"api_key_env_var": "DEEPSEEK_API_KEY",
|
|
14
|
+
"api_spec": "openai",
|
|
15
|
+
"input_cost": 0.27,
|
|
16
|
+
"output_cost": 1.10,
|
|
17
|
+
},
|
|
18
|
+
"deepseek-r1": {
|
|
19
|
+
"id": "deepseek-r1",
|
|
20
|
+
"name": "deepseek-reasoner",
|
|
21
|
+
"api_base": "https://api.deepseek.com/v1",
|
|
22
|
+
"api_key_env_var": "DEEPSEEK_API_KEY",
|
|
23
|
+
"api_spec": "openai",
|
|
24
|
+
"input_cost": 0.55,
|
|
25
|
+
"output_cost": 2.19,
|
|
26
|
+
},
|
|
27
|
+
}
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
FIREWORKS_MODELS = {
|
|
2
|
+
"gpt-oss-20b-fireworks": {
|
|
3
|
+
"id": "gpt-oss-20b-fireworks",
|
|
4
|
+
"name": "accounts/fireworks/models/gpt-oss-20b",
|
|
5
|
+
"api_base": "https://api.fireworks.ai/inference/v1",
|
|
6
|
+
"api_key_env_var": "FIREWORKS_API_KEY",
|
|
7
|
+
"api_spec": "openai",
|
|
8
|
+
},
|
|
9
|
+
"gpt-oss-120b-fireworks": {
|
|
10
|
+
"id": "gpt-oss-120b-fireworks",
|
|
11
|
+
"name": "accounts/fireworks/models/gpt-oss-120b",
|
|
12
|
+
"api_base": "https://api.fireworks.ai/inference/v1",
|
|
13
|
+
"api_key_env_var": "FIREWORKS_API_KEY",
|
|
14
|
+
"api_spec": "openai",
|
|
15
|
+
},
|
|
16
|
+
}
|