yoagent 0.26.5

The agent loop for Rust: stream from 7 LLM protocols, run tools, loop until done. Native or wasm32 (Cloudflare Workers).
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
{
  "schema": 1,
  "comment": "yoagent's built-in model prices, USD per million tokens, keyed by ModelConfig::provider then ModelConfig::id (decision models: by their price provider key, e.g. 'typesafe', then the model id the API reports). A cache rate of 0 (or omitted) bills at the band's input rate. Rates are a snapshot checked against each 'source' on its 'verified' date, not an authority; tests/price_audit.rs diffs every entry against models.dev. See docs/concepts/pricing.md.",
  "providers": {
    "anthropic": {
      "claude-fable-5": {
        "input": 10.0,
        "output": 50.0,
        "cache_read": 1.0,
        "cache_write": 12.5,
        "source": "https://platform.claude.com/docs/en/about-claude/pricing",
        "verified": "2026-08-19"
      },
      "claude-fable-5-1": {
        "input": 10.0,
        "output": 50.0,
        "cache_read": 0.25,
        "cache_write": 12.5,
        "note": "Cache hits bill at 0.025x input ($0.25), not Fable 5's 0.1x. cache_write is the 5-minute rate; the 1-hour rate ($20) is not modelled because yoagent places only 5-minute breakpoints. Verified against the raw page markup.",
        "source": "https://platform.claude.com/docs/en/about-claude/pricing",
        "verified": "2026-09-24"
      },
      "claude-haiku-4-5": {
        "input": 1.0,
        "output": 5.0,
        "cache_read": 0.1,
        "cache_write": 1.25,
        "note": "Flat: the 200K window is below any long-context band.",
        "source": "https://platform.claude.com/docs/en/about-claude/pricing",
        "verified": "2026-08-19"
      },
      "claude-opus-4-8": {
        "input": 5.0,
        "output": 25.0,
        "cache_read": 0.5,
        "cache_write": 6.25,
        "source": "https://platform.claude.com/docs/en/about-claude/pricing",
        "verified": "2026-08-19"
      },
      "claude-opus-5": {
        "input": 5.0,
        "output": 25.0,
        "cache_read": 0.5,
        "cache_write": 6.25,
        "source": "https://platform.claude.com/docs/en/about-claude/pricing",
        "verified": "2026-08-19"
      },
      "claude-opus-5-5": {
        "input": 4.0,
        "output": 20.0,
        "cache_read": 0.2,
        "cache_write": 5.0,
        "note": "Cache hits bill at 0.05x input ($0.20), not the usual 0.1x. cache_write is the 5-minute rate; the 1-hour rate ($8) is not modelled because yoagent places only 5-minute breakpoints. Verified against the raw page markup.",
        "source": "https://platform.claude.com/docs/en/about-claude/pricing",
        "verified": "2026-09-25"
      },
      "claude-sonnet-5": {
        "input": 2.0,
        "output": 10.0,
        "cache_read": 0.2,
        "cache_write": 2.5,
        "note": "Shipped Sonnet 4.6's $3/$15 from v0.9.0 through v0.16.5; these are Sonnet 5's own rates.",
        "source": "https://platform.claude.com/docs/en/about-claude/pricing",
        "verified": "2026-08-19"
      },
      "claude-sonnet-5-5": {
        "input": 2.0,
        "output": 10.0,
        "cache_read": 0.1,
        "cache_write": 2.5,
        "note": "5-minute cache write; the 1-hour write is $4.00. No long-context tier: the full 1M bills at these rates.",
        "source": "https://platform.claude.com/docs/en/about-claude/pricing",
        "verified": "2026-10-18"
      },
      "claude-haiku-5-5": {
        "input": 0.1,
        "output": 0.5,
        "cache_read": 0.01,
        "cache_write": 0.125,
        "tiers": [
          {
            "above_prompt_tokens": 100000,
            "input": 0.5,
            "output": 2.5,
            "cache_read": 0.05,
            "cache_write": 0.625
          }
        ],
        "note": "Prompts over 100,000 tokens (input + cache reads + cache writes) bill the whole request at the second rates. 5-minute cache write; the 1-hour write is $0.20 / $1.00.",
        "source": "https://platform.claude.com/docs/en/about-claude/pricing",
        "verified": "2026-10-18"
      }
    },
    "deepseek": {
        "deepseek-flash": {
            "input": 0.3,
            "output": 1.2,
            "cache_read": 0.006,
            "cache_write": 0.3,
            "cache_write_at_input": true,
            "note": "Peak rate. DeepSeek bills half of it off-peak: all hours but 01:00-04:00 and 06:00-10:00 UTC on weekdays (about 79% of the week). A flat CostConfig has no time of day, so the peak rate is the upper bound: costs are over-stated off-peak, never under-stated, and a Budget stops early rather than late.",
            "source": "https://api-docs.deepseek.com/quick_start/pricing",
            "verified": "2026-10-16"
        },
        "deepseek-v4-flash": {
            "input": 0.3,
            "output": 1.2,
            "cache_read": 0.006,
            "cache_write": 0.3,
            "cache_write_at_input": true,
            "note": "The legacy name: served by DeepSeek-V4.1-Flash and billed at the deepseek-flash price. Peak rate. DeepSeek bills half of it off-peak: all hours but 01:00-04:00 and 06:00-10:00 UTC on weekdays (about 79% of the week). A flat CostConfig has no time of day, so the peak rate is the upper bound: costs are over-stated off-peak, never under-stated, and a Budget stops early rather than late.",
            "source": "https://api-docs.deepseek.com/quick_start/pricing",
            "verified": "2026-10-16"
        },
        "deepseek-v4-flash-vision-exp": {
            "input": 0.3,
            "output": 1.2,
            "cache_read": 0.006,
            "cache_write": 0.3,
            "cache_write_at_input": true,
            "note": "The legacy name of a retired vision experiment: served by DeepSeek-V4.1-Flash-1017 (deepseek-flash, which takes images) and billed at the deepseek-flash price. Peak rate. DeepSeek bills half of it off-peak: all hours but 01:00-04:00 and 06:00-10:00 UTC on weekdays (about 79% of the week). A flat CostConfig has no time of day, so the peak rate is the upper bound: costs are over-stated off-peak, never under-stated, and a Budget stops early rather than late.",
            "source": "https://api-docs.deepseek.com/quick_start/pricing",
            "verified": "2026-10-18"
        },
        "deepseek-v4-pro": {
            "input": 1.32,
            "output": 3.96,
            "cache_read": 0.044,
            "cache_write": 1.32,
            "cache_write_at_input": true,
            "note": "Peak rate. DeepSeek bills half of it off-peak: all hours but 01:00-04:00 and 06:00-10:00 UTC on weekdays (about 79% of the week). A flat CostConfig has no time of day, so the peak rate is the upper bound: costs are over-stated off-peak, never under-stated, and a Budget stops early rather than late.",
            "source": "https://api-docs.deepseek.com/quick_start/pricing",
            "verified": "2026-10-16"
        }
    },
    "meta": {
      "muse-spark-1.1": {
        "input": 1.25,
        "output": 4.25,
        "cache_read": 0.15,
        "cache_write": 1.25,
        "cache_write_at_input": true,
        "note": "Meta charges no cache-write premium, so writes bill at the $1.25 input rate; models.dev omits cache_write for Muse Spark. No long-context premium. The contributor tier (muse-spark-*-contributor) is priced far lower and is deliberately not listed here.",
        "source": "https://dev.meta.ai/docs/pricing-rate-limits",
        "verified": "2026-08-19"
      },
      "muse-spark-1.2": {
        "input": 1.25,
        "output": 4.25,
        "cache_read": 0.15,
        "cache_write": 1.25,
        "cache_write_at_input": true,
        "note": "Meta charges no cache-write premium, so writes bill at the $1.25 input rate; models.dev omits cache_write for Muse Spark. No long-context premium. The contributor tier (muse-spark-*-contributor) is priced far lower and is deliberately not listed here.",
        "source": "https://dev.meta.ai/docs/pricing-rate-limits",
        "verified": "2026-08-19"
      },
      "muse-spark-1.3": {
        "input": 1.25,
        "output": 4.25,
        "cache_read": 0.15,
        "cache_write": 1.25,
        "cache_write_at_input": true,
        "note": "Meta charges no cache-write premium, so writes bill at the $1.25 input rate; models.dev omits cache_write for Muse Spark. No long-context premium. The contributor tier (muse-spark-*-contributor) is priced far lower and is deliberately not listed here.",
        "source": "https://dev.meta.ai/docs/pricing-rate-limits",
        "verified": "2026-11-01"
      },
      "muse-wonder-1.0": {
        "input": 4.0,
        "output": 20.0,
        "cache_read": 0.2,
        "cache_write": 4.0,
        "cache_write_at_input": true,
        "note": "Meta charges no cache-write premium, so writes bill at the $4 input rate; models.dev omits cache_write. No long-context premium. Contributor mode is not offered for Muse Wonder. In preview.",
        "source": "https://dev.meta.ai/docs/pricing-rate-limits",
        "verified": "2026-11-01"
      }
    },
    "openai": {
      "gpt-5.5": {
        "input": 5.0,
        "output": 30.0,
        "cache_read": 0.5,
        "cache_write": 5.0,
        "tiers": [
          {
            "above_prompt_tokens": 272000,
            "input": 10.0,
            "output": 45.0,
            "cache_read": 1.0,
            "cache_write": 10.0
          }
        ],
        "cache_write_at_input": true,
        "note": "The >272K cache_read ($1.00) is UNVERIFIED. The model page says only that \"prompts with >272K input tokens are priced at 2x input and 1.5x output for the full session\" - it names no cache rate, and the pricing page no longer lists gpt-5.5. $1.00 (2x, as the GPT-6 pages state for their cache rates) matches models.dev; the literal reading would keep $0.50. Input $10 and output $45 are stated. OpenAI charges no cache-write premium before GPT-5.6, so cache writes bill at the input rate ($5, $10 above 272K); models.dev omits cache_write for it.",
        "source": "https://developers.openai.com/api/docs/models/gpt-5.5",
        "verified": "2026-09-25"
      },
      "gpt-6-astra": {
        "input": 10.0,
        "output": 50.0,
        "cache_read": 1.0,
        "cache_write": 12.5,
        "tiers": [
          {
            "above_prompt_tokens": 272000,
            "input": 20.0,
            "output": 75.0,
            "cache_read": 2.0,
            "cache_write": 25.0
          }
        ],
        "source": "https://developers.openai.com/api/docs/pricing",
        "verified": "2026-09-25"
      },
      "gpt-6-luna": {
        "input": 0.1,
        "output": 0.5,
        "cache_read": 0.01,
        "cache_write": 0.125,
        "tiers": [
          {
            "above_prompt_tokens": 272000,
            "input": 0.2,
            "output": 0.75,
            "cache_read": 0.02,
            "cache_write": 0.25
          }
        ],
        "source": "https://developers.openai.com/api/docs/pricing",
        "verified": "2026-09-25"
      },
      "gpt-6-sol": {
        "input": 2.0,
        "output": 10.0,
        "cache_read": 0.2,
        "cache_write": 2.5,
        "tiers": [
          {
            "above_prompt_tokens": 272000,
            "input": 4.0,
            "output": 15.0,
            "cache_read": 0.4,
            "cache_write": 5.0
          }
        ],
        "source": "https://developers.openai.com/api/docs/pricing",
        "verified": "2026-09-25"
      },
      "gpt-6.1-sol": {
        "input": 2.0,
        "output": 10.0,
        "cache_read": 0.1,
        "cache_write": 2.5,
        "tiers": [
          {
            "above_prompt_tokens": 272000,
            "input": 4.0,
            "output": 15.0,
            "cache_read": 0.2,
            "cache_write": 5.0
          }
        ],
        "source": "https://developers.openai.com/api/docs/pricing",
        "verified": "2026-10-18"
      },
      "gpt-6.1-terra": {
        "input": 1.0,
        "output": 5.0,
        "cache_read": 0.05,
        "cache_write": 1.25,
        "tiers": [
          {
            "above_prompt_tokens": 272000,
            "input": 2.0,
            "output": 7.5,
            "cache_read": 0.1,
            "cache_write": 2.5
          }
        ],
        "note": "Cache writes bill at $1.25 under the 30-minute default retention; OpenAI says writes are not an additive fee.",
        "source": "https://developers.openai.com/api/docs/pricing",
        "verified": "2026-11-01"
      }
    },
    "google": {
      "gemini-3.8-flash": {
        "input": 1.5,
        "output": 7.5,
        "cache_read": 0.15,
        "note": "Regular price. Google bills an introductory $0.75 / $3.75 / $0.075 through 2026-12-31: until then costs read twice the bill (an upper bound, so a Budget stops early, never late). Context-cache storage ($1.00 per 1M tokens per hour) is not modelled.",
        "source": "https://ai.google.dev/gemini-api/docs/pricing",
        "verified": "2026-10-18"
      },
      "gemini-4-argon": {
        "input": 4.0,
        "output": 20.0,
        "cache_read": 0.2,
        "note": "Regular price. Google bills an introductory $2 / $10 / $0.10 through 2026-11-30: until then costs read twice the bill (an upper bound, so a Budget stops early, never late). No context tier.",
        "source": "https://ai.google.dev/gemini-api/docs/pricing",
        "verified": "2026-10-18"
      }
    },
    "mistral": {
      "mistral-large-4": {
        "input": 0.7,
        "output": 2.1,
        "cache_read": 0.07,
        "note": "Mistral's model page lists $0.70 / $2.10 (cached $0.07) from about 2026-10-30, with no sale marking; it listed $1.36 / $4.18 after the launch sale (50% off, $0.68 in, from 2026-10-06) ended. No changelog entry announces the change.",
        "source": "https://docs.mistral.ai/models/mistral-large-4-0",
        "verified": "2026-10-30"
      }
    },
    "qwen": {
      "qwen3.8-flash": {
        "input": 0.15,
        "output": 0.47,
        "cache_read": 0.016,
        "cache_write": 0.2,
        "note": "International (Singapore) deployment, the endpoint ModelConfig::qwen uses; the Global and Beijing scopes bill less.",
        "source": "https://www.alibabacloud.com/help/en/model-studio/model-pricing",
        "verified": "2026-10-18"
      },
      "qwen3.8-max": {
        "input": 2.0,
        "output": 6.0,
        "cache_read": 0.25,
        "cache_write": 2.5,
        "note": "International (Singapore) deployment, the endpoint ModelConfig::qwen uses. cache_read is the implicit-cache rate; an explicit-cache read bills $0.17. The Global and Beijing scopes bill less.",
        "source": "https://www.alibabacloud.com/help/en/model-studio/model-pricing",
        "verified": "2026-10-18"
      },
      "qwen3.8-omni-flash": {
        "input": 0.15,
        "output": 0.47,
        "cache_read": 0.016,
        "note": "International (Singapore) deployment; implicit cache only (no cache-creation charge); one input rate for every modality; the Global and Beijing scopes bill less ($0.113 / $0.382).",
        "source": "https://www.alibabacloud.com/help/en/model-studio/model-pricing",
        "verified": "2026-11-01"
      }
    },
    "xai": {
      "grok-4.7": {
        "input": 2.0,
        "output": 6.0,
        "cache_read": 0.5,
        "tiers": [
          {
            "above_prompt_tokens": 200000,
            "input": 4.0,
            "output": 12.0,
            "cache_read": 1.0
          }
        ],
        "note": "Prompts of 200,000 tokens or more bill the whole request at the second rates (this table's threshold is exclusive, so it costs a prompt of exactly 200,000 tokens at the lower rate, under-counting it; xAI bills it at the higher one). The US-region endpoint bills 10% more.",
        "source": "https://docs.x.ai/docs/models",
        "verified": "2026-10-18"
      }
    },
    "zai": {
      "glm-5.3": {
        "input": 1.4,
        "output": 4.4,
        "cache_read": 0.26,
        "note": "Cache storage is free for a limited time.",
        "source": "https://docs.z.ai/guides/overview/pricing",
        "verified": "2026-10-18"
      },
      "glm-5.3-flash": {
        "input": 0.15,
        "output": 0.5,
        "cache_read": 0.03,
        "source": "https://docs.z.ai/guides/overview/pricing",
        "verified": "2026-10-18"
      },
      "glm-5.3-flashx": {
        "input": 0.37,
        "output": 1.25,
        "cache_read": 0.075,
        "note": "Z.ai lists no cache-write rate; cached-input storage is free for a limited time and not modelled here, so costs will read low once that ends.",
        "source": "https://docs.z.ai/guides/overview/pricing",
        "verified": "2026-11-01"
      }
    },
    "cloudflare": {
      "clef": {
        "input": 0.24,
        "output": 0.0,
        "note": "A decision model (feature `decision`), not a ModelConfig: DecisionModel::clef() prices each evaluation by its model id while requests go to Cloudflare's REST API (yoagent-workers' binding presets use the same rate). Workers AI lists a unit price for input tokens only; output is not listed and is recorded as 0.",
        "source": "https://developers.cloudflare.com/workers-ai/models/clef/",
        "verified": "2026-10-03",
        "absent_upstream": "models.dev lists no Clef model; checked 2026-10-03"
      },
      "clef-flash": {
        "input": 0.09,
        "output": 0.0,
        "note": "A decision model (feature `decision`): DecisionModel::clef_flash(). Workers AI lists a unit price for input tokens only; output is not listed and is recorded as 0.",
        "source": "https://developers.cloudflare.com/workers-ai/models/clef-flash/",
        "verified": "2026-10-03",
        "absent_upstream": "models.dev lists no Clef model; checked 2026-10-03"
      }
    },
    "openai-decisions": {
      "gpt-6-luna": {
        "input": 0.1,
        "output": 0.0,
        "note": "A decision model (feature `decision`), not a ModelConfig: DecisionModel::gpt_6_luna() prices each evaluation on OpenAI's Decisions API (POST /v1/decisions) by the model id the response reports, while requests go to api.openai.com. Distinct from chat gpt-6-luna pricing (provider `openai`). Billed per input token, cached input included; no cache-read, cache-write or output charges. Regional-processing and long-context multipliers are not modelled.",
        "source": "https://developers.openai.com/api/docs/guides/decisions",
        "verified": "2026-10-07",
        "absent_upstream": "models.dev lists no Decisions API pricing (its openai entries are chat rates); checked 2026-10-07"
      }
    },
    "typesafe": {
      "jev-1.13.0": {
        "input": 0.042,
        "output": 0.0,
        "note": "A decision model (feature `decision`), not a ModelConfig: DecisionModel::jev() prices each evaluation by the versioned id the API reports. Billed per input token; output tokens are free ($42 per billion input tokens).",
        "source": "https://docs.typesafe.ai/models",
        "verified": "2026-09-26",
        "absent_upstream": "models.dev lists no TypeSafe provider and no Jev model; checked 2026-09-26"
      }
    }
  }
}