Model or dataset
QwenLM/Qwen-Agent avatar
QwenLM/Qwen-Agent

Qwen-Agent's Python executor is not sandboxed, and the note sits in the news section

Agent framework and applications built upon Qwen>=3.0, featuring Function Calling, MCP, Code Interpreter, RAG, Chrome extension, etc.

17,260 stars1,767 forksPythonApache-2.0

At a glance

What is it?
Qwen-Agent is Alibaba's framework for LLM applications on Qwen models, with function calling, MCP, RAG, a code interpreter, a browser extension and a separate example agent per model. It installs as an extra picker, parses tool calls itself rather than trusting the model's server to do it, and ships a Python executor that is explicitly not sandboxed.
Who is it for?
Qwen-Agent fits a team standardising on Qwen models that wants the tool-calling plumbing in one place and that will read the examples for the model it actually runs. Be careful with anything reachable by untrusted input, because the README states the python executor in its Qwen2.5-Math demo is not sandboxed and is intended for local testing only.
Can I use it commercially?
Yes. Apache-2.0 is a permissive licence: you can use, modify and sell software built on it, as long as you keep its copyright and licence notices.
Is it still maintained?
Activity is slowing. The repository last received commits 8 months ago.
What is it written in?
Mainly Python, according to GitHub's language statistics.

Answers come from the project's GitHub data, last synced on November 13, 2026, and from our analysis. They are not legal advice.

From daily snapshots

Star history

  • QwenLM/Qwen-Agent17,260 ★ · +147
Star history
Repository2026-09-212026-11-13
QwenLM/Qwen-Agent17.1k17.3k

147 Stars in the last 53 days, measured from the daily GitHub snapshot. Compare with other projects

Editorial analysis

The Python executor is not sandboxed, and the note is a news item

One sentence in this repository matters more than the rest of the feature list, and it is easy to miss because of where it sits. It appears in the news section, attached to the September 2024 entry about a maths demo, and it says the python executor is not sandboxed and is intended for local testing only, not for production use. The note is attached to the Qwen2.5-Math Tool-Integrated Reasoning demo, so check how any code execution you enable is isolated before exposing an agent to untrusted input.

For QwQ and Qwen3 you are told to disable the server's tool parser

The model service section contains an instruction that will save you a long debugging session. If you run your own OpenAI-compatible service with vLLM, the project recommends, for QwQ and Qwen3, that you do not add the automatic tool choice and hermes tool call parser parameters, because Qwen-Agent parses the tool outputs from vLLM on its own. For Qwen3-Coder the recommendation is the opposite: enable both, use vLLM's built-in tool parsing, and combine it with the use_raw_api parameter. The consequence is that the server configuration is model-specific, and a vLLM command line copied from a tutorial is wrong for half the model families here. Configure the server per model and check it with the matching example.

A tool is a class, a description string and a parameters schema

The customisation story is three base classes and a decorator. LLMs inherit from class BaseChatModel and come with function calling, tools inherit from class BaseTool, and higher-level agents derive from class Agent, with class Assistant provided as a built-in you can also subclass. To add a tool you decorate a class with register_tool and give it a description that tells the agent what the tool does and parameters that tell it what the input is. The mechanism is worth understanding because of what it implies. The description string is the only thing the model has, so it is prompt surface rather than documentation, and a vague description produces a model that calls the tool wrongly. And the tools on an agent are a permission surface: the set of tools on an agent is the set of things it can do to your systems.

The four extras are capability switches, and one of them is the dangerous one

The stable install is one line, and the line is the interesting part:

bash
pip install -U "qwen-agent[gui,rag,code_interpreter,mcp]"

The file then documents what each extra in the double brackets buys: gui for the Gradio-based interface, rag for retrieval support, code_interpreter for the code interpreter, and mcp for Model Context Protocol, with a plain qwen-agent install for the minimal requirements. So the minimal package and the full one are not the same product at different sizes, they are different capabilities. That makes the extras a per-environment decision rather than a convenience, since a development machine and a deployed service should not necessarily have the same set. The GUI extra also carries a floor of its own, because the file notes the Gradio upgrade requires Python 3.10 or higher.

A zero-series version, and a 2026 example the packaged release predates

The version story is the maintenance story here. The published releases are v0.0.24, v0.0.25 and v0.0.26, all three of them in May 2025, with 0.0.26 on 2025-05-29, and the last push recorded for the repository is 2026-03-04. The news section, meanwhile, describes work from 2026, including an open-sourced Qwen3.5 with a usage example added in February 2026 and a documentation site and evaluation benchmark added in January 2026. So a newcomer following the documentation will be pointed at a demo that their installed package predates by about nine months, and the package version they can install from an index is a zero-series number, even though the README calls the PyPI package the stable version. Installing from a source checkout is a different proposition from installing the package, and the file offers both, with the source route being a clone and an editable install.

pip install gives you the framework and not the server

