@whylineee/zerocode 0.1.0 → 0.1.2
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/README.md +237 -60
- package/dist/agents.d.ts +2 -1
- package/dist/agents.d.ts.map +1 -1
- package/dist/agents.js +10 -0
- package/dist/agents.js.map +1 -1
- package/dist/index.js +808 -17
- package/dist/index.js.map +1 -1
- package/dist/prompt.d.ts +4 -0
- package/dist/prompt.d.ts.map +1 -1
- package/dist/prompt.js +22 -1
- package/dist/prompt.js.map +1 -1
- package/dist/ui.d.ts +3 -1
- package/dist/ui.d.ts.map +1 -1
- package/dist/ui.js +38 -5
- package/dist/ui.js.map +1 -1
- package/package.json +3 -4
package/README.md
CHANGED
|
@@ -1,101 +1,278 @@
|
|
|
1
|
-
|
|
1
|
+
<div align="center">
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
```
|
|
4
|
+
███████╗███████╗██████╗ ██████╗
|
|
5
|
+
╚══███╔╝██╔════╝██╔══██╗██╔═══██╗
|
|
6
|
+
███╔╝ █████╗ ██████╔╝██║ ██║
|
|
7
|
+
███╔╝ ██╔══╝ ██╔══██╗██║ ██║
|
|
8
|
+
███████╗███████╗██║ ██║╚██████╔╝
|
|
9
|
+
╚══════╝╚══════╝╚═╝ ╚═╝ ╚═════╝
|
|
10
|
+
C O D E
|
|
11
|
+
```
|
|
12
|
+
|
|
13
|
+
### One command to wire MCP servers and skills into any AI agent on your machine.
|
|
14
|
+
|
|
15
|
+
<br>
|
|
16
|
+
|
|
17
|
+
[](https://www.npmjs.com/package/@whylineee/zerocode)
|
|
18
|
+
[](./LICENSE)
|
|
19
|
+
[](https://nodejs.org)
|
|
20
|
+
[](./package.json)
|
|
21
|
+
|
|
22
|
+
<br>
|
|
23
|
+
|
|
24
|
+
</div>
|
|
25
|
+
|
|
26
|
+
---
|
|
27
|
+
|
|
28
|
+
<br>
|
|
29
|
+
|
|
30
|
+
## Why ZeroCode?
|
|
31
|
+
|
|
32
|
+
You install a new MCP server. Then you open Claude's config JSON. Copy-paste the entry. Repeat for Cursor. Repeat for Windsurf. Forget which env vars you set. Break the JSON. Spend 20 minutes debugging a missing comma.
|
|
33
|
+
|
|
34
|
+
**ZeroCode replaces all of that with one command.**
|
|
4
35
|
|
|
5
|
-
|
|
36
|
+
```bash
|
|
37
|
+
npx @whylineee/zerocode init
|
|
38
|
+
```
|
|
39
|
+
|
|
40
|
+
It detects your agents, lets you pick MCP servers from a curated registry, collects API keys, and writes correct configs to every agent at once.
|
|
41
|
+
|
|
42
|
+
<br>
|
|
43
|
+
|
|
44
|
+
## Quick Start
|
|
6
45
|
|
|
7
46
|
```bash
|
|
8
|
-
|
|
9
|
-
npx zerocode
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
npx zerocode add
|
|
13
|
-
npx zerocode
|
|
47
|
+
# Interactive wizard — detects agents, picks servers, installs everything
|
|
48
|
+
npx @whylineee/zerocode init
|
|
49
|
+
|
|
50
|
+
# Or go surgical
|
|
51
|
+
npx @whylineee/zerocode add mcp github-mcp --agent cursor
|
|
52
|
+
npx @whylineee/zerocode add skill pr-reviewer
|
|
14
53
|
```
|
|
15
54
|
|
|
16
|
-
|
|
55
|
+
<br>
|
|
17
56
|
|
|
18
|
-
|
|
57
|
+
## What It Does
|
|
19
58
|
|
|
20
|
-
|
|
|
21
|
-
|
|
22
|
-
| Claude Desktop
|
|
23
|
-
|
|
|
24
|
-
|
|
|
25
|
-
|
|
|
26
|
-
|
|
|
27
|
-
|
|
|
28
|
-
|
|
|
59
|
+
| | Feature | |
|
|
60
|
+
|:---:|---|---|
|
|
61
|
+
| **01** | **Auto-detect agents** | Finds Claude Desktop, Cursor, Windsurf, Cline, Continue.dev, Claude Code, Codex CLI |
|
|
62
|
+
| **02** | **30+ MCP servers** | Filesystem, Git, GitHub, Slack, Notion, PostgreSQL, Docker, Stripe, and more |
|
|
63
|
+
| **03** | **Reusable skills** | PR review, prompt engineering, Docker best practices — as installable SKILL.md files |
|
|
64
|
+
| **04** | **Agent configurator** | Pick an agent, then add/remove/inspect servers interactively |
|
|
65
|
+
| **05** | **Sync between agents** | Copy MCP servers from Cursor to Claude Desktop (or any combo) in one command |
|
|
66
|
+
| **06** | **Export / Import** | Share your entire setup as a portable `.zerocode.json` — onboard teammates in seconds |
|
|
67
|
+
| **07** | **Doctor** | Checks runtimes, validates configs, flags broken env vars |
|
|
68
|
+
| **08** | **Backup / Restore** | Snapshot all agent configs before you experiment |
|
|
69
|
+
| **09** | **Zero dependencies** | Pure Node.js builtins. Nothing to install. Nothing to break. |
|
|
29
70
|
|
|
30
|
-
|
|
71
|
+
<br>
|
|
31
72
|
|
|
32
|
-
|
|
73
|
+
## Supported Agents
|
|
33
74
|
|
|
34
|
-
|
|
75
|
+
<table>
|
|
76
|
+
<tr>
|
|
77
|
+
<td width="200"><b>Claude Desktop</b></td>
|
|
78
|
+
<td><code>global</code></td>
|
|
79
|
+
<td>macOS Application Support config</td>
|
|
80
|
+
</tr>
|
|
81
|
+
<tr>
|
|
82
|
+
<td><b>Claude Code</b></td>
|
|
83
|
+
<td><code>project</code></td>
|
|
84
|
+
<td>.mcp.json in project root</td>
|
|
85
|
+
</tr>
|
|
86
|
+
<tr>
|
|
87
|
+
<td><b>Cursor</b></td>
|
|
88
|
+
<td><code>project + global</code></td>
|
|
89
|
+
<td>.cursor/mcp.json or ~/.cursor/mcp.json</td>
|
|
90
|
+
</tr>
|
|
91
|
+
<tr>
|
|
92
|
+
<td><b>Windsurf</b></td>
|
|
93
|
+
<td><code>project + global</code></td>
|
|
94
|
+
<td>.windsurf/mcp.json or ~/.codeium config</td>
|
|
95
|
+
</tr>
|
|
96
|
+
<tr>
|
|
97
|
+
<td><b>Cline (VS Code)</b></td>
|
|
98
|
+
<td><code>project</code></td>
|
|
99
|
+
<td>.vscode/mcp.json</td>
|
|
100
|
+
</tr>
|
|
101
|
+
<tr>
|
|
102
|
+
<td><b>Continue.dev</b></td>
|
|
103
|
+
<td><code>global</code></td>
|
|
104
|
+
<td>~/.continue/config.json</td>
|
|
105
|
+
</tr>
|
|
106
|
+
<tr>
|
|
107
|
+
<td><b>Codex CLI</b></td>
|
|
108
|
+
<td><code>project</code></td>
|
|
109
|
+
<td>AGENTS.md in project root</td>
|
|
110
|
+
</tr>
|
|
111
|
+
</table>
|
|
35
112
|
|
|
36
|
-
|
|
113
|
+
<br>
|
|
37
114
|
|
|
38
|
-
|
|
115
|
+
## MCP Server Registry (30+)
|
|
39
116
|
|
|
40
|
-
|
|
117
|
+
<details>
|
|
118
|
+
<summary><b>Essential</b> — filesystem, git, memory, sequential-thinking</summary>
|
|
41
119
|
|
|
42
|
-
|
|
120
|
+
| Server | What it does |
|
|
121
|
+
|---|---|
|
|
122
|
+
| `filesystem-mcp` | Read, write, and inspect project files safely |
|
|
123
|
+
| `git-mcp` | Inspect history, diffs, and safe commit workflows |
|
|
124
|
+
| `memory-mcp` | Persist useful facts across sessions |
|
|
125
|
+
| `sequential-thinking-mcp` | Dynamic multi-step problem-solving |
|
|
43
126
|
|
|
44
|
-
|
|
127
|
+
</details>
|
|
45
128
|
|
|
46
|
-
|
|
129
|
+
<details>
|
|
130
|
+
<summary><b>Web & Search</b> — fetch, brave-search, firecrawl, puppeteer, playwright</summary>
|
|
47
131
|
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
132
|
+
| Server | What it does |
|
|
133
|
+
|---|---|
|
|
134
|
+
| `fetch-mcp` | Pull web content into cleaner text for agent use |
|
|
135
|
+
| `brave-search-mcp` | Web and local search via Brave Search API |
|
|
136
|
+
| `firecrawl-mcp` | Crawl web pages and convert to clean markdown |
|
|
137
|
+
| `puppeteer-mcp` | Headless browser automation and screenshots |
|
|
138
|
+
| `playwright-mcp` | Cross-browser automation (Chromium, Firefox, WebKit) |
|
|
139
|
+
|
|
140
|
+
</details>
|
|
141
|
+
|
|
142
|
+
<details>
|
|
143
|
+
<summary><b>DevOps & Infra</b> — github, docker, sentry, cloudflare, vercel, aws-s3</summary>
|
|
144
|
+
|
|
145
|
+
| Server | What it does |
|
|
146
|
+
|---|---|
|
|
147
|
+
| `github-mcp` | Manage repos, issues, PRs via GitHub API |
|
|
148
|
+
| `docker-mcp` | Manage containers, images, and compose stacks |
|
|
149
|
+
| `sentry-mcp` | Query error reports and stack traces |
|
|
150
|
+
| `cloudflare-mcp` | Manage Workers, KV, R2, and DNS |
|
|
151
|
+
| `vercel-mcp` | Manage deployments and project settings |
|
|
152
|
+
| `aws-s3-mcp` | List, read, and manage S3 bucket objects |
|
|
153
|
+
|
|
154
|
+
</details>
|
|
155
|
+
|
|
156
|
+
<details>
|
|
157
|
+
<summary><b>Databases</b> — postgres, sqlite, mongodb, redis, elasticsearch, supabase</summary>
|
|
51
158
|
|
|
52
|
-
|
|
53
|
-
|
|
159
|
+
| Server | What it does |
|
|
160
|
+
|---|---|
|
|
161
|
+
| `postgres-mcp` | Read-only querying of PostgreSQL databases |
|
|
162
|
+
| `sqlite-mcp` | Query and analyze local SQLite databases |
|
|
163
|
+
| `mongodb-mcp` | Query and inspect MongoDB collections |
|
|
164
|
+
| `redis-mcp` | Inspect and query Redis instances |
|
|
165
|
+
| `elasticsearch-mcp` | Search and analyze data in Elasticsearch |
|
|
166
|
+
| `supabase-mcp` | Query Supabase databases, storage, and auth |
|
|
167
|
+
|
|
168
|
+
</details>
|
|
169
|
+
|
|
170
|
+
<details>
|
|
171
|
+
<summary><b>SaaS & Productivity</b> — slack, notion, linear, jira, todoist, google-drive, stripe, and more</summary>
|
|
172
|
+
|
|
173
|
+
| Server | What it does |
|
|
174
|
+
|---|---|
|
|
175
|
+
| `slack-mcp` | Read channels, search messages, post to Slack |
|
|
176
|
+
| `notion-mcp` | Search, read, and update Notion pages |
|
|
177
|
+
| `linear-mcp` | Create, search, and manage Linear issues |
|
|
178
|
+
| `jira-mcp` | Search, create, and update Jira issues |
|
|
179
|
+
| `todoist-mcp` | Create and manage tasks in Todoist |
|
|
180
|
+
| `google-drive-mcp` | Search, read, and organize Drive files |
|
|
181
|
+
| `stripe-mcp` | Query payments, customers, and subscriptions |
|
|
182
|
+
| `youtube-mcp` | Search videos and retrieve transcripts |
|
|
183
|
+
| `twilio-mcp` | Send SMS and manage messaging workflows |
|
|
184
|
+
|
|
185
|
+
</details>
|
|
186
|
+
|
|
187
|
+
<br>
|
|
188
|
+
|
|
189
|
+
## Starter Packs
|
|
190
|
+
|
|
191
|
+
The `init` wizard offers quick-start bundles so you don't pick from 30 servers one by one:
|
|
192
|
+
|
|
193
|
+
```
|
|
194
|
+
a) Essential — filesystem, git, memory
|
|
195
|
+
b) Web — fetch, brave-search, firecrawl
|
|
196
|
+
c) DevOps — github, docker, sentry
|
|
197
|
+
d) Custom — pick your own
|
|
54
198
|
```
|
|
55
199
|
|
|
56
|
-
|
|
200
|
+
<br>
|
|
57
201
|
|
|
58
|
-
|
|
202
|
+
## All Commands
|
|
203
|
+
|
|
204
|
+
```
|
|
205
|
+
zerocode init Interactive setup wizard
|
|
206
|
+
zerocode detect Detect installed agents
|
|
207
|
+
zerocode configure Pick an agent, manage it interactively
|
|
208
|
+
zerocode list mcp List available MCP servers
|
|
209
|
+
zerocode list skills List available skills
|
|
210
|
+
zerocode add mcp <name> Install MCP server to an agent
|
|
211
|
+
zerocode add skill <name> Install a skill to the project
|
|
212
|
+
zerocode remove mcp <name> Remove MCP server from an agent
|
|
213
|
+
zerocode sync Copy MCP servers from one agent to another
|
|
214
|
+
zerocode status Show what's installed on each agent
|
|
215
|
+
zerocode doctor Check runtimes, configs, and env vars
|
|
216
|
+
zerocode export Export setup to shareable .zerocode.json
|
|
217
|
+
zerocode import [path] Import setup from .zerocode.json
|
|
218
|
+
zerocode backup Backup all agent configs
|
|
219
|
+
zerocode restore Restore agent configs from backup
|
|
220
|
+
```
|
|
59
221
|
|
|
60
|
-
|
|
222
|
+
<br>
|
|
223
|
+
|
|
224
|
+
## Install
|
|
61
225
|
|
|
62
226
|
```bash
|
|
63
|
-
npx
|
|
227
|
+
# Run once with npx (no install needed)
|
|
228
|
+
npx @whylineee/zerocode init
|
|
229
|
+
|
|
230
|
+
# Or install globally
|
|
231
|
+
npm install -g @whylineee/zerocode
|
|
232
|
+
zerocode detect
|
|
64
233
|
```
|
|
65
234
|
|
|
66
|
-
|
|
235
|
+
<br>
|
|
67
236
|
|
|
68
|
-
|
|
237
|
+
## Architecture
|
|
69
238
|
|
|
70
|
-
```
|
|
71
|
-
|
|
239
|
+
```
|
|
240
|
+
src/
|
|
241
|
+
├── index.ts CLI entry, arg parsing, all commands
|
|
242
|
+
├── agents.ts Agent detection & config read/write
|
|
243
|
+
├── registry.ts 30+ MCP servers & skills registry
|
|
244
|
+
├── prompt.ts Interactive prompts (zero dependencies)
|
|
245
|
+
└── ui.ts Terminal colors, banners, formatting
|
|
72
246
|
```
|
|
73
247
|
|
|
74
|
-
|
|
248
|
+
**Zero runtime dependencies.** Built with Node.js builtins only.
|
|
75
249
|
|
|
76
|
-
|
|
250
|
+
<br>
|
|
77
251
|
|
|
78
252
|
## Development
|
|
79
253
|
|
|
80
254
|
```bash
|
|
81
|
-
|
|
255
|
+
git clone https://github.com/whylineee/ZeroCode.git
|
|
256
|
+
cd ZeroCode
|
|
82
257
|
npm install
|
|
83
|
-
npm run build
|
|
84
|
-
node dist/index.js detect
|
|
258
|
+
npm run build
|
|
259
|
+
node dist/index.js detect
|
|
85
260
|
```
|
|
86
261
|
|
|
87
|
-
|
|
262
|
+
<br>
|
|
88
263
|
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
264
|
+
## Star History
|
|
265
|
+
|
|
266
|
+
<a href="https://star-history.com/#whylineee/ZeroCode&Date">
|
|
267
|
+
<picture>
|
|
268
|
+
<source media="(prefers-color-scheme: dark)" srcset="https://api.star-history.com/svg?repos=whylineee/ZeroCode&type=Date&theme=dark" />
|
|
269
|
+
<source media="(prefers-color-scheme: light)" srcset="https://api.star-history.com/svg?repos=whylineee/ZeroCode&type=Date" />
|
|
270
|
+
<img alt="Star History Chart" src="https://api.star-history.com/svg?repos=whylineee/ZeroCode&type=Date" />
|
|
271
|
+
</picture>
|
|
272
|
+
</a>
|
|
273
|
+
|
|
274
|
+
<br>
|
|
275
|
+
|
|
276
|
+
## License
|
|
100
277
|
|
|
101
|
-
|
|
278
|
+
MIT
|
package/dist/agents.d.ts
CHANGED
|
@@ -17,9 +17,10 @@ export interface McpConfig {
|
|
|
17
17
|
}
|
|
18
18
|
export declare function detectAgents(): AgentInfo[];
|
|
19
19
|
export declare function allAgentTargets(): AgentInfo[];
|
|
20
|
+
export declare function supportsJsonConfig(agent: AgentInfo): boolean;
|
|
20
21
|
export declare function readAgentConfig(agent: AgentInfo): McpConfig;
|
|
21
22
|
export declare function writeAgentConfig(agent: AgentInfo, config: McpConfig): void;
|
|
22
|
-
export declare function addMcpToAgent(agent: AgentInfo, serverName: string, entry: McpServerEntry):
|
|
23
|
+
export declare function addMcpToAgent(agent: AgentInfo, serverName: string, entry: McpServerEntry): boolean;
|
|
23
24
|
export declare function removeMcpFromAgent(agent: AgentInfo, serverName: string): boolean;
|
|
24
25
|
export declare function listInstalledMcp(agent: AgentInfo): Record<string, McpServerEntry>;
|
|
25
26
|
//# sourceMappingURL=agents.d.ts.map
|
package/dist/agents.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"agents.d.ts","sourceRoot":"","sources":["../src/agents.ts"],"names":[],"mappings":"AAWA,MAAM,WAAW,SAAS;IACxB,EAAE,EAAE,MAAM,CAAC;IACX,IAAI,EAAE,MAAM,CAAC;IACb,UAAU,EAAE,MAAM,CAAC;IACnB,QAAQ,EAAE,OAAO,CAAC;IAClB,YAAY,EAAE,gBAAgB,GAAG,QAAQ,GAAG,UAAU,GAAG,OAAO,GAAG,UAAU,GAAG,aAAa,CAAC;IAC9F,KAAK,EAAE,QAAQ,GA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E7C;AAED,wBAAgB,kBAAkB,CAAC,KAAK,EAAE,SAAS,GAAG,OAAO,CAE5D;AAED,wBAAgB,eAAe,CAAC,KAAK,EAAE,SAAS,GAAG,SAAS,CAW3D;AAED,wBAAgB,gBAAgB,CAAC,KAAK,EAAE,SAAS,EAAE,MAAM,EAAE,SAAS,GAAG,IAAI,CAU1E;AAED,wBAAgB,aAAa,CAC3B,KAAK,EAAE,SAAS,EAChB,UAAU,EAAE,MAAM,EAClB,KAAK,EAAE,cAAc,GACpB,OAAO,CAST;AAED,wBAAgB,kBAAkB,CAChC,KAAK,EAAE,SAAS,EAChB,UAAU,EAAE,MAAM,GACjB,OAAO,CAST;AAED,wBAAgB,gBAAgB,CAC9B,KAAK,EAAE,SAAS,GACf,MAAM,CAAC,MAAM,EAAE,cAAc,CAAC,CAGhC"}
|
package/dist/agents.js
CHANGED
|
@@ -123,7 +123,12 @@ export function detectAgents() {
|
|
|
123
123
|
export function allAgentTargets() {
|
|
124
124
|
return resolveAgents();
|
|
125
125
|
}
|
|
126
|
+
export function supportsJsonConfig(agent) {
|
|
127
|
+
return agent.id !== "codex";
|
|
128
|
+
}
|
|
126
129
|
export function readAgentConfig(agent) {
|
|
130
|
+
if (!supportsJsonConfig(agent))
|
|
131
|
+
return {};
|
|
127
132
|
if (!existsSync(agent.configPath)) {
|
|
128
133
|
return {};
|
|
129
134
|
}
|
|
@@ -143,14 +148,19 @@ export function writeAgentConfig(agent, config) {
|
|
|
143
148
|
writeFileSync(agent.configPath, JSON.stringify(config, null, 2) + "\n", "utf-8");
|
|
144
149
|
}
|
|
145
150
|
export function addMcpToAgent(agent, serverName, entry) {
|
|
151
|
+
if (!supportsJsonConfig(agent))
|
|
152
|
+
return false;
|
|
146
153
|
const config = readAgentConfig(agent);
|
|
147
154
|
if (!config.mcpServers) {
|
|
148
155
|
config.mcpServers = {};
|
|
149
156
|
}
|
|
150
157
|
config.mcpServers[serverName] = entry;
|
|
151
158
|
writeAgentConfig(agent, config);
|
|
159
|
+
return true;
|
|
152
160
|
}
|
|
153
161
|
export function removeMcpFromAgent(agent, serverName) {
|
|
162
|
+
if (!supportsJsonConfig(agent))
|
|
163
|
+
return false;
|
|
154
164
|
const config = readAgentConfig(agent);
|
|
155
165
|
if (!config.mcpServers || !config.mcpServers[serverName]) {
|
|
156
166
|
return false;
|
package/dist/agents.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"agents.js","sourceRoot":"","sources":["../src/agents.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,UAAU,EACV,YAAY,EACZ,WAAW,EACX,aAAa,EACb,SAAS,GACV,MAAM,SAAS,CAAC;AACjB,OAAO,EAAE,OAAO,EAAE,MAAM,SAAS,CAAC;AAClC,OAAO,EAAE,IAAI,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;AAC1C,OAAO,EAAE,QAAQ,EAAE,MAAM,oBAAoB,CAAC;AAsB9C,MAAM,IAAI,GAAG,OAAO,EAAE,CAAC;AACvB,MAAM,GAAG,GAAG,OAAO,CAAC,GAAG,EAAE,CAAC;AAE1B,SAAS,aAAa,CAAC,GAAW;IAChC,IAAI,CAAC;QACH,QAAQ,CAAC,SAAS,GAAG,EAAE,EAAE,EAAE,KAAK,EAAE,QAAQ,EAAE,CAAC,CAAC;QAC9C,OAAO,IAAI,CAAC;IACd,CAAC;IAAC,MAAM,CAAC;QACP,OAAO,KAAK,CAAC;IACf,CAAC;AACH,CAAC;AAED,SAAS,SAAS,CAAC,IAAY;IAC7B,OAAO,CACL,UAAU,CAAC,iBAAiB,IAAI,MAAM,CAAC;QACvC,UAAU,CAAC,IAAI,CAAC,IAAI,EAAE,cAAc,EAAE,GAAG,IAAI,MAAM,CAAC,CAAC,CACtD,CAAC;AACJ,CAAC;AAED,SAAS,eAAe,CAAC,MAAc,EAAE,MAAc;IACrD,IAAI,CAAC,UAAU,CAAC,MAAM,CAAC;QAAE,OAAO,KAAK,CAAC;IACtC,IAAI,CAAC;QACH,OAAO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