How to Use MiniMax M2.7 in opencode
MiniMax M2.7 suits debugging, code delivery, and repeated revisions to office documents. Compared with MiniMax M2.5, MiniMax reports improved performance on its MMClaw agent evaluation.
Prompts to try with MiniMax M2.7 in opencode
Copy an example into opencode, or ask in your own words.
Use MiniMax M2.7 to reproduce the failing test in this repository, trace the cause, and apply a focused fix. Run the relevant tests and report the results.
Use MiniMax M2.7 to compare the incident logs with this project's recent changes. Rank three possible causes and test the strongest explanation.
Use MiniMax M2.7 to review this project's authentication code for security defects. Show the affected path, a concrete failure scenario, and a regression test for each confirmed finding.
Use MiniMax M2.7 to build a searchable inventory prototype using this project's existing framework. Include filtering, empty states, and tests for the search behavior.
Use MiniMax M2.7 to examine this project's experiment code and results. Identify possible data leakage and propose one controlled comparison before changing the training pipeline.
How to set up MiniMax M2.7 in opencode
Pick the way that suits you. Each takes about two minutes.
Use Spiral's MCP server
- Add the server
Leave out --global to add Spiral to the current project only. No header and no client ID or secret: opencode registers itself with Spiral.
opencode mcp add spiral --global --url https://api.spiral.ai/mcp
- Sign in
Your browser opens. Sign in to Spiral, pick the organization and click Authorize, then return to the terminal. No API key. Inside opencode, /mcps starts the same sign-in.
opencode mcp auth spiral
- Check it
Spiral shows as connected.
opencode mcp list
Use the Spiral skill
- Send opencode this message
Your agent reads Spiral's skill and sets itself up.
set up https://spiral.ai/SKILL.md
- Sign in or paste a key
Approve Spiral in the browser, or give the agent a key from the console.
Use the Spiral CLI
- Install and sign in
Installs the Spiral CLI, signs you in and adds its skill to your coding agents.
npx -y spiral-cli@latest init
Call the Spiral API
- Create an API key
In the console, under API keys.
- Run MiniMax M2.7
One request; the result comes back by polling or a webhook.
curl https://api.spiral.ai/v1/runs \ -H "Authorization: Bearer $SPIRAL_API_KEY" \ -H "Content-Type: application/json" \ -H "Idempotency-Key: $(uuidgen)" \ -d '{ "provider": "openrouter", "model": "minimax/minimax-m2.7", "input": { "messages": [ { "role": "system" } ] } }'
Then paste one of the prompts above: opencode finds MiniMax M2.7 on Spiral, shows the price and runs it.
MiniMax M2.7 providers and prices
Spiral runs MiniMax M2.7 through OpenRouter. Open a card for today's price, with every fee included.
Up to $0.306737 per run at the default inputs. $0.78 per 1M input tokens, $2.34 per 1M output tokens.
Settings you can ask for
Ask opencode for any of these in your prompt.
| Setting | Allowed values | Default | Description |
|---|---|---|---|
| Seed | a whole number | ||
| Min p | 0 to 1 | ||
| Top k | a whole number from 0 | ||
| Top p | 0 to 1 | ||
| Max tokens | 1 to 176947 | The most output tokens to generate. | |
| Temperature | 0 to 2 | ||
| Presence penalty | -2 to 2 | ||
| Frequency penalty | -2 to 2 | ||
| Repetition penalty | 0 to 2 |
Every API field of MiniMax: MiniMax M2.7 is on its tool page: open its card above.
What can you do with MiniMax M2.7 in opencode?
Turn a reported failure into a tested patch with MiniMax M2.7. Give the agent the relevant project files, a reproducer, and a clear definition of success.
Production incident investigation
Use MiniMax M2.7 to examine logs, rank possible causes, and propose checks that distinguish them.
Bug fixes with verification
Ask MiniMax M2.7 to reproduce a failure, propose a focused patch, and verify it with tests.
Code security review
Have MiniMax M2.7 inspect code for security defects and explain each finding with a concrete failure path.
Application prototypes
Give MiniMax M2.7 a bounded specification and acceptance criteria for a working application prototype.
Machine learning experiment review
Use MiniMax M2.7 to examine experiment results, diagnose failures, and propose the next controlled comparison.
Office document revisions
With document tools, ask MiniMax M2.7 to revise reports or presentations while preserving specified content.
Spreadsheet model maintenance
With spreadsheet tools, use MiniMax M2.7 to revise assumptions and formulas across several review rounds.
More on MiniMax M2.7 and opencode
Overview
MiniMax M2.7 in other agents
Questions about MiniMax M2.7 in opencode
Can opencode use MiniMax M2.7?
Yes. Add Spiral to opencode as an MCP server, and opencode can find and run MiniMax M2.7 like any built-in tool.
How much does MiniMax M2.7 cost in opencode?
Up to $0.004483 per run at the default inputs. $0.273 per 1M input tokens, $1.092 per 1M output tokens. You pay from your Spiral balance as you go, with no subscription, and a failed run is not charged. Your opencode plan is separate.
Do I need an OpenRouter account to use MiniMax M2.7 in opencode?
No. Spiral runs MiniMax M2.7 on its own OpenRouter account. You sign in to Spiral once and never paste a key.
How long does it take to set up MiniMax M2.7 in opencode?
About two minutes: add the server, then sign in, then check it.
Does opencode wait while MiniMax M2.7 runs?
MiniMax M2.7 runs in the background. opencode starts the run, checks on it and gives you the text, json when it's ready.
What is MiniMax M2.7 good at?
Its documented uses include debugging, log analysis, software delivery, code security, and machine learning. It also suits office tasks that need several rounds of revision.
How much context can MiniMax M2.7 handle?
MiniMax's deployment guide documents 196K tokens per sequence. For long tasks, keep the working context below that limit and request a concise handoff summary between stages.
Can MiniMax M2.7 work directly with images and video?
Plan around text and tool results. MiniMax directs projects requiring native multimodal input to MiniMax M3; provide extracted text or a description for M2.7.
Which generation settings should I start with?
MiniMax recommends temperature 1.0, top-p 0.95, and top-k 40. Use those as a starting point, then evaluate changes against examples from your actual task.
Can MiniMax M2.7 revise spreadsheets and presentations?
Yes, with an agent that supplies document editing tools. MiniMax documents repeated editing of Word, Excel, and PowerPoint content; specify which values, formulas, and sections must stay intact.
Start using MiniMax M2.7 in opencode
One Spiral account for every tool your agent needs. No subscription; you pay per run.
Paste this into opencode:
set up https://spiral.ai/SKILL.md


