qwen-code

What does it do?

Qwen Code is described as an open-source AI coding agent for terminals, editors, desktops, browsers, and chat. [1a][1b] Its README quick start shows opening a terminal in a project, starting Qwen Code, and asking it to explain the repository and show where to start. [2]

Currently trending because

  • A Qwen Code pull request appears to leak unreleased Qwen4 model IDs—qwen4-max, qwen4-coder-plus and qwen4-omni-120b—all resolving to a 262,144-token context. [1]

Activity, over time

Daily observations from the public event archive.

Attention

Daily stars & forks

Loading attention chart

Star accumulation

Cumulative stars

Loading star accumulation chart

Pull requests

Daily opens & merges

Loading pull requests chart

Conversations

Daily issues & comments

Loading conversations chart

Community

Daily accounts & reviews

Loading community chart

Releases

Daily releases

Loading releases chart

Mentions

57posts · 30d
Nov 35 posts
  1. Reddit · · r/LocalLLaMA · u/feelspeaceman

    Alibaba's Qwen Code repo just leaked qwen4-max, qwen4-coder-plus, and qwen4-omni-120b PRs: 1. qwen-code#15762 "Measured on main at 79a9b753c60, before this change: qwen4, qwen4-max, qwen4-plus, qwen4.5-max, qwen4-coder-plus, qwen4-max-2026-10-01, openai/qwen4-max and qwen4-omni-120b-think all resolved to 262,144. The last of those is already in use as the session model in the omni fixtures, so these ids are not hypothetical." 2. qwen-code#15987 Thank god, it looks like that we're getting successor of Q38FN!

    585 points · 93 comments
  2. DEV · · @adam_z

    Is Qwen Code Really Free? A Practical Setup and Pricing Guide (2026) Qwen Code is an open-source AI coding agent that can inspect repositories, edit files, execute commands, and connect to different AI model providers. But there's a question that often causes confusion: Is Qwen Code actually free, or do you need to pay for an API key? The short answer: the client is free, but the AI models you connect to it may not be. And if you're following an older tutorial that recommends signing in with Qwen OAuth for free usage, that advice is now outdated. Here's how Qwen Code works in 2026 and how to set it up without choosing the wrong authentication or billing method. 1. What is free, and what costs money? Qwen Code itself is an open-source application licensed under Apache 2.0. You can install the client without purchasing a software license. However, the client still needs access to an AI model. There are several ways to provide that access: | Connection | How billing generally works | |---|---| | QwenCloud Token Plan | Subscription with a monthly credit quota | | QwenCloud Standard API Key | Pay-as-you-go API usage | | Alibaba ModelStudio Coding Plan | Subscription with an included usage quota | | Alibaba ModelStudio Token Plan | Usage-based billing through a dedicated endpoint | | Alibaba ModelStudio Standard API Key | Pay-as-you-go API usage | | Third-party model provider | Depends on that provider's pricing | | Self-hosted local model | No hosted inference charge, but requires your own hardware | This distinction matters. Installing a free coding agent does not automatically give you unlimited free access to the models it uses. Also, QwenCloud Token Plan and Alibaba ModelStudio Token Plan are separate offerings. Do not assume that a key or subscription for one automatically works with the other. 2. Install Qwen Code For an npm installation, first check that you have Node.js 22 or later. node --version Then install Qwen Code: npm install -g @qwen-code/qwen-code@latest On macOS or Linux, Homebrew is another documented installation option: brew install qwen-code Navigate to a project directory and launch the client: cd your-project qwen The first launch will guide you through provider authentication. Official installation guide: Qwen Code Quickstart. 3. Choose the right authentication method Inside the running Qwen Code interface, enter: /auth You'll be able to choose from supported connection types. Option A: QwenCloud This is a straightforward option if you want to use QwenCloud directly. You can choose between: - Token Plan: a subscription with a monthly credit quota. - Standard API Key: pay for API usage based on the provider's pricing. Select the correct regional platform and enter the key issued for that service. Option B: Alibaba ModelStudio Alibaba ModelStudio provides several choices, including Coding Plan, Token Plan, and Standard API Key. These offerings differ in their intended users, quotas, billing rules, and endpoints. For example, Coding Plan is oriented toward individual developers with an included usage quota. Token Plan uses a separate usage-based endpoint. Choose the specific offering that matches your account and API key. Option C: Third-party providers Qwen Code can also connect to supported third-party model providers. This can make sense if you already have an API account elsewhere or want more flexibility over which model you use. You should verify the provider's supported models, usage terms, and pricing before connecting. Option D: Custom or local provider Qwen Code supports custom model connections, including compatible locally hosted model servers. For example, a local inference server exposing an OpenAI-compatible endpoint may be configured as a model provider. This can avoid hosted-model API charges, but it doesn't guarantee every tool or feature works entirely offline. 4. Important: the old free Qwen OAuth option is gone This is one of the biggest changes to watch out for. The previous Qwen OAuth free tier was discontinued on April 15, 2026. As a result, some older installation videos and blog posts may describe a sign-in path that is no longer available for normal use. If an old tutorial tells you to rely on free Qwen OAuth access, check the current official documentation instead. The current recommended workflow is to launch qwen and configure an available provider through /auth. Also note that the old standalone qwen auth CLI command has been removed in the current documentation. The interactive /auth command is entered inside Qwen Code, not directly in your shell. Official reference: Qwen Code Authentication. 5. Check your connection and select a model Once authentication is complete, you can use these commands inside Qwen Code: /doctor Check your environment and authentication configuration. /model Choose from the models available through your configured providers. /help Show the currently available commands. Before running an expensive repository-wide task, try a small request first. For example: > Inspect this repository and explain its main modules. Do not modify any files. Then verify that the selected model responds correctly and that the provider's usage is being recorded as expected. Never commit your API keys to a Git repository. 6. Which setup should you choose? Here's a practical way to decide: You already pay for an API provider: Check whether Qwen Code supports that provider and whether your existing credentials are eligible. You want predictable usage within an included quota: Compare the current subscription and quota terms of the relevant QwenCloud or Alibaba ModelStudio plan. You prefer usage-based billing: Choose an appropriate Standard API Key or usage-based provider connection. You want to run models locally: Check your available hardware, local inference server, model compatibility, and offline requirements. There isn't one universally cheapest option. The total cost depends on the model, workload, quota, cache behavior, and provider terms. 7. A final recommendation Before committing to a paid plan, do three things: 1. Confirm that your intended model is supported by your chosen provider. 2. Run a small real coding task and inspect the result. 3. Check the provider's billing dashboard or quota usage. A free client is useful, but the right model connection determines much of the actual experience and cost. For a source-backed overview of Qwen Code, including its model and API relationships, I've also put together a reference page on iilib — Qwen Code. Official references - Qwen Code Quickstart - Qwen Code Authentication - Qwen Code Model Providers Documentation reviewed: November 2026. Model availability, authentication options and pricing may change. Which provider are you using with Qwen Code, and what has your setup experience been like?

  3. 编程 agent 换个地方就得换工具,模型还绑死? Qwen Code 是终端开源 AI 编程 agent:OpenAI、Anthropic、Gemini、Qwen 都能接,本地 Ollama/vLLM 也行。 适合不想被单一模型绑住的人,先从终端试起。 你会先在哪用,终端还是编辑器? #AI编程 #开源 @grok QwenLM/qwen-code

    13 likes · 388 views
  4. Qwen Code's Multi-Protocol Agent Runtime: How One Terminal Agent Switches Between OpenAI, Anthropic, and Local Models at Runtime Qwen Code is a terminal-based AI coding agent that lets you switch between OpenAI, Anthropic, Gemini, Qwen APIs, and local models (Ollama, vLLM) without rewriting tool definitions or restarting the session. It ships with Auto-Memory, Auto-Skills, SubAgents, Agent Teams, and MCP support. The project has 28.8K stars and is trending #9 on GitHub for TypeScript. The team uses the agent to file issues, submit PRs, and review code on its own repository. The interesting plumbing is how it maintains state and context when you swap providers mid-conversation, and how the same tool definitions work across OpenAI function calling, Anthropic tool use, and local model APIs that may not support structured outputs. Architecture: Provider Abstraction and Tool Normalization Qwen Code uses a provider abstraction layer that normalizes tool definitions and response formats across different LLM APIs. The agent does not call OpenAI or Anthropic directly. Instead, it routes requests through a unified interface that translates tool schemas and response payloads. Key components: - Provider registry: Maps provider names (openai, anthropic, gemini, qwen, ollama, vllm) to adapter classes. - Tool schema normalizer: Converts internal tool definitions to OpenAI function calling, Anthropic tool use, or plain JSON schemas for local models. - Response parser: Extracts tool calls from different response formats (OpenAI's tool_calls, Anthropic's content blocks, or regex-parsed JSON from local models). - State manager: Persists conversation history, tool results, and memory entries in a local SQLite database or JSON file. When you switch providers, the agent re-serializes the conversation history into the new provider's format. OpenAI and Anthropic use different message structures for tool calls, so the adapter rewrites the history array before sending the next request. Tool Call Flow Across Providers Here's how a single tool definition flows through different providers: | Provider | Tool Schema Format | Tool Call Extraction | Fallback Behavior | |------------|-------------------------------|------------------------------------------|--------------------------------------------| | OpenAI | functions or tools array | Parse tool_calls from response | Retry with plain JSON if model lacks tools | | Anthropic | tools array | Parse content blocks with tool_use | Retry with plain JSON if model lacks tools | | Gemini | function_declarations | Parse functionCall from response | Retry with plain JSON if model lacks tools | | Qwen API | tools array (OpenAI-like) | Parse tool_calls from response | Retry with plain JSON if model lacks tools | | Ollama | Plain JSON in system prompt | Regex parse JSON from text response | No fallback, fails if JSON is malformed | | vLLM | Plain JSON in system prompt | Regex parse JSON from text response | No fallback, fails if JSON is malformed | For local models, the agent injects a system prompt that describes available tools as JSON schemas and instructs the model to return tool calls in a specific format. The response parser uses regex to extract JSON blocks. If the model returns malformed JSON, the agent retries once with a clarification prompt. Auto-Memory and Auto-Skills: Persistence and Skill Generation Auto-Memory persists conversation history, tool results, and user preferences in a local SQLite database. Each session has a unique ID. When you switch providers, the agent loads the session history and re-serializes it for the new provider. Memory entries include: - Raw message arrays (user, assistant, tool) - Tool call metadata (function name, arguments, result) - User preferences (preferred provider, temperature, max tokens) Auto-Skills generates new tool definitions at runtime based on repeated patterns. If the agent detects that you ask for the same multi-step workflow three times, it proposes a new skill. The skill is stored as a JSON file in ~/.qwen-code/skills/ and registered in the tool schema normalizer. The next time you invoke that workflow, the agent calls the skill directly instead of re-planning. Skill generation uses a separate LLM call with a prompt that includes the conversation history and asks the model to extract a reusable function signature. The agent validates the generated schema and tests it once before persisting. SubAgents and Agent Teams: Nested Orchestration SubAgents are child agent instances that run in isolated contexts. The parent agent spawns a SubAgent by calling a special tool (spawn_subagent) with a task description and optional provider override. The SubAgent runs its own conversation loop and returns a final result to the parent. Agent Teams are collections of SubAgents with different roles (planner, coder, reviewer). The parent agent routes tasks to the appropriate SubAgent based on a role classifier. The classifier is a small local model (Qwen2.5-0.5B) that runs inference in under 50ms. If the classifier is unavailable, the agent falls back to keyword matching. SubAgents share the same tool registry as the parent but maintain separate conversation histories. If a SubAgent switches providers, it does not affect the parent's provider state. MCP Support: External Tool Integration Qwen Code supports the Model Context Protocol (MCP) for integrating external tools. MCP servers expose tools as JSON-RPC endpoints. The agent discovers available tools by calling the server's tools/list method and registers them in the tool schema normalizer. When the agent invokes an MCP tool, it sends a JSON-RPC request to the server and waits for the response. The response is appended to the conversation history as a tool result. MCP tools can be stateful (the server maintains state between calls) or stateless. The agent does not validate MCP tool schemas. If the server returns a malformed response, the agent logs the error and continues. This can cause the agent to hallucinate tool results. Security Boundaries: Sandboxing and Credential Management Qwen Code runs tool calls in a sandboxed subprocess. The sandbox uses Node.js's vm module to isolate tool execution. File system access is restricted to the current working directory. Network access is unrestricted. Credential management: - API keys are stored in ~/.qwen-code/config.json or environment variables. - The agent does not send API keys to SubAgents or MCP servers. - If a tool requires credentials (e.g., GitHub API), the user must configure them manually. The sandbox does not prevent tools from spawning child processes or making network requests. A malicious tool can exfiltrate data or execute arbitrary code. The agent logs all tool calls and results, but does not block suspicious behavior. Observability: Logging and Debugging The agent logs all LLM requests, tool calls, and state transitions to ~/.qwen-code/logs/. Logs are structured JSON with timestamps, session IDs, and provider names. You can tail the log file to watch the agent's decision-making in real time. Debugging flags: - --debug: Enables verbose logging (includes full request/response payloads). - --trace: Enables trace-level logging (includes internal state changes). - --dry-run: Simulates tool calls without executing them. The agent does not expose metrics or telemetry by default. You can integrate with observability platforms (Datadog, Prometheus) by parsing the log files. Deployment Shape: CLI, Desktop, Web, and Chat Integrations Qwen Code ships as: - CLI: Standalone binary installed via curl script. - Desktop app: Electron wrapper with system tray integration. - Web UI: React app that connects to a local agent server. - IDE plugins: VS Code, Zed, JetBrains extensions. - Chat integrations: Telegram, DingTalk, WeChat, Feishu bots. All deployment shapes share the same agent core. The CLI and desktop app run the agent locally. The web UI and chat integrations connect to a remote agent server via WebSocket. The IDE plugins use language server protocol (LSP) to communicate with the agent. The agent server is a Node.js HTTP server that exposes a REST API for starting sessions, sending messages, and retrieving history. WebSocket connections are used for streaming responses. Failure Modes and Recovery Common failure modes: - Provider rate limits: The agent retries with exponential backoff (max 3 retries). If all retries fail, it prompts the user to switch providers. - Malformed tool calls: The agent retries once with a clarification prompt. If the retry fails, it logs the error and continues without executing the tool. - SubAgent hangs: The parent agent sets a 60-second timeout for SubAgent tasks. If the timeout expires, the parent kills the SubAgent and returns an error. - MCP server unavailable: The agent logs the error and removes the MCP tools from the registry. It does not retry. The agent does not checkpoint state during long-running tasks. If the process crashes, you lose the current session. You can resume from the last persisted message in the SQLite database, but tool results are not replayed. Code Example: Provider Switching Here's how the agent switches providers mid-conversation: // Internal provider adapter interface interface ProviderAdapter { name: string; sendMessage(history: Message[], tools: Tool[]): Promise<Response>; parseToolCalls(response: Response): ToolCall[]; } // Switching providers async function switchProvider( session: Session, newProvider: string ): Promise<void> { const adapter = providerRegistry.get(newProvider); if (!adapter) throw new Error(`Unknown provider: ${newProvider}`); // Re-serialize conversation history for new provider const history = session.history.map(msg => adapter.normalizeMessage(msg) ); // Update session state session.provider = newProvider; session.history = history; await session.save(); } // Example: OpenAI to Anthropic const session = await loadSession('abc123'); await switchProvider(session, 'anthropic'); const response = await session.sendMessage('Refactor this function'); The normalizeMessage method rewrites message objects to match the new provider's schema. OpenAI uses role and content, Anthropic uses role and content arrays with type fields. Technical Verdict Use Qwen Code when: - You need to switch between cloud and local models without rewriting tool definitions. - You want a terminal-based agent that integrates with your existing IDE and chat tools. - You are building agentic workflows that require SubAgents or Agent Teams. - You need MCP support for external tool integration. Avoid Qwen Code when: - You require strong sandboxing or credential isolation (the sandbox is weak). - You need checkpointing or replay for long-running tasks (state is not checkpointed). - You are building a production system that requires telemetry and metrics (observability is limited to log files). - You need guaranteed tool call reliability (local models can return malformed JSON). The multi-protocol abstraction is solid for prototyping and side projects. For production systems, you will need to add checkpointing, stronger sandboxing, and structured observability. Source Links - Qwen Code GitHub Repository

  5. Reddit · · r/LocalLLaMA · u/giveen

    Qwen4! preview.redd.it qwen-code#15762 Notice the 120B model!

    149 points · 51 comments
  6. Reddit · · r/openagi · u/syedshad

    Alibaba previews four Qwen4 models: Max, Flash, Plus and 27B Alibaba previewed four models in its Qwen4 family at the Apsara Conference in Amsterdam on October 29. A presentation slide photographed by attendee John T Davies listed: - Qwen4-Max - Qwen4-Flash - Qwen4-Plus - Qwen4-27B The slide describes the series as “coming soon.” Davies separately reported that Alibaba Cloud CTO Dr. Feifei Li said “Qwen4 next week.” The photographed slide does not specify pricing, licensing terms, benchmark results, or whether all four models will arrive together. sources - Alibaba presentation slide, photographed by John T Davies - QwenLM Github PR

    57 points · 25 comments
  7. Qwen 4 ,预计下周发布。 qwen-code#15762

    3 likes · 553 views
  8. 我觉得 Qwen Code v0.26.3 这次更新,治的是真痛点 工具返回结果按剩余上下文自动收着给,不再撑爆窗口 qwen4 别名默认 100 万 token 上下文,长活儿不用算着省了 省心了 github.com/QwenLM/qwen-code/releases t.co

    3 likes · 362 views
  9. Good news! Qwen4 models will have 1M context 🤩 Except Qwen4-27b, all other models will have 1M token max context. qwen-code#15762 t.co

    376 likes · 20 reposts · 18,579 views
  10. Reddit · · r/Qwen_AI · u/BasketFar667

    Qwen 4 plus, max, plus - coder, omni Officially they will be released on November 1 Models (might be released) Plus, Max, Plus (coder), omni, it can be released sooner, but planned to release first 4 on November now DATA: qwen-code#15762

    255 points · 92 comments

