ask-llm-providers 0.1.2 → 0.8.2

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.
Files changed (39) hide show
  1. checksums.yaml +4 -4
  2. data/CHANGELOG.md +181 -0
  3. data/lib/ask/llm/aliases.json +11 -0
  4. data/lib/ask/llm/aliases.rb +62 -0
  5. data/lib/ask/llm/catalog.rb +221 -0
  6. data/lib/ask/llm/cost_calculator.rb +114 -0
  7. data/lib/ask/llm/http.rb +68 -12
  8. data/lib/ask/llm/models/anthropic.json +872 -0
  9. data/lib/ask/llm/models/bedrock.json +3769 -0
  10. data/lib/ask/llm/models/deepseek.json +340 -0
  11. data/lib/ask/llm/models/gemini.json +1211 -0
  12. data/lib/ask/llm/models/meta.json +299 -0
  13. data/lib/ask/llm/models/mistral.json +1303 -0
  14. data/lib/ask/llm/models/moonshot.json +198 -0
  15. data/lib/ask/llm/models/nvidia_nim.json +289 -0
  16. data/lib/ask/llm/models/openai.json +2521 -0
  17. data/lib/ask/llm/models/opencode.json +552 -0
  18. data/lib/ask/llm/models/perplexity.json +148 -0
  19. data/lib/ask/llm/models/vertex_ai.json +1347 -0
  20. data/lib/ask/llm/models/xai.json +326 -0
  21. data/lib/ask/llm/models_schema.json +74 -0
  22. data/lib/ask/llm/openai_compatible.rb +100 -0
  23. data/lib/ask/llm/provider_config.rb +65 -0
  24. data/lib/ask/llm/sources/models_dev.rb +154 -0
  25. data/lib/ask/llm/sources/openrouter.rb +176 -0
  26. data/lib/ask/llm/sse_buffer.rb +43 -0
  27. data/lib/ask/llm/version.rb +1 -1
  28. data/lib/ask/provider/anthropic.rb +106 -103
  29. data/lib/ask/provider/bedrock.rb +84 -52
  30. data/lib/ask/provider/cloudflare.rb +62 -40
  31. data/lib/ask/provider/google.rb +112 -74
  32. data/lib/ask/provider/mistral.rb +156 -6
  33. data/lib/ask/provider/ollama.rb +83 -29
  34. data/lib/ask/provider/openai.rb +141 -68
  35. data/lib/ask/provider/openai_compatible.rb +91 -0
  36. data/lib/ask/skills/providers.model_select/SKILL.md +164 -0
  37. data/lib/ask-llm-providers.rb +22 -18
  38. metadata +35 -7
  39. data/lib/ask/llm/models/openai.rb +0 -69
@@ -0,0 +1,340 @@
1
+ [
2
+ {
3
+ "id": "deepseek-chat",
4
+ "name": "DeepSeek Chat",
5
+ "provider": "deepseek",
6
+ "family": "deepseek",
7
+ "context_window": 1000000,
8
+ "max_output_tokens": 384000,
9
+ "capabilities": [
10
+ "function_calling"
11
+ ],
12
+ "modalities": {
13
+ "input": [
14
+ "text"
15
+ ],
16
+ "output": [
17
+ "text"
18
+ ]
19
+ },
20
+ "pricing": {
21
+ "text_tokens": {
22
+ "standard": {
23
+ "input_per_million": 0.14,
24
+ "output_per_million": 0.28,
25
+ "cache_read_input_per_million": 0.0028
26
+ }
27
+ }
28
+ },
29
+ "knowledge_cutoff": "2025-09",
30
+ "created_at": "2025-12-01"
31
+ },
32
+ {
33
+ "id": "deepseek-reasoner",
34
+ "name": "DeepSeek Reasoner",
35
+ "provider": "deepseek",
36
+ "family": "deepseek-thinking",
37
+ "context_window": 1000000,
38
+ "max_output_tokens": 384000,
39
+ "capabilities": [
40
+ "function_calling",
41
+ "reasoning"
42
+ ],
43
+ "modalities": {
44
+ "input": [
45
+ "text"
46
+ ],
47
+ "output": [
48
+ "text"
49
+ ]
50
+ },
51
+ "pricing": {
52
+ "text_tokens": {
53
+ "standard": {
54
+ "input_per_million": 0.14,
55
+ "output_per_million": 0.28,
56
+ "cache_read_input_per_million": 0.0028
57
+ }
58
+ }
59
+ },
60
+ "knowledge_cutoff": "2025-09",
61
+ "created_at": "2025-12-01"
62
+ },
63
+ {
64
+ "id": "deepseek-v4-flash",
65
+ "name": "DeepSeek V4 Flash",
66
+ "provider": "deepseek",
67
+ "family": "deepseek-flash",
68
+ "context_window": 1000000,
69
+ "max_output_tokens": 384000,
70
+ "capabilities": [
71
+ "function_calling",
72
+ "structured_output",
73
+ "reasoning"
74
+ ],
75
+ "modalities": {
76
+ "input": [
77
+ "text"
78
+ ],
79
+ "output": [
80
+ "text"
81
+ ]
82
+ },
83
+ "pricing": {
84
+ "text_tokens": {
85
+ "standard": {
86
+ "input_per_million": 0.14,
87
+ "output_per_million": 0.28,
88
+ "cache_read_input_per_million": 0.0028
89
+ }
90
+ }
91
+ },
92
+ "knowledge_cutoff": "2025-05",
93
+ "created_at": "2026-04-24"
94
+ },
95
+ {
96
+ "id": "deepseek-v4-pro",
97
+ "name": "DeepSeek V4 Pro",
98
+ "provider": "deepseek",
99
+ "family": "deepseek-thinking",
100
+ "context_window": 1000000,
101
+ "max_output_tokens": 384000,
102
+ "capabilities": [
103
+ "function_calling",
104
+ "structured_output",
105
+ "reasoning"
106
+ ],
107
+ "modalities": {
108
+ "input": [
109
+ "text"
110
+ ],
111
+ "output": [
112
+ "text"
113
+ ]
114
+ },
115
+ "pricing": {
116
+ "text_tokens": {
117
+ "standard": {
118
+ "input_per_million": 0.435,
119
+ "output_per_million": 0.87,
120
+ "cache_read_input_per_million": 0.003625
121
+ }
122
+ }
123
+ },
124
+ "knowledge_cutoff": "2025-05",
125
+ "created_at": "2026-04-24"
126
+ },
127
+ {
128
+ "id": "deepseek-chat-v3-0324",
129
+ "name": "DeepSeek: DeepSeek V3 0324",
130
+ "provider": "deepseek",
131
+ "context_window": 163840,
132
+ "max_output_tokens": 65536,
133
+ "capabilities": [],
134
+ "modalities": {
135
+ "input": [
136
+ "text"
137
+ ],
138
+ "output": [
139
+ "text"
140
+ ]
141
+ },
142
+ "pricing": {
143
+ "text_tokens": {
144
+ "standard": {
145
+ "input_per_million": 0.27,
146
+ "output_per_million": 1.12,
147
+ "cache_read_input_per_million": 0.135
148
+ }
149
+ }
150
+ },
151
+ "architecture": "text->text",
152
+ "source": "openrouter"
153
+ },
154
+ {
155
+ "id": "deepseek-chat-v3.1",
156
+ "name": "DeepSeek: DeepSeek V3.1",
157
+ "provider": "deepseek",
158
+ "context_window": 163840,
159
+ "max_output_tokens": 32768,
160
+ "capabilities": [],
161
+ "modalities": {
162
+ "input": [
163
+ "text"
164
+ ],
165
+ "output": [
166
+ "text"
167
+ ]
168
+ },
169
+ "pricing": {
170
+ "text_tokens": {
171
+ "standard": {
172
+ "input_per_million": 0.25,
173
+ "output_per_million": 0.95,
174
+ "cache_read_input_per_million": 0.13
175
+ }
176
+ }
177
+ },
178
+ "architecture": "text->text",
179
+ "source": "openrouter"
180
+ },
181
+ {
182
+ "id": "deepseek-v3.1-terminus",
183
+ "name": "DeepSeek: DeepSeek V3.1 Terminus",
184
+ "provider": "deepseek",
185
+ "context_window": 131072,
186
+ "max_output_tokens": 32768,
187
+ "capabilities": [],
188
+ "modalities": {
189
+ "input": [
190
+ "text"
191
+ ],
192
+ "output": [
193
+ "text"
194
+ ]
195
+ },
196
+ "pricing": {
197
+ "text_tokens": {
198
+ "standard": {
199
+ "input_per_million": 0.27,
200
+ "output_per_million": 1.0,
201
+ "cache_read_input_per_million": 0.135
202
+ }
203
+ }
204
+ },
205
+ "architecture": "text->text",
206
+ "source": "openrouter"
207
+ },
208
+ {
209
+ "id": "deepseek-v3.2",
210
+ "name": "DeepSeek: DeepSeek V3.2",
211
+ "provider": "deepseek",
212
+ "context_window": 163840,
213
+ "max_output_tokens": 65536,
214
+ "capabilities": [],
215
+ "modalities": {
216
+ "input": [
217
+ "text"
218
+ ],
219
+ "output": [
220
+ "text"
221
+ ]
222
+ },
223
+ "pricing": {
224
+ "text_tokens": {
225
+ "standard": {
226
+ "input_per_million": 0.269,
227
+ "output_per_million": 0.4,
228
+ "cache_read_input_per_million": 0.1345
229
+ }
230
+ }
231
+ },
232
+ "architecture": "text->text",
233
+ "source": "openrouter"
234
+ },
235
+ {
236
+ "id": "deepseek-v3.2-exp",
237
+ "name": "DeepSeek: DeepSeek V3.2 Exp",
238
+ "provider": "deepseek",
239
+ "context_window": 163840,
240
+ "max_output_tokens": 65536,
241
+ "capabilities": [],
242
+ "modalities": {
243
+ "input": [
244
+ "text"
245
+ ],
246
+ "output": [
247
+ "text"
248
+ ]
249
+ },
250
+ "pricing": {
251
+ "text_tokens": {
252
+ "standard": {
253
+ "input_per_million": 0.27,
254
+ "output_per_million": 0.41
255
+ }
256
+ }
257
+ },
258
+ "architecture": "text->text",
259
+ "source": "openrouter"
260
+ },
261
+ {
262
+ "id": "deepseek-r1",
263
+ "name": "DeepSeek: R1",
264
+ "provider": "deepseek",
265
+ "context_window": 163840,
266
+ "max_output_tokens": 16000,
267
+ "capabilities": [],
268
+ "modalities": {
269
+ "input": [
270
+ "text"
271
+ ],
272
+ "output": [
273
+ "text"
274
+ ]
275
+ },
276
+ "pricing": {
277
+ "text_tokens": {
278
+ "standard": {
279
+ "input_per_million": 0.7,
280
+ "output_per_million": 2.5
281
+ }
282
+ }
283
+ },
284
+ "architecture": "text->text",
285
+ "source": "openrouter"
286
+ },
287
+ {
288
+ "id": "deepseek-r1-0528",
289
+ "name": "DeepSeek: R1 0528",
290
+ "provider": "deepseek",
291
+ "context_window": 163840,
292
+ "max_output_tokens": 32768,
293
+ "capabilities": [],
294
+ "modalities": {
295
+ "input": [
296
+ "text"
297
+ ],
298
+ "output": [
299
+ "text"
300
+ ]
301
+ },
302
+ "pricing": {
303
+ "text_tokens": {
304
+ "standard": {
305
+ "input_per_million": 0.5,
306
+ "output_per_million": 2.15,
307
+ "cache_read_input_per_million": 0.35
308
+ }
309
+ }
310
+ },
311
+ "architecture": "text->text",
312
+ "source": "openrouter"
313
+ },
314
+ {
315
+ "id": "deepseek-r1-distill-llama-70b",
316
+ "name": "DeepSeek: R1 Distill Llama 70B",
317
+ "provider": "deepseek",
318
+ "context_window": 128000,
319
+ "max_output_tokens": 8192,
320
+ "capabilities": [],
321
+ "modalities": {
322
+ "input": [
323
+ "text"
324
+ ],
325
+ "output": [
326
+ "text"
327
+ ]
328
+ },
329
+ "pricing": {
330
+ "text_tokens": {
331
+ "standard": {
332
+ "input_per_million": 0.8,
333
+ "output_per_million": 0.8
334
+ }
335
+ }
336
+ },
337
+ "architecture": "text->text",
338
+ "source": "openrouter"
339
+ }
340
+ ]