@softspark/ai-toolkit 2.0.2 → 2.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -3,10 +3,10 @@ title: "AI Toolkit - Architecture Overview"
3
3
  category: reference
4
4
  service: ai-toolkit
5
5
  tags: [architecture, overview, design, structure]
6
- version: "1.4.2"
6
+ version: "1.4.4"
7
7
  created: "2026-03-23"
8
- last_updated: "2026-04-09"
9
- description: "Architecture of ai-toolkit: directory layout, global install model, skill tiers, and integration with projects."
8
+ last_updated: "2026-04-13"
9
+ description: "Architecture of ai-toolkit: directory layout, global install model, editor-aware MCP install, Codex translation layer, skill tiers, and integration with projects."
10
10
  ---
11
11
 
12
12
  # AI Toolkit Architecture
@@ -105,11 +105,13 @@ Machine (global) Project (local)
105
105
  **`ai-toolkit update`** — re-apply after `npm install -g @softspark/ai-toolkit@latest` or after `add-rule` / `remove-rule`. Same as `install` but semantically correct for update flows.
106
106
 
107
107
  **`ai-toolkit install --local`** — run per project. Always installs Claude Code configs (CLAUDE.md, settings.local.json, constitution.md, language rules). Editor configs are opt-in via `--editors`:
108
- - `--editors all` — install all 8 editors (Cursor, Windsurf, Cline, Roo, Aider, Augment, Copilot, Antigravity)
108
+ - `--editors all` — install all 9 editors (Cursor, Windsurf, Cline, Roo, Aider, Augment, Copilot, Antigravity, Codex)
109
109
  - `--editors cursor,aider` — install only selected editors
110
110
  - (no flag) — auto-detect from existing project files; `update --local` picks up whatever editors already have configs
111
111
 
112
- Each editor gets directory-based format (`.cursor/rules/*.mdc`, `.windsurf/rules/*.md`, `.clinerules/*.md`, `.roo/rules/*.md`, `.augment/rules/ai-toolkit-*.md`, `.agent/rules/*.md`, `CONVENTIONS.md`). Hooks are global-only — not merged into project settings.
112
+ Each editor gets directory-based format (`.cursor/rules/*.mdc`, `.windsurf/rules/*.md`, `.clinerules/*.md`, `.roo/rules/*.md`, `.augment/rules/ai-toolkit-*.md`, `.agent/rules/*.md`, `CONVENTIONS.md`). Codex local install additionally generates `AGENTS.md`, `.agents/rules/*.md`, `.agents/skills/*`, and `.codex/hooks.json`. Hooks are global-only — not merged into project settings except for editor-native local hook files such as Codex `.codex/hooks.json`. Experimental plugin packs can also layer a global Codex target in `HOME` (`~/AGENTS.md`, `~/.agents/`, `~/.codex/hooks.json`) when installed with `ai-toolkit plugin install --editor codex`.
113
+
114
+ If a project already has `.mcp.json`, local install mirrors its `mcpServers` entries into `.claude/settings.local.json` plus any selected editors with project-scoped native MCP files (`.cursor/mcp.json`, `.github/mcp.json`).
113
115
 
114
116
  ## CLI Commands
115
117
 
