Skip to content

feat: add MiniMax as alternative LLM provider for video chat (M3 default)#265

Open
octo-patch wants to merge 2 commits into
OpenGVLab:mainfrom
octo-patch:feature/add-minimax-provider
Open

feat: add MiniMax as alternative LLM provider for video chat (M3 default)#265
octo-patch wants to merge 2 commits into
OpenGVLab:mainfrom
octo-patch:feature/add-minimax-provider

Conversation

@octo-patch

@octo-patch octo-patch commented Mar 26, 2026

Copy link
Copy Markdown

Summary

Add MiniMax M3 as an alternative LLM provider for the video_chat_with_ChatGPT component. Users can now choose between OpenAI GPT-4 and MiniMax via a Gradio dropdown or the LLM_PROVIDER environment variable. MiniMax-M3 is the default, with MiniMax-M2.7 and MiniMax-M2.7-highspeed retained as alternatives.

Changes

  • chatbot.py: Add create_llm() factory with an LLM_PROVIDERS registry. MiniMax uses ChatOpenAI with an OpenAI-compatible endpoint and clamps temperature to (0.01, 1.0]. Default model is MiniMax-M3.
  • app.py: Add LLM Provider dropdown in the Gradio UI; safer os.environ.get() for the API key.
  • README.md: Add MiniMax (M3) to the provider list.
  • video_chat_with_ChatGPT/README.md: Add MiniMax setup instructions, defaulting to M3.
  • tests/: 25 unit tests + 3 integration tests covering provider registry, factory behaviour, temperature clamping, and init_agent with both providers.

Why MiniMax-M3?

MiniMax-M3 is the latest MiniMax model — 512K context window, up to 128K output, and image input support — providing a high-quality, cost-effective alternative to GPT-4 for reasoning about video descriptions through an OpenAI-compatible API. Older models M2.5/M2.1/M2/M1 were never wired in; M2.7 and M2.7-highspeed remain selectable for users that prefer the previous generation.

Test Plan

  • 25 unit tests pass (provider registry, create_llm factory, temperature clamping, init_agent with both providers, env-var fallback) — default-model assertions updated to MiniMax-M3
  • 3 integration tests pass against the live MiniMax API (create_llm, chat completion, MiniMax-M2.7-highspeed model)
  • Manual testing with the Gradio UI

PR Bot and others added 2 commits March 26, 2026 17:32
Add MiniMax M2.7 as an alternative LLM provider alongside OpenAI GPT-4
in the video_chat_with_ChatGPT component. MiniMax offers an OpenAI-compatible
API, enabling users to choose between providers via a Gradio dropdown or
the LLM_PROVIDER environment variable.

Changes:
- chatbot.py: add create_llm() factory with LLM_PROVIDERS registry,
  ChatOpenAI-based MiniMax integration with temperature clamping
- app.py: add LLM Provider dropdown, configurable API key input
- README.md: add MiniMax to the provider list in main README
- video_chat_with_ChatGPT/README.md: add MiniMax setup instructions
- tests/: 25 unit tests + 3 integration tests
- Set MiniMax-M3 as the default model for the minimax provider
- Keep MiniMax-M2.7 and MiniMax-M2.7-highspeed available
- Update README docs and unit-test expectations
@octo-patch octo-patch changed the title feat: add MiniMax as alternative LLM provider for video chat feat: add MiniMax as alternative LLM provider for video chat (M3 default) Jun 7, 2026
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