Add MiniMax summarizer provider - #218
Conversation
This reverts commit 42c3fa2.
MiniMax speaks the OpenAI chat-completions API, so it already works through the openai_compat backend — the only friction was knowing the base URL and model id. Add preset buttons that fill both in (MiniMax global, MiniMax China, local llama.cpp) instead of a per-vendor adapter. Verified the endpoint through the existing adapter: an unauthenticated POST to https://api.minimax.io/v1/chat/completions returns MiniMax's 401 body, which errors.classify() already buckets as `auth` with the right hint. Adding a provider is one entry in ENDPOINT_PRESETS, not a new module, a hardcoded model allowlist, and a test-connection route. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
|
I've reverted the dedicated adapter on this branch and replaced it with endpoint presets on the existing WhyMiniMax speaks the OpenAI chat-completions API, so it already worked through Three things the dedicated adapter got wrong that the existing one already handles:
Separately, every test in What's on the branch now
Adding the next provider is one array entry. Verified
Needs a human check before mergeI don't have a MiniMax API key, so the authenticated end-to-end run hasn't happened. Please verify:
If step 3 shows reasoning text, that's a |
A preset with an empty model left the previous id in place, so clicking MiniMax and then the local llama.cpp preset would POST model "MiniMax-M3" to localhost:8080. Reassign unconditionally; null falls through to openai_compat's `self._model or "default"`, which is what a local server that serves whatever is loaded expects. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
|
Follow-up on the local-server case. The One bug in the preset buttons though, now fixed in 81595e7: a preset with an empty model id left the previous one in place, so clicking MiniMax and then the local preset would POST Add to the verification pass: after testing MiniMax, click the local preset and confirm the model field clears rather than keeping the MiniMax id. |
Reason: Make MiniMax directly configurable for trace summarization across supported regions and compatible protocols.
Changes:
Checks:
git diff --check HEAD^PYTHONPATH=backend python3 backend/test_minimax_summarizer.pyfrontend/node_modules/.bin/eslint --config frontend/eslint.config.mjs frontend/src/app/settings/page.tsx frontend/src/components/summarizer/BackendPicker.tsx frontend/src/components/summarizer/OnboardingModal.tsx frontend/src/lib/agents.ts frontend/src/lib/summarizer.ts --rule 'react-hooks/set-state-in-effect: off'npm --prefix frontend run buildThe repository-wide
npm --prefix frontend run lintcheck still reports existing lint failures outside this change.