> ## Documentation Index
> Fetch the complete documentation index at: https://platform.minimaxi.com/docs/llms.txt
> Use this file to discover all available pages before exploring further.

# Pi

> 在 Pi 中使用最新的 MiniMax M 系列模型。

[**Pi**](https://github.com/earendil-works/pi) 是 earendil-works 出品的开源终端编程 Agent，通过统一 LLM API 接入任意服务商。

## 配置 MiniMax

> [tab] 方式一：一键配置向导
>
> Pi 的自动安装要求 Node.js 22.19 或更高版本。直接运行：
>
> ```bash theme={null}
> npx -y mmx-cli@latest agent setup
> ```
>
> 在工具列表中选择 **Pi**。如果尚未安装，在第二个多选列表中保留 Pi。向导会安装官方 npm 包、检查版本，并把 MiniMax 模型写入 Pi 的模型和默认设置。
>
> 完成后直接运行：
>
> ```bash theme={null}
> pi
> ```

> [tab] 方式二：手动配置
>
> **1. 安装 Pi**
>
> ```bash theme={null}
> npm install -g @earendil-works/pi-coding-agent
> ```
>
> **2. 设环境变量并启动**
>
> 把 [订阅 Key](https://platform.minimax.cn/console/plan)（前缀 `sk-cp-…`）设到环境变量后启动 Pi：
>
> ```bash theme={null}
> export MINIMAX_CN_API_KEY=sk-cp-...
> pi --provider minimax-cn --model MiniMax-M3.1-Flash
> ```
