@aiwayds/pi-bailian-token-plan
阿里云百炼 Token Plan 扩展 - 支持千问、DeepSeek、GLM 等模型
Package details
Install @aiwayds/pi-bailian-token-plan from npm and Pi will load the resources declared by the package manifest.
$ pi install npm:@aiwayds/pi-bailian-token-plan- Package
@aiwayds/pi-bailian-token-plan- Version
1.1.2- Published
- Aug 28, 2026
- Downloads
- 441/mo · 43/wk
- Author
- aiwayds
- License
- MIT
- Types
- extension
- Size
- 7.3 KB
- Dependencies
- 0 dependencies · 1 peer
Pi manifest JSON
{
"extensions": [
"./index.ts"
]
}Security note
Pi packages can execute code and influence agent behavior. Review the source before installing third-party packages.
README
Pi 百炼 Token Plan 扩展
为 Pi 添加阿里云百炼 Token Plan 的 AI 模型支持。
可用模型
| 模型 | 上下文 | 最大输出 | 推理 | 视觉 |
|---|---|---|---|---|
| qwen3.8-max-preview | 1M | 65,536 | ✅ | ✅ |
| qwen3.8-max | 1M | 65,536 | ✅ | ✅ |
| qwen3.7-plus | 1M | 65,536 | ✅ | ✅ |
| qwen3.7-max | 262K | 65,536 | ✅ | ❌ |
| qwen3.6-flash | 1M | 65,536 | ✅ | ✅ |
| deepseek-v4-flash-0731 | 1M | 65,536 | ✅ | ❌ |
| deepseek-v4-pro | 262K | 65,536 | ✅ | ❌ |
| glm-5.2 | 202K | 16,384 | ✅ | ❌ |
安装
使用 pi 从 GitHub 安装:
pi install https://github.com/fan56/pi-bailian-token-plan
安装后扩展会位于 ~/.pi/agent/extensions/pi-bailian-token-plan/ 目录。
使用方法
启动 Pi:
pi登录:
- 在 Pi 中输入
/login - 选择 “bailian-tp” 提供商
- 输入你的 百炼 Token Plan API 密钥(以
sk-开头)
- 在 Pi 中输入
选择模型:
- 使用
/model命令选择模型 - 或使用
Ctrl+P循环切换模型
- 使用
API 密钥获取
访问 阿里云百炼控制台 - Token Plan 获取 API 密钥。
注意事项
- Token Plan 是订阅制服务,不按 tokens 计费
- API 密钥以
sk-开头 - Base URL:
https://token-plan.cn-beijing.maas.aliyuncs.com/compatible-mode/v1
支持的功能
- ✅ 文本生成
- ✅ 推理模型(支持扩展思考)
- ✅ 视觉理解(部分模型)
许可证
MIT License