@agentproto/model-catalog 0.3.0 → 0.4.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.
@@ -1,8 +1,8 @@
1
- export { A as AccessDecision, a as AccessEffect, b as AccessEvalInput, c as AccessRule, d as AccessTarget, e as AppScope, f as evaluateAccess } from '../evaluate-BWuQauRR.js';
2
- import { R as ResolvedModel } from '../index-DL-GcOAF.js';
3
- import '../base-BJo3zO1J.js';
1
+ export { A as AccessDecision, a as AccessEffect, b as AccessEvalInput, c as AccessRule, d as AccessTarget, e as AppScope, f as evaluateAccess } from '../evaluate-9mZ_5dki.js';
2
+ import { R as ResolvedModel } from '../index-DiJfHoVM.js';
3
+ import '../base-DWHjM4_d.js';
4
4
  import 'zod';
5
- import '../catalog-BXCENAMh.js';
5
+ import '../catalog-7Uyx_VEW.js';
6
6
  import '../image/index.js';
7
7
  import '../video/index.js';
8
8
  import '../audio/index.js';
@@ -126,4 +126,4 @@ declare const baseEntryShape: {
126
126
  readonly aliases: z.ZodOptional<z.ZodArray<z.ZodString>>;
127
127
  };
128
128
 
129
- export { type CatalogProvider as C, type Lifecycle as L, type ModelKind as M, type NsfwPolicy as N, PROVIDER_KEY_ENV as P, type CatalogPriceTier as a, CatalogPriceTierSchema as b, CatalogProviderSchema as c, LifecycleSchema as d, ModelKindSchema as e, NsfwPolicySchema as f, baseEntryShape as g };
129
+ export { type CatalogPriceTier as C, type Lifecycle as L, type ModelKind as M, type NsfwPolicy as N, PROVIDER_KEY_ENV as P, CatalogPriceTierSchema as a, type CatalogProvider as b, CatalogProviderSchema as c, LifecycleSchema as d, ModelKindSchema as e, NsfwPolicySchema as f, baseEntryShape as g };
@@ -1,4 +1,11 @@
1
- import { C as CatalogProvider } from './base-BJo3zO1J.js';
1
+ import { b as CatalogProvider } from './base-DWHjM4_d.js';
2
+
3
+ interface ContextWindowEntry {
4
+ contextWindow: number;
5
+ maxOutput?: number;
6
+ displayName?: string;
7
+ provider: "anthropic" | "groq" | "xai" | "moonshot";
8
+ }
2
9
 
3
10
  /**
4
11
  * LLM Pricing Catalog — per-token costs for all LLM models.
@@ -73,6 +80,7 @@ interface LLMPricing {
73
80
  */
74
81
  vendor?: string;
75
82
  }
