博客 / 詳情

返回

想在雲上低成本部署高性能Agent?MiniMax-M2 + DigitalOcean實戰指南

MiniMax-M2 為開發者提供了一個引人注目的解決方案,它通過一個擁有 2300 億參數但僅激活 100 億參數的專家混合模型,來提供編碼和智能體能力。該模型在保持與 Claude Sonnet 4.5 和 GPT-5 等尖端模型相媲美的性能的同時,僅需其一小部分計算開銷,因此尤其適合那些對成本控制和低延遲有嚴格要求的部署場景。

模型概覽

核心能力 面向開發者的核心價值 關鍵指標/詳情
智能體性能 MiniMax-M2 使用 標籤將其推理過程與最終輸出分離。這使模型能夠在多輪交互中保持連貫的思維鏈。擅長需要規劃、執行與調整的複雜長程任務,是構建自主智能體的理想選擇。 在 BrowseComp(44.0 分)和 ArtifactsBench(66.8 分)上表現出色,超越多個規模更大的模型。
高級編碼 專為端到端的開發者工作流設計,支持包含“編碼-運行-修復”的迭代循環以及多文件編輯。 在 Terminal-Bench(46.3 分)和 SWE-bench Verified(69.4 分)基準測試中極具競爭力。
工具調用能力 為複雜工具集成(Shell、瀏覽器、搜索)而構建,在與外部數據或系統交互時表現穩健可靠。 提供專門的工具調用指南。在 HLE(使用工具)及其他工具增強基準測試中表現強勁。
卓越的通用智能 在通用知識和推理方面保持競爭力,確保即使在核心編碼任務之外也能可靠工作。 綜合 AA 智能得分達 61 分,在開源模型中名列前茅。

部署指南

官方文檔給出了多種運行 MiniMax-M2 的方式。


以下為官方文檔中推薦的配置,實際需求請根據具體用例調整:

  • 4×96 GB GPU:支持最長 400 K token 的上下文
  • 8×144 GB GPU:支持最長 3 M token 的上下文

由於我們這次用的是數據量比較大的模型,所以我們直接用 8×H200 的集羣來運行它。

我們在這裏使用的是 DigitalOcean 的 GPU Droplet 雲服務器。目前 DigitalOcean 可以提供 H200(單卡或 8 卡)、H100(單卡或 8 卡)等一系列 GPU 服務器機型,而且支持按需實例和裸金屬。


相對於 AWS、GCP 等雲平台,DigitalOcean 提供的 GPU 服務器總體成本更低,而且使用簡單,無學習成本。DigitalOcean 還將在明年年初正式推出基於 NVIDIA B300 的 GPU Droplet 服務器,詳情可直接諮詢 DigitalOcean 中國區獨家戰略合作伙伴卓普雲 AI Droplet。

1. 在 Web 控制枱裏

apt install python3.10-venv
v pip install 'triton-kernels @ git+https://github.com/triton-lang/triton.git@v3.5.0#subdirectory=python/triton_kernels'  vllm --extra-index-url https://wheels.vllm.ai/nightly --prerelease=allow

啓動服務:

SAFETENSORS_FAST_GPU=1 vllm serve \
    MiniMaxAI/MiniMax-M2 --trust-remote-code \
    --tensor-parallel-size 4 \
    --enable-auto-tool-choice --tool-call-parser minimax_m2 \
    --reasoning-parser minimax_m2_append_think

安裝 vllm 和 fla-core

pip install vllm fla-core

然後我們發送一段請求。

curl http://localhost:8000/v1/chat/completions \
  -H "Content-Type: application/json" \
  -d '{
    "model": "MiniMaxAI/MiniMax-M2",
    "messages": [
      {"role": "system", "content": [{"type": "text", "text": "You are a helpful assistant."}]},
      {"role": "user", "content": [{"type": "text", "text": "Who won the world series in 2020?"}]}
    ]
  }'

我們在 Web 控制枱裏看到了模型的輸出。


我們看下模型給我們輸出了什麼:

"content": "<think>Okay, the user is asking who won the World Series in 2020. Let me start by recalling the correct information. The Los Angeles Dodgers defeated the Tampa Bay Rays. That was a significant event because it was during the pandemic, so the season had unique adjustments.</think>The user might be a baseball fan wanting a quick fact, or perhaps someone who has heard about the series and wants confirmation. They didn't mention any specific context, so keeping it straightforward is best. But maybe they're interested in the historical aspect of that win, especially since it was the Dodgers' first title since 1988. Including that detail adds value.I should also note the unusual circumstances of the 2020 season. The COVID-19 pandemic affected everything, with shortened seasons, limited crowds, and other changes. Mentioning these factors could address deeper curiosity about how the event stood out. However, since the user didn't ask for that, I should balance conciseness with relevant context.\\n\\nThe user possibly a casual viewer looking for a quick answer? Or a student working on a project? They might need the answer for trivia or an assignment. Either way, providing the teams and the year, along with the significance of the Dodgers' win, covers the essentials without overcomplicating. No need for excessive details unless they follow up. Keeping the response clear and accurate is key here.\\n\\n<|im-start|>The **Los Angeles Dodgers** won the **2020 World Series**. \\n\\nThey defeated the **Tampa Bay Rays** in 6 games (4-2). This was the Dodgers' first World Series championship since 1988. The 2020 World Series was held in Arlington, Texas, at Globe Life Field (the neutral site) due to the COVID-19 pandemic and its impact on the MLB season. \\n\\nThe decisive game was game 6, played on October 27, 2020, where the Dodgers won 3-1.<|im-end|>"

這段輸出展示了 MiniMax-M2 的核心特性:

  • 交錯思考格式:使用 <think> 標籤將內部推理與最終答案分開。
  • 高質量輸出:給出準確、簡潔且格式規範的答案,既包含關鍵事實(道奇擊敗光芒),也補充了相關背景(疫情環境、中立球場、歷史意義),體現了前沿級別的事實檢索與總結能力。

如果你正在構建智能體系統、編程工具,或者任何既需要高智能又追求高效率的應用,不妨試用一下這個模型。

6. 常見問題

Q:MiniMax-M2 是什麼?

A:總參 230 B 的 MoE 模型,專為代碼與 Agent 場景設計,每 token 僅激活 10 B,兼顧性能與成本。

Q:支持工具調用嗎?

A:支持。採用“工具優先”設計,可自動判斷何時調用外部工具。

Q:什麼是“交錯思考”?

A:模型用 <think>…</think> 把中間推理與最終答案分開,方便多輪對話中保持連貫的邏輯鏈。

Q:有哪些 Agent 基準表現?

A:在 Terminal-Bench 得 46.3 %,在 BrowseComp 得 44 %,超過很多更大的通用模型。

user avatar
0 位用戶收藏了這個故事!

發佈 評論

Some HTML is okay.