The packaging file has one line that explains the shape of the project. Packages are found with find_packages, excluding examples and qwen_server and their subpackages. So neither the example applications nor the server are importable from an installed qwen-agent, even though both are in the repository, along with a run_server.py at the root and a browser extension directory with its own English and Chinese documentation. The consequence is that the framework is a library you can install, and the server and the browser assistant are checkout-only components. That is a defensible split for a project whose examples are meant to be read, but it means the deployment story for anything that runs as a service is a repository clone rather than a dependency. The version string, incidentally, is read out of the package's own __init__ module with a regular expression, so the single source of version truth lives in the code rather than in the packaging file.

The examples are indexed by model, and that is the shape of the API

The examples directory is the real reference, and its filenames tell you how the framework is expected to be used: one agent per model, with files for Qwen3.5, Qwen3, Qwen3-Coder, Qwen3-VL and QwQ, plus others for an omni model, audio, retrieval, a model context protocol agent backed by SQLite, a weather bot, a custom tool, and group chat. There are also two function-calling examples, one of them explicitly about calling functions in parallel, several cookbooks as notebooks covering database manipulation, a mind map, a drive guide and thinking with images, and quick chats against an OpenAI-compatible endpoint. If you are starting now, the example for the model you actually run is the file to read first, because the differences between those agents are the API surface rather than incidental detail. Alongside them the repository holds the browser extension, the DeepPlanning benchmark, the documentation directory and the tests.

Editorial conclusion

Qwen-Agent fits a team standardising on Qwen models that wants the tool-calling plumbing in one place and that will read the examples for the model it actually runs. Be careful with anything reachable by untrusted input, because the README states the python executor in its Qwen2.5-Math demo is not sandboxed and is intended for local testing only. Before you install, choose the extras per environment, since the minimal package and the full one differ by whether the agent can execute code at all. Then configure the model server for the model you picked: for QwQ and Qwen3 the project tells you to leave automatic tool choice and the hermes parser off because Qwen-Agent parses the output itself, while for Qwen3-Coder it tells you to enable both and pass use_raw_api. And pin with care, because the newest package release is 0.0.26 from 2025-05-29 while the last push recorded was 2026-03-04.

Frequently asked questions

what is qwen agent

It is a Python framework for developing LLM applications on the instruction following, tool usage, planning and memory capabilities of Qwen models. It provides atomic components, LLMs inheriting from BaseChatModel and tools inheriting from BaseTool, plus higher-level agents built on class Agent, and ships example applications such as a browser assistant, a code interpreter and a custom assistant.

how to install qwen agent

From a package index, run pip install -U "qwen-agent[gui,rag,code_interpreter,mcp]", where the extras are the Gradio GUI, retrieval support, the code interpreter and Model Context Protocol support, or install plain qwen-agent for the minimal requirements. From source, clone the repository and run pip install -e ./"[gui,rag,code_interpreter,mcp]".

how to use qwen agent

Point it at a model service first, either DashScope with a DASHSCOPE_API_KEY environment variable, or your own OpenAI-compatible service using vLLM for GPU throughput or Ollama for local CPU deployment. Then import an agent, such as the Assistant class, give it tools registered with register_tool, and run it, optionally through the Gradio interface with WebUI(bot).run().

Does Qwen have an agent?

Yes. Qwen-Agent is the agent framework from the Qwen team, and the file states that it now plays as the backend of Qwen Chat. It is built on Qwen models of version 3.0 and above, with separate example agents for Qwen3.5, Qwen3, Qwen3-Coder, Qwen3-VL and QwQ.

is qwen agent free

The framework is open source under the Apache License 2.0, held by the Qwen team at Alibaba Group. The costs that the file mentions are elsewhere: using Alibaba Cloud's DashScope model service requires your own API key, and the README notes that the python executor in its Qwen2.5-Math demo is not sandboxed and is intended for local testing only.

Who is the provider for Qwen?

The Qwen team at Alibaba Group. The repository's copyright line names the Qwen team and Alibaba Group, the package author is the Qwen Team with an Alibaba address, and the documentation links point at Qwen Chat, the Hugging Face organisation and ModelScope.

Official sources

  1. License: Apache-2.0
  2. Project website
  3. QwenLM/Qwen-Agent on GitHub
  4. README
  5. Releases
Add this badge to your README

If you maintain this project, the badge below links readers to this analysis and shows its maintenance status from the daily GitHub snapshot. Paste the markdown into your README; add ?metric=license or ?metric=stars to the image URL for a different field.

Add this badge to your README

markdown
[![Hysen Labs](https://hysenlabs.com/badge/qwenlm-qwen-agent.svg)](https://hysenlabs.com/projects/qwenlm-qwen-agent)

Star history chart for your README

markdown
[![Star history](https://hysenlabs.com/chart/qwenlm-qwen-agent.svg)](https://hysenlabs.com/projects/qwenlm-qwen-agent)

Was this useful?