集成
快速配置你常用的 AI 编程工具——从 CLI 编程代理到 IDE 插件,几步即可接入 WisGate 模型。
Junie CLI
JetBrains Agentic 编程命令行工具,通过 OpenAI 兼容接口接入 WisGate。
Junie CLI
Junie CLI 是 JetBrains 提供的 agentic 编程命令行工具,支持 BYOK 和自定义模型 Profile。通过自定义 LLM Profile,可以把 Junie CLI 接入 WisGate 的 OpenAI 兼容接口。
一、安装 Junie CLI
Linux / macOS 可使用安装脚本:
curl -fsSL https://junie.jetbrains.com/install.sh | bash
验证安装:
junie --version
二、创建 WisGate 自定义模型 Profile
Junie CLI 会从 $JUNIE_HOME/models/*.json 或项目内 .junie/models/*.json 读取自定义模型。若未设置 JUNIE_HOME,可使用默认用户目录 ~/.junie:
mkdir -p ~/.junie/models
新增 ~/.junie/models/wisgate.json:
{
"id": "gpt-5.5",
"baseUrl": "https://api.wisgate.cn/v1/chat/completions",
"apiType": "OpenAICompletion",
"apiKey": "your_wisgate_api_key",
"temperature": 0.7,
"fasterModel": {
"id": "gpt-4.7"
}
}
如果需要在项目中共享模型配置,请把 profile 放到 .junie/models/wisgate.json,但不要把真实 API Key 提交到代码仓库。
三、启动 Junie
进入项目目录并指定模型:
cd /path/to/your/project
junie --model wisgate
也可以先启动 Junie,在会话中使用 /model 查看并切换模型。
使用场景
- 交互式编码:在终端中让 Junie 审查、编写和修改代码。
- 文件上下文:使用
@附加文件或目录,让模型读取指定上下文。 - 自动化审查:在 headless 模式中执行代码质量检查和修复建议。
- 团队 Profile:把不含密钥的
.junie/models/wisgate.json作为团队模板。
常见问题
Junie 没有发现自定义模型
请确认 JSON 文件位于 ~/.junie/models/、$JUNIE_HOME/models/ 或 .junie/models/,并确认文件名和 --model 参数一致。
请求失败
请确认 baseUrl 使用完整 Chat Completions 地址 https://api.wisgate.cn/v1/chat/completions,apiType 为 OpenAICompletion,API Key 正确。