From 38bc7b84d5217fc3b19b76bb21321284ce1191c3 Mon Sep 17 00:00:00 2001 From: HatcherLabs Date: Sat, 11 Jul 2026 20:51:06 +0300 Subject: [PATCH] feat: refresh hosted model recommendations --- .github/workflows/ci.yml | 3 + dist/index.d.mts | 2 +- dist/index.d.ts | 2 +- dist/index.js | 176 ++++++++++++++----- dist/index.mjs | 176 ++++++++++++++----- package.json | 1 + src/constants/index.ts | 178 +++++++++++++++----- tests/hosted-model-recommendations.test.mjs | 94 +++++++++++ 8 files changed, 500 insertions(+), 132 deletions(-) create mode 100644 tests/hosted-model-recommendations.test.mjs diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 9e34ba8..68cf959 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -30,6 +30,9 @@ jobs: - name: Build run: npm run build + - name: Test + run: npm test + - name: Verify dist output run: | test -f dist/index.js || (echo "dist/index.js missing" && exit 1) diff --git a/dist/index.d.mts b/dist/index.d.mts index 7035e68..24e2d69 100644 --- a/dist/index.d.mts +++ b/dist/index.d.mts @@ -568,7 +568,7 @@ declare const AI_CREDIT_DEFAULT_MARGIN_MULTIPLIER = 1; declare const AI_CREDIT_MIN_CHARGE = 1; declare const TIER_AI_CREDITS_MONTHLY: Record; type HostedModelCategory = 'default' | 'fast' | 'balanced' | 'coding' | 'premium' | 'advanced'; -type HostedModelCostTier = 'free' | 'low' | 'medium' | 'high' | 'premium'; +type HostedModelCostTier = 'free' | 'low' | 'medium' | 'high' | 'premium' | 'variable'; interface HostedModelRecommendation { id: string; name: string; diff --git a/dist/index.d.ts b/dist/index.d.ts index 7035e68..24e2d69 100644 --- a/dist/index.d.ts +++ b/dist/index.d.ts @@ -568,7 +568,7 @@ declare const AI_CREDIT_DEFAULT_MARGIN_MULTIPLIER = 1; declare const AI_CREDIT_MIN_CHARGE = 1; declare const TIER_AI_CREDITS_MONTHLY: Record; type HostedModelCategory = 'default' | 'fast' | 'balanced' | 'coding' | 'premium' | 'advanced'; -type HostedModelCostTier = 'free' | 'low' | 'medium' | 'high' | 'premium'; +type HostedModelCostTier = 'free' | 'low' | 'medium' | 'high' | 'premium' | 'variable'; interface HostedModelRecommendation { id: string; name: string; diff --git a/dist/index.js b/dist/index.js index b3262db..cf88c20 100644 --- a/dist/index.js +++ b/dist/index.js @@ -324,24 +324,6 @@ var HATCHER_HOSTED_MODEL_RECOMMENDATIONS = [ context: "1M", description: "Balanced Xiaomi MiMo model for multi-step reasoning, writing, and longer conversations." }, - { - id: "xiaomi/mimo-v2-pro", - name: "MiMo V2 Pro", - provider: "Xiaomi MiMo", - category: "advanced", - costTier: "low", - context: "1M", - description: "Previous-generation MiMo Pro model for long-context coding and agent workflows." - }, - { - id: "xiaomi/mimo-v2-omni", - name: "MiMo V2 Omni", - provider: "Xiaomi MiMo", - category: "advanced", - costTier: "low", - context: "256K", - description: "Multimodal MiMo model for image-aware analysis, OCR, charts, and visual context." - }, { id: "acedata/claude-opus-4-8", name: "Claude Opus 4.8 (AceData)", @@ -382,16 +364,6 @@ var HATCHER_HOSTED_MODEL_RECOMMENDATIONS = [ description: "Fast Claude option through AceData for extraction, classification, and lightweight chat.", warning: "Uses estimated AI Credits because AceData exposes costs in their usage console, not in chat responses." }, - { - id: "acedata/gpt-5.5", - name: "GPT-5.5 (AceData)", - provider: "AceData", - category: "premium", - costTier: "high", - context: "1.05M", - description: "Partner-hosted OpenAI-compatible GPT-5.5 through AceData, with OpenRouter fallback when needed.", - warning: "Uses estimated AI Credits because AceData exposes costs in their usage console, not in chat responses." - }, { id: "acedata/gpt-5.4-pro", name: "GPT-5.4 Pro (AceData)", @@ -620,22 +592,14 @@ var HATCHER_HOSTED_MODEL_RECOMMENDATIONS = [ warning: "Consumes AI Credits quickly." }, { - id: "x-ai/grok-4.1-fast", - name: "Grok 4.1 Fast", + id: "x-ai/grok-4.5", + name: "Grok 4.5", provider: "xAI", - category: "fast", - costTier: "low", - context: "2M", - description: "Fast Grok model with very large context." - }, - { - id: "x-ai/grok-code-fast-1", - name: "Grok Code Fast 1", - provider: "xAI", - category: "coding", - costTier: "medium", - context: "256K", - description: "xAI coding model tuned for fast code generation." + category: "premium", + costTier: "high", + context: "500K", + description: "Current Grok model for reasoning, coding, and multimodal agent workflows.", + warning: "The current UsePod marketplace route can report additional provider-side tokens. Monitor AI Credit usage." }, { id: "mistralai/mistral-small-2603", @@ -691,6 +655,132 @@ var HATCHER_HOSTED_MODEL_RECOMMENDATIONS = [ context: "256K", description: "Low-cost NVIDIA model for lightweight workflows." }, + { + id: "virtuals/anthropic-claude-fable-5", + name: "Claude Fable 5", + provider: "Virtuals", + category: "advanced", + costTier: "variable", + context: "1M", + description: "Virtuals Compute Anthropic route for autonomous knowledge work, coding, and multimodal inputs." + }, + { + id: "virtuals/e2ee-deepseek-v4-flash", + name: "DeepSeek V4 Flash (E2EE)", + provider: "Virtuals", + category: "fast", + costTier: "variable", + context: "1M", + description: "Virtuals provider-side TEE with hardware attestation; Hatcher still processes and forwards the request." + }, + { + id: "virtuals/openai-gpt-56-luna", + name: "GPT-5.6 Luna", + provider: "Virtuals", + category: "fast", + costTier: "variable", + context: "1M", + description: "Virtuals Compute cost-efficient GPT-5.6 route for high-volume and latency-sensitive tasks." + }, + { + id: "virtuals/openai-gpt-56-luna-pro", + name: "GPT-5.6 Luna Pro", + provider: "Virtuals", + category: "advanced", + costTier: "variable", + context: "1M", + description: "Virtuals Compute GPT-5.6 Luna route with the provider pro reasoning mode." + }, + { + id: "virtuals/openai-gpt-56-sol", + name: "GPT-5.6 Sol", + provider: "Virtuals", + category: "premium", + costTier: "variable", + context: "1M", + description: "Virtuals Compute flagship GPT-5.6 route for complex reasoning, coding, and agentic workflows." + }, + { + id: "virtuals/openai-gpt-56-sol-pro", + name: "GPT-5.6 Sol Pro", + provider: "Virtuals", + category: "premium", + costTier: "variable", + context: "1M", + description: "Virtuals Compute GPT-5.6 Sol route with the provider pro reasoning mode." + }, + { + id: "virtuals/openai-gpt-56-terra", + name: "GPT-5.6 Terra", + provider: "Virtuals", + category: "balanced", + costTier: "variable", + context: "1M", + description: "Virtuals Compute balanced GPT-5.6 route for everyday coding, reasoning, and agent tasks." + }, + { + id: "virtuals/openai-gpt-56-terra-pro", + name: "GPT-5.6 Terra Pro", + provider: "Virtuals", + category: "advanced", + costTier: "variable", + context: "1M", + description: "Virtuals Compute GPT-5.6 Terra route with the provider pro reasoning mode." + }, + { + id: "virtuals/x-ai-grok-4-5", + name: "Grok 4.5", + provider: "Virtuals", + category: "premium", + costTier: "variable", + context: "500K", + description: "Virtuals Compute Grok route for coding, knowledge work, and STEM-heavy agent tasks." + }, + { + id: "virtuals/moonshotai-kimi-k2-5", + name: "Kimi K2 5", + provider: "Virtuals", + category: "balanced", + costTier: "variable", + context: "256K", + description: "Virtuals Compute Kimi model for general agent work, routed with the platform Virtuals key." + }, + { + id: "virtuals/moonshotai-kimi-k2-6", + name: "Kimi K2 6", + provider: "Virtuals", + category: "advanced", + costTier: "variable", + context: "256K", + description: "Virtuals Compute Kimi variant for analysis-heavy prompts and longer planning loops." + }, + { + id: "virtuals/moonshotai-kimi-k2-7-code", + name: "Kimi K2 7 Code", + provider: "Virtuals", + category: "coding", + costTier: "variable", + context: "256K", + description: "Virtuals Compute coding-oriented Kimi route for repo analysis and implementation tasks." + }, + { + id: "virtuals/deepseek-deepseek-v3-2", + name: "DeepSeek V3.2", + provider: "Virtuals", + category: "advanced", + costTier: "variable", + context: "160K", + description: "Virtuals Compute DeepSeek route for reasoning and structured task decomposition." + }, + { + id: "virtuals/google-gemini-3-flash-preview", + name: "Gemini 3 Flash Preview", + provider: "Virtuals", + category: "fast", + costTier: "variable", + context: "256K", + description: "Virtuals Compute Gemini route for quick responses and multimodal-adjacent workflows." + }, { id: "openai/gpt-5.3-codex", name: "GPT-5.3 Codex", diff --git a/dist/index.mjs b/dist/index.mjs index c8d6bf3..9dabe3e 100644 --- a/dist/index.mjs +++ b/dist/index.mjs @@ -273,24 +273,6 @@ var HATCHER_HOSTED_MODEL_RECOMMENDATIONS = [ context: "1M", description: "Balanced Xiaomi MiMo model for multi-step reasoning, writing, and longer conversations." }, - { - id: "xiaomi/mimo-v2-pro", - name: "MiMo V2 Pro", - provider: "Xiaomi MiMo", - category: "advanced", - costTier: "low", - context: "1M", - description: "Previous-generation MiMo Pro model for long-context coding and agent workflows." - }, - { - id: "xiaomi/mimo-v2-omni", - name: "MiMo V2 Omni", - provider: "Xiaomi MiMo", - category: "advanced", - costTier: "low", - context: "256K", - description: "Multimodal MiMo model for image-aware analysis, OCR, charts, and visual context." - }, { id: "acedata/claude-opus-4-8", name: "Claude Opus 4.8 (AceData)", @@ -331,16 +313,6 @@ var HATCHER_HOSTED_MODEL_RECOMMENDATIONS = [ description: "Fast Claude option through AceData for extraction, classification, and lightweight chat.", warning: "Uses estimated AI Credits because AceData exposes costs in their usage console, not in chat responses." }, - { - id: "acedata/gpt-5.5", - name: "GPT-5.5 (AceData)", - provider: "AceData", - category: "premium", - costTier: "high", - context: "1.05M", - description: "Partner-hosted OpenAI-compatible GPT-5.5 through AceData, with OpenRouter fallback when needed.", - warning: "Uses estimated AI Credits because AceData exposes costs in their usage console, not in chat responses." - }, { id: "acedata/gpt-5.4-pro", name: "GPT-5.4 Pro (AceData)", @@ -569,22 +541,14 @@ var HATCHER_HOSTED_MODEL_RECOMMENDATIONS = [ warning: "Consumes AI Credits quickly." }, { - id: "x-ai/grok-4.1-fast", - name: "Grok 4.1 Fast", + id: "x-ai/grok-4.5", + name: "Grok 4.5", provider: "xAI", - category: "fast", - costTier: "low", - context: "2M", - description: "Fast Grok model with very large context." - }, - { - id: "x-ai/grok-code-fast-1", - name: "Grok Code Fast 1", - provider: "xAI", - category: "coding", - costTier: "medium", - context: "256K", - description: "xAI coding model tuned for fast code generation." + category: "premium", + costTier: "high", + context: "500K", + description: "Current Grok model for reasoning, coding, and multimodal agent workflows.", + warning: "The current UsePod marketplace route can report additional provider-side tokens. Monitor AI Credit usage." }, { id: "mistralai/mistral-small-2603", @@ -640,6 +604,132 @@ var HATCHER_HOSTED_MODEL_RECOMMENDATIONS = [ context: "256K", description: "Low-cost NVIDIA model for lightweight workflows." }, + { + id: "virtuals/anthropic-claude-fable-5", + name: "Claude Fable 5", + provider: "Virtuals", + category: "advanced", + costTier: "variable", + context: "1M", + description: "Virtuals Compute Anthropic route for autonomous knowledge work, coding, and multimodal inputs." + }, + { + id: "virtuals/e2ee-deepseek-v4-flash", + name: "DeepSeek V4 Flash (E2EE)", + provider: "Virtuals", + category: "fast", + costTier: "variable", + context: "1M", + description: "Virtuals provider-side TEE with hardware attestation; Hatcher still processes and forwards the request." + }, + { + id: "virtuals/openai-gpt-56-luna", + name: "GPT-5.6 Luna", + provider: "Virtuals", + category: "fast", + costTier: "variable", + context: "1M", + description: "Virtuals Compute cost-efficient GPT-5.6 route for high-volume and latency-sensitive tasks." + }, + { + id: "virtuals/openai-gpt-56-luna-pro", + name: "GPT-5.6 Luna Pro", + provider: "Virtuals", + category: "advanced", + costTier: "variable", + context: "1M", + description: "Virtuals Compute GPT-5.6 Luna route with the provider pro reasoning mode." + }, + { + id: "virtuals/openai-gpt-56-sol", + name: "GPT-5.6 Sol", + provider: "Virtuals", + category: "premium", + costTier: "variable", + context: "1M", + description: "Virtuals Compute flagship GPT-5.6 route for complex reasoning, coding, and agentic workflows." + }, + { + id: "virtuals/openai-gpt-56-sol-pro", + name: "GPT-5.6 Sol Pro", + provider: "Virtuals", + category: "premium", + costTier: "variable", + context: "1M", + description: "Virtuals Compute GPT-5.6 Sol route with the provider pro reasoning mode." + }, + { + id: "virtuals/openai-gpt-56-terra", + name: "GPT-5.6 Terra", + provider: "Virtuals", + category: "balanced", + costTier: "variable", + context: "1M", + description: "Virtuals Compute balanced GPT-5.6 route for everyday coding, reasoning, and agent tasks." + }, + { + id: "virtuals/openai-gpt-56-terra-pro", + name: "GPT-5.6 Terra Pro", + provider: "Virtuals", + category: "advanced", + costTier: "variable", + context: "1M", + description: "Virtuals Compute GPT-5.6 Terra route with the provider pro reasoning mode." + }, + { + id: "virtuals/x-ai-grok-4-5", + name: "Grok 4.5", + provider: "Virtuals", + category: "premium", + costTier: "variable", + context: "500K", + description: "Virtuals Compute Grok route for coding, knowledge work, and STEM-heavy agent tasks." + }, + { + id: "virtuals/moonshotai-kimi-k2-5", + name: "Kimi K2 5", + provider: "Virtuals", + category: "balanced", + costTier: "variable", + context: "256K", + description: "Virtuals Compute Kimi model for general agent work, routed with the platform Virtuals key." + }, + { + id: "virtuals/moonshotai-kimi-k2-6", + name: "Kimi K2 6", + provider: "Virtuals", + category: "advanced", + costTier: "variable", + context: "256K", + description: "Virtuals Compute Kimi variant for analysis-heavy prompts and longer planning loops." + }, + { + id: "virtuals/moonshotai-kimi-k2-7-code", + name: "Kimi K2 7 Code", + provider: "Virtuals", + category: "coding", + costTier: "variable", + context: "256K", + description: "Virtuals Compute coding-oriented Kimi route for repo analysis and implementation tasks." + }, + { + id: "virtuals/deepseek-deepseek-v3-2", + name: "DeepSeek V3.2", + provider: "Virtuals", + category: "advanced", + costTier: "variable", + context: "160K", + description: "Virtuals Compute DeepSeek route for reasoning and structured task decomposition." + }, + { + id: "virtuals/google-gemini-3-flash-preview", + name: "Gemini 3 Flash Preview", + provider: "Virtuals", + category: "fast", + costTier: "variable", + context: "256K", + description: "Virtuals Compute Gemini route for quick responses and multimodal-adjacent workflows." + }, { id: "openai/gpt-5.3-codex", name: "GPT-5.3 Codex", diff --git a/package.json b/package.json index 7b3465c..72667b6 100644 --- a/package.json +++ b/package.json @@ -24,6 +24,7 @@ }, "scripts": { "build": "tsup src/index.ts --format esm,cjs --dts", + "test": "npm run build && node --test tests/*.test.mjs", "type-check": "tsc --noEmit", "clean": "rm -rf dist", "prepublishOnly": "npm run build" diff --git a/src/constants/index.ts b/src/constants/index.ts index 5e4bb59..4eebe83 100644 --- a/src/constants/index.ts +++ b/src/constants/index.ts @@ -45,7 +45,7 @@ export const TIER_AI_CREDITS_MONTHLY: Record = { }; export type HostedModelCategory = 'default' | 'fast' | 'balanced' | 'coding' | 'premium' | 'advanced'; -export type HostedModelCostTier = 'free' | 'low' | 'medium' | 'high' | 'premium'; +export type HostedModelCostTier = 'free' | 'low' | 'medium' | 'high' | 'premium' | 'variable'; export interface HostedModelRecommendation { id: string; @@ -269,24 +269,6 @@ export const HATCHER_HOSTED_MODEL_RECOMMENDATIONS: HostedModelRecommendation[] = context: '1M', description: 'Balanced Xiaomi MiMo model for multi-step reasoning, writing, and longer conversations.', }, - { - id: 'xiaomi/mimo-v2-pro', - name: 'MiMo V2 Pro', - provider: 'Xiaomi MiMo', - category: 'advanced', - costTier: 'low', - context: '1M', - description: 'Previous-generation MiMo Pro model for long-context coding and agent workflows.', - }, - { - id: 'xiaomi/mimo-v2-omni', - name: 'MiMo V2 Omni', - provider: 'Xiaomi MiMo', - category: 'advanced', - costTier: 'low', - context: '256K', - description: 'Multimodal MiMo model for image-aware analysis, OCR, charts, and visual context.', - }, { id: 'acedata/claude-opus-4-8', name: 'Claude Opus 4.8 (AceData)', @@ -327,16 +309,6 @@ export const HATCHER_HOSTED_MODEL_RECOMMENDATIONS: HostedModelRecommendation[] = description: 'Fast Claude option through AceData for extraction, classification, and lightweight chat.', warning: 'Uses estimated AI Credits because AceData exposes costs in their usage console, not in chat responses.', }, - { - id: 'acedata/gpt-5.5', - name: 'GPT-5.5 (AceData)', - provider: 'AceData', - category: 'premium', - costTier: 'high', - context: '1.05M', - description: 'Partner-hosted OpenAI-compatible GPT-5.5 through AceData, with OpenRouter fallback when needed.', - warning: 'Uses estimated AI Credits because AceData exposes costs in their usage console, not in chat responses.', - }, { id: 'acedata/gpt-5.4-pro', name: 'GPT-5.4 Pro (AceData)', @@ -565,22 +537,14 @@ export const HATCHER_HOSTED_MODEL_RECOMMENDATIONS: HostedModelRecommendation[] = warning: 'Consumes AI Credits quickly.', }, { - id: 'x-ai/grok-4.1-fast', - name: 'Grok 4.1 Fast', + id: 'x-ai/grok-4.5', + name: 'Grok 4.5', provider: 'xAI', - category: 'fast', - costTier: 'low', - context: '2M', - description: 'Fast Grok model with very large context.', - }, - { - id: 'x-ai/grok-code-fast-1', - name: 'Grok Code Fast 1', - provider: 'xAI', - category: 'coding', - costTier: 'medium', - context: '256K', - description: 'xAI coding model tuned for fast code generation.', + category: 'premium', + costTier: 'high', + context: '500K', + description: 'Current Grok model for reasoning, coding, and multimodal agent workflows.', + warning: 'The current UsePod marketplace route can report additional provider-side tokens. Monitor AI Credit usage.', }, { id: 'mistralai/mistral-small-2603', @@ -636,6 +600,132 @@ export const HATCHER_HOSTED_MODEL_RECOMMENDATIONS: HostedModelRecommendation[] = context: '256K', description: 'Low-cost NVIDIA model for lightweight workflows.', }, + { + id: 'virtuals/anthropic-claude-fable-5', + name: 'Claude Fable 5', + provider: 'Virtuals', + category: 'advanced', + costTier: 'variable', + context: '1M', + description: 'Virtuals Compute Anthropic route for autonomous knowledge work, coding, and multimodal inputs.', + }, + { + id: 'virtuals/e2ee-deepseek-v4-flash', + name: 'DeepSeek V4 Flash (E2EE)', + provider: 'Virtuals', + category: 'fast', + costTier: 'variable', + context: '1M', + description: 'Virtuals provider-side TEE with hardware attestation; Hatcher still processes and forwards the request.', + }, + { + id: 'virtuals/openai-gpt-56-luna', + name: 'GPT-5.6 Luna', + provider: 'Virtuals', + category: 'fast', + costTier: 'variable', + context: '1M', + description: 'Virtuals Compute cost-efficient GPT-5.6 route for high-volume and latency-sensitive tasks.', + }, + { + id: 'virtuals/openai-gpt-56-luna-pro', + name: 'GPT-5.6 Luna Pro', + provider: 'Virtuals', + category: 'advanced', + costTier: 'variable', + context: '1M', + description: 'Virtuals Compute GPT-5.6 Luna route with the provider pro reasoning mode.', + }, + { + id: 'virtuals/openai-gpt-56-sol', + name: 'GPT-5.6 Sol', + provider: 'Virtuals', + category: 'premium', + costTier: 'variable', + context: '1M', + description: 'Virtuals Compute flagship GPT-5.6 route for complex reasoning, coding, and agentic workflows.', + }, + { + id: 'virtuals/openai-gpt-56-sol-pro', + name: 'GPT-5.6 Sol Pro', + provider: 'Virtuals', + category: 'premium', + costTier: 'variable', + context: '1M', + description: 'Virtuals Compute GPT-5.6 Sol route with the provider pro reasoning mode.', + }, + { + id: 'virtuals/openai-gpt-56-terra', + name: 'GPT-5.6 Terra', + provider: 'Virtuals', + category: 'balanced', + costTier: 'variable', + context: '1M', + description: 'Virtuals Compute balanced GPT-5.6 route for everyday coding, reasoning, and agent tasks.', + }, + { + id: 'virtuals/openai-gpt-56-terra-pro', + name: 'GPT-5.6 Terra Pro', + provider: 'Virtuals', + category: 'advanced', + costTier: 'variable', + context: '1M', + description: 'Virtuals Compute GPT-5.6 Terra route with the provider pro reasoning mode.', + }, + { + id: 'virtuals/x-ai-grok-4-5', + name: 'Grok 4.5', + provider: 'Virtuals', + category: 'premium', + costTier: 'variable', + context: '500K', + description: 'Virtuals Compute Grok route for coding, knowledge work, and STEM-heavy agent tasks.', + }, + { + id: 'virtuals/moonshotai-kimi-k2-5', + name: 'Kimi K2 5', + provider: 'Virtuals', + category: 'balanced', + costTier: 'variable', + context: '256K', + description: 'Virtuals Compute Kimi model for general agent work, routed with the platform Virtuals key.', + }, + { + id: 'virtuals/moonshotai-kimi-k2-6', + name: 'Kimi K2 6', + provider: 'Virtuals', + category: 'advanced', + costTier: 'variable', + context: '256K', + description: 'Virtuals Compute Kimi variant for analysis-heavy prompts and longer planning loops.', + }, + { + id: 'virtuals/moonshotai-kimi-k2-7-code', + name: 'Kimi K2 7 Code', + provider: 'Virtuals', + category: 'coding', + costTier: 'variable', + context: '256K', + description: 'Virtuals Compute coding-oriented Kimi route for repo analysis and implementation tasks.', + }, + { + id: 'virtuals/deepseek-deepseek-v3-2', + name: 'DeepSeek V3.2', + provider: 'Virtuals', + category: 'advanced', + costTier: 'variable', + context: '160K', + description: 'Virtuals Compute DeepSeek route for reasoning and structured task decomposition.', + }, + { + id: 'virtuals/google-gemini-3-flash-preview', + name: 'Gemini 3 Flash Preview', + provider: 'Virtuals', + category: 'fast', + costTier: 'variable', + context: '256K', + description: 'Virtuals Compute Gemini route for quick responses and multimodal-adjacent workflows.', + }, { id: 'openai/gpt-5.3-codex', name: 'GPT-5.3 Codex', diff --git a/tests/hosted-model-recommendations.test.mjs b/tests/hosted-model-recommendations.test.mjs new file mode 100644 index 0000000..afa8b88 --- /dev/null +++ b/tests/hosted-model-recommendations.test.mjs @@ -0,0 +1,94 @@ +import assert from 'node:assert/strict'; +import test from 'node:test'; + +import { HATCHER_HOSTED_MODEL_RECOMMENDATIONS } from '../dist/index.mjs'; + +const modelsById = new Map( + HATCHER_HOSTED_MODEL_RECOMMENDATIONS.map((model) => [model.id, model]), +); + +test('hosted model ids remain unique', () => { + assert.equal(modelsById.size, HATCHER_HOSTED_MODEL_RECOMMENDATIONS.length); +}); + +test('stale selectable partner and xAI ids are removed', () => { + const staleIds = [ + 'xiaomi/mimo-v2-pro', + 'xiaomi/mimo-v2-omni', + 'x-ai/grok-4.1-fast', + 'x-ai/grok-code-fast-1', + 'acedata/gpt-5.5', + 'virtuals/llama-3-3-70b', + ]; + + for (const id of staleIds) { + assert.equal(modelsById.has(id), false, `${id} must not remain selectable`); + } +}); + +test('current direct Grok model replaces retired xAI options', () => { + assert.deepEqual(modelsById.get('x-ai/grok-4.5'), { + id: 'x-ai/grok-4.5', + name: 'Grok 4.5', + provider: 'xAI', + category: 'premium', + costTier: 'high', + context: '500K', + description: 'Current Grok model for reasoning, coding, and multimodal agent workflows.', + warning: 'The current UsePod marketplace route can report additional provider-side tokens. Monitor AI Credit usage.', + }); +}); + +test('Virtuals fallback catalog matches the current no-Llama set', () => { + const expectedIds = [ + 'virtuals/anthropic-claude-fable-5', + 'virtuals/e2ee-deepseek-v4-flash', + 'virtuals/openai-gpt-56-luna', + 'virtuals/openai-gpt-56-luna-pro', + 'virtuals/openai-gpt-56-sol', + 'virtuals/openai-gpt-56-sol-pro', + 'virtuals/openai-gpt-56-terra', + 'virtuals/openai-gpt-56-terra-pro', + 'virtuals/x-ai-grok-4-5', + 'virtuals/moonshotai-kimi-k2-5', + 'virtuals/moonshotai-kimi-k2-6', + 'virtuals/moonshotai-kimi-k2-7-code', + 'virtuals/deepseek-deepseek-v3-2', + 'virtuals/google-gemini-3-flash-preview', + ]; + const actualIds = HATCHER_HOSTED_MODEL_RECOMMENDATIONS + .filter((model) => model.provider === 'Virtuals') + .map((model) => model.id); + + assert.deepEqual(actualIds, expectedIds); + for (const id of expectedIds) { + assert.equal(modelsById.get(id)?.costTier, 'variable', `${id} must expose variable pricing`); + } +}); + +test('new Virtuals frontier models expose verified context labels', () => { + const oneMillionContextIds = [ + 'virtuals/anthropic-claude-fable-5', + 'virtuals/e2ee-deepseek-v4-flash', + 'virtuals/openai-gpt-56-luna', + 'virtuals/openai-gpt-56-luna-pro', + 'virtuals/openai-gpt-56-sol', + 'virtuals/openai-gpt-56-sol-pro', + 'virtuals/openai-gpt-56-terra', + 'virtuals/openai-gpt-56-terra-pro', + ]; + + for (const id of oneMillionContextIds) { + assert.equal(modelsById.get(id)?.context, '1M'); + } + assert.equal(modelsById.get('virtuals/x-ai-grok-4-5')?.context, '500K'); + for (const id of [ + 'virtuals/moonshotai-kimi-k2-5', + 'virtuals/moonshotai-kimi-k2-6', + 'virtuals/moonshotai-kimi-k2-7-code', + 'virtuals/google-gemini-3-flash-preview', + ]) { + assert.equal(modelsById.get(id)?.context, '256K'); + } + assert.equal(modelsById.get('virtuals/deepseek-deepseek-v3-2')?.context, '160K'); +});