@prestyj/core 5.31.0 → 5.32.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.
package/dist/index.cjs CHANGED
@@ -123,6 +123,9 @@ __export(index_exports, {
123
123
  });
124
124
  module.exports = __toCommonJS(index_exports);
125
125
 
126
+ // src/model-registry.ts
127
+ var import_ai2 = require("@prestyj/ai");
128
+
126
129
  // src/oauth/kimi.ts
127
130
  var import_node_child_process = require("child_process");
128
131
  var import_node_crypto = require("crypto");
@@ -2241,6 +2244,25 @@ var MODELS = [
2241
2244
  defaultThinkingLevel: "medium",
2242
2245
  maxThinkingLevel: "max"
2243
2246
  },
2247
+ {
2248
+ // Opus 5.5 in fast mode (research preview): the same model at up to 2.5x
2249
+ // output tokens/sec, $8/$40 MTok. @prestyj/ai's `stream()` sends it as
2250
+ // `claude-opus-5-5` + `speed: "fast"` + the fast-mode beta. On a Claude
2251
+ // subscription it bills usage credits only — never included plan usage —
2252
+ // and Anthropic 429s "Usage credits are required for fast mode" until they
2253
+ // are turned on. Its prompt cache is separate from standard-speed Opus.
2254
+ id: "claude-opus-5-5-fast",
2255
+ name: "Claude Opus 5.5 Fast",
2256
+ provider: "anthropic",
2257
+ contextWindow: 1e6,
2258
+ maxOutputTokens: 128e3,
2259
+ supportsThinking: true,
2260
+ supportsImages: true,
2261
+ supportsVideo: false,
2262
+ costTier: "high",
2263
+ defaultThinkingLevel: "medium",
2264
+ maxThinkingLevel: "max"
2265
+ },
2244
2266
  {
2245
2267
  // Released 2026-09-28 — replaces Sonnet 5 at $2/$10 MTok, with the same
2246
2268
  // 1M context / 128K output and adaptive thinking, now including xhigh.
@@ -2308,6 +2330,24 @@ var MODELS = [
2308
2330
  costTier: "high",
2309
2331
  maxThinkingLevel: "ultra"
2310
2332
  },
2333
+ {
2334
+ // Codex Fast mode for Astra (catalog `service_tiers: priority`, "2x speed,
2335
+ // increased usage"). @prestyj/ai's `stream()` sends it as `gpt-6-astra` +
2336
+ // `service_tier: "priority"`, exactly what the Codex CLI sends. On a
2337
+ // ChatGPT plan it draws included limits at 2.5x the standard rate.
2338
+ id: "gpt-6-astra-fast",
2339
+ name: "GPT-6 Astra Fast",
2340
+ provider: "openai",
2341
+ contextWindow: 105e4,
2342
+ codexContextWindow: 272e3,
2343
+ maxOutputTokens: 128e3,
2344
+ supportsThinking: true,
2345
+ defaultThinkingLevel: "low",
2346
+ supportsImages: true,
2347
+ supportsVideo: false,
2348
+ costTier: "high",
2349
+ maxThinkingLevel: "ultra"
2350
+ },
2311
2351
  // GPT-6 Sol + Luna — released 2026-09-22 below Astra, replacing the whole
2312
2352
  // GPT-5.6 family (Sol/Terra/Luna; there is no GPT-6 Terra — OpenAI's Codex
2313
2353
  // catalog upgrades 5.6 Terra to 6 Sol). GPT-6.1 Sol (2026-09-29) then replaced
@@ -2336,6 +2376,22 @@ var MODELS = [
2336
2376
  costTier: "medium",
2337
2377
  maxThinkingLevel: "ultra"
2338
2378
  },
2379
+ {
2380
+ // Codex Fast mode for 6.1 Sol ("2x speed, increased usage") — see
2381
+ // `gpt-6-astra-fast` for the wire mapping and billing.
2382
+ id: "gpt-6.1-sol-fast",
2383
+ name: "GPT-6.1 Sol Fast",
2384
+ provider: "openai",
2385
+ contextWindow: 105e4,
2386
+ codexContextWindow: 272e3,
2387
+ maxOutputTokens: 128e3,
2388
+ supportsThinking: true,
2389
+ defaultThinkingLevel: "low",
2390
+ supportsImages: true,
2391
+ supportsVideo: false,
2392
+ costTier: "medium",
2393
+ maxThinkingLevel: "ultra"
2394
+ },
2339
2395
  {
2340
2396
  // Luna — "Fast and affordable model for easier tasks." (Codex priority 4,
2341
2397
  // default medium, needs a Codex client >= 0.155.0). $0.10/$0.50 MTok.
@@ -2353,6 +2409,23 @@ var MODELS = [
2353
2409
  costTier: "low",
2354
2410
  maxThinkingLevel: "max"
2355
2411
  },
2412
+ {
2413
+ // Codex Fast mode for Luna ("1.5x speed") — see `gpt-6-astra-fast` for the
2414
+ // wire mapping and billing. Listed after Luna so compaction summaries
2415
+ // (first `low` OpenAI model) stay on standard-speed Luna.
2416
+ id: "gpt-6-luna-fast",
2417
+ name: "GPT-6 Luna Fast",
2418
+ provider: "openai",
2419
+ contextWindow: 105e4,
2420
+ codexContextWindow: 272e3,
2421
+ maxOutputTokens: 128e3,
2422
+ supportsThinking: true,
2423
+ defaultThinkingLevel: "medium",
2424
+ supportsImages: true,
2425
+ supportsVideo: false,
2426
+ costTier: "low",
2427
+ maxThinkingLevel: "max"
2428
+ },
2356
2429
  // ── Sakana (Fugu) ──────────────────────────────────────
2357
2430
  // Sakana Fugu is a multi-agent system surfaced as a standard LLM via the
2358
2431
  // OpenAI-compatible Sakana API (https://api.sakana.ai/v1). All three take
@@ -2942,7 +3015,9 @@ var SUMMARY_COST_TIER = {
2942
3015
  };
2943
3016
  function getSummaryModel(provider, currentModelId) {
2944
3017
  const tier = SUMMARY_COST_TIER[provider];
2945
- const tagged = tier ? getModelsForProvider(provider).find((m) => m.costTier === tier) : void 0;
3018
+ const tagged = tier ? getModelsForProvider(provider).find(
3019
+ (m) => m.costTier === tier && !(0, import_ai2.resolveFastModeModel)(provider, m.id).fast
3020
+ ) : void 0;
2946
3021
  return tagged ?? getModel(currentModelId) ?? getDefaultModel(provider);
2947
3022
  }
2948
3023
 
@@ -3348,13 +3423,13 @@ var AUTH_PROVIDERS = [
3348
3423
  {
3349
3424
  value: "anthropic",
3350
3425
  label: "Anthropic",
3351
- description: "Claude Fable 5.1, Opus 5.5, Sonnet 5.5, Haiku 5.5",
3426
+ description: "Claude Fable 5.1, Opus 5.5, Opus 5.5 Fast, Sonnet 5.5, Haiku 5.5",
3352
3427
  methods: ["oauth"]
3353
3428
  },
3354
3429
  {
3355
3430
  value: "openai",
3356
3431
  label: "OpenAI",
3357
- description: "GPT-6 Astra, GPT-6.1 Sol, GPT-6 Luna",
3432
+ description: "GPT-6 Astra, GPT-6 Astra Fast, GPT-6.1 Sol, GPT-6.1 Sol Fast, GPT-6 Luna, GPT-6 Luna Fast",
3358
3433
  methods: ["oauth"]
3359
3434
  },
3360
3435
  {