xtctx 0.3.2 → 0.11.1
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.
- package/CHANGELOG.md +267 -122
- package/LICENSE +21 -21
- package/README.md +154 -121
- package/dist/src/cli/disconnect.d.ts +8 -0
- package/dist/src/cli/disconnect.d.ts.map +1 -0
- package/dist/src/cli/disconnect.js +42 -0
- package/dist/src/cli/disconnect.js.map +1 -0
- package/dist/src/cli/hook.d.ts +7 -0
- package/dist/src/cli/hook.d.ts.map +1 -0
- package/dist/src/cli/hook.js +21 -0
- package/dist/src/cli/hook.js.map +1 -0
- package/dist/src/cli/index.d.ts.map +1 -1
- package/dist/src/cli/index.js +71 -33
- package/dist/src/cli/index.js.map +1 -1
- package/dist/src/cli/setup.d.ts +8 -0
- package/dist/src/cli/setup.d.ts.map +1 -0
- package/dist/src/cli/setup.js +77 -0
- package/dist/src/cli/setup.js.map +1 -0
- package/dist/src/cli/status.d.ts +7 -0
- package/dist/src/cli/status.d.ts.map +1 -0
- package/dist/src/cli/status.js +84 -0
- package/dist/src/cli/status.js.map +1 -0
- package/dist/src/config/disconnect.d.ts +32 -0
- package/dist/src/config/disconnect.d.ts.map +1 -0
- package/dist/src/config/disconnect.js +304 -0
- package/dist/src/config/disconnect.js.map +1 -0
- package/dist/src/config/mcp-config.d.ts +91 -0
- package/dist/src/config/mcp-config.d.ts.map +1 -0
- package/dist/src/config/mcp-config.js +462 -0
- package/dist/src/config/mcp-config.js.map +1 -0
- package/dist/src/config/setup.d.ts +37 -0
- package/dist/src/config/setup.d.ts.map +1 -0
- package/dist/src/config/setup.js +338 -0
- package/dist/src/config/setup.js.map +1 -0
- package/dist/src/config/skills.d.ts +73 -0
- package/dist/src/config/skills.d.ts.map +1 -0
- package/dist/src/config/skills.js +427 -0
- package/dist/src/config/skills.js.map +1 -0
- package/dist/src/handoff/embeddings.d.ts +15 -0
- package/dist/src/handoff/embeddings.d.ts.map +1 -0
- package/dist/src/handoff/embeddings.js +63 -0
- package/dist/src/handoff/embeddings.js.map +1 -0
- package/dist/src/handoff/sqlite-index.d.ts +43 -0
- package/dist/src/handoff/sqlite-index.d.ts.map +1 -0
- package/dist/src/handoff/sqlite-index.js +718 -0
- package/dist/src/handoff/sqlite-index.js.map +1 -0
- package/dist/src/handoff/types.d.ts +57 -0
- package/dist/src/handoff/types.d.ts.map +1 -0
- package/dist/src/handoff/types.js +2 -0
- package/dist/src/handoff/types.js.map +1 -0
- package/dist/src/handoff/vector.d.ts +4 -0
- package/dist/src/handoff/vector.d.ts.map +1 -0
- package/dist/src/handoff/vector.js +31 -0
- package/dist/src/handoff/vector.js.map +1 -0
- package/dist/src/mcp/server.d.ts +2 -19
- package/dist/src/mcp/server.d.ts.map +1 -1
- package/dist/src/mcp/server.js +75 -199
- package/dist/src/mcp/server.js.map +1 -1
- package/dist/src/mcp/tools/continuity.d.ts +3 -0
- package/dist/src/mcp/tools/continuity.d.ts.map +1 -0
- package/dist/src/mcp/tools/continuity.js +30 -0
- package/dist/src/mcp/tools/continuity.js.map +1 -0
- package/dist/src/mcp/tools/manifest.d.ts +40 -0
- package/dist/src/mcp/tools/manifest.d.ts.map +1 -0
- package/dist/src/mcp/tools/manifest.js +96 -0
- package/dist/src/mcp/tools/manifest.js.map +1 -0
- package/dist/src/mcp/tools/sessions.d.ts +11 -32
- package/dist/src/mcp/tools/sessions.d.ts.map +1 -1
- package/dist/src/mcp/tools/sessions.js +47 -13
- package/dist/src/mcp/tools/sessions.js.map +1 -1
- package/dist/src/runtime/services.d.ts +11 -38
- package/dist/src/runtime/services.d.ts.map +1 -1
- package/dist/src/runtime/services.js +43 -202
- package/dist/src/runtime/services.js.map +1 -1
- package/dist/src/scrapers/antigravity.d.ts +41 -0
- package/dist/src/scrapers/antigravity.d.ts.map +1 -0
- package/dist/src/scrapers/antigravity.js +858 -0
- package/dist/src/scrapers/antigravity.js.map +1 -0
- package/dist/src/scrapers/base.d.ts +53 -1
- package/dist/src/scrapers/base.d.ts.map +1 -1
- package/dist/src/scrapers/base.js +89 -3
- package/dist/src/scrapers/base.js.map +1 -1
- package/dist/src/scrapers/claude-code.d.ts +20 -6
- package/dist/src/scrapers/claude-code.d.ts.map +1 -1
- package/dist/src/scrapers/claude-code.js +144 -26
- package/dist/src/scrapers/claude-code.js.map +1 -1
- package/dist/src/scrapers/codex.d.ts +36 -6
- package/dist/src/scrapers/codex.d.ts.map +1 -1
- package/dist/src/scrapers/codex.js +256 -46
- package/dist/src/scrapers/codex.js.map +1 -1
- package/dist/src/scrapers/copilot-cli.d.ts +33 -0
- package/dist/src/scrapers/copilot-cli.d.ts.map +1 -0
- package/dist/src/scrapers/copilot-cli.js +257 -0
- package/dist/src/scrapers/copilot-cli.js.map +1 -0
- package/dist/src/scrapers/copilot.d.ts +41 -8
- package/dist/src/scrapers/copilot.d.ts.map +1 -1
- package/dist/src/scrapers/copilot.js +256 -118
- package/dist/src/scrapers/copilot.js.map +1 -1
- package/dist/src/scrapers/cursor.d.ts +24 -9
- package/dist/src/scrapers/cursor.d.ts.map +1 -1
- package/dist/src/scrapers/cursor.js +247 -151
- package/dist/src/scrapers/cursor.js.map +1 -1
- package/dist/src/scrapers/index.d.ts +18 -0
- package/dist/src/scrapers/index.d.ts.map +1 -0
- package/dist/src/scrapers/index.js +17 -0
- package/dist/src/scrapers/index.js.map +1 -0
- package/dist/src/scrapers/opencode.d.ts +36 -0
- package/dist/src/scrapers/opencode.d.ts.map +1 -0
- package/dist/src/scrapers/opencode.js +248 -0
- package/dist/src/scrapers/opencode.js.map +1 -0
- package/dist/src/scrapers/registry.d.ts +1 -0
- package/dist/src/scrapers/registry.d.ts.map +1 -1
- package/dist/src/scrapers/registry.js +3 -0
- package/dist/src/scrapers/registry.js.map +1 -1
- package/dist/src/tools/sources.d.ts +28 -0
- package/dist/src/tools/sources.d.ts.map +1 -0
- package/dist/src/tools/sources.js +149 -0
- package/dist/src/tools/sources.js.map +1 -0
- package/dist/src/types/config.d.ts +24 -37
- package/dist/src/types/config.d.ts.map +1 -1
- package/dist/src/types/index.d.ts +0 -2
- package/dist/src/types/index.d.ts.map +1 -1
- package/dist/src/types/index.js +0 -2
- package/dist/src/types/index.js.map +1 -1
- package/dist/src/types/scraper.d.ts +34 -5
- package/dist/src/types/scraper.d.ts.map +1 -1
- package/dist/src/utils/errors.d.ts +2 -0
- package/dist/src/utils/errors.d.ts.map +1 -0
- package/dist/src/utils/errors.js +7 -0
- package/dist/src/utils/errors.js.map +1 -0
- package/dist/src/utils/package-info.d.ts +11 -0
- package/dist/src/utils/package-info.d.ts.map +1 -0
- package/dist/src/utils/package-info.js +30 -0
- package/dist/src/utils/package-info.js.map +1 -0
- package/dist/src/utils/project-scope.d.ts +3 -0
- package/dist/src/utils/project-scope.d.ts.map +1 -0
- package/dist/src/utils/project-scope.js +45 -0
- package/dist/src/utils/project-scope.js.map +1 -0
- package/package.json +70 -66
- package/dist/src/api/routes/config.d.ts +0 -4
- package/dist/src/api/routes/config.d.ts.map +0 -1
- package/dist/src/api/routes/config.js +0 -61
- package/dist/src/api/routes/config.js.map +0 -1
- package/dist/src/api/routes/knowledge.d.ts +0 -4
- package/dist/src/api/routes/knowledge.d.ts.map +0 -1
- package/dist/src/api/routes/knowledge.js +0 -40
- package/dist/src/api/routes/knowledge.js.map +0 -1
- package/dist/src/api/routes/search.d.ts +0 -7
- package/dist/src/api/routes/search.d.ts.map +0 -1
- package/dist/src/api/routes/search.js +0 -108
- package/dist/src/api/routes/search.js.map +0 -1
- package/dist/src/api/routes/sources.d.ts +0 -12
- package/dist/src/api/routes/sources.d.ts.map +0 -1
- package/dist/src/api/routes/sources.js +0 -70
- package/dist/src/api/routes/sources.js.map +0 -1
- package/dist/src/api/server.d.ts +0 -26
- package/dist/src/api/server.d.ts.map +0 -1
- package/dist/src/api/server.js +0 -312
- package/dist/src/api/server.js.map +0 -1
- package/dist/src/cli/ingest.d.ts +0 -6
- package/dist/src/cli/ingest.d.ts.map +0 -1
- package/dist/src/cli/ingest.js +0 -11
- package/dist/src/cli/ingest.js.map +0 -1
- package/dist/src/cli/init.d.ts +0 -6
- package/dist/src/cli/init.d.ts.map +0 -1
- package/dist/src/cli/init.js +0 -105
- package/dist/src/cli/init.js.map +0 -1
- package/dist/src/cli/serve.d.ts +0 -7
- package/dist/src/cli/serve.d.ts.map +0 -1
- package/dist/src/cli/serve.js +0 -100
- package/dist/src/cli/serve.js.map +0 -1
- package/dist/src/cli/sync.d.ts +0 -5
- package/dist/src/cli/sync.d.ts.map +0 -1
- package/dist/src/cli/sync.js +0 -13
- package/dist/src/cli/sync.js.map +0 -1
- package/dist/src/compaction/pipeline.d.ts +0 -19
- package/dist/src/compaction/pipeline.d.ts.map +0 -1
- package/dist/src/compaction/pipeline.js +0 -37
- package/dist/src/compaction/pipeline.js.map +0 -1
- package/dist/src/compaction/providers/cli.d.ts +0 -13
- package/dist/src/compaction/providers/cli.d.ts.map +0 -1
- package/dist/src/compaction/providers/cli.js +0 -60
- package/dist/src/compaction/providers/cli.js.map +0 -1
- package/dist/src/compaction/rule-based.d.ts +0 -8
- package/dist/src/compaction/rule-based.d.ts.map +0 -1
- package/dist/src/compaction/rule-based.js +0 -120
- package/dist/src/compaction/rule-based.js.map +0 -1
- package/dist/src/config/loader.d.ts +0 -12
- package/dist/src/config/loader.d.ts.map +0 -1
- package/dist/src/config/loader.js +0 -76
- package/dist/src/config/loader.js.map +0 -1
- package/dist/src/config/mappings/claude-code.d.ts +0 -3
- package/dist/src/config/mappings/claude-code.d.ts.map +0 -1
- package/dist/src/config/mappings/claude-code.js +0 -31
- package/dist/src/config/mappings/claude-code.js.map +0 -1
- package/dist/src/config/mappings/codex.d.ts +0 -3
- package/dist/src/config/mappings/codex.d.ts.map +0 -1
- package/dist/src/config/mappings/codex.js +0 -31
- package/dist/src/config/mappings/codex.js.map +0 -1
- package/dist/src/config/mappings/copilot.d.ts +0 -3
- package/dist/src/config/mappings/copilot.d.ts.map +0 -1
- package/dist/src/config/mappings/copilot.js +0 -33
- package/dist/src/config/mappings/copilot.js.map +0 -1
- package/dist/src/config/mappings/cursor.d.ts +0 -3
- package/dist/src/config/mappings/cursor.d.ts.map +0 -1
- package/dist/src/config/mappings/cursor.js +0 -29
- package/dist/src/config/mappings/cursor.js.map +0 -1
- package/dist/src/config/sync.d.ts +0 -13
- package/dist/src/config/sync.d.ts.map +0 -1
- package/dist/src/config/sync.js +0 -96
- package/dist/src/config/sync.js.map +0 -1
- package/dist/src/ingestion/coordinator.d.ts +0 -37
- package/dist/src/ingestion/coordinator.d.ts.map +0 -1
- package/dist/src/ingestion/coordinator.js +0 -127
- package/dist/src/ingestion/coordinator.js.map +0 -1
- package/dist/src/ingestion/daemon.d.ts +0 -17
- package/dist/src/ingestion/daemon.d.ts.map +0 -1
- package/dist/src/ingestion/daemon.js +0 -35
- package/dist/src/ingestion/daemon.js.map +0 -1
- package/dist/src/ingestion/watcher.d.ts +0 -19
- package/dist/src/ingestion/watcher.d.ts.map +0 -1
- package/dist/src/ingestion/watcher.js +0 -70
- package/dist/src/ingestion/watcher.js.map +0 -1
- package/dist/src/knowledge/autotag.d.ts +0 -3
- package/dist/src/knowledge/autotag.d.ts.map +0 -1
- package/dist/src/knowledge/autotag.js +0 -24
- package/dist/src/knowledge/autotag.js.map +0 -1
- package/dist/src/knowledge/dedup.d.ts +0 -7
- package/dist/src/knowledge/dedup.d.ts.map +0 -1
- package/dist/src/knowledge/dedup.js +0 -15
- package/dist/src/knowledge/dedup.js.map +0 -1
- package/dist/src/knowledge/repository.d.ts +0 -12
- package/dist/src/knowledge/repository.d.ts.map +0 -1
- package/dist/src/knowledge/repository.js +0 -74
- package/dist/src/knowledge/repository.js.map +0 -1
- package/dist/src/mcp/tools/config.d.ts +0 -36
- package/dist/src/mcp/tools/config.d.ts.map +0 -1
- package/dist/src/mcp/tools/config.js +0 -54
- package/dist/src/mcp/tools/config.js.map +0 -1
- package/dist/src/mcp/tools/knowledge.d.ts +0 -17
- package/dist/src/mcp/tools/knowledge.d.ts.map +0 -1
- package/dist/src/mcp/tools/knowledge.js +0 -46
- package/dist/src/mcp/tools/knowledge.js.map +0 -1
- package/dist/src/mcp/tools/search.d.ts +0 -22
- package/dist/src/mcp/tools/search.d.ts.map +0 -1
- package/dist/src/mcp/tools/search.js +0 -30
- package/dist/src/mcp/tools/search.js.map +0 -1
- package/dist/src/mcp/tools/write.d.ts +0 -38
- package/dist/src/mcp/tools/write.d.ts.map +0 -1
- package/dist/src/mcp/tools/write.js +0 -97
- package/dist/src/mcp/tools/write.js.map +0 -1
- package/dist/src/runtime/ingestion.d.ts +0 -17
- package/dist/src/runtime/ingestion.d.ts.map +0 -1
- package/dist/src/runtime/ingestion.js +0 -106
- package/dist/src/runtime/ingestion.js.map +0 -1
- package/dist/src/scrapers/gemini.d.ts +0 -17
- package/dist/src/scrapers/gemini.d.ts.map +0 -1
- package/dist/src/scrapers/gemini.js +0 -245
- package/dist/src/scrapers/gemini.js.map +0 -1
- package/dist/src/store/embeddings.d.ts +0 -9
- package/dist/src/store/embeddings.d.ts.map +0 -1
- package/dist/src/store/embeddings.js +0 -28
- package/dist/src/store/embeddings.js.map +0 -1
- package/dist/src/store/lance.d.ts +0 -25
- package/dist/src/store/lance.d.ts.map +0 -1
- package/dist/src/store/lance.js +0 -74
- package/dist/src/store/lance.js.map +0 -1
- package/dist/src/store/search.d.ts +0 -18
- package/dist/src/store/search.d.ts.map +0 -1
- package/dist/src/store/search.js +0 -55
- package/dist/src/store/search.js.map +0 -1
- package/dist/src/types/compaction.d.ts +0 -29
- package/dist/src/types/compaction.d.ts.map +0 -1
- package/dist/src/types/compaction.js +0 -2
- package/dist/src/types/compaction.js.map +0 -1
- package/dist/src/types/context.d.ts +0 -33
- package/dist/src/types/context.d.ts.map +0 -1
- package/dist/src/types/context.js +0 -18
- package/dist/src/types/context.js.map +0 -1
- package/dist/src/utils/retry.d.ts +0 -11
- package/dist/src/utils/retry.d.ts.map +0 -1
- package/dist/src/utils/retry.js +0 -46
- package/dist/src/utils/retry.js.map +0 -1
- package/dist/src/utils/shutdown.d.ts +0 -25
- package/dist/src/utils/shutdown.d.ts.map +0 -1
- package/dist/src/utils/shutdown.js +0 -56
- package/dist/src/utils/shutdown.js.map +0 -1
- package/dist/web/apple-touch-icon.png +0 -0
- package/dist/web/assets/index-Nuadr5ox.css +0 -1
- package/dist/web/assets/index-aA0u8eXA.js +0 -3504
- package/dist/web/assets/primeicons-C6QP2o4f.woff2 +0 -0
- package/dist/web/assets/primeicons-DMOk5skT.eot +0 -0
- package/dist/web/assets/primeicons-Dr5RGzOO.svg +0 -345
- package/dist/web/assets/primeicons-MpK4pl85.ttf +0 -0
- package/dist/web/assets/primeicons-WjwUDZjB.woff +0 -0
- package/dist/web/favicon.ico +0 -0
- package/dist/web/favicon.svg +0 -21
- package/dist/web/index.html +0 -21
- package/dist/web/site.webmanifest +0 -19
- package/dist/web/vite.svg +0 -1
|
@@ -0,0 +1,462 @@
|
|
|
1
|
+
import { mkdir, readFile, writeFile } from "node:fs/promises";
|
|
2
|
+
import { homedir } from "node:os";
|
|
3
|
+
import { dirname, join } from "node:path";
|
|
4
|
+
import { parse as parseToml, stringify as stringifyToml } from "@iarna/toml";
|
|
5
|
+
import { errorMessage } from "../utils/errors.js";
|
|
6
|
+
/**
|
|
7
|
+
* Tools with native MCP configuration support.
|
|
8
|
+
*
|
|
9
|
+
* Tools NOT listed here receive MCP connection details embedded in their
|
|
10
|
+
* managed-block instructions file via `renderMcpServersMarkdown`.
|
|
11
|
+
*/
|
|
12
|
+
const NATIVE_MCP_TOOLS = {
|
|
13
|
+
// Claude Code — `.mcp.json` at project root, `mcpServers` key, stdio entries.
|
|
14
|
+
// Keep both aliases because older local setup files may refer to `claude`,
|
|
15
|
+
// while the current scraper/tool id is `claude-code`.
|
|
16
|
+
claude: {
|
|
17
|
+
projectPath: (root) => join(root, ".mcp.json"),
|
|
18
|
+
},
|
|
19
|
+
"claude-code": {
|
|
20
|
+
projectPath: (root) => join(root, ".mcp.json"),
|
|
21
|
+
},
|
|
22
|
+
// Cursor — `.cursor/mcp.json` at project root, same JSON shape.
|
|
23
|
+
cursor: {
|
|
24
|
+
projectPath: (root) => join(root, ".cursor", "mcp.json"),
|
|
25
|
+
},
|
|
26
|
+
// VS Code GitHub Copilot — `.vscode/mcp.json`. Note: the root key is
|
|
27
|
+
// `servers`, not `mcpServers` (per VS Code's MCP configuration reference).
|
|
28
|
+
copilot: {
|
|
29
|
+
projectPath: (root) => join(root, ".vscode", "mcp.json"),
|
|
30
|
+
rootKey: "servers",
|
|
31
|
+
},
|
|
32
|
+
// Codex CLI — TOML at `.codex/config.toml` (project) or `~/.codex/config.toml`
|
|
33
|
+
// (global). Server entries live under `[mcp_servers.<name>]` tables. Codex's
|
|
34
|
+
// TOML format uses `command` + `args` + `env` and does NOT include a `type`
|
|
35
|
+
// field (stdio is implicit).
|
|
36
|
+
codex: {
|
|
37
|
+
format: "toml",
|
|
38
|
+
projectPath: (root) => join(root, ".codex", "config.toml"),
|
|
39
|
+
globalPath: (home) => join(home, ".codex", "config.toml"),
|
|
40
|
+
rootKey: "mcp_servers",
|
|
41
|
+
buildEntry: buildCodexEntry,
|
|
42
|
+
},
|
|
43
|
+
// Google Antigravity — JSON at `~/.gemini/antigravity/mcp_config.json`.
|
|
44
|
+
// App-level config under the Gemini state directory; entries omit `type`.
|
|
45
|
+
antigravity: {
|
|
46
|
+
globalPath: (home) => join(home, ".gemini", "antigravity", "mcp_config.json"),
|
|
47
|
+
buildEntry: buildAntigravityEntry,
|
|
48
|
+
},
|
|
49
|
+
// opencode (sst/opencode-ai) — JSON at `opencode.json` (project) or
|
|
50
|
+
// `~/.config/opencode/opencode.json` (global). Top-level `mcp` key. Entries
|
|
51
|
+
// use `type: "local" | "remote"`, `command` as a combined ARRAY of
|
|
52
|
+
// strings (executable + args together), `enabled: true`, and `environment`
|
|
53
|
+
// (not `env`) for env vars on local servers. Remote uses `url` + `headers`.
|
|
54
|
+
opencode: {
|
|
55
|
+
projectPath: (root) => join(root, "opencode.json"),
|
|
56
|
+
globalPath: (home) => join(home, ".config", "opencode", "opencode.json"),
|
|
57
|
+
rootKey: "mcp",
|
|
58
|
+
buildEntry: buildOpencodeEntry,
|
|
59
|
+
},
|
|
60
|
+
// GitHub Copilot CLI (the standalone `~/.copilot/`-rooted CLI, distinct
|
|
61
|
+
// from VS Code Copilot) — JSON at `~/.copilot/mcp-config.json`. User-level
|
|
62
|
+
// only; project-level MCP for Copilot CLI lives in `.mcp.json` at the
|
|
63
|
+
// project root, which is already written by the `claude` / `claude-code`
|
|
64
|
+
// renderers above (one file, two consumers).
|
|
65
|
+
"copilot-cli": {
|
|
66
|
+
globalPath: (home) => join(home, ".copilot", "mcp-config.json"),
|
|
67
|
+
buildEntry: buildCopilotCliEntry,
|
|
68
|
+
},
|
|
69
|
+
};
|
|
70
|
+
export function hasNativeMcpSupport(tool) {
|
|
71
|
+
return tool in NATIVE_MCP_TOOLS;
|
|
72
|
+
}
|
|
73
|
+
export function isGlobalOnlyMcpTool(tool) {
|
|
74
|
+
const renderer = NATIVE_MCP_TOOLS[tool];
|
|
75
|
+
return Boolean(renderer?.globalPath && !renderer.projectPath);
|
|
76
|
+
}
|
|
77
|
+
/**
|
|
78
|
+
* Sync MCP server configs into native formats for tools that support them.
|
|
79
|
+
*
|
|
80
|
+
* For each enabled tool with a renderer:
|
|
81
|
+
* - Prefer the project-scoped path if the renderer provides one
|
|
82
|
+
* - Fall back to the user-scoped path if project is unset (Copilot CLI)
|
|
83
|
+
* - Skip duplicate writes when two renderer aliases resolve to the same
|
|
84
|
+
* file path (claude + claude-code both write `.mcp.json`)
|
|
85
|
+
*/
|
|
86
|
+
export async function syncToolMcpConfigs(projectRoot, servers, enabledTools, options = {}) {
|
|
87
|
+
if (servers.length === 0) {
|
|
88
|
+
return { results: [], servers_loaded: 0 };
|
|
89
|
+
}
|
|
90
|
+
const home = options.homeDir ?? homedir();
|
|
91
|
+
const results = [];
|
|
92
|
+
const writtenPaths = new Set();
|
|
93
|
+
for (const tool of enabledTools) {
|
|
94
|
+
const renderer = NATIVE_MCP_TOOLS[tool];
|
|
95
|
+
if (!renderer)
|
|
96
|
+
continue;
|
|
97
|
+
// Choose path: project preferred, fall back to global. Tools without
|
|
98
|
+
// a project path (Copilot CLI) write to global only.
|
|
99
|
+
let configPath = null;
|
|
100
|
+
let scope = "project";
|
|
101
|
+
if (renderer.projectPath) {
|
|
102
|
+
configPath = renderer.projectPath(projectRoot);
|
|
103
|
+
scope = "project";
|
|
104
|
+
}
|
|
105
|
+
else if (renderer.globalPath) {
|
|
106
|
+
configPath = renderer.globalPath(home);
|
|
107
|
+
scope = "global";
|
|
108
|
+
}
|
|
109
|
+
if (!configPath)
|
|
110
|
+
continue;
|
|
111
|
+
if (writtenPaths.has(configPath)) {
|
|
112
|
+
results.push({
|
|
113
|
+
tool,
|
|
114
|
+
path: configPath,
|
|
115
|
+
scope,
|
|
116
|
+
updated: false,
|
|
117
|
+
created: false,
|
|
118
|
+
skipped: true,
|
|
119
|
+
});
|
|
120
|
+
continue;
|
|
121
|
+
}
|
|
122
|
+
writtenPaths.add(configPath);
|
|
123
|
+
const result = await writeMcpConfig(tool, configPath, scope, renderer, servers);
|
|
124
|
+
results.push(result);
|
|
125
|
+
}
|
|
126
|
+
return { results, servers_loaded: servers.length };
|
|
127
|
+
}
|
|
128
|
+
export async function removeMcpServerConfigs(projectRoot, serverName, tools, options = {}) {
|
|
129
|
+
const home = options.homeDir ?? homedir();
|
|
130
|
+
const results = [];
|
|
131
|
+
const writtenPaths = new Set();
|
|
132
|
+
for (const tool of tools) {
|
|
133
|
+
const renderer = NATIVE_MCP_TOOLS[tool];
|
|
134
|
+
if (!renderer)
|
|
135
|
+
continue;
|
|
136
|
+
const target = resolveConfigTarget(projectRoot, home, renderer);
|
|
137
|
+
if (!target)
|
|
138
|
+
continue;
|
|
139
|
+
if (writtenPaths.has(target.path)) {
|
|
140
|
+
results.push({
|
|
141
|
+
tool,
|
|
142
|
+
path: target.path,
|
|
143
|
+
scope: target.scope,
|
|
144
|
+
removed: false,
|
|
145
|
+
skipped: true,
|
|
146
|
+
});
|
|
147
|
+
continue;
|
|
148
|
+
}
|
|
149
|
+
writtenPaths.add(target.path);
|
|
150
|
+
results.push(await removeMcpConfig(tool, target.path, target.scope, renderer, serverName));
|
|
151
|
+
}
|
|
152
|
+
return { results };
|
|
153
|
+
}
|
|
154
|
+
// ---------------------------------------------------------------------------
|
|
155
|
+
// Generic writer + merge
|
|
156
|
+
// ---------------------------------------------------------------------------
|
|
157
|
+
async function writeMcpConfig(tool, configPath, scope, renderer, servers) {
|
|
158
|
+
try {
|
|
159
|
+
const format = renderer.format ?? "json";
|
|
160
|
+
const rootKey = renderer.rootKey ?? "mcpServers";
|
|
161
|
+
const buildEntry = renderer.buildEntry ?? defaultBuildEntry;
|
|
162
|
+
let existingContent = null;
|
|
163
|
+
try {
|
|
164
|
+
existingContent = await readFile(configPath, "utf-8");
|
|
165
|
+
}
|
|
166
|
+
catch (error) {
|
|
167
|
+
if (!isMissingFile(error)) {
|
|
168
|
+
return failedMcpSync(tool, configPath, scope, `Failed to read existing MCP config: ${errorMessage(error)}`);
|
|
169
|
+
}
|
|
170
|
+
}
|
|
171
|
+
let existing = null;
|
|
172
|
+
if (existingContent !== null) {
|
|
173
|
+
try {
|
|
174
|
+
existing = parseConfig(existingContent, format);
|
|
175
|
+
}
|
|
176
|
+
catch (error) {
|
|
177
|
+
return failedMcpSync(tool, configPath, scope, `Failed to parse existing MCP config; leaving it unchanged: ${errorMessage(error)}`);
|
|
178
|
+
}
|
|
179
|
+
}
|
|
180
|
+
const serverEntries = buildServerEntries(servers, buildEntry);
|
|
181
|
+
const merged = mergeUnderRootKey(existing, rootKey, serverEntries);
|
|
182
|
+
const content = serializeConfig(merged, format);
|
|
183
|
+
if (existingContent !== null && normalizeNewlines(existingContent) === normalizeNewlines(content)) {
|
|
184
|
+
return {
|
|
185
|
+
tool,
|
|
186
|
+
path: configPath,
|
|
187
|
+
scope,
|
|
188
|
+
updated: false,
|
|
189
|
+
created: false,
|
|
190
|
+
skipped: true,
|
|
191
|
+
};
|
|
192
|
+
}
|
|
193
|
+
await mkdir(dirname(configPath), { recursive: true });
|
|
194
|
+
await writeFile(configPath, content, "utf-8");
|
|
195
|
+
return {
|
|
196
|
+
tool,
|
|
197
|
+
path: configPath,
|
|
198
|
+
scope,
|
|
199
|
+
updated: existing !== null,
|
|
200
|
+
created: existing === null,
|
|
201
|
+
skipped: false,
|
|
202
|
+
};
|
|
203
|
+
}
|
|
204
|
+
catch (error) {
|
|
205
|
+
return failedMcpSync(tool, configPath, scope, `Failed to write MCP config: ${errorMessage(error)}`);
|
|
206
|
+
}
|
|
207
|
+
}
|
|
208
|
+
function parseConfig(raw, format) {
|
|
209
|
+
if (format === "toml") {
|
|
210
|
+
return parseToml(raw);
|
|
211
|
+
}
|
|
212
|
+
return JSON.parse(raw);
|
|
213
|
+
}
|
|
214
|
+
function serializeConfig(value, format) {
|
|
215
|
+
if (format === "toml") {
|
|
216
|
+
// @iarna/toml emits a final newline already; normalise to single trailing.
|
|
217
|
+
return stringifyToml(value).replace(/\n*$/, "\n");
|
|
218
|
+
}
|
|
219
|
+
return JSON.stringify(value, null, 2) + "\n";
|
|
220
|
+
}
|
|
221
|
+
function buildServerEntries(servers, buildEntry) {
|
|
222
|
+
const result = {};
|
|
223
|
+
for (const server of servers) {
|
|
224
|
+
result[server.name] = buildEntry(server);
|
|
225
|
+
}
|
|
226
|
+
return result;
|
|
227
|
+
}
|
|
228
|
+
function mergeUnderRootKey(existing, rootKey, serverEntries) {
|
|
229
|
+
if (!existing) {
|
|
230
|
+
return { [rootKey]: serverEntries };
|
|
231
|
+
}
|
|
232
|
+
const existingEntries = isRecord(existing[rootKey]) ? existing[rootKey] : {};
|
|
233
|
+
return {
|
|
234
|
+
...existing,
|
|
235
|
+
[rootKey]: { ...existingEntries, ...serverEntries },
|
|
236
|
+
};
|
|
237
|
+
}
|
|
238
|
+
function isRecord(value) {
|
|
239
|
+
return !!value && typeof value === "object" && !Array.isArray(value);
|
|
240
|
+
}
|
|
241
|
+
function isMissingFile(error) {
|
|
242
|
+
return Boolean(error && typeof error === "object" && error.code === "ENOENT");
|
|
243
|
+
}
|
|
244
|
+
function failedMcpSync(tool, configPath, scope, warning) {
|
|
245
|
+
return {
|
|
246
|
+
tool,
|
|
247
|
+
path: configPath,
|
|
248
|
+
scope,
|
|
249
|
+
updated: false,
|
|
250
|
+
created: false,
|
|
251
|
+
skipped: false,
|
|
252
|
+
warning,
|
|
253
|
+
};
|
|
254
|
+
}
|
|
255
|
+
// ---------------------------------------------------------------------------
|
|
256
|
+
// Per-tool entry builders
|
|
257
|
+
// ---------------------------------------------------------------------------
|
|
258
|
+
/**
|
|
259
|
+
* Default Claude-Code-style entry shape.
|
|
260
|
+
*
|
|
261
|
+
* { type: "stdio" | "sse" | "streamable-http", command, args, env, url }
|
|
262
|
+
*
|
|
263
|
+
* Used by Claude Code, Cursor, and (with rootKey override) VS Code Copilot.
|
|
264
|
+
*/
|
|
265
|
+
function defaultBuildEntry(server) {
|
|
266
|
+
const entry = {};
|
|
267
|
+
if (server.transport === "sse" || server.transport === "streamable-http") {
|
|
268
|
+
entry.type = server.transport;
|
|
269
|
+
if (server.url)
|
|
270
|
+
entry.url = server.url;
|
|
271
|
+
}
|
|
272
|
+
else {
|
|
273
|
+
entry.type = "stdio";
|
|
274
|
+
entry.command = server.command;
|
|
275
|
+
if (server.args?.length)
|
|
276
|
+
entry.args = server.args;
|
|
277
|
+
}
|
|
278
|
+
if (server.env && Object.keys(server.env).length > 0) {
|
|
279
|
+
entry.env = { ...server.env };
|
|
280
|
+
}
|
|
281
|
+
return entry;
|
|
282
|
+
}
|
|
283
|
+
/**
|
|
284
|
+
* Codex TOML entry. No `type` field (stdio is implicit). Renders as:
|
|
285
|
+
*
|
|
286
|
+
* [mcp_servers.xtctx]
|
|
287
|
+
* command = "npx"
|
|
288
|
+
* args = ["-y", "xtctx"]
|
|
289
|
+
*/
|
|
290
|
+
function buildCodexEntry(server) {
|
|
291
|
+
const entry = {};
|
|
292
|
+
if (server.transport === "sse" || server.transport === "streamable-http") {
|
|
293
|
+
if (server.url)
|
|
294
|
+
entry.url = server.url;
|
|
295
|
+
}
|
|
296
|
+
else {
|
|
297
|
+
entry.command = server.command;
|
|
298
|
+
if (server.args?.length)
|
|
299
|
+
entry.args = server.args;
|
|
300
|
+
}
|
|
301
|
+
if (server.env && Object.keys(server.env).length > 0) {
|
|
302
|
+
entry.env = { ...server.env };
|
|
303
|
+
}
|
|
304
|
+
return entry;
|
|
305
|
+
}
|
|
306
|
+
/**
|
|
307
|
+
* Antigravity MCP entry shape. Same as Codex (no `type` field) but JSON.
|
|
308
|
+
*
|
|
309
|
+
* "mcpServers": {
|
|
310
|
+
* "xtctx": { "command": "npx", "args": [...] }
|
|
311
|
+
* }
|
|
312
|
+
*/
|
|
313
|
+
function buildAntigravityEntry(server) {
|
|
314
|
+
return buildCodexEntry(server);
|
|
315
|
+
}
|
|
316
|
+
/**
|
|
317
|
+
* opencode entry shape (sst/opencode-ai).
|
|
318
|
+
*
|
|
319
|
+
* "mcp": {
|
|
320
|
+
* "xtctx": {
|
|
321
|
+
* "type": "local",
|
|
322
|
+
* "command": ["npx", "-y", "xtctx"],
|
|
323
|
+
* "enabled": true
|
|
324
|
+
* }
|
|
325
|
+
* }
|
|
326
|
+
*
|
|
327
|
+
* Note that opencode's `command` is a combined array (executable + args),
|
|
328
|
+
* env vars use the key `environment`, and remote servers use `type: "remote"`
|
|
329
|
+
* + `url` + optional `headers`.
|
|
330
|
+
*/
|
|
331
|
+
function buildOpencodeEntry(server) {
|
|
332
|
+
if (server.transport === "sse" || server.transport === "streamable-http") {
|
|
333
|
+
const remote = {
|
|
334
|
+
type: "remote",
|
|
335
|
+
url: server.url ?? "",
|
|
336
|
+
enabled: true,
|
|
337
|
+
};
|
|
338
|
+
if (server.env && Object.keys(server.env).length > 0) {
|
|
339
|
+
remote.headers = { ...server.env };
|
|
340
|
+
}
|
|
341
|
+
return remote;
|
|
342
|
+
}
|
|
343
|
+
const command = [server.command, ...(server.args ?? [])];
|
|
344
|
+
const local = {
|
|
345
|
+
type: "local",
|
|
346
|
+
command,
|
|
347
|
+
enabled: true,
|
|
348
|
+
};
|
|
349
|
+
if (server.env && Object.keys(server.env).length > 0) {
|
|
350
|
+
local.environment = { ...server.env };
|
|
351
|
+
}
|
|
352
|
+
return local;
|
|
353
|
+
}
|
|
354
|
+
/**
|
|
355
|
+
* GitHub Copilot CLI entry shape (`~/.copilot/mcp-config.json`).
|
|
356
|
+
*
|
|
357
|
+
* "mcpServers": {
|
|
358
|
+
* "xtctx": {
|
|
359
|
+
* "type": "local",
|
|
360
|
+
* "command": "npx",
|
|
361
|
+
* "args": ["-y", "xtctx"],
|
|
362
|
+
* "tools": ["*"]
|
|
363
|
+
* }
|
|
364
|
+
* }
|
|
365
|
+
*
|
|
366
|
+
* Copilot CLI uses `type: "local" | "http"` and a `tools` allowlist
|
|
367
|
+
* (`["*"]` = allow all tools the server exposes). The defaults grant
|
|
368
|
+
* full access; tighten by editing the file post-sync if needed.
|
|
369
|
+
*/
|
|
370
|
+
function buildCopilotCliEntry(server) {
|
|
371
|
+
if (server.transport === "sse" || server.transport === "streamable-http") {
|
|
372
|
+
const http = {
|
|
373
|
+
type: "http",
|
|
374
|
+
url: server.url ?? "",
|
|
375
|
+
tools: ["*"],
|
|
376
|
+
};
|
|
377
|
+
if (server.env && Object.keys(server.env).length > 0) {
|
|
378
|
+
http.env = { ...server.env };
|
|
379
|
+
}
|
|
380
|
+
return http;
|
|
381
|
+
}
|
|
382
|
+
const local = {
|
|
383
|
+
type: "local",
|
|
384
|
+
command: server.command,
|
|
385
|
+
args: server.args ?? [],
|
|
386
|
+
tools: ["*"],
|
|
387
|
+
};
|
|
388
|
+
if (server.env && Object.keys(server.env).length > 0) {
|
|
389
|
+
local.env = { ...server.env };
|
|
390
|
+
}
|
|
391
|
+
return local;
|
|
392
|
+
}
|
|
393
|
+
// ---------------------------------------------------------------------------
|
|
394
|
+
// Misc helpers
|
|
395
|
+
// ---------------------------------------------------------------------------
|
|
396
|
+
function normalizeNewlines(input) {
|
|
397
|
+
return input.replace(/\r\n/g, "\n");
|
|
398
|
+
}
|
|
399
|
+
async function removeMcpConfig(tool, configPath, scope, renderer, serverName) {
|
|
400
|
+
try {
|
|
401
|
+
const format = renderer.format ?? "json";
|
|
402
|
+
const rootKey = renderer.rootKey ?? "mcpServers";
|
|
403
|
+
let existingContent;
|
|
404
|
+
try {
|
|
405
|
+
existingContent = await readFile(configPath, "utf-8");
|
|
406
|
+
}
|
|
407
|
+
catch {
|
|
408
|
+
return {
|
|
409
|
+
tool,
|
|
410
|
+
path: configPath,
|
|
411
|
+
scope,
|
|
412
|
+
removed: false,
|
|
413
|
+
skipped: true,
|
|
414
|
+
};
|
|
415
|
+
}
|
|
416
|
+
const existing = parseConfig(existingContent, format);
|
|
417
|
+
const existingEntries = isRecord(existing[rootKey]) ? { ...existing[rootKey] } : {};
|
|
418
|
+
if (!(serverName in existingEntries)) {
|
|
419
|
+
return {
|
|
420
|
+
tool,
|
|
421
|
+
path: configPath,
|
|
422
|
+
scope,
|
|
423
|
+
removed: false,
|
|
424
|
+
skipped: true,
|
|
425
|
+
};
|
|
426
|
+
}
|
|
427
|
+
delete existingEntries[serverName];
|
|
428
|
+
const updated = { ...existing, [rootKey]: existingEntries };
|
|
429
|
+
const content = serializeConfig(updated, format);
|
|
430
|
+
if (normalizeNewlines(existingContent) !== normalizeNewlines(content)) {
|
|
431
|
+
await mkdir(dirname(configPath), { recursive: true });
|
|
432
|
+
await writeFile(configPath, content, "utf-8");
|
|
433
|
+
}
|
|
434
|
+
return {
|
|
435
|
+
tool,
|
|
436
|
+
path: configPath,
|
|
437
|
+
scope,
|
|
438
|
+
removed: true,
|
|
439
|
+
skipped: false,
|
|
440
|
+
};
|
|
441
|
+
}
|
|
442
|
+
catch (error) {
|
|
443
|
+
return {
|
|
444
|
+
tool,
|
|
445
|
+
path: configPath,
|
|
446
|
+
scope,
|
|
447
|
+
removed: false,
|
|
448
|
+
skipped: false,
|
|
449
|
+
warning: `Failed to remove MCP config: ${errorMessage(error)}`,
|
|
450
|
+
};
|
|
451
|
+
}
|
|
452
|
+
}
|
|
453
|
+
function resolveConfigTarget(projectRoot, home, renderer) {
|
|
454
|
+
if (renderer.projectPath) {
|
|
455
|
+
return { path: renderer.projectPath(projectRoot), scope: "project" };
|
|
456
|
+
}
|
|
457
|
+
if (renderer.globalPath) {
|
|
458
|
+
return { path: renderer.globalPath(home), scope: "global" };
|
|
459
|
+
}
|
|
460
|
+
return null;
|
|
461
|
+
}
|
|
462
|
+
//# sourceMappingURL=mcp-config.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"mcp-config.js","sourceRoot":"","sources":["../../../src/config/mcp-config.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,EAAE,QAAQ,EAAE,SAAS,EAAE,MAAM,kBAAkB,CAAC;AAC9D,OAAO,EAAE,OAAO,EAAE,MAAM,SAAS,CAAC;AAClC,OAAO,EAAE,OAAO,EAAE,IAAI,EAAE,MAAM,WAAW,CAAC;AAC1C,OAAO,EAAE,KAAK,IAAI,SAAS,EAAE,SAAS,IAAI,aAAa,EAAE,MAAM,aAAa,CAAC;AAC7E,OAAO,EAAE,YAAY,EAAE,MAAM,oBAAoB,CAAC;AAiFlD;;;;;GAKG;AACH,MAAM,gBAAgB,GAAgC;IACpD,8EAA8E;IAC9E,2EAA2E;IAC3E,sDAAsD;IACtD,MAAM,EAAE;QACN,WAAW,EAAE,CAAC,IAAI,EAAE,EAAE,CAAC,IAAI,CAAC,IAAI,EAAE,WAAW,CAAC;KAC/C;IACD,aAAa,EAAE;QACb,WAAW,EAAE,CAAC,IAAI,EAAE,EAAE,CAAC,IAAI,CAAC,IAAI,EAAE,WAAW,CAAC;KAC/C;IAED,gEAAgE;IAChE,MAAM,EAAE;QACN,WAAW,EA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;QACzB,OAAO,EAAE,IAAI,EAAE,QAAQ,CAAC,WAAW,CAAC,WAAW,CAAC,EAAE,KAAK,EAAE,SAAS,EAAE,CAAC;IACvE,CAAC;IAED,IAAI,QAAQ,CAAC,UAAU,EAAE,CAAC;QACxB,OAAO,EAAE,IAAI,EAAE,QAAQ,CAAC,UAAU,CAAC,IAAI,CAAC,EAAE,KAAK,EAAE,QAAQ,EAAE,CAAC;IAC9D,CAAC;IAED,OAAO,IAAI,CAAC;AACd,CAAC"}
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
import { type McpServerDefinition } from "./mcp-config.js";
|
|
2
|
+
export interface SetupOptions {
|
|
3
|
+
projectPath?: string;
|
|
4
|
+
yes?: boolean;
|
|
5
|
+
repair?: boolean;
|
|
6
|
+
homeDir?: string;
|
|
7
|
+
selectedSkillIds?: string[];
|
|
8
|
+
includeGlobalMcp?: boolean;
|
|
9
|
+
}
|
|
10
|
+
export interface SetupResult {
|
|
11
|
+
projectRoot: string;
|
|
12
|
+
configPath: string;
|
|
13
|
+
writes: Array<{
|
|
14
|
+
path: string;
|
|
15
|
+
kind: string;
|
|
16
|
+
changed: boolean;
|
|
17
|
+
}>;
|
|
18
|
+
warnings: string[];
|
|
19
|
+
}
|
|
20
|
+
export interface PlannedSetupWrite {
|
|
21
|
+
path: string;
|
|
22
|
+
kind: string;
|
|
23
|
+
}
|
|
24
|
+
export declare function runSetup(options?: SetupOptions): Promise<SetupResult>;
|
|
25
|
+
export declare function setupProject(options?: SetupOptions): Promise<SetupResult>;
|
|
26
|
+
export declare function describeSetupPlan(projectPath?: string, selectedSkillIds?: string[], includeGlobalMcp?: boolean): {
|
|
27
|
+
projectRoot: string;
|
|
28
|
+
writes: PlannedSetupWrite[];
|
|
29
|
+
};
|
|
30
|
+
export declare function inspectManagedFile(filePath: string): Promise<{
|
|
31
|
+
exists: boolean;
|
|
32
|
+
blockCount: number;
|
|
33
|
+
staleReferences: string[];
|
|
34
|
+
}>;
|
|
35
|
+
export declare function xtctxServerDefinition(): McpServerDefinition;
|
|
36
|
+
export declare function pathExists(filePath: string): Promise<boolean>;
|
|
37
|
+
//# sourceMappingURL=setup.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"setup.d.ts","sourceRoot":"","sources":["../../../src/config/setup.ts"],"names":[],"mappings":"AAGA,OAAO,EAGL,KAAK,mBAAmB,EACzB,MAAM,iBAAiB,CAAC;AAczB,MAAM,WAAW,YAAY;IAC3B,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,GAAG,CAAC,EAAE,OAAO,CAAC;IACd,MAAM,CAAC,EAAE,OAAO,CAAC;IACjB,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,gBAAgB,CAAC,EAAE,MAAM,EAAE,CAAC;IAC5B,gBAAgB,CAAC,EAAE,OAAO,CAAC;CAC5B;AAED,MAAM,WAAW,WAAW;IAC1B,WAAW,EAAE,MAAM,CAAC;IACpB,UAAU,EAAE,MAAM,CAAC;IACnB,MAAM,EAAE,KAAK,CAAC;QAAE,IAAI,EAAE,MAAM,CAAC;QAAC,IAAI,EAAE,MAAM,CAAC;QAAC,OAAO,EAAE,OAAO,CAAA;KAAE,CAAC,CAAC;IAChE,QAAQ,EAAE,MAAM,EAAE,CAAC;CACpB;AAED,MAAM,WAAW,iBAAiB;IAChC,IAAI,EAAE,MAAM,CAAC;IACb,IAAI,EAAE,MAAM,CAAC;CACd;AASD,wBAAsB,QAAQ,CAAC,OAAO,GAAE,YAAiB,GAAG,OAAO,CAAC,WAAW,CAAC,CAI/E;AAED,wBAAsB,YAAY,CAAC,OAAO,GAAE,YAAiB,GAAG,OAAO,CAAC,WAAW,CAAC,CAwEnF;AAED,wBAAgB,iBAAiB,CAC/B,WAAW,CAAC,EAAE,MAAM,EACpB,gBAAgB,GAAE,MAAM,EAAsB,EAC9C,gBAAgB,UAAQ,GACvB;IACD,WAAW,EAAE,MAAM,CAAC;IACpB,MAAM,EAAE,iBAAiB,EAAE,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