@prestyj/core 5.23.0 → 5.25.0

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.
@@ -163,11 +163,37 @@ var MODELS = [
163
163
  // costTier: "high",
164
164
  // maxThinkingLevel: "max",
165
165
  // },
166
+ {
167
+ // Released 2026-09-22 — "For long-running agentic coding and knowledge
168
+ // work". Fable-class capability at $4/$20 MTok (cheaper than the Opus 5 it
169
+ // replaces, $5/$25). Adaptive thinking with the full effort ladder
170
+ // (low→max, xhigh included), but thinking can no longer be disabled: a
171
+ // `thinking: {type: "disabled"}` or budget_tokens request 400s. @prestyj/ai
172
+ // omits the field entirely when thinking is off, so that path is safe.
173
+ // Forced tool use (`tool_choice` any/tool) also 400s — see
174
+ // `toAnthropicToolChoice`, which downgrades it to `auto` for this model.
175
+ // Anthropic declares the server-side default effort as `medium` (Opus 5
176
+ // ran `high`), and 5.5 thinks more per turn at a given level, so a fresh
177
+ // session starts at `medium` rather than the ladder ceiling.
178
+ id: "claude-opus-5-5",
179
+ name: "Claude Opus 5.5",
180
+ provider: "anthropic",
181
+ contextWindow: 1e6,
182
+ maxOutputTokens: 128e3,
183
+ supportsThinking: true,
184
+ defaultThinkingLevel: "medium",
185
+ supportsImages: true,
186
+ supportsVideo: false,
187
+ costTier: "high",
188
+ maxThinkingLevel: "max"
189
+ },
166
190
  {
167
191
  // Released 2026-07-24 — "For complex agentic coding and enterprise work".
168
192
  // Near-Fable capability at half the price ($5/$25 vs $10/$50). Adaptive
169
193
  // thinking with the full effort ladder (low→max, xhigh included); dateless
170
- // ID is the canonical pinned snapshot (post-4.6 naming scheme).
194
+ // ID is the canonical pinned snapshot (post-4.6 naming scheme). Kept as a
195
+ // legacy option now that Opus 5.5 leads the line: it's the last Opus that
196
+ // accepts disabled thinking and forced tool use.
171
197
  id: "claude-opus-5",
172
198
  name: "Claude Opus 5",
173
199
  provider: "anthropic",
@@ -316,16 +342,21 @@ var MODELS = [
316
342
  maxThinkingLevel: "max"
317
343
  },
318
344
  // ── xAI (Grok) ─────────────────────────────────────────
319
- // Grok 4.6 (released 2026-08-12) is xAI's flagship for coding, agentic tasks,
320
- // and knowledge work, with a focus on long-running agents — 500K context,
321
- // text+image input, and a `reasoning_effort` ladder that adds a new `xhigh`
322
- // top rung (low/medium/high default/xhigh; reasoning still can't be fully
345
+ // Grok 4.7 (released 2026-09-21) — xAI's flagship for coding, agentic tasks,
346
+ // and knowledge work: a new, larger base model with a longer RL run weighted
347
+ // toward hours-long tasks, plus stronger self-verification and long-context
348
+ // management. 500K context, text+image input, and a `reasoning_effort`
349
+ // ladder of low/medium/high default/xhigh (reasoning still can't be fully
323
350
  // disabled). $2/$6 per MTok under 200K prompt tokens ($4/$12 at or above),
324
- // and it's the default model of the Grok Build coding agent. xAI advertises "no text output limit"; we keep the same
325
- // 131K practical cap as 4.5 for budget predictability and input headroom.
326
- {
327
- id: "grok-4.6",
328
- name: "Grok 4.6",
351
+ // and it's the default model of the Grok Build coding agent. xAI advertises
352
+ // "no fixed text output limit"; we keep the 131K practical cap for budget
353
+ // predictability and input headroom. (A faster "Grok 4.7 Fast" variant
354
+ // exists but is Cursor/Grok Build-only — not on the public API — so it isn't
355
+ // registered.) Only the newest Grok ships — 4.6/4.5 are superseded and
356
+ // retired; saved sessions on them fall back to this default.
357
+ {
358
+ id: "grok-4.7",
359
+ name: "Grok 4.7",
329
360
  provider: "xai",
330
361
  contextWindow: 5e5,
331
362
  maxOutputTokens: 131072,
@@ -335,24 +366,6 @@ var MODELS = [
335
366
  costTier: "medium",
336
367
  maxThinkingLevel: "xhigh"
337
368
  },
338
- // Grok 4.5 (released 2026-07-08) — superseded by 4.6 but retained as an explicit option. 500K context, text+image input,
339
- // configurable `reasoning_effort` (low/medium/high, server default high;
340
- // reasoning can't be fully disabled). Served over the OpenAI-compatible API
341
- // at https://api.x.ai/v1 (API key from console.x.ai). xAI hasn't published an
342
- // official max-output cap for 4.5; 131K matches the Grok Responses ceiling
343
- // third-party integrations use.
344
- {
345
- id: "grok-4.5",
346
- name: "Grok 4.5",
347
- provider: "xai",
348
- contextWindow: 5e5,
349
- maxOutputTokens: 131072,
350
- supportsThinking: true,
351
- supportsImages: true,
352
- supportsVideo: false,
353
- costTier: "medium",
354
- maxThinkingLevel: "high"
355
- },
356
369
  // ── Gemini ─────────────────────────────────────────
357
370
  {
358
371
  id: "gemini-3.1-flash-lite",
@@ -541,11 +554,15 @@ var MODELS = [
541
554
  maxThinkingLevel: "high"
542
555
  },
543
556
  // ── Xiaomi (MiMo) ──────────────────────────────────────
544
- // V2.6 series (2026-09) supersedes V2.5 one-for-one: pro → pro, the omni
545
- // `mimo-v2.5` → flash, ultraspeed → ultraspeed. The whole series is now
546
- // full-modality, so unlike V2.5-Pro the flagship no longer needs a separate
547
- // omni sibling for attachments. V2.5 entries are retired here — a session
548
- // that still has one saved falls back to the provider default on next start.
557
+ // V2.6 series (released 2026-09-22, open-weight: Pro 1.02T/42B-A, Flash
558
+ // 309B/15B-A, plus a 9B Qwen distill not served over the API) supersedes V2.5
559
+ // one-for-one: pro → pro, the omni `mimo-v2.5` → flash, ultraspeed →
560
+ // ultraspeed. Every V2.6 text model is natively full-modality, so unlike
561
+ // V2.5-Pro the flagship no longer needs a separate omni sibling for
562
+ // attachments — image/video ride the same OpenAI-compatible base64 transport
563
+ // the old omni model used. API prices are unchanged from V2.5. The V2.5 ids
564
+ // deprecate on the platform 2026-10-21 and are retired here — a session that
565
+ // still has one saved falls back to the provider default on next start.
549
566
  //
550
567
  // Capabilities below are measured against the Token Plan host, not taken
551
568
  // from marketing copy: image and video both come back with `image_tokens` /
@@ -555,6 +572,8 @@ var MODELS = [
555
572
  // binary 1M below (2^20) and not the decimal 1e6 V2.5 was listed with — the
556
573
  // few-token gap is the chat envelope the server adds on top of the content.
557
574
  {
575
+ // Coding/agentic flagship — highest open-weight score on Artificial
576
+ // Analysis at launch (46, tied with Grok 4.7).
558
577
  id: "mimo-v2.6-pro",
559
578
  name: "MiMo-V2.6-Pro",
560
579
  provider: "xiaomi",
@@ -568,9 +587,10 @@ var MODELS = [
568
587
  maxThinkingLevel: "high",
569
588
  authStorageKeys: ["xiaomi", XIAOMI_CREDITS_KEY]
570
589
  },
571
- // Flash: the cheap, high-frequency sibling at the same modality surface and
572
- // window as Pro. It is the provider's `low` tier, so scout sub-agents and
573
- // compaction summaries route here instead of paying Pro rates.
590
+ // Flash: the cheap, high-frequency sibling (~10% of Pro's price class) at the
591
+ // same modality surface and window as Pro. It is the provider's `low` tier,
592
+ // so scout sub-agents and compaction summaries route here instead of paying
593
+ // Pro rates.
574
594
  {
575
595
  id: "mimo-v2.6-flash",
576
596
  name: "MiMo-V2.6-Flash",
@@ -591,9 +611,9 @@ var MODELS = [
591
611
  // authStorageKeys doc). The Token Plan host rejects it with "Not supported
592
612
  // model" — the known-model/wrong-host reply — where an invented id gets
593
613
  // "Unsupported model", which is how this id was confirmed without a
594
- // Credits key. Attachment support is inferred from the series announcement
595
- // ("full modality across the series") rather than measured: images are
596
- // enabled, video stays off until it can be verified on the platform host.
614
+ // Credits key. Attachments can't be probed directly for the same reason, so
615
+ // this entry tracks the rest of the V2.6 series ("full modality across the
616
+ // series") and mirrors Pro's verified image+video surface.
597
617
  {
598
618
  id: "mimo-v2.6-pro-ultraspeed",
599
619
  name: "MiMo-V2.6-Pro-UltraSpeed",
@@ -602,7 +622,8 @@ var MODELS = [
602
622
  maxOutputTokens: 131072,
603
623
  supportsThinking: true,
604
624
  supportsImages: true,
605
- supportsVideo: false,
625
+ supportsVideo: true,
626
+ maxVideoBytes: 36 * 1024 * 1024,
606
627
  costTier: "high",
607
628
  maxThinkingLevel: "high",
608
629
  authStorageKeys: [XIAOMI_CREDITS_KEY]
@@ -752,7 +773,7 @@ function getDefaultModel(provider) {
752
773
  return MODELS.find((m) => m.id === "Qwen/Qwen3-Coder-480B-A35B-Instruct");
753
774
  if (provider === "openrouter") return MODELS.find((m) => m.id === "qwen/qwen3.6-plus");
754
775
  if (provider === "sakana") return MODELS.find((m) => m.id === "fugu");
755
- if (provider === "xai") return MODELS.find((m) => m.id === "grok-4.6");
776
+ if (provider === "xai") return MODELS.find((m) => m.id === "grok-4.7");
756
777
  if (provider === "local") {
757
778
  return getModelsForProvider("local")[0] ?? PLACEHOLDER_LOCAL_MODEL;
758
779
  }