@@ -122,6 +124,8 @@ Each editor gets directory-based format (`.cursor/rules/*.mdc`, `.windsurf/rules
122
124
  | `uninstall` | `~/.claude/` | Strips toolkit components (preserves user content) |
123
125
  | `add-rule <file>` | `~/.softspark/ai-toolkit/rules/` | Register rule — auto-applied on every `update` |
124
126
  | `remove-rule <name>` | `~/.softspark/ai-toolkit/rules/` + `~/.claude/CLAUDE.md` | Unregister rule and remove its block |
127
+ | `mcp add <name...>` | `./.mcp.json` | Merge canonical MCP template(s) into project config |
128
+ | `mcp install --editor <name...>` | native editor config | Render MCP template(s) into editor-native config files |
125
129
  | `validate` | toolkit | Integrity check |
126
130
  | `doctor` | toolkit | Install health, hooks, benchmark freshness, and artifact drift diagnostics |
127
131
  | `benchmark-ecosystem` | toolkit | Benchmark snapshot for official Claude Code and external ecosystem repos |
@@ -140,6 +144,9 @@ Each editor gets directory-based format (`.cursor/rules/*.mdc`, `.windsurf/rules
140
144
  | `conventions-md` | `./` | Generates `CONVENTIONS.md` (Aider auto-loaded) |
141
145
  | `augment-dir-rules` | `./` | Generates `.augment/rules/ai-toolkit-*.md` |
142
146
  | `antigravity-rules` | `./` | Generates `.agent/rules/` + `.agent/workflows/` |
147
+ | `codex-md` | `./` | Generates Codex-facing `AGENTS.md` |
148
+ | `codex-rules` | `./` | Generates `.agents/rules/*.md` |
149
+ | `codex-hooks` | `./` | Generates `.codex/hooks.json` |
143
150
  | `agents-md` | toolkit | Regenerates `AGENTS.md` |
144
151
  | `llms-txt` | `./` | Generates `llms.txt` |
145
152
  | `generate-all` | `./` | Generates all platform configs at once |
@@ -191,6 +198,38 @@ Skills that spawn real parallel agents use:
191
198
 
192
199
  `CLAUDE_CODE_EXPERIMENTAL_AGENT_TEAMS=1` must be set for Agent Teams (tmux-based) support.
193
200
 
201
+ ### Codex Translation Layer
202
+
203
+ Codex does not expose Claude's `Agent`, `Team*`, and `Task*` primitives with the
204
+ same runtime semantics. To keep the skill catalog aligned, local Codex install
205
+ uses a translation layer:
206
+
207
+ - native Codex-compatible skills are linked directly
208
+ - Claude-only orchestration skills are emitted as generated wrappers
209
+ - wrapper guidance maps delegation to `spawn_agent`, `send_input`, `wait_agent`, `close_agent`, and `update_plan`
210
+
211
+ Codex therefore receives the full skill catalog, but not the full Claude hook
212
+ surface or tmux-backed Agent Teams lifecycle. Plugin packs reuse the same
213
+ translation and hook-compatibility model when targeting the global Codex layer.
214
+
215
+ See `kb/reference/codex-cli-compatibility.md` for the detailed mapping.
216
+
217
+ ## MCP Rendering Layer
218
+
219
+ `.mcp.json` is the canonical project-level template format. ai-toolkit can render that configuration into editor-native MCP files through `scripts/mcp_editors.py`.
220
+
221
+ Current native adapters:
222
+ - Claude Code: `.claude/settings.local.json` and `~/.claude/settings.json`
223
+ - Cursor: `.cursor/mcp.json` and `~/.cursor/mcp.json`
224
+ - GitHub Copilot: `.github/mcp.json` and `~/.copilot/mcp-config.json`
225
+ - Gemini CLI: `.gemini/settings.json` and `~/.gemini/settings.json`
226
+ - Windsurf: `~/.codeium/windsurf/mcp_config.json`
227
+ - Cline: `~/.cline/data/settings/cline_mcp_settings.json`
228
+ - Augment: `~/.augment/settings.json`
229
+ - Codex CLI: `~/.codex/config.toml`
230
+
231
+ See `kb/reference/mcp-editor-compatibility.md` for the support matrix and scope rules.
232
+
194
233
  ## Quality Guardrails
195
234
 
196
235
  ### Anti-Rationalization Tables
@@ -5,8 +5,8 @@ service: ai-toolkit
5
5
  tags: [benchmark, claude-code, ecosystem, hooks, plugins, architecture]
6
6
  version: "1.0.0"
7
7
  created: "2026-03-27"
8
- last_updated: "2026-04-01"
9
- description: "Reference summary of the ecosystem signals and implementation foundations adopted in ai-toolkit."
8
+ last_updated: "2026-04-13"
9
+ description: "Reference summary of the ecosystem signals and implementation foundations adopted in ai-toolkit, including runtime-aware plugin packaging."
10
10
  ---
11
11
 
12
12
  # Claude Ecosystem Expansion Foundations
@@ -19,13 +19,13 @@ This document captures the architectural foundations adopted in `ai-toolkit` aft
19
19
  2. official Claude Code patterns,
20
20
  3. selected external benchmark repositories.
21
21
 
22
- The outcome is a toolkit that is now positioned as a more modular, Claude-native, benchmark-backed system with stronger lifecycle automation and extension tooling.
22
+ The outcome is a toolkit that is now positioned as a more modular, Claude-first, benchmark-backed system with stronger lifecycle automation and extension tooling.
23
23
 
24
24
  ## Implemented Foundations
25
25
 
26
26
  ### 1. Plugin-oriented structure
27
27
 
28
- `ai-toolkit` now treats plugin packaging as a first-class capability.
28
+ `ai-toolkit` now treats plugin packaging as a first-class capability, with runtime-aware install surfaces for Claude and optional global Codex layering.
29
29
 
30
30
  Implemented artifacts:
31
31
  - `app/.claude-plugin/plugin.json`
@@ -0,0 +1,136 @@
1
+ ---
2
+ title: "AI Toolkit - Codex CLI Compatibility"
3
+ category: reference
4
+ service: ai-toolkit
5
+ tags: [codex, compatibility, install, skills, hooks]
6
+ version: "1.0.0"
7
+ created: "2026-04-12"
8
+ last_updated: "2026-04-13"
9
+ description: "Reference for how ai-toolkit maps Claude-oriented skills, hooks, and plugin packs to Codex CLI."
10
+ ---
11
+
12
+ # AI Toolkit - Codex CLI Compatibility
13
+
14
+ ## Summary
15
+
16
+ Codex CLI now receives the full `ai-toolkit` skill catalog during local install.
17
+
18
+ Native Codex-compatible skills are linked directly into `.agents/skills/`. Skills
19
+ that depend on Claude-only orchestration primitives are generated as Codex
20
+ wrappers that preserve the original workflow intent while translating execution
21
+ to Codex subagents and plan tracking.
22
+
23
+ Experimental plugin packs can also target a global Codex surface with
24
+ `ai-toolkit plugin install --editor codex`, which layers plugin-specific skills,
25
+ rules, and hooks into `HOME` without changing the project-local core install
26
+ model.
27
+
28
+ ## Local Install Outputs
29
+
30
+ `ai-toolkit install --local --editors codex` generates:
31
+
32
+ - `AGENTS.md`
33
+ - `.agents/rules/*.md`
34
+ - `.agents/skills/*`
35
+ - `.codex/hooks.json`
36
+
37
+ ## Global Plugin Outputs
38
+
39
+ `ai-toolkit plugin install --editor codex <pack>` bootstraps or reuses:
40
+
41
+ - `~/AGENTS.md`
42
+ - `~/.agents/rules/*.md`
43
+ - `~/.agents/skills/*`
44
+ - `~/.codex/hooks.json`
45
+
46
+ Plugin packs only add their own runtime-specific layer on top of the generated
47
+ Codex base. Shared hook scripts and plugin scripts still live in
48
+ `~/.softspark/ai-toolkit/`.
49
+
50
+ ## Skill Translation Model
51
+
52
+ Two delivery modes are used for Codex:
53
+
54
+ | Mode | How it is installed | Use case |
55
+ |------|----------------------|----------|
56
+ | Native | Symlink to `app/skills/<name>/` | Skills whose `allowed-tools` are already supported in Codex |
57
+ | Adapted | Generated wrapper directory in `.agents/skills/<name>/` | Skills that rely on Claude-only `Agent`, `Team*`, or `Task*` primitives |
58
+
59
+ Adapted skills keep the same support assets (`reference/`, `scripts/`, `assets/`)
60
+ via symlinks, but rewrite `SKILL.md` to Codex-native guidance.
61
+
62
+ ## Claude-to-Codex Tool Mapping
63
+
64
+ The adapter rewrites Claude-specific delegation guidance to the closest Codex
65
+ runtime primitives:
66
+
67
+ | Claude-oriented primitive | Codex replacement |
68
+ |---------------------------|------------------|
69
+ | `Agent(...)` | `spawn_agent(..., fork_context=True, ...)` |
70
+ | `SendMessage` | `send_input` |
71
+ | `TaskCreate` / `TaskList` / `TaskUpdate` | `update_plan` or explicit checklist tracking |
72
+ | `TaskGet` / `TaskOutput` | `wait_agent` |
73
+ | `TaskStop` / `TeamDelete` | `close_agent` |
74
+ | Agent teams | Multiple spawned subagents with explicit file ownership |
75
+
76
+ ## Adapted Skill Classes
77
+
78
+ The main adapted group is multi-agent orchestration:
79
+
80
+ - `/orchestrate`
81
+ - `/workflow`
82
+ - `/swarm`
83
+ - `/teams`
84
+ - `/subagent-development`
85
+
86
+ The adapter also covers skills that previously depended only on Claude's
87
+ `Agent` primitive, such as:
88
+
89
+ - `/tdd`
90
+ - `/write-a-prd`
91
+ - `/qa-session`
92
+ - `/triage-issue`
93
+ - `/architecture-audit`
94
+
95
+ ## Hook Compatibility
96
+
97
+ Codex does not expose the full Claude hook event surface. The Codex hook
98
+ generator emits only the events supported by Codex runtime integration:
99
+
100
+ - `SessionStart`
101
+ - `PreToolUse`
102
+ - `PostToolUse`
103
+ - `UserPromptSubmit`
104
+ - `Stop`
105
+
106
+ This means Claude-only events such as `TaskCompleted`, `TeammateIdle`,
107
+ `SubagentStart`, `SubagentStop`, `PreCompact`, `SessionEnd`, and
108
+ `Notification` are not available in `.codex/hooks.json`.
109
+
110
+ ## Behavioral Limits
111
+
112
+ Codex wrappers preserve workflow intent, but not every Claude runtime behavior
113
+ has a perfect one-to-one equivalent.
114
+
115
+ Known limits:
116
+
117
+ - No native Codex equivalent of tmux-backed Agent Teams lifecycle events
118
+ - No separate task object model equivalent to Claude `Task*` APIs
119
+ - Hook event coverage is narrower than Claude Code
120
+
121
+ These are runtime platform limits, not installation defects.
122
+
123
+ ## Verification
124
+
125
+ The Codex compatibility path is verified by:
126
+
127
+ 1. Generator contract tests for `generate_codex.py`
128
+ 2. Local install tests for `.agents/skills/` and `.codex/hooks.json`
129
+ 3. Plugin install tests for global Codex rules, hooks, and cleanup paths
130
+ 4. CLI tests for `codex-md` and `codex-hooks`
131
+
132
+ ## Related
133
+
134
+ - `kb/reference/skills-catalog.md`
135
+ - `kb/reference/architecture-overview.md`
136
+ - `kb/reference/global-install-model.md`
@@ -2,11 +2,11 @@
2
2
  title: "Extension API Reference"
3
3
  category: reference
4
4
  service: ai-toolkit
5
- tags: [extension-api, inject-rule, inject-hook, mcp-templates, integration]
6
- version: "1.3.8"
5
+ tags: [extension-api, inject-rule, inject-hook, mcp-templates, integration, editors]
6
+ version: "1.3.9"
7
7
  created: "2026-04-07"
8
- last_updated: "2026-04-07"
9
- description: "Reference for ai-toolkit's extension API: inject-rule, inject-hook, remove-rule, remove-hook, and mcp template management."
8
+ last_updated: "2026-04-12"
9
+ description: "Reference for ai-toolkit's extension API: inject-rule, inject-hook, remove-rule, remove-hook, and editor-aware MCP template management."
10
10
  ---
11
11
 
12
12
  # Extension API Reference
@@ -27,6 +27,7 @@ This design is intentional: ai-toolkit is a generic toolkit. Consumers (MCP serv
27
27
  | `remove-hook <name>` | `~/.claude/settings.json` | Strip all entries with matching `_source` | Yes |
28
28
  | `add-rule <file.md>` | `~/.softspark/ai-toolkit/rules/` | File copy + re-inject all rules on next `update` | Yes |
29
29
  | `mcp add <name...>` | `.mcp.json` | Merge `mcpServers` block from template | Yes |
30
+ | `mcp install --editor <name...>` | Native editor MCP config | Render canonical template into editor format | Yes |
30
31
 
31
32
  ## inject-rule
32
33
 
@@ -103,7 +104,7 @@ npx @softspark/ai-toolkit remove-hook my-tool-hooks
103
104
 
104
105
  The argument is the source name (file stem used during `inject-hook`). If no entries with that source are present, the command exits 0 silently.
105
106
 
106
- ## mcp add
107
+ ## mcp add / install
107
108
 
108
109
  Merges one or more MCP server templates from `app/mcp-templates/` into the project's `.mcp.json`.
109
110
 
@@ -111,13 +112,24 @@ Merges one or more MCP server templates from `app/mcp-templates/` into the proje
111
112
  ai-toolkit mcp add github # add a single template
112
113
  ai-toolkit mcp add github postgres slack # add multiple at once
113
114
  ai-toolkit mcp list # list all available templates
115
+ ai-toolkit mcp editors # list supported native adapters
114
116
  ai-toolkit mcp show github # print a template's JSON
117
+ ai-toolkit mcp install --editor cursor --scope project github --target .
118
+ ai-toolkit mcp install --editor codex context7
115
119
  ai-toolkit mcp remove github # remove an entry from .mcp.json
120
+ ai-toolkit mcp remove github --editor cursor --scope project --target .
116
121
  ```
117
122
 
118
123
  **Implementation:** `scripts/mcp_manager.py`.
119
124
 
120
- The `add` command merges the `mcpServers` block from the template into `.mcp.json`. If `.mcp.json` does not exist, it is created. If the server name already exists, the entry is overwritten. See [mcp-templates.md](mcp-templates.md) for the full list of available templates.
125
+ The `add` command merges the `mcpServers` block from the template into `.mcp.json`. If `.mcp.json` does not exist, it is created. If the server name already exists, the entry is overwritten.
126
+
127
+ The `install` command renders the same canonical template into a native editor config format. Supported adapters currently cover:
128
+ - JSON clients with `mcpServers`: Claude Code, Cursor, Gemini CLI, Windsurf, Cline, Augment
129
+ - JSON clients with additional required metadata: GitHub Copilot
130
+ - TOML clients: Codex CLI
131
+
132
+ When `install` runs with `--scope project`, ai-toolkit also updates `.mcp.json` so the project-level config remains the source of truth for later sync and local install flows.
121
133
 
122
134
  ## Architecture
123
135
 
@@ -132,6 +144,7 @@ The `add` command merges the `mcpServers` block from the template into `.mcp.jso
132
144
  │ remove-hook <name> → settings.json │
133
145
  │ add-rule <file.md> → rules/ registry │
134
146
  │ mcp add <template> → .mcp.json │
147
+ │ mcp install <template> → editor-native MCP │
135
148
  │ │
136
149
  │ Idempotent: markers (rules) / _source tags (hooks) │
137
150
  │ ai-toolkit NEVER calls external services │
@@ -157,6 +170,9 @@ npx @softspark/ai-toolkit inject-hook ./hooks/my-tool-hooks.json
157
170
 
158
171
  # Add an MCP server template
159
172
  npx @softspark/ai-toolkit mcp add github
173
+
174
+ # Render the same template into Cursor project config
175
+ npx @softspark/ai-toolkit mcp install --editor cursor --scope project github --target .
160
176
  ```
161
177
 
162
178
  To uninstall:
@@ -172,4 +188,5 @@ All operations are idempotent — safe to run on every install or update.
172
188
 
173
189
  - [PATH: kb/reference/hooks-catalog.md] — built-in hooks reference
174
190
  - [PATH: kb/reference/mcp-templates.md] — available MCP server templates
191
+ - [PATH: kb/reference/mcp-editor-compatibility.md] — native editor MCP support matrix
175
192
  - [PATH: kb/reference/architecture-overview.md] — overall install model
@@ -2,11 +2,11 @@
2
2
  title: "Global Install Model"
3
3
  category: reference
4
4
  service: ai-toolkit
5
- tags: [install, global, claude, local-setup]
6
- version: "1.4.2"
5
+ tags: [install, global, claude, codex, plugins, local-setup]
6
+ version: "1.4.4"
7
7
  created: "2026-03-26"
8
- last_updated: "2026-04-09"
9
- description: "Reference description of the global install target, local project setup, and command responsibilities in ai-toolkit."
8
+ last_updated: "2026-04-13"
9
+ description: "Reference description of the global install target, project-local editor setup, global Codex plugin layering, and command responsibilities in ai-toolkit."
10
10
  ---
11
11
 
12
12
  # Global Install Model
@@ -17,6 +17,10 @@ description: "Reference description of the global install target, local project
17
17
 
18
18
  That means one machine-level install provides agents, skills, hooks, and rules to every project without committing toolkit boilerplate into each repository.
19
19
 
20
+ Codex remains project-local for the core toolkit install, but experimental
21
+ plugin packs can now layer a global Codex target in `HOME` when explicitly
22
+ installed with `ai-toolkit plugin install --editor codex`.
23
+
20
24
  ## Command Responsibilities
21
25
 
22
26
  | Command | Target | Purpose |
@@ -29,6 +33,11 @@ That means one machine-level install provides agents, skills, hooks, and rules t
29
33
  | `ai-toolkit update --local` | current project | refresh project configs; auto-detects editors from existing files |
30
34
  | `ai-toolkit add-rule` | `~/.softspark/ai-toolkit/rules/` | register a global rule |
31
35
  | `ai-toolkit remove-rule` | `~/.softspark/ai-toolkit/rules/` | unregister a global rule |
36
+ | `ai-toolkit mcp add <name...>` | current project | merge MCP templates into `.mcp.json` |
37
+ | `ai-toolkit mcp install --editor <name...>` | editor-native config | render MCP templates into editor-specific config files |
38
+ | `ai-toolkit plugin install --editor claude|codex|all <name>` | runtime-native config | install plugin pack for selected runtime(s) |
39
+ | `ai-toolkit plugin update --editor claude|codex|all <name>` | runtime-native config | re-apply plugin pack after toolkit updates |
40
+ | `ai-toolkit plugin remove --editor claude|codex|all <name>` | runtime-native config | remove plugin pack from selected runtime(s) |
32
41
 
33
42
  ## Why global install is the default
34
43
 
@@ -39,10 +48,17 @@ That means one machine-level install provides agents, skills, hooks, and rules t
39
48
 
40
49
  ## What remains project-local
41
50
 
42
- These files still stay local to a repository:
51
+ These files still stay local to a repository as part of the core install model:
43
52
  - `CLAUDE.md`
44
53
  - `.claude/settings.local.json`
54
+ - `.mcp.json`
55
+ - `.cursor/mcp.json`
56
+ - `.github/mcp.json`
45
57
  - `.claude/constitution.md`
58
+ - project `AGENTS.md`
59
+ - project `.agents/rules/*.md`
60
+ - project `.agents/skills/*`
61
+ - project `.codex/hooks.json`
46
62
  - `.github/copilot-instructions.md`
47
63
  - `.clinerules`
48
64
  - `.roomodes`
@@ -54,7 +70,48 @@ These files still stay local to a repository:
54
70
 
55
71
  Hooks do **not** live in project-local settings. They are merged only into global `~/.claude/settings.json`.
56
72
 
73
+ Codex is the exception in terms of file location, not hook ownership: its local
74
+ `.codex/hooks.json` points to hook scripts already installed globally in
75
+ `~/.softspark/ai-toolkit/hooks/`.
76
+
77
+ ## Codex Local Install Behavior
78
+
79
+ `ai-toolkit install --local --editors codex` creates:
80
+
81
+ - `AGENTS.md`
82
+ - `.agents/rules/*.md`
83
+ - `.agents/skills/*`
84
+ - `.codex/hooks.json`
85
+
86
+ Native Codex-compatible skills are linked directly. Claude-oriented skills that
87
+ depend on `Agent`, `Team*`, or `Task*` primitives are translated into generated
88
+ Codex wrappers so the project still receives the full skill catalog.
89
+
90
+ ## Codex Global Plugin Layer
91
+
92
+ `ai-toolkit plugin install --editor codex <pack>` additionally targets:
93
+
94
+ - `~/AGENTS.md`
95
+ - `~/.agents/rules/*.md`
96
+ - `~/.agents/skills/*`
97
+ - `~/.codex/hooks.json`
98
+
99
+ This is not the default core install path. It is an explicit, opt-in plugin
100
+ layer used only for plugin packs. Runtime state is tracked in
101
+ `~/.softspark/ai-toolkit/plugins.json` per target (`claude`, `codex`).
102
+
103
+ ## MCP Local Sync Behavior
104
+
105
+ If `.mcp.json` exists in the current project, `ai-toolkit install --local` mirrors its `mcpServers` block into:
106
+ - `.claude/settings.local.json`
107
+ - `.cursor/mcp.json` when `--editors cursor` is selected
108
+ - `.github/mcp.json` when `--editors copilot` is selected
109
+
110
+ Global-only editor MCP configs are not written during `install --local`. Use `ai-toolkit mcp install --editor <name...>` for those targets.
111
+
57
112
  ## Related Documents
58
113
 
59
114
  - `kb/reference/distribution-model.md`
60
115
  - `kb/reference/merge-friendly-install-model.md`
116
+ - `kb/reference/codex-cli-compatibility.md`
117
+ - `kb/reference/mcp-editor-compatibility.md`
@@ -0,0 +1,62 @@
1
+ ---
2
+ title: "AI Toolkit - MCP Editor Compatibility"
3
+ category: reference
4
+ service: ai-toolkit
5
+ tags: [mcp, editors, compatibility, codex, cursor]
6
+ version: "1.0.0"
7
+ created: "2026-04-12"
8
+ last_updated: "2026-04-12"
9
+ description: "Official MCP support matrix and native config targets for editors supported by ai-toolkit."
10
+ ---
11
+
12
+ # MCP Editor Compatibility
13
+
14
+ ## Overview
15
+
16
+ ai-toolkit keeps `.mcp.json` as the project-level canonical template format and can render that config into native editor MCP files where the editor exposes a stable, documented configuration surface.
17
+
18
+ ## Supported Native Adapters
19
+
20
+ | Editor | Scope | Native Config Path | Adapter Behavior |
21
+ |--------|-------|--------------------|------------------|
22
+ | Claude Code | project + global | `.claude/settings.local.json`, `~/.claude/settings.json` | Merges `mcpServers` while preserving other settings keys |
23
+ | Cursor | project + global | `.cursor/mcp.json`, `~/.cursor/mcp.json` | Mirrors `mcpServers` directly |
24
+ | GitHub Copilot | project + global | `.github/mcp.json`, `~/.copilot/mcp-config.json` | Adds Copilot-required `type` and `tools` fields |
25
+ | Gemini CLI | project + global | `.gemini/settings.json`, `~/.gemini/settings.json` | Merges `mcpServers` into settings JSON |
26
+ | Windsurf | global | `~/.codeium/windsurf/mcp_config.json` | Global-only JSON config |
27
+ | Cline | global | `~/.cline/data/settings/cline_mcp_settings.json` | Global-only JSON config |
28
+ | Augment | global | `~/.augment/settings.json` | Global-only JSON settings file |
29
+ | Codex CLI | global | `~/.codex/config.toml` | Renders JSON templates as TOML `mcp_servers` tables |
30
+
31
+ ## Unsupported for Automatic Install
32
+
33
+ These editors are still supported by ai-toolkit for rules and instructions, but ai-toolkit does not currently auto-write MCP config because a stable official file target was not adopted:
34
+
35
+ | Editor | Reason |
36
+ |--------|--------|
37
+ | Roo Code | MCP support exists, but no verified official file path was adopted in ai-toolkit |
38
+ | Aider | No verified native MCP config surface was adopted in ai-toolkit |
39
+ | Google Antigravity | MCP can be configured via UI/import flows, but no stable file target was adopted in ai-toolkit |
40
+
41
+ ## CLI
42
+
43
+ ```bash
44
+ ai-toolkit mcp editors
45
+ ai-toolkit mcp install --editor cursor --scope project github --target .
46
+ ai-toolkit mcp install --editor codex context7
47
+ ai-toolkit mcp remove github --editor cursor --scope project --target .
48
+ ```
49
+
50
+ ## Install Flow Integration
51
+
52
+ When `.mcp.json` exists in a project, `ai-toolkit install --local` mirrors its servers into:
53
+ - `.claude/settings.local.json`
54
+ - `.cursor/mcp.json` when `--editors cursor` is selected
55
+ - `.github/mcp.json` when `--editors copilot` is selected
56
+
57
+ Global-only clients are configured explicitly via `ai-toolkit mcp install --editor ...`.
58
+
59
+ ## Related
60
+
61
+ - [PATH: kb/reference/mcp-templates.md] — template catalog and CLI
62
+ - [PATH: kb/reference/extension-api.md] — extension API surface
@@ -2,33 +2,58 @@
2
2
  title: "MCP Server Templates"
3
3
  category: reference
4
4
  service: ai-toolkit
5
- tags: [mcp, templates, servers, configuration]
6
- version: "1.0.0"
5
+ tags: [mcp, templates, servers, configuration, editors]
6
+ version: "1.1.0"
7
7
  created: "2026-04-07"
8
- last_updated: "2026-04-07"
9
- description: "Reference for 25 MCP server configuration templates: GitHub, PostgreSQL, Slack, Sentry, and more."
8
+ last_updated: "2026-04-12"
9
+ description: "Reference for 25 MCP server templates plus native editor MCP installation support."
10
10
  ---
11
11
 
12
12
  # MCP Server Templates
13
13
 
14
14
  ## Overview
15
15
 
16
- ai-toolkit ships 25 ready-to-use MCP server configuration templates in `app/mcp-templates/`. Each template is a JSON file that defines the `mcpServers` block for a specific service. Templates are merged into the project's `.mcp.json` via the `ai-toolkit mcp` CLI subcommand.
16
+ ai-toolkit ships 25 ready-to-use MCP server configuration templates in `app/mcp-templates/`. Each template is a JSON file that defines the canonical `mcpServers` block for a specific service. Templates can be merged into the project's `.mcp.json` and rendered into editor-native MCP config files via the `ai-toolkit mcp` CLI subcommand.
17
17
 
18
18
  ## CLI
19
19
 
20
20
  ```bash
21
21
  ai-toolkit mcp list # List all available templates
22
+ ai-toolkit mcp editors # List editors with native MCP adapters
22
23
  ai-toolkit mcp show <name> # Print a template's JSON config
23
24
  ai-toolkit mcp add <name> # Merge a template into .mcp.json
24
25
  ai-toolkit mcp add <n1> <n2> # Add multiple templates at once
25
- ai-toolkit mcp remove <name> # Remove a server entry from .mcp.json
26
+ ai-toolkit mcp install --editor cursor --scope project github --target .
27
+ ai-toolkit mcp install --editor codex context7
28
+ ai-toolkit mcp remove <name> # Remove from .mcp.json or native editor config
26
29
  ```
27
30
 
28
31
  **Implementation:** `scripts/mcp_manager.py`
29
32
 
30
33
  The `add` command merges the `mcpServers` block from the template into `.mcp.json`. If `.mcp.json` does not exist it is created. If the server name already exists in `.mcp.json`, the entry is overwritten with the template version.
31
34
 
35
+ The `install` command renders the same canonical template into an editor-native config format:
36
+ - JSON clients with `mcpServers` blocks: Claude Code, Cursor, Gemini CLI, Windsurf, Cline, Augment
37
+ - JSON clients with additional transport metadata: GitHub Copilot
38
+ - TOML clients: Codex CLI (`[mcp_servers.<name>]`)
39
+
40
+ When `install` runs with `--scope project`, ai-toolkit also updates the project's `.mcp.json` so it remains the source of truth for later syncs.
41
+
42
+ ## Editor Support Matrix
43
+
44
+ | Editor | Scope | Native Config Path | Notes |
45
+ |--------|-------|--------------------|-------|
46
+ | `claude` | project + global | `.claude/settings.local.json`, `~/.claude/settings.json` | Preserves existing hooks and env keys |
47
+ | `cursor` | project + global | `.cursor/mcp.json`, `~/.cursor/mcp.json` | Mirrors canonical `mcpServers` |
48
+ | `copilot` | project + global | `.github/mcp.json`, `~/.copilot/mcp-config.json` | Adds `type` and `tools: ["*"]` automatically |
49
+ | `gemini` | project + global | `.gemini/settings.json`, `~/.gemini/settings.json` | Uses Gemini CLI `mcpServers` format |
50
+ | `windsurf` | global | `~/.codeium/windsurf/mcp_config.json` | Global-only official config |
51
+ | `cline` | global | `~/.cline/data/settings/cline_mcp_settings.json` | Global-only official config |
52
+ | `augment` | global | `~/.augment/settings.json` | Global-only settings file |
53
+ | `codex` | global | `~/.codex/config.toml` | Rendered as TOML `mcp_servers` tables |
54
+
55
+ Project-local `ai-toolkit install --local` also mirrors `.mcp.json` into Claude project settings plus selected project editors that have official repository/workspace MCP files (`cursor`, `copilot`).
56
+
32
57
  ## Template List
33
58
 
34
59
  | Name | Description | Required Env Vars |
@@ -108,3 +133,4 @@ export GITHUB_PERSONAL_ACCESS_TOKEN=ghp_...
108
133
 
109
134
  - [PATH: kb/reference/extension-api.md] — `mcp add` as part of the extension API
110
135
  - [PATH: kb/reference/architecture-overview.md] — overall install model
136
+ - [PATH: kb/reference/mcp-editor-compatibility.md] — native editor MCP support matrix