diff --git a/README.md b/README.md index 66bed3a..0145cf0 100644 --- a/README.md +++ b/README.md @@ -241,7 +241,7 @@ All settings are manageable in the **Settings** page at `/settings` or via envir | API Base URL | `ANTHROPIC_BASE_URL` | Custom endpoint for proxies or local Anthropic-compatible models | | AI Model | Settings page only | Haiku 4.5 (default, fastest/cheapest), Sonnet 4.6, Opus 4.6 | | OpenAI Key | `OPENAI_API_KEY` | Alternative provider — GPT-4.1 Mini/Nano/Full, o4-mini, o3 | -| MiniMax Key | `MINIMAX_API_KEY` | Alternative provider — M2.7 (1M context), M2.5, M2.5-highspeed | +| MiniMax Key | `MINIMAX_API_KEY` | Alternative provider — M3 (default, 512K context), M2.7 (192K context), M2.7 Highspeed | | MiniMax Base URL | `MINIMAX_BASE_URL` | Custom MiniMax API endpoint (default: `https://api.minimax.io/v1`) | | Database | `DATABASE_URL` | SQLite file path (default: `file:./prisma/dev.db`) | @@ -356,7 +356,7 @@ For Prisma command and workflow details, see: | [SQLite](https://sqlite.org) | — | Local database — zero setup, includes FTS5 | | [Tailwind CSS](https://tailwindcss.com) | v4 | Styling | | [Anthropic SDK](https://docs.anthropic.com) | — | Vision, semantic tagging, categorization, search | -| [MiniMax](https://platform.minimaxi.com) | — | Alternative AI provider (M2.7 1M context, M2.5) | +| [MiniMax](https://platform.minimaxi.com) | — | Alternative AI provider (M3 default, M2.7 192K context, M2.7 Highspeed) | | [@xyflow/react](https://xyflow.com) | 12 | Interactive mindmap graph | | [Framer Motion](https://www.framer.com/motion/) | 12 | Animations | | [Radix UI](https://www.radix-ui.com) | — | Accessible UI primitives | diff --git a/__tests__/minimax-ai-client.test.ts b/__tests__/minimax-ai-client.test.ts index 3a8d8e6..ac46a98 100644 --- a/__tests__/minimax-ai-client.test.ts +++ b/__tests__/minimax-ai-client.test.ts @@ -26,7 +26,7 @@ describe('MiniMaxAIClient', () => { const client = new MiniMaxAIClient(mock) const result = await client.createMessage({ - model: 'MiniMax-M2.7', + model: 'MiniMax-M3', max_tokens: 100, messages: [{ role: 'user', content: 'hi' }], }) @@ -41,7 +41,7 @@ describe('MiniMaxAIClient', () => { const client = new MiniMaxAIClient(mock) const result = await client.createMessage({ - model: 'MiniMax-M2.5', + model: 'MiniMax-M3', max_tokens: 100, messages: [{ role: 'user', content: 'test' }], }) @@ -57,7 +57,7 @@ describe('MiniMaxAIClient', () => { const client = new MiniMaxAIClient(mock) const result = await client.createMessage({ - model: 'MiniMax-M2.5', + model: 'MiniMax-M3', max_tokens: 100, messages: [{ role: 'user', content: 'test' }], }) @@ -113,14 +113,14 @@ describe('MiniMaxAIClient', () => { const client = new MiniMaxAIClient(mock) await client.createMessage({ - model: 'MiniMax-M2.7', + model: 'MiniMax-M3', max_tokens: 512, messages: [{ role: 'user', content: 'test' }], }) expect(createFn).toHaveBeenCalledWith( expect.objectContaining({ - model: 'MiniMax-M2.7', + model: 'MiniMax-M3', max_tokens: 512, }) ) diff --git a/__tests__/minimax-integration.test.ts b/__tests__/minimax-integration.test.ts index 2081bca..7b85ab6 100644 --- a/__tests__/minimax-integration.test.ts +++ b/__tests__/minimax-integration.test.ts @@ -32,7 +32,7 @@ describe('MiniMax integration - categorization pipeline', () => { const client = new MiniMaxAIClient(createMockSDK(jsonResponse)) const result = await client.createMessage({ - model: 'MiniMax-M2.7', + model: 'MiniMax-M3', max_tokens: 4096, messages: [ { @@ -53,7 +53,7 @@ describe('MiniMax integration - categorization pipeline', () => { const client = new MiniMaxAIClient(createMockSDK(response)) const result = await client.createMessage({ - model: 'MiniMax-M2.5', + model: 'MiniMax-M3', max_tokens: 4096, messages: [{ role: 'user', content: 'Categorize...' }], }) diff --git a/app/api/settings/route.ts b/app/api/settings/route.ts index 6debf8d..f4bfb2a 100644 --- a/app/api/settings/route.ts +++ b/app/api/settings/route.ts @@ -24,9 +24,9 @@ const ALLOWED_OPENAI_MODELS = [ ] as const const ALLOWED_MINIMAX_MODELS = [ + 'MiniMax-M3', 'MiniMax-M2.7', - 'MiniMax-M2.5', - 'MiniMax-M2.5-highspeed', + 'MiniMax-M2.7-highspeed', ] as const export async function GET(): Promise { @@ -54,7 +54,7 @@ export async function GET(): Promise { openaiModel: openaiModel?.value ?? 'gpt-4.1-mini', minimaxApiKey: maskKey(minimax?.value ?? null), hasMinimaxKey: minimax !== null, - minimaxModel: minimaxModel?.value ?? 'MiniMax-M2.7', + minimaxModel: minimaxModel?.value ?? 'MiniMax-M3', xOAuthClientId: maskKey(xClientId?.value ?? null), xOAuthClientSecret: maskKey(xClientSecret?.value ?? null), hasXOAuth: !!xClientId?.value, diff --git a/app/api/settings/test/route.ts b/app/api/settings/test/route.ts index e1291a6..a92ba74 100644 --- a/app/api/settings/test/route.ts +++ b/app/api/settings/test/route.ts @@ -90,7 +90,7 @@ export async function POST(request: NextRequest): Promise { try { await client.chat.completions.create({ - model: 'MiniMax-M2.7', + model: 'MiniMax-M3', max_tokens: 5, messages: [{ role: 'user', content: 'hi' }], }) diff --git a/app/settings/page.tsx b/app/settings/page.tsx index 56f3115..ee89b2a 100644 --- a/app/settings/page.tsx +++ b/app/settings/page.tsx @@ -42,9 +42,9 @@ const OPENAI_MODELS = [ ] const MINIMAX_MODELS = [ - { value: 'MiniMax-M2.7', label: 'M2.7', description: '1M Context, Latest' }, - { value: 'MiniMax-M2.5', label: 'M2.5', description: '204K Context' }, - { value: 'MiniMax-M2.5-highspeed', label: 'M2.5 Highspeed', description: '204K, Fastest' }, + { value: 'MiniMax-M3', label: 'M3', description: '512K Context, Latest' }, + { value: 'MiniMax-M2.7', label: 'M2.7', description: '192K Context' }, + { value: 'MiniMax-M2.7-highspeed', label: 'M2.7 Highspeed', description: 'Fast M2.7 Variant' }, ] @@ -678,10 +678,10 @@ function ApiKeySection({ onToast }: { onToast: (t: Toast) => void }) { -

MiniMax M2.7 supports 1M context window — great for large batch categorization

+

MiniMax M3 is the latest flagship with 512K context — M2.7 (1M context) remains available

)} diff --git a/lib/settings.ts b/lib/settings.ts index 7da5eb8..7880ab9 100644 --- a/lib/settings.ts +++ b/lib/settings.ts @@ -55,7 +55,7 @@ export async function getOpenAIModel(): Promise { export async function getMiniMaxModel(): Promise { if (_cachedMiniMaxModel && Date.now() < _miniMaxModelCacheExpiry) return _cachedMiniMaxModel const setting = await prisma.setting.findUnique({ where: { key: 'minimaxModel' } }) - _cachedMiniMaxModel = setting?.value ?? 'MiniMax-M2.7' + _cachedMiniMaxModel = setting?.value ?? 'MiniMax-M3' _miniMaxModelCacheExpiry = Date.now() + CACHE_TTL return _cachedMiniMaxModel }