Skip to content

feat(studio): add MiniMax as an external LLM provider#6867

Open
octo-patch wants to merge 1 commit into
unslothai:mainfrom
octo-patch:octo/minimax-provider
Open

feat(studio): add MiniMax as an external LLM provider#6867
octo-patch wants to merge 1 commit into
unslothai:mainfrom
octo-patch:octo/minimax-provider

Conversation

@octo-patch

Copy link
Copy Markdown
Contributor

Summary

Add MiniMax as a new external LLM provider in Unsloth Studio, alongside the existing OpenAI-compatible providers (DeepSeek, Kimi, Qwen, …).

Changes

  • Add a minimax entry to PROVIDER_REGISTRY in studio/backend/core/inference/providers.py. It uses MiniMax's OpenAI-compatible endpoint (https://api.minimax.io/v1) with Bearer auth, so it routes through the existing /chat/completions path like the other OpenAI-compatible providers — no new backend translation needed.
  • Seed the model picker with MiniMax-M3 (1M-token context, image input).
  • Update tests/test_providers_api.py: register MiniMax in the provider config map and bump the expected registry size (9 → 10).

Testing

  • python -m py_compile on both changed files.
  • Imported the registry and asserted the new entry resolves (get_provider_info/get_base_url), routes through the OpenAI-compatible path, and that list_available_providers() returns 10 entries all carrying the required fields.
  • ruff check passes on the changed files.
  • The test_providers_api.py suite is a live-server integration test (skipped without a running Studio instance / API key), so the registry wiring is covered by CI.

@octo-patch octo-patch requested a review from danielhanchen as a code owner July 4, 2026 08:43
@chatgpt-codex-connector

Copy link
Copy Markdown

Codex usage limits have been reached for code reviews. Please check with the admins of this repo to increase the limits by adding credits.
Repo admins can enable using credits for code reviews in their settings.

@gemini-code-assist gemini-code-assist Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request adds support for the MiniMax inference provider, updating both the provider registry and the test suite. The review feedback suggests adding the China mainland base URL to the provider notes for consistency and including MiniMax in the vision test parameters to ensure its vision capabilities are properly covered.

Important

The consumer version of Gemini Code Assist on GitHub is being sunset. Starting June 18, 2026, new organization installations will be blocked, and all code review activity will officially cease on July 17, 2026.
For more details on the timeline and next steps, please review the Help Documentation.

"supports_tool_calling": True,
"auth_header": "Authorization",
"auth_prefix": "Bearer ",
"notes": "OpenAI-compatible API. API key from platform.minimax.io. MiniMax-M3 has a 1M-token context window and image input.",

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

medium

For consistency with other China-based providers (like Kimi and Qwen), it is highly beneficial to mention the China mainland base URL (https://api.minimaxi.com/v1) in the notes field.

Suggested change
"notes": "OpenAI-compatible API. API key from platform.minimax.io. MiniMax-M3 has a 1M-token context window and image input.",
"notes": "OpenAI-compatible API. API key from platform.minimax.io. MiniMax-M3 has a 1M-token context window and image input. China mainland: override base URL to https://api.minimaxi.com/v1",

"huggingface": ("HUGGINGFACE_API_KEY", "meta-llama/Llama-3.3-70B-Instruct"),
"kimi": ("MOONSHOT_API_KEY", "moonshot-v1-8k"),
"qwen": ("DASHSCOPE_API_KEY", "qwen-turbo"),
"minimax": ("MINIMAX_API_KEY", "MiniMax-M3"),

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

medium

Since the minimax provider supports vision (supports_vision: True in the registry), it should also be included in the _VISION_PARAMS list (around line 480) so that its vision capabilities are covered by the integration tests.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant