Add MiniMax as a new LLM provider client#533
Open
octo-patch wants to merge 1 commit intowaylaidwanderer:mainfrom
Open
Add MiniMax as a new LLM provider client#533octo-patch wants to merge 1 commit intowaylaidwanderer:mainfrom
octo-patch wants to merge 1 commit intowaylaidwanderer:mainfrom
Conversation
Add MiniMaxClient extending ChatGPTClient, supporting MiniMax's OpenAI-compatible Chat Completions API with M2.7/M2.7-highspeed models, temperature clamping [0,1], 1M context window, proper user/assistant role messages, streaming, and conversation management. - src/MiniMaxClient.js: new client with buildPrompt override for proper chat message roles - bin/server.js, bin/cli.js: add 'minimax' client option in getClient() - settings.example.js: add miniMaxClient config section - demos/use-minimax-client.js: usage example - test/minimax-client-unit.js: 30 unit tests - test/minimax-client-integration.js: 3 integration tests - README.md: document MiniMax support
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
MiniMaxClientextendingChatGPTClientfor MiniMax's OpenAI-compatible Chat Completions APIMiniMax-M2.7,MiniMax-M2.7-highspeed,MiniMax-M2.5, andMiniMax-M2.5-highspeedmodels with 1M context windowminimaxclient option[0, 1]range, properuser/assistantrole message constructionChanges
src/MiniMaxClient.jsbuildPromptfor proper chat message rolesbin/server.jsminimaxcase ingetClient()factorybin/cli.jsminimaxclient option with MiniMax AI labelindex.jsMiniMaxClientsettings.example.jsminiMaxClientconfiguration sectiondemos/use-minimax-client.jstest/minimax-client-unit.jstest/minimax-client-integration.jsREADME.mdTest plan
node --test test/minimax-client-unit.js)MINIMAX_API_KEY=... node --test test/minimax-client-integration.js)clientToUse: 'minimax'works in API server modeclientToUse: 'minimax'works in CLI mode