83
+
76
84
  declare const LLM_PRICING_CATALOG: {
77
85
  "claude-opus-4-5": {
78
86
  inputPer1M: number;
@@ -295,6 +303,168 @@ declare const LLM_PRICING_CATALOG: {
295
303
  vendor: string;
296
304
  provider: "openai";
297
305
  };
306
+ "gpt-5.6-luna": {
307
+ inputPer1M: number;
308
+ outputPer1M: number;
309
+ cacheReadMultiplier: number;
310
+ vendor: string;
311
+ provider: "openai";
312
+ };
313
+ "gpt-5.6-luna-pro": {
314
+ inputPer1M: number;
315
+ outputPer1M: number;
316
+ cacheReadMultiplier: number;
317
+ vendor: string;
318
+ provider: "openai";
319
+ };
320
+ "gpt-5.6-terra": {
321
+ inputPer1M: number;
322
+ outputPer1M: number;
323
+ cacheReadMultiplier: number;
324
+ vendor: string;
325
+ provider: "openai";
326
+ };
327
+ "gpt-5.6-terra-pro": {
328
+ inputPer1M: number;
329
+ outputPer1M: number;
330
+ cacheReadMultiplier: number;
331
+ vendor: string;
332
+ provider: "openai";
333
+ };
334
+ "gpt-5.6-sol": {
335
+ inputPer1M: number;
336
+ outputPer1M: number;
337
+ cacheReadMultiplier: number;
338
+ vendor: string;
339
+ provider: "openai";
340
+ };
341
+ "gpt-5.6-sol-pro": {
342
+ inputPer1M: number;
343
+ outputPer1M: number;
344
+ cacheReadMultiplier: number;
345
+ vendor: string;
346
+ provider: "openai";
347
+ };
348
+ "gpt-5-mini": {
349
+ inputPer1M: number;
350
+ outputPer1M: number;
351
+ cacheReadMultiplier: number;
352
+ vendor: string;
353
+ provider: "openai";
354
+ };
355
+ "gpt-5-nano": {
356
+ inputPer1M: number;
357
+ outputPer1M: number;
358
+ cacheReadMultiplier: number;
359
+ vendor: string;
360
+ provider: "openai";
361
+ };
362
+ "gpt-5-codex": {
363
+ inputPer1M: number;
364
+ outputPer1M: number;
365
+ cacheReadMultiplier: number;
366
+ vendor: string;
367
+ provider: "openai";
368
+ };
369
+ "gpt-5-pro": {
370
+ inputPer1M: number;
371
+ outputPer1M: number;
372
+ vendor: string;
373
+ provider: "openai";
374
+ };
375
+ "gpt-5-image": {
376
+ inputPer1M: number;
377
+ outputPer1M: number;
378
+ cacheReadMultiplier: number;
379
+ vendor: string;
380
+ provider: "openai";
381
+ };
382
+ "gpt-5-image-mini": {
383
+ inputPer1M: number;
384
+ outputPer1M: number;
385
+ cacheReadMultiplier: number;
386
+ vendor: string;
387
+ provider: "openai";
388
+ };
389
+ "gpt-audio": {
390
+ inputPer1M: number;
391
+ outputPer1M: number;
392
+ vendor: string;
393
+ provider: "openai";
394
+ };
395
+ "gpt-audio-mini": {
396
+ inputPer1M: number;
397
+ outputPer1M: number;
398
+ vendor: string;
399
+ provider: "openai";
400
+ };
401
+ "o3-pro": {
402
+ inputPer1M: number;
403
+ outputPer1M: number;
404
+ vendor: string;
405
+ provider: "openai";
406
+ };
407
+ "o3-deep-research": {
408
+ inputPer1M: number;
409
+ outputPer1M: number;
410
+ cacheReadMultiplier: number;
411
+ vendor: string;
412
+ provider: "openai";
413
+ };
414
+ "o4-mini-high": {
415
+ inputPer1M: number;
416
+ outputPer1M: number;
417
+ cacheReadMultiplier: number;
418
+ vendor: string;
419
+ provider: "openai";
420
+ };
421
+ "o4-mini-deep-research": {
422
+ inputPer1M: number;
423
+ outputPer1M: number;
424
+ cacheReadMultiplier: number;
425
+ vendor: string;
426
+ provider: "openai";
427
+ };
428
+ "o1-pro": {
429
+ inputPer1M: number;
430
+ outputPer1M: number;
431
+ vendor: string;
432
+ provider: "openai";
433
+ };
434
+ "gpt-5.1-codex": {
435
+ inputPer1M: number;
436
+ outputPer1M: number;
437
+ cacheReadMultiplier: number;
438
+ vendor: string;
439
+ provider: "openai";
440
+ };
441
+ "gpt-5.1-codex-mini": {
442
+ inputPer1M: number;
443
+ outputPer1M: number;
444
+ cacheReadMultiplier: number;
445
+ vendor: string;
446
+ provider: "openai";
447
+ };
448
+ "gpt-5.1-codex-max": {
449
+ inputPer1M: number;
450
+ outputPer1M: number;
451
+ cacheReadMultiplier: number;
452
+ vendor: string;
453
+ provider: "openai";
454
+ };
455
+ "gpt-5.2-codex": {
456
+ inputPer1M: number;
457
+ outputPer1M: number;
458
+ cacheReadMultiplier: number;
459
+ vendor: string;
460
+ provider: "openai";
461
+ };
462
+ "gpt-5.2-pro": {
463
+ inputPer1M: number;
464
+ outputPer1M: number;
465
+ vendor: string;
466
+ provider: "openai";
467
+ };
298
468
  "MiniMax-M2": {
299
469
  inputPer1M: number;
300
470
  outputPer1M: number;
@@ -504,6 +674,18 @@ declare function resolvePricing(modelId: string): LLMPricing | undefined;
504
674
  * the pricing payload.
505
675
  */
506
676
  declare function resolveAlias(modelId: string): string;
677
+ /**
678
+ * Resolves a model id to its live context window (max input tokens) and max
679
+ * output tokens, sourced from `CONTEXT_WINDOWS`
680
+ * (`packages/catalog-sync/src/generators/llm-context-windows.ts` — re-synced
681
+ * from each provider's live `/v1/models` endpoint; never hand-maintain these
682
+ * numbers). Covers Anthropic, Groq, xAI, and Moonshot — the providers that
683
+ * publish this data live. Handles bare aliases the provider's own API doesn't
684
+ * use ("claude-haiku-4-5" vs. the dated live id "claude-haiku-4-5-20251001")
685
+ * via prefix match, then falls back through the pricing alias table for
686
+ * older aliases. Returns undefined for ids no synced provider carries.
687
+ */
688
+ declare function resolveContextWindow(modelId: string): ContextWindowEntry | undefined;
507
689
  /**
508
690
  * Resolve a model id to its DEFAULT provider — the single source of truth for
509
691
  * "which SDK reaches this model when no per-model override is set". Reads the
@@ -652,4 +834,4 @@ interface CacheStats {
652
834
  */
653
835
  declare function getCacheStats(modelId: string, usage: LLMUsageBreakdown, opts?: CalculateLLMCreditCostOptions): CacheStats;
654
836
 
655
- export { type CacheStats as C, DEFAULT_PRICING as D, type KnownLlmId as K, type LLMCreditCostResult as L, MODEL_ALIASES as M, type CalculateLLMCreditCostOptions as a, type LLMPricing as b, type LLMUsageBreakdown as c, LLM_PRICING_CATALOG as d, type LlmModelAlias as e, type LlmModelId as f, type ModelRoute as g, calculateLLMCreditCost as h, getCacheStats as i, getModelProvider as j, resolveModelRoute as k, resolvePricing as l, resolveAlias as r };
837
+ export { type CacheStats as C, DEFAULT_PRICING as D, type KnownLlmId as K, type LLMCreditCostResult as L, MODEL_ALIASES as M, type CalculateLLMCreditCostOptions as a, type ContextWindowEntry as b, type LLMPricing as c, type LLMUsageBreakdown as d, LLM_PRICING_CATALOG as e, type LlmModelAlias as f, type LlmModelId as g, type ModelRoute as h, calculateLLMCreditCost as i, getCacheStats as j, getModelProvider as k, resolveContextWindow as l, resolveModelRoute as m, resolvePricing as n, resolveAlias as r };
@@ -2032,6 +2032,57 @@ var OPENROUTER_ROUTES = {
2032
2032
  }
2033
2033
  };
2034
2034
 
2035
+ // src/llm/context-windows.generated.ts
2036
+ var CONTEXT_WINDOWS = {
2037
+ "allam-2-7b": { contextWindow: 4096, maxOutput: 4096, provider: "groq" },
2038
+ "canopylabs/orpheus-arabic-saudi": { contextWindow: 4e3, maxOutput: 5e4, provider: "groq" },
2039
+ "canopylabs/orpheus-v1-english": { contextWindow: 4e3, maxOutput: 5e4, provider: "groq" },
2040
+ "claude-fable-5": { contextWindow: 1e6, maxOutput: 128e3, displayName: "Claude Fable 5", provider: "anthropic" },
2041
+ "claude-haiku-4-5-20251001": { contextWindow: 2e5, maxOutput: 64e3, displayName: "Claude Haiku 4.5", provider: "anthropic" },
2042
+ "claude-opus-4-1-20250805": { contextWindow: 2e5, maxOutput: 32e3, displayName: "Claude Opus 4.1", provider: "anthropic" },
2043
+ "claude-opus-4-5-20251101": { contextWindow: 2e5, maxOutput: 64e3, displayName: "Claude Opus 4.5", provider: "anthropic" },
2044
+ "claude-opus-4-6": { contextWindow: 1e6, maxOutput: 128e3, displayName: "Claude Opus 4.6", provider: "anthropic" },
2045
+ "claude-opus-4-7": { contextWindow: 1e6, maxOutput: 128e3, displayName: "Claude Opus 4.7", provider: "anthropic" },
2046
+ "claude-opus-4-8": { contextWindow: 1e6, maxOutput: 128e3, displayName: "Claude Opus 4.8", provider: "anthropic" },
2047
+ "claude-sonnet-4-5-20250929": { contextWindow: 1e6, maxOutput: 64e3, displayName: "Claude Sonnet 4.5", provider: "anthropic" },
2048
+ "claude-sonnet-4-6": { contextWindow: 1e6, maxOutput: 128e3, displayName: "Claude Sonnet 4.6", provider: "anthropic" },
2049
+ "claude-sonnet-5": { contextWindow: 1e6, maxOutput: 128e3, displayName: "Claude Sonnet 5", provider: "anthropic" },
2050
+ "grok-4.20-0309-non-reasoning": { contextWindow: 1e6, provider: "xai" },
2051
+ "grok-4.20-0309-reasoning": { contextWindow: 1e6, provider: "xai" },
2052
+ "grok-4.20-multi-agent-0309": { contextWindow: 1e6, provider: "xai" },
2053
+ "grok-4.3": { contextWindow: 1e6, provider: "xai" },
2054
+ "grok-4.5": { contextWindow: 5e5, provider: "xai" },
2055
+ "grok-build-0.1": { contextWindow: 256e3, provider: "xai" },
2056
+ "grok-imagine-image": { contextWindow: 8e3, provider: "xai" },
2057
+ "grok-imagine-image-quality": { contextWindow: 8e3, provider: "xai" },
2058
+ "groq/compound": { contextWindow: 131072, maxOutput: 8192, provider: "groq" },
2059
+ "groq/compound-mini": { contextWindow: 131072, maxOutput: 8192, provider: "groq" },
2060
+ "kimi-k2.5": { contextWindow: 262144, provider: "moonshot" },
2061
+ "kimi-k2.6": { contextWindow: 262144, provider: "moonshot" },
2062
+ "kimi-k2.7-code": { contextWindow: 262144, provider: "moonshot" },
2063
+ "kimi-k2.7-code-highspeed": { contextWindow: 262144, provider: "moonshot" },
2064
+ "kimi-k3": { contextWindow: 1048576, provider: "moonshot" },
2065
+ "llama-3.1-8b-instant": { contextWindow: 131072, maxOutput: 131072, provider: "groq" },
2066
+ "llama-3.3-70b-versatile": { contextWindow: 131072, maxOutput: 32768, provider: "groq" },
2067
+ "meta-llama/llama-4-scout-17b-16e-instruct": { contextWindow: 131072, maxOutput: 8192, provider: "groq" },
2068
+ "meta-llama/llama-prompt-guard-2-22m": { contextWindow: 512, maxOutput: 512, provider: "groq" },
2069
+ "meta-llama/llama-prompt-guard-2-86m": { contextWindow: 512, maxOutput: 512, provider: "groq" },
2070
+ "moonshot-v1-128k": { contextWindow: 131072, provider: "moonshot" },
2071
+ "moonshot-v1-128k-vision-preview": { contextWindow: 131072, provider: "moonshot" },
2072
+ "moonshot-v1-32k": { contextWindow: 32768, provider: "moonshot" },
2073
+ "moonshot-v1-32k-vision-preview": { contextWindow: 32768, provider: "moonshot" },
2074
+ "moonshot-v1-8k": { contextWindow: 8192, provider: "moonshot" },
2075
+ "moonshot-v1-8k-vision-preview": { contextWindow: 8192, provider: "moonshot" },
2076
+ "moonshot-v1-auto": { contextWindow: 131072, provider: "moonshot" },
2077
+ "openai/gpt-oss-120b": { contextWindow: 131072, maxOutput: 65536, provider: "groq" },
2078
+ "openai/gpt-oss-20b": { contextWindow: 131072, maxOutput: 65536, provider: "groq" },
2079
+ "openai/gpt-oss-safeguard-20b": { contextWindow: 131072, maxOutput: 65536, provider: "groq" },
2080
+ "qwen/qwen3-32b": { contextWindow: 131072, maxOutput: 40960, provider: "groq" },
2081
+ "qwen/qwen3.6-27b": { contextWindow: 131072, maxOutput: 32768, provider: "groq" },
2082
+ "whisper-large-v3": { contextWindow: 448, maxOutput: 448, provider: "groq" },
2083
+ "whisper-large-v3-turbo": { contextWindow: 448, maxOutput: 448, provider: "groq" }
2084
+ };
2085
+
2035
2086
  // src/llm/catalog.ts
2036
2087
  var LLM_PRICING_CATALOG = {
2037
2088
  // ── Anthropic ──────────────────────────────────────────────────────────
@@ -2318,6 +2369,202 @@ var LLM_PRICING_CATALOG = {
2318
2369
  vendor: "openai",
2319
2370
  provider: "openai"
2320
2371
  },
2372
+ // ── OpenAI GPT-5.6 series ──────────────────────────────────────────────
2373
+ // Source: OpenRouter pricing (fetched 2026-07-16)
2374
+ "gpt-5.6-luna": {
2375
+ // $1.00 in / $6.00 out per 1M. Cache read 0.1x.
2376
+ inputPer1M: 1,
2377
+ outputPer1M: 6,
2378
+ cacheReadMultiplier: 0.1,
2379
+ vendor: "openai",
2380
+ provider: "openai"
2381
+ },
2382
+ "gpt-5.6-luna-pro": {
2383
+ // $1.00 in / $6.00 out per 1M. Cache read 0.1x.
2384
+ inputPer1M: 1,
2385
+ outputPer1M: 6,
2386
+ cacheReadMultiplier: 0.1,
2387
+ vendor: "openai",
2388
+ provider: "openai"
2389
+ },
2390
+ "gpt-5.6-terra": {
2391
+ // $2.50 in / $15.00 out per 1M. Cache read 0.1x.
2392
+ inputPer1M: 2.5,
2393
+ outputPer1M: 15,
2394
+ cacheReadMultiplier: 0.1,
2395
+ vendor: "openai",
2396
+ provider: "openai"
2397
+ },
2398
+ "gpt-5.6-terra-pro": {
2399
+ // $2.50 in / $15.00 out per 1M. Cache read 0.1x.
2400
+ inputPer1M: 2.5,
2401
+ outputPer1M: 15,
2402
+ cacheReadMultiplier: 0.1,
2403
+ vendor: "openai",
2404
+ provider: "openai"
2405
+ },
2406
+ "gpt-5.6-sol": {
2407
+ // $5.00 in / $30.00 out per 1M. Cache read 0.1x.
2408
+ inputPer1M: 5,
2409
+ outputPer1M: 30,
2410
+ cacheReadMultiplier: 0.1,
2411
+ vendor: "openai",
2412
+ provider: "openai"
2413
+ },
2414
+ "gpt-5.6-sol-pro": {
2415
+ // $5.00 in / $30.00 out per 1M. Cache read 0.1x.
2416
+ inputPer1M: 5,
2417
+ outputPer1M: 30,
2418
+ cacheReadMultiplier: 0.1,
2419
+ vendor: "openai",
2420
+ provider: "openai"
2421
+ },
2422
+ // ── OpenAI GPT-5 min/nano (lite variants) ──────────────────────────────
2423
+ "gpt-5-mini": {
2424
+ // $0.25 in / $2.00 out per 1M. Cache read 0.1x.
2425
+ inputPer1M: 0.25,
2426
+ outputPer1M: 2,
2427
+ cacheReadMultiplier: 0.1,
2428
+ vendor: "openai",
2429
+ provider: "openai"
2430
+ },
2431
+ "gpt-5-nano": {
2432
+ // $0.05 in / $0.40 out per 1M. Cache read 0.1x.
2433
+ inputPer1M: 0.05,
2434
+ outputPer1M: 0.4,
2435
+ cacheReadMultiplier: 0.1,
2436
+ vendor: "openai",
2437
+ provider: "openai"
2438
+ },
2439
+ // ── OpenAI GPT-5 codex (coding specialist) ─────────────────────────────
2440
+ "gpt-5-codex": {
2441
+ // $1.25 in / $10.00 out per 1M. Cache read 0.1x.
2442
+ inputPer1M: 1.25,
2443
+ outputPer1M: 10,
2444
+ cacheReadMultiplier: 0.1,
2445
+ vendor: "openai",
2446
+ provider: "openai"
2447
+ },
2448
+ // ── OpenAI GPT-5 pro (reasoning-enhanced) ──────────────────────────────
2449
+ "gpt-5-pro": {
2450
+ // $15.00 in / $120.00 out per 1M. No cache discount.
2451
+ inputPer1M: 15,
2452
+ outputPer1M: 120,
2453
+ vendor: "openai",
2454
+ provider: "openai"
2455
+ },
2456
+ // ── OpenAI GPT-5 image generation ──────────────────────────────────────
2457
+ "gpt-5-image": {
2458
+ // $10.00 in / $10.00 out (+ $40/1M image output). Cache read 0.125x.
2459
+ inputPer1M: 10,
2460
+ outputPer1M: 10,
2461
+ cacheReadMultiplier: 0.125,
2462
+ vendor: "openai",
2463
+ provider: "openai"
2464
+ },
2465
+ "gpt-5-image-mini": {
2466
+ // $2.50 in / $2.00 out (+ $8/1M image output). Cache read 0.1x.
2467
+ inputPer1M: 2.5,
2468
+ outputPer1M: 2,
2469
+ cacheReadMultiplier: 0.1,
2470
+ vendor: "openai",
2471
+ provider: "openai"
2472
+ },
2473
+ // ── OpenAI GPT audio (multimodal) ──────────────────────────────────────
2474
+ "gpt-audio": {
2475
+ // $2.50 in / $10.00 out (+ audio in $32/1M, audio out $64/1M).
2476
+ inputPer1M: 2.5,
2477
+ outputPer1M: 10,
2478
+ vendor: "openai",
2479
+ provider: "openai"
2480
+ },
2481
+ "gpt-audio-mini": {
2482
+ // $0.60 in / $2.40 out (+ audio in $0.60/1M, audio out $2.40/1M).
2483
+ inputPer1M: 0.6,
2484
+ outputPer1M: 2.4,
2485
+ vendor: "openai",
2486
+ provider: "openai"
2487
+ },
2488
+ // ── OpenAI o-series (reasoning models) ─────────────────────────────────
2489
+ // Extended reasoning variants with cache support.
2490
+ "o3-pro": {
2491
+ // $20.00 in / $80.00 out per 1M. No cache discount.
2492
+ inputPer1M: 20,
2493
+ outputPer1M: 80,
2494
+ vendor: "openai",
2495
+ provider: "openai"
2496
+ },
2497
+ "o3-deep-research": {
2498
+ // $10.00 in / $40.00 out per 1M. Cache read 0.25x.
2499
+ inputPer1M: 10,
2500
+ outputPer1M: 40,
2501
+ cacheReadMultiplier: 0.25,
2502
+ vendor: "openai",
2503
+ provider: "openai"
2504
+ },
2505
+ "o4-mini-high": {
2506
+ // $1.10 in / $4.40 out per 1M. Cache read 0.25x.
2507
+ inputPer1M: 1.1,
2508
+ outputPer1M: 4.4,
2509
+ cacheReadMultiplier: 0.25,
2510
+ vendor: "openai",
2511
+ provider: "openai"
2512
+ },
2513
+ "o4-mini-deep-research": {
2514
+ // $2.00 in / $8.00 out per 1M. Cache read 0.25x.
2515
+ inputPer1M: 2,
2516
+ outputPer1M: 8,
2517
+ cacheReadMultiplier: 0.25,
2518
+ vendor: "openai",
2519
+ provider: "openai"
2520
+ },
2521
+ "o1-pro": {
2522
+ // $150.00 in / $600.00 out per 1M. No cache discount.
2523
+ inputPer1M: 150,
2524
+ outputPer1M: 600,
2525
+ vendor: "openai",
2526
+ provider: "openai"
2527
+ },
2528
+ // ── OpenAI GPT-5.1/5.2 codex (code specialist) ─────────────────────────
2529
+ "gpt-5.1-codex": {
2530
+ // $1.25 in / $10.00 out per 1M. Cache read 0.1x.
2531
+ inputPer1M: 1.25,
2532
+ outputPer1M: 10,
2533
+ cacheReadMultiplier: 0.1,
2534
+ vendor: "openai",
2535
+ provider: "openai"
2536
+ },
2537
+ "gpt-5.1-codex-mini": {
2538
+ // $0.25 in / $2.00 out per 1M. Cache read 0.1x.
2539
+ inputPer1M: 0.25,
2540
+ outputPer1M: 2,
2541
+ cacheReadMultiplier: 0.1,
2542
+ vendor: "openai",
2543
+ provider: "openai"
2544
+ },
2545
+ "gpt-5.1-codex-max": {
2546
+ // $1.25 in / $10.00 out per 1M. Cache read 0.1x.
2547
+ inputPer1M: 1.25,
2548
+ outputPer1M: 10,
2549
+ cacheReadMultiplier: 0.1,
2550
+ vendor: "openai",
2551
+ provider: "openai"
2552
+ },
2553
+ "gpt-5.2-codex": {
2554
+ // $1.75 in / $14.00 out per 1M. Cache read 0.1x.
2555
+ inputPer1M: 1.75,
2556
+ outputPer1M: 14,
2557
+ cacheReadMultiplier: 0.1,
2558
+ vendor: "openai",
2559
+ provider: "openai"
2560
+ },
2561
+ "gpt-5.2-pro": {
2562
+ // $21.00 in / $168.00 out per 1M. No cache discount.
2563
+ inputPer1M: 21,
2564
+ outputPer1M: 168,
2565
+ vendor: "openai",
2566
+ provider: "openai"
2567
+ },
2321
2568
  // ── MiniMax (direct SDK) ───────────────────────────────────────────────
2322
2569
  // Bare ids match what the MiniMax SDK expects on the wire (PascalCase
2323
2570
  // with optional minor version). OpenRouter equivalents under
@@ -2560,6 +2807,14 @@ function resolveAlias(modelId) {
2560
2807
  }
2561
2808
  return modelId;
2562
2809
  }
2810
+ function resolveContextWindow(modelId) {
2811
+ if (CONTEXT_WINDOWS[modelId]) return CONTEXT_WINDOWS[modelId];
2812
+ const datedMatch = Object.keys(CONTEXT_WINDOWS).filter((key) => key.startsWith(`${modelId}-2`)).sort((a, b) => a.length - b.length)[0];
2813
+ if (datedMatch) return CONTEXT_WINDOWS[datedMatch];
2814
+ const alias = ALIAS_BY_ID[modelId];
2815
+ if (alias && CONTEXT_WINDOWS[alias]) return CONTEXT_WINDOWS[alias];
2816
+ return void 0;
2817
+ }
2563
2818
  function getModelProvider(modelId) {
2564
2819
  return resolvePricing(modelId)?.provider;
2565
2820
  }
@@ -2658,6 +2913,6 @@ function getCacheStats(modelId, usage, opts) {
2658
2913
  };
2659
2914
  }
2660
2915
 
2661
- export { DEFAULT_PRICING, LLM_PRICING_CATALOG, MODEL_ALIASES, OPENROUTER_ROUTES, calculateLLMCreditCost, getCacheStats, getModelProvider, resolveAlias, resolveModelRoute, resolvePricing };
2662
- //# sourceMappingURL=chunk-OCVWDFVT.mjs.map
2663
- //# sourceMappingURL=chunk-OCVWDFVT.mjs.map
2916
+ export { DEFAULT_PRICING, LLM_PRICING_CATALOG, MODEL_ALIASES, OPENROUTER_ROUTES, calculateLLMCreditCost, getCacheStats, getModelProvider, resolveAlias, resolveContextWindow, resolveModelRoute, resolvePricing };
2917
+ //# sourceMappingURL=chunk-FCPS2VGK.mjs.map
2918
+ //# sourceMappingURL=chunk-FCPS2VGK.mjs.map