feat: add MiniMax as LLM provider (llm-chain-minimax crate)#306
Open
octo-patch wants to merge 1 commit into
Open
feat: add MiniMax as LLM provider (llm-chain-minimax crate)#306octo-patch wants to merge 1 commit into
octo-patch wants to merge 1 commit into
Conversation
Add a new llm-chain-minimax crate that integrates MiniMax LLM models (M2.7, M2.7-highspeed, M2.5, M2.5-highspeed) via their OpenAI-compatible API. - Implements the Executor trait using async-openai with MiniMax API endpoint - Adds Model enum with context size metadata (up to 1M tokens for M2.7) - Strips think tags from model responses (M2.5+ thinking support) - Adds executor!(minimax) macro support - Includes 16 unit tests and 3 integration tests - Updates README with MiniMax documentation
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
Adds a new
llm-chain-minimaxcrate that integrates MiniMax LLM models via their OpenAI-compatible API, following the same architecture pattern asllm-chain-openai.What's included
llm-chain-minimax— FullExecutortrait implementation usingasync-openaiwith MiniMax's API endpoint (https://api.minimax.io/v1)<think>...</think>reasoning tags from M2.5+ model responsesexecutor!(minimax)macro — Integrated into the existing executor macro systemMINIMAX_API_KEYand optionalMINIMAX_API_BASE_URLSupported models
Files changed (12 files, 934 additions)
crates/llm-chain-minimax/— New crate (Cargo.toml, README, src/, tests/, examples/)crates/llm-chain/src/executor.rs— Addedminimaxvariant toexecutor!macrodocs/README.md— Added MiniMax to features and getting started sectionsTest plan
cargo test -p llm-chain-minimax)--ignoredflag)llm-chain-openaitests still pass (no modifications to existing crate logic)