Enhanced ChatGPT Clone: Features Agents, MCP, Skills, DeepSeek, Anthropic, AWS, OpenAI, Responses API, Azure, Groq, o1, GPT-5, Mistral, OpenRouter, Vertex AI, Gemini, Artifacts, AI model switching, message search, Code Interpreter, langchain, DALL-E-3, OpenAPI Actions, Functions, Secure Multi-User Auth, Presets, open-source for self-hosting. Active
TypeScript aianthropicartifactsawsazurechatgptchatgpt-cloneclaudeclonedeepseekgeminigooglegpt-5librechatmcpo1openairesponses-apivisionwebui
🪙 chore: GPT-5.6 Terra and Luna Token Cost Rates (#14964)
Heinz-Alexander Fuetterer0ab3414c015b
diff --git a/packages/data-schemas/src/methods/tx.spec.ts b/packages/data-schemas/src/methods/tx.spec.tsindex 42688881ef..323b591858 100644--- a/packages/data-schemas/src/methods/tx.spec.ts+++ b/packages/data-schemas/src/methods/tx.spec.ts@@ -470,6 +470,36 @@ describe('getMultiplier', () => {}});+ it('should use the documented gpt-5.6 pricing', () => {+ const expectedPricing = {+ 'gpt-5.6': {+ standard: { prompt: 5, completion: 30 },+ cache: { write: 6.25, read: 0.5 },+ premium: { threshold: 272000, prompt: 10, completion: 45 },+ premiumCache: { threshold: 272000, write: 12.5, read: 1 },+ },+ 'gpt-5.6-terra': {+ standard: { prompt: 2, completion: 12 },+ cache: { write: 2.5, read: 0.2 },+ premium: { threshold: 272000, prompt: 4, completion: 18 },+ premiumCache: { threshold: 272000, write: 5, read: 0.4 },+ },+ 'gpt-5.6-luna': {+ standard: { prompt: 0.2, completion: 1.2 },+ cache: { write: 0.25, read: 0.02 },+ premium: { threshold: 272000, prompt: 0.4, completion: 1.8 },+ premiumCache: { threshold: 272000, write: 0.5, read: 0.04 },+ },+ };++ for (const [model, pricing] of Object.entries(expectedPricing)) {+ expect(tokenValues[model]).toEqual(pricing.standard);+ expect(cacheTokenValues[model]).toEqual(pricing.cache);+ expect(premiumTokenValues[model]).toEqual(pricing.premium);+ expect(premiumCacheTokenValues[model]).toEqual(pricing.premiumCache);+ }+ });+it('should return the correct multiplier for gpt-4o', () => {const valueKey = getValueKey('gpt-4o-2024-08-06');expect(getMultiplier({ valueKey, tokenType: 'prompt' })).toBe(tokenValues['gpt-4o'].prompt);@@ -2854,8 +2884,8 @@ describe('GPT-5.6 Long-Context Premium Pricing', () => {const premiumEntry = premiumTokenValues[model];expect(premiumEntry).toBeDefined();expect(premiumEntry.threshold).toBe(272000);- expect(premiumEntry.prompt).toBe(tokenValues[model].prompt * 2);- expect(premiumEntry.completion).toBe(tokenValues[model].completion * 1.5);+ expect(premiumEntry.prompt).toBeCloseTo(tokenValues[model].prompt * 2);+ expect(premiumEntry.completion).toBeCloseTo(tokenValues[model].completion * 1.5);}});diff --git a/packages/data-schemas/src/methods/tx.ts b/packages/data-schemas/src/methods/tx.tsindex c474ee5da2..d498179052 100644--- a/packages/data-schemas/src/methods/tx.ts+++ b/packages/data-schemas/src/methods/tx.ts@@ -148,8 +148,8 @@ export const tokenValues: Record<string, { prompt: number; completion: number }>'gpt-5.5': { prompt: 5, completion: 30 },'gpt-5.5-pro': { prompt: 30, completion: 180 },'gpt-5.6': { prompt: 5, completion: 30 },- 'gpt-5.6-terra': { prompt: 2.5, completion: 15 },- 'gpt-5.6-luna': { prompt: 1, completion: 6 },+ 'gpt-5.6-terra': { prompt: 2, completion: 12 },+ 'gpt-5.6-luna': { prompt: 0.2, completion: 1.2 },'chat-latest': { prompt: 5, completion: 30 },'gpt-5-chat-latest': { prompt: 1.25, completion: 10 },'gpt-5.1-chat-latest': { prompt: 1.25, completion: 10 },@@ -381,8 +381,8 @@ export const cacheTokenValues: Record<string, { write: number; read: number }> ='gpt-5.4-nano': { write: 0.2, read: 0.02 },'gpt-5.5': { write: 5, read: 0.5 },'gpt-5.6': { write: 6.25, read: 0.5 },- 'gpt-5.6-terra': { write: 3.125, read: 0.25 },- 'gpt-5.6-luna': { write: 1.25, read: 0.1 },+ 'gpt-5.6-terra': { write: 2.5, read: 0.2 },+ 'gpt-5.6-luna': { write: 0.25, read: 0.02 },'chat-latest': { write: 5, read: 0.5 },'gpt-5-chat-latest': { write: 1.25, read: 0.125 },'gpt-5.1-chat-latest': { write: 1.25, read: 0.125 },@@ -436,8 +436,8 @@ export const premiumTokenValues: Record<'gpt-5.5': { threshold: 272000, prompt: 10, completion: 45 },'gpt-5.5-pro': { threshold: 272000, prompt: 60, completion: 270 },'gpt-5.6': { threshold: 272000, prompt: 10, completion: 45 },- 'gpt-5.6-terra': { threshold: 272000, prompt: 5, completion: 22.5 },- 'gpt-5.6-luna': { threshold: 272000, prompt: 2, completion: 9 },+ 'gpt-5.6-terra': { threshold: 272000, prompt: 4, completion: 18 },+ 'gpt-5.6-luna': { threshold: 272000, prompt: 0.4, completion: 1.8 },'grok-4.5': { threshold: 200000, prompt: 4, completion: 12 },'grok-4-5': { threshold: 200000, prompt: 4, completion: 12 },'grok-4.6': { threshold: 200000, prompt: 4, completion: 12 },@@ -457,8 +457,8 @@ export const premiumCacheTokenValues: Record<'gpt-5.4': { threshold: 272000, write: 5, read: 0.5 },'gpt-5.5': { threshold: 272000, write: 10, read: 1 },'gpt-5.6': { threshold: 272000, write: 12.5, read: 1 },- 'gpt-5.6-terra': { threshold: 272000, write: 6.25, read: 0.5 },- 'gpt-5.6-luna': { threshold: 272000, write: 2.5, read: 0.2 },+ 'gpt-5.6-terra': { threshold: 272000, write: 5, read: 0.4 },+ 'gpt-5.6-luna': { threshold: 272000, write: 0.5, read: 0.04 },};export function createTxMethods(