feat(gateway): add MiniMax compatibility - #815
Merged
Merged
Conversation
3 tasks
Greptile SummaryAdds MiniMax support to the bundled gateway provider.
Confidence Score: 5/5The PR appears safe to merge. No blocking failure remains; the previously reported parallel tool-result serialization issue is fixed by grouping consecutive results into one Anthropic user message and is covered by the gateway runner test.
|
| Filename | Overview |
|---|---|
| src/agent-cli-provider/gateway-client.ts | Dispatches requests by protocol, translates Anthropic messages and tools, preserves response blocks, and groups parallel tool results correctly. |
| src/agent-cli-provider/gateway-runner.ts | Propagates protocol and token-limit settings while retaining Anthropic assistant content across tool turns. |
| src/agent-cli-provider/gateway-tools.ts | Normalizes and validates gateway protocol and positive token-limit configuration. |
| src/agent-cli-provider/adapters/gateway.ts | Registers MiniMax models and forwards the new gateway configuration fields. |
| tests/agent-cli-provider/gateway-runner.test.js | Covers OpenAI token limits and Anthropic endpoint, content-preservation, and parallel-tool-result behavior. |
| docs/providers.md | Documents protocol selection, token requirements, and MiniMax regional endpoint configurations. |
Sequence Diagram
sequenceDiagram
participant Runner as Gateway Runner
participant Client as Gateway Client
participant API as Compatible Endpoint
Runner->>Client: Request with protocol and messages
alt OpenAI protocol
Client->>API: POST /chat/completions
else Anthropic protocol
Client->>API: POST /v1/messages
API-->>Client: Assistant content with parallel tool_use blocks
Client-->>Runner: Tool calls and original content
Runner->>Runner: Execute requested tools
Runner->>Client: Consecutive tool-result messages
Client->>Client: Group results into one user message
Client->>API: Follow-up Messages API request
end
API-->>Runner: Final response
Reviews (3): Last reviewed commit: "fix(gateway): preserve compatible reques..." | Re-trigger Greptile
tomdps
force-pushed
the
codex/migrate-pr-658-to-main
branch
from
July 28, 2026 21:22
504118a to
08d8311
Compare
|
🎉 This PR is included in version 6.9.0 🎉 The release is available on: Your semantic-release bot 📦🚀 |
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.
Main-trunk migration
Replaces #658 after the trunk cutover. The contributor commit now starts from the new
main; original authorship is preserved. The only migration resolution retained both the current reasoning-effort tests and the contributor’s new gateway tests.Original PR body
Reason: add target provider/model to existing provider registry
Summary
Adds MiniMax model compatibility to the bundled gateway configuration.
Related Issues
None.
Changes Made
Testing
npm cinpm run check:agent-cli-provider:cinpm run checknpm testChecklist
npm test)