From 762766f0ef1e6d7a0068e4de7c1c17f7a5bae683 Mon Sep 17 00:00:00 2001 From: Meng Lu Date: Fri, 10 Jul 2026 09:29:05 -0700 Subject: [PATCH 1/3] Added MCP support to Qwen Code. --- .../References/SetUpWolframMCPServer.md | 1 + .../references/SetUpWolframMCPServer.md | 1 + .../references/SetUpWolframMCPServer.md | 1 + .../references/SetUpWolframMCPServer.md | 1 + .../references/SetUpWolframMCPServer.md | 1 + Kernel/InstallMCPServer.wl | 1 + Kernel/SupportedClients.wl | 10 ++++++++ README.md | 1 + docs/mcp-clients.md | 14 +++++++++++ docs/quickstart-coding.md | 24 +++++++++++++++++++ 10 files changed, 55 insertions(+) diff --git a/AgentSkills/References/SetUpWolframMCPServer.md b/AgentSkills/References/SetUpWolframMCPServer.md index 43a82b89..40d97880 100644 --- a/AgentSkills/References/SetUpWolframMCPServer.md +++ b/AgentSkills/References/SetUpWolframMCPServer.md @@ -46,6 +46,7 @@ Replace `` with one of the supported clients: | Junie | `"Junie"` | | LM Studio | `"LMStudio"` | | OpenCode | `"OpenCode"` | +| Qwen Code | `"QwenCode"` | | VS Code | `"VisualStudioCode"` | | Windsurf | `"Windsurf"` | | Zed | `"Zed"` | diff --git a/AgentSkills/Skills/wolfram-alpha/references/SetUpWolframMCPServer.md b/AgentSkills/Skills/wolfram-alpha/references/SetUpWolframMCPServer.md index 43a82b89..40d97880 100644 --- a/AgentSkills/Skills/wolfram-alpha/references/SetUpWolframMCPServer.md +++ b/AgentSkills/Skills/wolfram-alpha/references/SetUpWolframMCPServer.md @@ -46,6 +46,7 @@ Replace `` with one of the supported clients: | Junie | `"Junie"` | | LM Studio | `"LMStudio"` | | OpenCode | `"OpenCode"` | +| Qwen Code | `"QwenCode"` | | VS Code | `"VisualStudioCode"` | | Windsurf | `"Windsurf"` | | Zed | `"Zed"` | diff --git a/AgentSkills/Skills/wolfram-language/references/SetUpWolframMCPServer.md b/AgentSkills/Skills/wolfram-language/references/SetUpWolframMCPServer.md index 43a82b89..40d97880 100644 --- a/AgentSkills/Skills/wolfram-language/references/SetUpWolframMCPServer.md +++ b/AgentSkills/Skills/wolfram-language/references/SetUpWolframMCPServer.md @@ -46,6 +46,7 @@ Replace `` with one of the supported clients: | Junie | `"Junie"` | | LM Studio | `"LMStudio"` | | OpenCode | `"OpenCode"` | +| Qwen Code | `"QwenCode"` | | VS Code | `"VisualStudioCode"` | | Windsurf | `"Windsurf"` | | Zed | `"Zed"` | diff --git a/AgentSkills/Skills/wolfram-notebooks/references/SetUpWolframMCPServer.md b/AgentSkills/Skills/wolfram-notebooks/references/SetUpWolframMCPServer.md index 43a82b89..40d97880 100644 --- a/AgentSkills/Skills/wolfram-notebooks/references/SetUpWolframMCPServer.md +++ b/AgentSkills/Skills/wolfram-notebooks/references/SetUpWolframMCPServer.md @@ -46,6 +46,7 @@ Replace `` with one of the supported clients: | Junie | `"Junie"` | | LM Studio | `"LMStudio"` | | OpenCode | `"OpenCode"` | +| Qwen Code | `"QwenCode"` | | VS Code | `"VisualStudioCode"` | | Windsurf | `"Windsurf"` | | Zed | `"Zed"` | diff --git a/AgentSkills/Skills/wolfram-paclets/references/SetUpWolframMCPServer.md b/AgentSkills/Skills/wolfram-paclets/references/SetUpWolframMCPServer.md index 43a82b89..40d97880 100644 --- a/AgentSkills/Skills/wolfram-paclets/references/SetUpWolframMCPServer.md +++ b/AgentSkills/Skills/wolfram-paclets/references/SetUpWolframMCPServer.md @@ -46,6 +46,7 @@ Replace `` with one of the supported clients: | Junie | `"Junie"` | | LM Studio | `"LMStudio"` | | OpenCode | `"OpenCode"` | +| Qwen Code | `"QwenCode"` | | VS Code | `"VisualStudioCode"` | | Windsurf | `"Windsurf"` | | Zed | `"Zed"` | diff --git a/Kernel/InstallMCPServer.wl b/Kernel/InstallMCPServer.wl index 34fd04f5..c096e9fd 100644 --- a/Kernel/InstallMCPServer.wl +++ b/Kernel/InstallMCPServer.wl @@ -633,6 +633,7 @@ guessClientName[ file_? fileQ ] := Enclose[ { __, ".amazonq", "mcp.json" }, Throw[ "AmazonQ" ], { __, ".aws", "amazonq", "mcp.json" }, Throw[ "AmazonQ" ], { __, ".junie", "mcp", "mcp.json" }, Throw[ "Junie" ], + { __, ".qwen", "settings.json" }, Throw[ "QwenCode" ], { __, ".continue", "config.yaml" }, Throw[ "Continue" ], { __, ".continue", "mcpservers", _ }, Throw[ "Continue" ], { __, ".lmstudio", "mcp.json" }, Throw[ "LMStudio" ], diff --git a/Kernel/SupportedClients.wl b/Kernel/SupportedClients.wl index 4e1b0288..9534bb93 100644 --- a/Kernel/SupportedClients.wl +++ b/Kernel/SupportedClients.wl @@ -83,6 +83,16 @@ $supportedMCPClients = <| "URL" -> "https://github.com/google-gemini/gemini-cli", "InstallLocation" :> { $HomeDirectory, ".gemini", "settings.json" } |>, + "QwenCode" -> <| + "DisplayName" -> "Qwen Code", + "DefaultToolset" -> "WolframLanguage", + "Aliases" -> { "Qwen" }, + "ConfigFormat" -> "JSON", + "ConfigKey" -> { "mcpServers" }, + "URL" -> "https://github.com/QwenLM/qwen-code", + "ProjectPath" -> { ".qwen", "settings.json" }, + "InstallLocation" :> { $HomeDirectory, ".qwen", "settings.json" } + |>, "Goose" -> <| "DisplayName" -> "Goose", "DefaultToolset" -> "Wolfram", diff --git a/README.md b/README.md index c81df0cb..ee5da8a0 100644 --- a/README.md +++ b/README.md @@ -133,6 +133,7 @@ AgentTools can be installed into the following MCP client applications: | [LM Studio](https://lmstudio.ai) | `"LMStudio"` | No | | [OpenAI Codex](https://openai.com/codex) | `"Codex"` | Yes | | [OpenCode](https://opencode.ai) | `"OpenCode"` | Yes | +| [Qwen Code](https://github.com/QwenLM/qwen-code) | `"QwenCode"` | Yes | | [Visual Studio Code](https://code.visualstudio.com) | `"VisualStudioCode"` | Yes | | [Windsurf](https://codeium.com/windsurf) | `"Windsurf"` | No | | [Zed](https://zed.dev) | `"Zed"` | Yes | diff --git a/docs/mcp-clients.md b/docs/mcp-clients.md index eefb8272..c724190b 100644 --- a/docs/mcp-clients.md +++ b/docs/mcp-clients.md @@ -33,6 +33,7 @@ The following clients have built-in support for automatic configuration via `Ins | LM Studio | `"LMStudio"` | — | JSON | No | `"Wolfram"` | | Codex CLI | `"Codex"` | `"OpenAICodex"` | TOML | Yes | `"WolframLanguage"` | | OpenCode | `"OpenCode"` | — | JSON | Yes | `"WolframLanguage"` | +| Qwen Code | `"QwenCode"` | `"Qwen"` | JSON | Yes | `"WolframLanguage"` | | Visual Studio Code | `"VisualStudioCode"` | `"VSCode"` | JSON | Yes | `"WolframLanguage"` | | Windsurf | `"Windsurf"` | `"Codeium"` | JSON | No | `"WolframLanguage"` | | Zed | `"Zed"` | — | JSON | Yes | `"WolframLanguage"` | @@ -262,6 +263,19 @@ Note: Copilot CLI requires the `tools` field to specify which tools to enable. ` **Format:** Same as Claude Desktop (`mcpServers` key). +### Qwen Code + +Qwen Code is Alibaba's terminal coding agent, forked from Gemini CLI. It reads MCP servers from the `mcpServers` key of its `settings.json`, at both user and project scope. + +| Scope | Config Location | +|-------|----------------| +| Global | `~/.qwen/settings.json` | +| Project | `.qwen/settings.json` (in project root) | + +**Format:** Same as Claude Desktop (`mcpServers` key). + +Note: Qwen Code shares Gemini CLI's config structure but, unlike Gemini CLI, also supports a project-scope `.qwen/settings.json`, so `InstallMCPServer[{"QwenCode", "/path/to/project"}]` installs a server for just that project. Qwen Code auto-migrates older `settings.json` layouts, but `mcpServers` remains a root-level key. + ### Antigravity (IDE, desktop app, and CLI) A **single** `"Antigravity"` client entry covers the Antigravity IDE, the Antigravity 2.0 desktop app, and the Antigravity CLI (the terminal agent that replaces Gemini CLI for free / consumer tiers on **June 18, 2026**). `"AntigravityCLI"`, `"GoogleAntigravity"`, and `"GoogleAntigravityCLI"` are **aliases** of this entry — not separate clients. They share one global config file, so a single entry is required: two entries pointing at the same file would let `DeployAgentTools` create two deployments for one file and let `DeleteObject[AgentToolsDeployment[...]]` corrupt shared state. diff --git a/docs/quickstart-coding.md b/docs/quickstart-coding.md index ca0d5d03..2e2d1266 100644 --- a/docs/quickstart-coding.md +++ b/docs/quickstart-coding.md @@ -198,6 +198,30 @@ opencode mcp list The output should indicate that the "WolframLanguage" server is connected. +### Qwen Code + +Choose whether to install the server globally or project-level. Global installation is available in all projects, while project-level installation writes `.qwen/settings.json` in the project root. + +Global installation: + +```wl +InstallMCPServer["QwenCode", "WolframLanguage"] +``` + +Project-level installation: + +```wl +InstallMCPServer[{"QwenCode", "/path/to/project"}, "WolframLanguage"] +``` + +To verify the installation from the command line: + +```shell +qwen mcp list +``` + +The output should indicate that the "WolframLanguage" server is configured. + ### Visual Studio Code Choose whether to install the server globally or project-level. Global installation is available in all projects, while project-level installation is available only in a specific project directory. From 2ca84ac049dfbdb9819f7876733d99a8974db927 Mon Sep 17 00:00:00 2001 From: Meng Lu Date: Fri, 10 Jul 2026 11:53:27 -0700 Subject: [PATCH 2/3] Fixed broken tests by the addition of Qwen Code MCP support. --- Kernel/SupportedClients.wl | 20 ++++++++++---------- Tests/InstallMCPServer.wlt | 4 ++-- 2 files changed, 12 insertions(+), 12 deletions(-) diff --git a/Kernel/SupportedClients.wl b/Kernel/SupportedClients.wl index 9534bb93..0018faf1 100644 --- a/Kernel/SupportedClients.wl +++ b/Kernel/SupportedClients.wl @@ -83,16 +83,6 @@ $supportedMCPClients = <| "URL" -> "https://github.com/google-gemini/gemini-cli", "InstallLocation" :> { $HomeDirectory, ".gemini", "settings.json" } |>, - "QwenCode" -> <| - "DisplayName" -> "Qwen Code", - "DefaultToolset" -> "WolframLanguage", - "Aliases" -> { "Qwen" }, - "ConfigFormat" -> "JSON", - "ConfigKey" -> { "mcpServers" }, - "URL" -> "https://github.com/QwenLM/qwen-code", - "ProjectPath" -> { ".qwen", "settings.json" }, - "InstallLocation" :> { $HomeDirectory, ".qwen", "settings.json" } - |>, "Goose" -> <| "DisplayName" -> "Goose", "DefaultToolset" -> "Wolfram", @@ -222,6 +212,16 @@ $supportedMCPClients = <| "ProjectPath" -> { "opencode.json" }, "InstallLocation" :> { $HomeDirectory, ".config", "opencode", "opencode.json" } |>, + "QwenCode" -> <| + "DisplayName" -> "Qwen Code", + "DefaultToolset" -> "WolframLanguage", + "Aliases" -> { "Qwen" }, + "ConfigFormat" -> "JSON", + "ConfigKey" -> { "mcpServers" }, + "URL" -> "https://github.com/QwenLM/qwen-code", + "ProjectPath" -> { ".qwen", "settings.json" }, + "InstallLocation" :> { $HomeDirectory, ".qwen", "settings.json" } + |>, "VisualStudioCode" -> <| "DisplayName" -> "Visual Studio Code", "DefaultToolset" -> "WolframLanguage", diff --git a/Tests/InstallMCPServer.wlt b/Tests/InstallMCPServer.wlt index 85ce5a9e..85d92d09 100644 --- a/Tests/InstallMCPServer.wlt +++ b/Tests/InstallMCPServer.wlt @@ -3838,14 +3838,14 @@ VerificationTest[ VerificationTest[ Length @ $SupportedMCPClients, - 20, + 21, SameTest -> Equal, TestID -> "SupportedMCPClients-Has20Clients@@Tests/InstallMCPServer.wlt:3839,1-3844,2" ] VerificationTest[ Keys @ $SupportedMCPClients, - { "AmazonQ", "Antigravity", "AugmentCode", "AugmentCodeIDE", "ClaudeCode", "ClaudeDesktop", "Cline", "Codex", "Continue", "CopilotCLI", "Cursor", "GeminiCLI", "Goose", "Junie", "Kiro", "LMStudio", "OpenCode", "VisualStudioCode", "Windsurf", "Zed" }, + { "AmazonQ", "Antigravity", "AugmentCode", "AugmentCodeIDE", "ClaudeCode", "ClaudeDesktop", "Cline", "Codex", "Continue", "CopilotCLI", "Cursor", "GeminiCLI", "Goose", "Junie", "Kiro", "LMStudio", "OpenCode", "QwenCode", "VisualStudioCode", "Windsurf", "Zed" }, SameTest -> Equal, TestID -> "SupportedMCPClients-KeysSorted@@Tests/InstallMCPServer.wlt:3846,1-3851,2" ] From ce0241e270026888ce129e12328cf8855d485ac8 Mon Sep 17 00:00:00 2001 From: Rick Hennigan Date: Mon, 13 Jul 2026 09:13:33 -0400 Subject: [PATCH 3/3] Potential fix for pull request finding Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com> --- Tests/InstallMCPServer.wlt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Tests/InstallMCPServer.wlt b/Tests/InstallMCPServer.wlt index 85d92d09..0cd1a3da 100644 --- a/Tests/InstallMCPServer.wlt +++ b/Tests/InstallMCPServer.wlt @@ -3840,7 +3840,7 @@ VerificationTest[ Length @ $SupportedMCPClients, 21, SameTest -> Equal, - TestID -> "SupportedMCPClients-Has20Clients@@Tests/InstallMCPServer.wlt:3839,1-3844,2" + TestID -> "SupportedMCPClients-Has21Clients@@Tests/InstallMCPServer.wlt:3839,1-3844,2" ] VerificationTest[