# Kokon (MCP server)

> Kokon is an MCP server that adds search and knowledge tools to AI assistants such as Claude Desktop, Claude Code and Cursor. Generate and edit images offline with Qwen-Image 2.1 on your GPU. It has 220 GitHub stars, is released under the AGPL-3.0 license and runs locally with npx -y kokon-mcp.

MCP server for Kokon. It lets Claude Code, Cursor, Claude Desktop and other MCP clients generate and edit images with Qwen-Image 2.1, running offline on your own GPU. No API key, no cloud. Everything stays on 127.0.0.1.

## Key facts

| Fact | Value |
|---|---|
| Repository | https://github.com/GabrieleLozupone/kokon |
| GitHub stars | 220 |
| License | AGPL-3.0 |
| Language | TypeScript |
| Transport | stdio |
| Packages | npm: kokon-mcp |
| Remote URL | none |
| Needs API key | no |
| Official | no |
| Works with | Claude Desktop, Claude Code, Cursor, VS Code |
| Category | AI & search |
| Latest release | v0.11.0 (Oct 24, 2026) |
| Last commit | Oct 24, 2026 |
| MCP registry name | io.github.GabrieleLozupone/kokon |

## Install

### Claude Desktop (claude_desktop_config.json)

```json
{
  "mcpServers": {
    "kokon": {
      "command": "npx",
      "args": [
        "-y",
        "kokon-mcp"
      ],
      "env": {
        "QLS_MCP_ALLOWED_DIRS": "your-value"
      }
    }
  }
}
```

Settings > Developer > Edit Config. macOS: ~/Library/Application Support/Claude/, Windows: %APPDATA%\Claude\. Restart Claude Desktop afterwards.

### Claude Code

```sh
claude mcp add --env QLS_MCP_ALLOWED_DIRS=your-value --transport stdio kokon -- npx -y kokon-mcp
```

### Cursor (.cursor/mcp.json)

```json
{
  "mcpServers": {
    "kokon": {
      "type": "stdio",
      "command": "npx",
      "args": [
        "-y",
        "kokon-mcp"
      ],
      "env": {
        "QLS_MCP_ALLOWED_DIRS": "your-value"
      }
    }
  }
}
```

Project file; use ~/.cursor/mcp.json to enable it in every project.

### VS Code (.vscode/mcp.json)

```json
{
  "servers": {
    "kokon": {
      "type": "stdio",
      "command": "npx",
      "args": [
        "-y",
        "kokon-mcp"
      ],
      "env": {
        "QLS_MCP_ALLOWED_DIRS": "your-value"
      }
    }
  }
}
```

Config formats checked against the official docs on 2026-10-07.

## Environment variables

- `QLS_MCP_ALLOWED_DIRS`: Extra folders the server may read and write, separated by semicolons. The project folder and Kokon's output folder are always allowed.

## Tools

- `generate_image`: Text to image, optionally with up to 10 reference images (a person, a product, a style) in a new scene.
- `edit_image`: Edit an image with an instruction. Keeps its size; never overwrites the input.
- `edit_images`: Edit image 1 with the help of up to 9 more images ("image 1", "image 2"...).
- `inpaint_image`: Change only a masked area: edit, remove, replace or add something.
- `outpaint_image`: Extend an image beyond its borders.
- `upscale_image`: Enlarge an image (default 2x, up to 8192 px).
- `get_image_info`: Size, type and, for Kokon images, the prompt, seed and settings.
- `get_generator_status`: Engine state, GPU, VRAM and job queue.

## Similar MCP servers

- [SuperCMO](https://appsgit.com/mcp-servers/supercmo): Marketing media generation — image, video, voice — for AI agents. (221 stars, Apache-2.0, needs API key)
- [ClawMem](https://appsgit.com/mcp-servers/clawmem): On-device memory layer for AI agents. Claude Code, OpenClaw and Hermes. (212 stars, MIT)
- [Vexor](https://appsgit.com/mcp-servers/vexor): A semantic search engine for files and code. (247 stars, MIT)
- [Argo](https://appsgit.com/mcp-servers/argo): 专门为 agent 打造的开源 agent 搜索工具，具备 200+的搜索源及多语言搜索能力，覆盖中文/英文/学术/代码/购物/金融/新闻/百科。. (207 stars, Apache-2.0)
- [MCP Sap Docs](https://appsgit.com/mcp-servers/mcp-sap-docs): Fast MCP server for unified SAP docs search (SAPUI5, CAP, OpenUI5, wdi5) with BM25 full-text search. (247 stars, Apache-2.0)
- [Mengram](https://appsgit.com/mcp-servers/mengram): Long-term memory for AI agents: semantic facts, episodic events, and procedural workflows. (204 stars, Apache-2.0, needs API key)

---

Canonical page: https://appsgit.com/mcp-servers/kokon
Source: appsgit (https://appsgit.com), the app store for github. Data from the GitHub API, refreshed daily.
Machine access: JSON API https://appsgit.com/api/v1/apps (OpenAPI: https://appsgit.com/openapi.json), MCP server https://mcp.appsgit.com/mcp, full index https://appsgit.com/llms-full.txt.
