Source: https://aiprimetech.io/zh/docs/guides/aider/ [首页](/zh/) / [文档](/zh/docs/) / Aider # Aider 使用任一种通信格式,将终端结对编程工具连接到网关。 复制页面 [ 以 Markdown 查看](/zh/docs/guides/aider.md) [ 向 ChatGPT 提问](https://chatgpt.com/?q=Read%20https%3A//aiprimetech.io/docs/guides/aider.md%20and%20answer%20questions%20about%20it.%20Start%20with%20a%20short%20summary.) [ 在 Claude 中提问](https://claude.ai/new?q=Read%20https%3A//aiprimetech.io/docs/guides/aider.md%20and%20answer%20questions%20about%20it.%20Start%20with%20a%20short%20summary.) Aider 通过 LiteLLM 路由模型调用,因此支持两种格式,具体取决于您如何命名模型。 ## OpenAI 兼容路由 ``` Copyexport OPENAI_API_BASE="https://aiprimetech.io/v1" export OPENAI_API_KEY="sk-your-key" aider --model openai/claude-sonnet-4-6 ``` ## Anthropic 路由 ``` Copyexport ANTHROPIC_API_BASE="https://aiprimetech.io" export ANTHROPIC_API_KEY="sk-your-key" aider --model anthropic/claude-sonnet-4-6 ``` 该 openai/ 或 anthropic/ 前缀用于告知 LiteLLM 使用哪种格式。如果前缀有误,请求会发送到与请求体不匹配的端点,您将看到 404。 ## 推荐参数 ``` Copy"c"># a cheaper model for commit messages and summaries aider --model anthropic/claude-sonnet-4-6 \ --weak-model anthropic/claude-haiku-4-5 ``` Aider 会频繁发起小型辅助调用。将这些调用发送给 Haiku 而非主模型,可以在长时间会话中显著节省费用,同时不影响质量。 [模型ID 与价格](/zh/docs/getting-started/models/)[费用控制按任务路由](/zh/docs/guides/cost-control/) [上一页Cline](/zh/docs/guides/cline/)[下一页Zed](/zh/docs/guides/zed/)