Latest stargazers

The last 10 distinct accounts we observed this year.

Most active participants

PR, issue, comment & review events in the past year.

Packages

15
PackageVersionDownloads · 30dTrend · 30d
docs-sitev0.0.1
v0.0.1
≥17
v1.0.0
≥117
@qwen-code/audio-capturev0.25.3-preview.0
v0.25.3-preview.0
≥107.2K
v0.26.0——
@qwen-code/channel-basev0.25.3-preview.0
v0.25.3-preview.0
≥6K
v0.25.3-preview.0
≥4.9K
@qwen-code/channel-dwsv0.25.3-preview.0
v0.25.3-preview.0
≥2.3K
@qwen-code/channel-feishuv0.25.3-preview.0
v0.25.3-preview.0
≥3K
@qwen-code/channel-githubv0.25.3-preview.0
v0.25.3-preview.0
≥2.4K
@qwen-code/channel-qqbotv0.25.3-preview.0
v0.25.3-preview.0
≥2.4K
v0.25.3-preview.0
≥2.7K
@qwen-code/channel-wecomv0.25.3-preview.0
v0.25.3-preview.0
≥3.1K
@qwen-code/channel-weixinv0.25.3-preview.0
v0.25.3-preview.0
≥2.5K
———
———

README badges

Embed a badge in your README or website.

  • QwenLM/qwen-code reached #7 in daily mentions on gitwal · Oct 29, 2026
  • QwenLM/qwen-code reached #1 in daily stars on gitwal · Jul 23, 2025
  • QwenLM/qwen-code reached #3 in weekly stars on gitwal · Week of Jul 21, 2025
  • QwenLM/qwen-code reached #2 in daily forks on gitwal · Jul 23, 2025
  • QwenLM/qwen-code reached #3 in daily PR authors on gitwal · Jul 26, 2026
Live mentions · last 30 days
QwenLM/qwen-code mentions in the last 30 days