QwenLM / qwen-code
本文为原文前 6,000 字符的节选翻译,完整内容请查看原文。
The open-source AI coding agent for your terminal, editor, desktop, browser, and chat. 中文 | Deutsch | français | 日本語 | Русский | Português (Brasil) | 한국어 Qwen Code 1.0 Preview Qwen Code 1.0 Preview brings together the agent harness capabilities of Qoder and Qwen Code in an open-source release.Try Qwen Code 1.0 Preview · Documentation · 中文文档.
适用于您的终端、编辑器、桌面、浏览器和聊天的开源 AI 编码代理。中文 | Deutsch | français | 日本語 | Русский | Português (Brasil) | 한국어 Qwen Code 1.0 预览版。Qwen Code 1.0 预览版将 Qoder 和 Qwen Code 的代理工具功能整合到了一个开源版本中。尝试 Qwen Code 1.0 预览版 · 文档 · 中文文档。
Why Qwen Code? Agentic out of the box — Auto-Memory, Auto-Skills, SubAgents, Agent Teams, and MCP. Dynamic workflows, zero setup. Open-source, inside and out — The framework and the Qwen models are open-source. They evolve together. No vendor lock-in. Multi-protocol — Supports OpenAI, Anthropic, Gemini, and Qwen APIs. Any third-party provider or local model (Ollama / vLLM). Switch at runtime. Beyond the terminal — IDE plugins, Desktop app, Web UI, SDKs, and chat integrations (Telegram / DingTalk / WeChat / Feishu).
为什么选择 Qwen Code?开箱即用的代理能力——自动记忆、自动技能、子代理、代理团队和 MCP。动态工作流,零配置。由内而外的开源——框架和 Qwen 模型均为开源,共同演进,无供应商锁定。多协议支持——支持 OpenAI、Anthropic、Gemini 和 Qwen API,以及任何第三方提供商或本地模型(Ollama / vLLM),支持运行时切换。超越终端——提供 IDE 插件、桌面应用、Web UI、SDK 以及聊天集成(Telegram / 钉钉 / 微信 / 飞书)。
TipQwen Code is actively iterating on itself — using its own agent and models to file issues, submit PRs, review code, and run tests. Powered by the community, driven by AI. Installation Looking for Qwen Code 1.0 Preview? Get started here. The instructions below are for the main version. Linux / macOS: curl -fsSL https://qwen-code-assets.oss-cn-hangzhou.aliyuncs.com/installation/install-qwen-standalone.sh | bash Windows: irm https://qwen-code-assets.oss-cn-hangzhou.aliyuncs.com/installation/install-qwen-standalone.ps1 | iex Restart your terminal after installation to ensure environment variables take effect.
提示:Qwen Code 正在积极自我迭代——使用其自身的代理和模型来提交 Issue、提交 PR、审查代码并运行测试。由社区驱动,由 AI 驱动。安装:正在寻找 Qwen Code 1.0 预览版?请从这里开始。以下说明适用于主版本。Linux / macOS: curl -fsSL https://qwen-code-assets.oss-cn-hangzhou.aliyuncs.com/installation/install-qwen-standalone.sh | bash Windows: irm https://qwen-code-assets.oss-cn-hangzhou.aliyuncs.com/installation/install-qwen-standalone.ps1 | iex 安装后请重启终端以确保环境变量生效。
NPM / Homebrew NPM (requires Node.js 22+): npm install -g @qwen-code/qwen-code@latest Homebrew (macOS / Linux): brew install qwen-code Quick Start Open a terminal in your project and start Qwen Code: cd /path/to/your-project qwen Inside the session, run /auth and choose Qwen Account with Subscription to sign in with your Plus or Pro subscription, or configure a provider with an API key. Then try: Explain this repository and show me where to start. See the Authentication Guide and Settings Reference for detailed setup. See the terminal interface
NPM / Homebrew:NPM(需要 Node.js 22+):npm install -g @qwen-code/qwen-code@latest Homebrew (macOS / Linux):brew install qwen-code。快速开始:在您的项目目录中打开终端并启动 Qwen Code:cd /path/to/your-project qwen。在会话中,运行 /auth 并选择“Qwen Account with Subscription”以使用您的 Plus 或 Pro 订阅登录,或者配置带有 API 密钥的提供商。然后尝试:Explain this repository and show me where to start(解释此仓库并告诉我从哪里开始)。详细设置请参阅身份验证指南和设置参考。查看终端界面。
How to Use Qwen Code Choose the interface that fits your workflow: Interface Get started Terminal Run qwen in your project — see Quick Start. Desktop Download Qwen Code Desktop for macOS, Windows, and Linux. Web Run qwen serve —open to open the Web UI in your browser. (experimental) Editor Set up VS Code, Zed, or JetBrains. Chat Connect Telegram, DingTalk, WeChat, or Feishu, then run qwen channel start.
如何使用 Qwen Code:选择适合您工作流的界面:界面:开始使用。终端:在您的项目中运行 qwen——请参阅快速开始。桌面:下载适用于 macOS、Windows 和 Linux 的 Qwen Code 桌面版。Web:运行 qwen serve —open 以在浏览器中打开 Web UI(实验性)。编辑器:设置 VS Code、Zed 或 JetBrains。聊天:连接 Telegram、钉钉、微信或飞书,然后运行 qwen channel start。
For automation and custom integrations: Headless — Run qwen -p ”…” in scripts, CI/CD, or batch jobs. SDKs — Build with TypeScript, Python, or Java. Daemon — Run qwen serve to connect clients over HTTP + SSE (ACP). (experimental) Daemon guide. Computer Use — Set up native MCP tools or Node REPL + SDK in Qwen Code, Claude Code, or Codex. SDK example (Python) import asyncio from qwen_code_sdk import is_sdk_result_message, query async def main() -> None: result = query( “Summarize the repository layout.”, { “cwd”: “/path/to/project”, “path_to_qwen_executable”: “qwen”, }, ) async for message in result: if is_sdk_result_message(message): print(message[“result”]) asyncio.run(main())
针对自动化和自定义集成:Headless(无头模式)——在脚本、CI/CD 或批处理作业中运行 qwen -p ”…”。SDK——使用 TypeScript、Python 或 Java 进行构建。守护进程——运行 qwen serve 以通过 HTTP + SSE (ACP) 连接客户端(实验性)。守护进程指南。计算机使用——在 Qwen Code、Claude Code 或 Codex 中设置原生 MCP 工具或 Node REPL + SDK。SDK 示例(Python):import asyncio from qwen_code_sdk import is_sdk_result_message, query async def main() -> None: result = query( “Summarize the repository layout.”, { “cwd”: “/path/to/project”, “path_to_qwen_executable”: “qwen”, }, ) async for message in result: if is_sdk_result_message(message): print(message[“result”]) asyncio.run(main())
Daemon Mode Run Qwen Code as a long-lived service when you want browser, editor, SDK, and automation clients to share agent sessions without each starting a separate process. The daemon provides the built-in Web Shell and an HTTP + SSE API, supports multiple workspaces, and lets clients reconnect to active sessions. Start it in the foreground and open the Web Shell: qwen serve —open The default address is http://127.0.0.1:4170. To run and manage it in the background instead: qwen daemon start qwen daemon status qwen daemon logs -f qwen daemon stop
守护进程模式:当您希望浏览器、编辑器、SDK 和自动化客户端共享代理会话而无需各自启动独立进程时,可将 Qwen Code 作为长期运行的服务运行。该守护进程提供内置的 Web Shell 和 HTTP + SSE API,支持多个工作区,并允许客户端重新连接到活动会话。在前台启动并打开 Web Shell:qwen serve —open。默认地址为 http://127.0.0.1:4170。若要在后台运行和管理:qwen daemon start, qwen daemon status, qwen daemon logs -f, qwen daemon stop。
By default, the daemon listens on loopback without bearer authentication; any local process that can reach it can use the full API, including code execution. On shared or untrusted hosts, set QWEN_SERVER_TOKEN and use —require-auth. See the Daemon guide for workspaces, authentication, remote access, and the API.
默认情况下,守护进程在回环地址上监听且无需 Bearer 身份验证;任何可以访问它的本地进程都可以使用完整 API,包括代码执行。在共享或不受信任的主机上,请设置 QWEN_SERVER_TOKEN 并使用 —require-auth。有关工作区、身份验证、远程访问和 API 的详细信息,请参阅守护进程指南。
Capabilities If you know Claude Code, you already know Qwen Code — and then some. We’ve put significant effort into bringing Qwen Code to feature parity with Claude Code, improving both breadth and reliability across the board. Feature Qwen Code Claude Code SubAgents, Agent Teams, Dynamic Workflows ✓ ✓ Auto-Memory, Auto-Skills, Hooks ✓ ✓ Built-in Skills (/review, /batch, /loop, /bugfix…) ✓ ✓ MCP, Plan Mode, LSP Integration ✓ ✓ Auto Mode, Sandbox, Git Worktrees ✓ ✓ Computer Use (desktop automation) ✓ ✓ IDE Plugins (VS Code / JetBrains / Zed) ✓ ✓ SDK ✓ ✓ Headless Mode, Session Management ✓ ✓ Open-source — model and framework ✓ — Multi-protocol (OpenAI / Anthropic / Gemini / Qwen + any provider) ✓ — Agent Arena (multi-model head-to-head on same task) ✓ — Daemon Mode — qwen serve (multi-client shared agent) ✓ — IM Channels (Telegram / DingTalk / WeChat / Feishu) ✓ —
功能:如果您了解 Claude Code,那么您也就了解 Qwen Code——甚至更多。我们投入了大量精力使 Qwen Code 在功能上与 Claude Code 对齐,并在广度和可靠性上进行了全面提升。功能对比表:SubAgents、代理团队、动态工作流(✓ ✓);自动记忆、自动技能、Hooks(✓ ✓);内置技能(/review, /batch, /loop, /bugfix…)(✓ ✓);MCP、计划模式、LSP 集成(✓ ✓);自动模式、沙箱、Git 工作树(✓ ✓);计算机使用(桌面自动化)(✓ ✓);IDE 插件(VS Code / JetBrains / Zed)(✓ ✓);SDK(✓ ✓);Headless 模式、会话管理(✓ ✓);开源——模型和框架(✓ —);多协议(OpenAI / Anthropic / Gemini / Qwen + 任何提供商)(✓ —);代理竞技场(同一任务的多模型对决)(✓ —);守护进程模式——qwen serve(多客户端共享代理)(✓ —);即时通讯频道(Telegram / 钉钉 / 微信 / 飞书)(✓ —)。
Qwen Code Evaluation On SWE-bench Verified, seven Qwen Code versions scored 76.40%–77.80% on average using the same Qwen 3.7 Max model (500 tasks, three trials per version). Full results and evaluation configuration →
Qwen Code 评估:在 SWE-bench Verified 上,七个 Qwen Code 版本在使用相同的 Qwen 3.7 Max 模型(500 个任务,每个版本三次试验)的情况下,平均得分在 76.40%–77.80% 之间。完整结果和评估配置 →
Ecosystem Qwen Code Desktop — Official desktop app for macOS, Windows, and Linux AionUi — A modern GUI for command-line AI tools including Qwen Code Gemini CLI Desktop — A cross-platform desktop/web/mobile UI for Qwen Code qwen-audio-agent — Realtime full-duplex voice frontend for Qwen Code over ACP — talk hands-free with barge-in and a local wake word 🦞 Qwen Code Claw — Let other agents (Claude, Codex, etc.) delegate coding tasks to Qwen Code via ACP. Paste this prompt into your agent: Use Qwen Code as a coding agent. First, fetch and read this skill reference: https://raw.githubusercontent.com/QwenLM/qwen-code/refs/heads/main/.qwen/skills/qwen-code-claw/SKILL.md Then follow the instructions inside to install, authenticate, and use Qwen Code via acpx for all coding tasks. Aliyun Model Studio CLI — Official CLI for Aliyun’s AI platform (bailian-cli). Extends Qwen Code with image/video generation,
生态系统:Qwen Code Desktop——适用于 macOS、Windows 和 Linux 的官方桌面应用;AionUi——用于包括 Qwen Code 在内的命令行 AI 工具的现代 GUI;Gemini CLI Desktop——用于 Qwen Code 的跨平台桌面/Web/移动端 UI;qwen-audio-agent——通过 ACP 为 Qwen Code 提供的实时全双工语音前端——支持免提通话、打断和本地唤醒词;🦞 Qwen Code Claw——让其他代理(Claude、Codex 等)通过 ACP 将编码任务委托给 Qwen Code。将此提示词粘贴到您的代理中:Use Qwen Code as a coding agent. First, fetch and read this skill reference: [URL] Then follow the instructions inside to install, authenticate, and use Qwen Code via acpx for all coding tasks. Aliyun Model Studio CLI——阿里云 AI 平台的官方 CLI (bailian-cli),通过图像/视频生成扩展了 Qwen Code。