@stan-chen/simple-cli 0.2.2 → 0.2.4
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 +58 -271
- package/dist/anyllm.py +62 -0
- package/dist/builtins.d.ts +726 -0
- package/dist/builtins.js +481 -0
- package/dist/cli.d.ts +0 -4
- package/dist/cli.js +37 -279
- package/dist/engine.d.ts +33 -0
- package/dist/engine.js +138 -0
- package/dist/learnings.d.ts +15 -0
- package/dist/learnings.js +54 -0
- package/dist/llm.d.ts +18 -0
- package/dist/llm.js +66 -0
- package/dist/mcp.d.ts +132 -0
- package/dist/mcp.js +43 -0
- package/dist/skills.d.ts +5 -16
- package/dist/skills.js +91 -253
- package/dist/tui.d.ts +1 -0
- package/dist/tui.js +10 -0
- package/package.json +88 -78
- package/dist/commands/add.d.ts +0 -9
- package/dist/commands/add.js +0 -50
- package/dist/commands/git/commit.d.ts +0 -12
- package/dist/commands/git/commit.js +0 -97
- package/dist/commands/git/status.d.ts +0 -6
- package/dist/commands/git/status.js +0 -42
- package/dist/commands/index.d.ts +0 -16
- package/dist/commands/index.js +0 -376
- package/dist/commands/mcp/status.d.ts +0 -6
- package/dist/commands/mcp/status.js +0 -31
- package/dist/commands/swarm.d.ts +0 -36
- package/dist/commands/swarm.js +0 -236
- package/dist/commands.d.ts +0 -32
- package/dist/commands.js +0 -427
- package/dist/context.d.ts +0 -116
- package/dist/context.js +0 -327
- package/dist/index.d.ts +0 -6
- package/dist/index.js +0 -109
- package/dist/lib/agent.d.ts +0 -98
- package/dist/lib/agent.js +0 -281
- package/dist/lib/editor.d.ts +0 -74
- package/dist/lib/editor.js +0 -441
- package/dist/lib/git.d.ts +0 -164
- package/dist/lib/git.js +0 -351
- package/dist/lib/ui.d.ts +0 -159
- package/dist/lib/ui.js +0 -252
- package/dist/mcp/client.d.ts +0 -22
- package/dist/mcp/client.js +0 -81
- package/dist/mcp/manager.d.ts +0 -186
- package/dist/mcp/manager.js +0 -446
- package/dist/prompts/provider.d.ts +0 -22
- package/dist/prompts/provider.js +0 -78
- package/dist/providers/index.d.ts +0 -15
- package/dist/providers/index.js +0 -82
- package/dist/providers/multi.d.ts +0 -11
- package/dist/providers/multi.js +0 -28
- package/dist/registry.d.ts +0 -24
- package/dist/registry.js +0 -379
- package/dist/repoMap.d.ts +0 -5
- package/dist/repoMap.js +0 -79
- package/dist/router.d.ts +0 -41
- package/dist/router.js +0 -108
- package/dist/swarm/coordinator.d.ts +0 -86
- package/dist/swarm/coordinator.js +0 -257
- package/dist/swarm/index.d.ts +0 -28
- package/dist/swarm/index.js +0 -29
- package/dist/swarm/task.d.ts +0 -104
- package/dist/swarm/task.js +0 -221
- package/dist/swarm/types.d.ts +0 -132
- package/dist/swarm/types.js +0 -37
- package/dist/swarm/worker.d.ts +0 -107
- package/dist/swarm/worker.js +0 -299
- package/dist/tools/analyzeFile.d.ts +0 -16
- package/dist/tools/analyzeFile.js +0 -43
- package/dist/tools/git.d.ts +0 -40
- package/dist/tools/git.js +0 -236
- package/dist/tools/glob.d.ts +0 -34
- package/dist/tools/glob.js +0 -165
- package/dist/tools/grep.d.ts +0 -53
- package/dist/tools/grep.js +0 -296
- package/dist/tools/linter.d.ts +0 -35
- package/dist/tools/linter.js +0 -349
- package/dist/tools/listDir.d.ts +0 -29
- package/dist/tools/listDir.js +0 -50
- package/dist/tools/memory.d.ts +0 -34
- package/dist/tools/memory.js +0 -215
- package/dist/tools/readFiles.d.ts +0 -25
- package/dist/tools/readFiles.js +0 -31
- package/dist/tools/reloadTools.d.ts +0 -11
- package/dist/tools/reloadTools.js +0 -22
- package/dist/tools/runCommand.d.ts +0 -32
- package/dist/tools/runCommand.js +0 -79
- package/dist/tools/scraper.d.ts +0 -31
- package/dist/tools/scraper.js +0 -211
- package/dist/tools/writeFiles.d.ts +0 -63
- package/dist/tools/writeFiles.js +0 -87
- package/dist/ui/server.d.ts +0 -5
- package/dist/ui/server.js +0 -74
- package/dist/watcher.d.ts +0 -35
- package/dist/watcher.js +0 -164
- /package/{docs/assets → assets}/logo.jpeg +0 -0
|
@@ -0,0 +1,726 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
export declare const readFiles: {
|
|
3
|
+
name: string;
|
|
4
|
+
description: string;
|
|
5
|
+
inputSchema: z.ZodObject<{
|
|
6
|
+
paths: z.ZodArray<z.ZodString, "many">;
|
|
7
|
+
}, "strip", z.ZodTypeAny, {
|
|
8
|
+
paths: string[];
|
|
9
|
+
}, {
|
|
10
|
+
paths: string[];
|
|
11
|
+
}>;
|
|
12
|
+
execute: (args: any) => Promise<{
|
|
13
|
+
error: string;
|
|
14
|
+
}[] | ({
|
|
15
|
+
path: any;
|
|
16
|
+
content: string;
|
|
17
|
+
error?: undefined;
|
|
18
|
+
} | {
|
|
19
|
+
path: any;
|
|
20
|
+
error: any;
|
|
21
|
+
content?: undefined;
|
|
22
|
+
})[]>;
|
|
23
|
+
};
|
|
24
|
+
export declare const writeFiles: {
|
|
25
|
+
name: string;
|
|
26
|
+
description: string;
|
|
27
|
+
inputSchema: z.ZodObject<{
|
|
28
|
+
files: z.ZodArray<z.ZodObject<{
|
|
29
|
+
path: z.ZodString;
|
|
30
|
+
content: z.ZodOptional<z.ZodString>;
|
|
31
|
+
searchReplace: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
32
|
+
search: z.ZodString;
|
|
33
|
+
replace: z.ZodString;
|
|
34
|
+
}, "strip", z.ZodTypeAny, {
|
|
35
|
+
search: string;
|
|
36
|
+
replace: string;
|
|
37
|
+
}, {
|
|
38
|
+
search: string;
|
|
39
|
+
replace: string;
|
|
40
|
+
}>, "many">>;
|
|
41
|
+
}, "strip", z.ZodTypeAny, {
|
|
42
|
+
path: string;
|
|
43
|
+
content?: string | undefined;
|
|
44
|
+
searchReplace?: {
|
|
45
|
+
search: string;
|
|
46
|
+
replace: string;
|
|
47
|
+
}[] | undefined;
|
|
48
|
+
}, {
|
|
49
|
+
path: string;
|
|
50
|
+
content?: string | undefined;
|
|
51
|
+
searchReplace?: {
|
|
52
|
+
search: string;
|
|
53
|
+
replace: string;
|
|
54
|
+
}[] | undefined;
|
|
55
|
+
}>, "many">;
|
|
56
|
+
}, "strip", z.ZodTypeAny, {
|
|
57
|
+
files: {
|
|
58
|
+
path: string;
|
|
59
|
+
content?: string | undefined;
|
|
60
|
+
searchReplace?: {
|
|
61
|
+
search: string;
|
|
62
|
+
replace: string;
|
|
63
|
+
}[] | undefined;
|
|
64
|
+
}[];
|
|
65
|
+
}, {
|
|
66
|
+
files: {
|
|
67
|
+
path: string;
|
|
68
|
+
content?: string | undefined;
|
|
69
|
+
searchReplace?: {
|
|
70
|
+
search: string;
|
|
71
|
+
replace: string;
|
|
72
|
+
}[] | undefined;
|
|
73
|
+
}[];
|
|
74
|
+
}>;
|
|
75
|
+
execute: (args: any) => Promise<({
|
|
76
|
+
success: boolean;
|
|
77
|
+
message: string;
|
|
78
|
+
path?: undefined;
|
|
79
|
+
} | {
|
|
80
|
+
path: any;
|
|
81
|
+
success: boolean;
|
|
82
|
+
message?: undefined;
|
|
83
|
+
} | {
|
|
84
|
+
path: any;
|
|
85
|
+
success: boolean;
|
|
86
|
+
message: any;
|
|
87
|
+
})[]>;
|
|
88
|
+
};
|
|
89
|
+
export declare const createTool: {
|
|
90
|
+
name: string;
|
|
91
|
+
description: string;
|
|
92
|
+
inputSchema: z.ZodObject<{
|
|
93
|
+
source_path: z.ZodString;
|
|
94
|
+
name: z.ZodString;
|
|
95
|
+
description: z.ZodString;
|
|
96
|
+
usage: z.ZodString;
|
|
97
|
+
scope: z.ZodDefault<z.ZodEnum<["local", "global"]>>;
|
|
98
|
+
}, "strip", z.ZodTypeAny, {
|
|
99
|
+
source_path: string;
|
|
100
|
+
name: string;
|
|
101
|
+
description: string;
|
|
102
|
+
usage: string;
|
|
103
|
+
scope: "local" | "global";
|
|
104
|
+
}, {
|
|
105
|
+
source_path: string;
|
|
106
|
+
name: string;
|
|
107
|
+
description: string;
|
|
108
|
+
usage: string;
|
|
109
|
+
scope?: "local" | "global" | undefined;
|
|
110
|
+
}>;
|
|
111
|
+
execute: ({ source_path, name, description, usage, scope }: {
|
|
112
|
+
source_path: string;
|
|
113
|
+
name: string;
|
|
114
|
+
description: string;
|
|
115
|
+
usage: string;
|
|
116
|
+
scope: string;
|
|
117
|
+
}) => Promise<string>;
|
|
118
|
+
};
|
|
119
|
+
export declare const scrapeUrl: {
|
|
120
|
+
name: string;
|
|
121
|
+
description: string;
|
|
122
|
+
inputSchema: z.ZodObject<{
|
|
123
|
+
url: z.ZodString;
|
|
124
|
+
convertToMarkdown: z.ZodDefault<z.ZodBoolean>;
|
|
125
|
+
timeout: z.ZodOptional<z.ZodNumber>;
|
|
126
|
+
}, "strip", z.ZodTypeAny, {
|
|
127
|
+
url: string;
|
|
128
|
+
convertToMarkdown: boolean;
|
|
129
|
+
timeout?: number | undefined;
|
|
130
|
+
}, {
|
|
131
|
+
url: string;
|
|
132
|
+
convertToMarkdown?: boolean | undefined;
|
|
133
|
+
timeout?: number | undefined;
|
|
134
|
+
}>;
|
|
135
|
+
execute: ({ url, convertToMarkdown, timeout }: {
|
|
136
|
+
url: string;
|
|
137
|
+
convertToMarkdown: boolean;
|
|
138
|
+
timeout?: number;
|
|
139
|
+
}) => Promise<{
|
|
140
|
+
url: string;
|
|
141
|
+
content: string;
|
|
142
|
+
contentType: string;
|
|
143
|
+
error?: undefined;
|
|
144
|
+
} | {
|
|
145
|
+
url: string;
|
|
146
|
+
error: any;
|
|
147
|
+
content?: undefined;
|
|
148
|
+
contentType?: undefined;
|
|
149
|
+
}>;
|
|
150
|
+
};
|
|
151
|
+
export declare const listFiles: {
|
|
152
|
+
name: string;
|
|
153
|
+
description: string;
|
|
154
|
+
inputSchema: z.ZodObject<{
|
|
155
|
+
pattern: z.ZodString;
|
|
156
|
+
path: z.ZodDefault<z.ZodString>;
|
|
157
|
+
ignore: z.ZodDefault<z.ZodArray<z.ZodString, "many">>;
|
|
158
|
+
includeDirectories: z.ZodDefault<z.ZodBoolean>;
|
|
159
|
+
maxResults: z.ZodOptional<z.ZodNumber>;
|
|
160
|
+
}, "strip", z.ZodTypeAny, {
|
|
161
|
+
path: string;
|
|
162
|
+
pattern: string;
|
|
163
|
+
ignore: string[];
|
|
164
|
+
includeDirectories: boolean;
|
|
165
|
+
maxResults?: number | undefined;
|
|
166
|
+
}, {
|
|
167
|
+
pattern: string;
|
|
168
|
+
path?: string | undefined;
|
|
169
|
+
ignore?: string[] | undefined;
|
|
170
|
+
includeDirectories?: boolean | undefined;
|
|
171
|
+
maxResults?: number | undefined;
|
|
172
|
+
}>;
|
|
173
|
+
execute: ({ pattern, path, ignore, includeDirectories, maxResults }: {
|
|
174
|
+
pattern: string;
|
|
175
|
+
path: string;
|
|
176
|
+
ignore: string[];
|
|
177
|
+
includeDirectories: boolean;
|
|
178
|
+
maxResults?: number;
|
|
179
|
+
}) => Promise<{
|
|
180
|
+
matches: string[];
|
|
181
|
+
count: number;
|
|
182
|
+
truncated: boolean;
|
|
183
|
+
}>;
|
|
184
|
+
};
|
|
185
|
+
export declare const searchFiles: {
|
|
186
|
+
name: string;
|
|
187
|
+
description: string;
|
|
188
|
+
inputSchema: z.ZodObject<{
|
|
189
|
+
pattern: z.ZodString;
|
|
190
|
+
path: z.ZodDefault<z.ZodString>;
|
|
191
|
+
glob: z.ZodDefault<z.ZodString>;
|
|
192
|
+
ignoreCase: z.ZodDefault<z.ZodBoolean>;
|
|
193
|
+
contextLines: z.ZodDefault<z.ZodNumber>;
|
|
194
|
+
maxResults: z.ZodOptional<z.ZodNumber>;
|
|
195
|
+
filesOnly: z.ZodDefault<z.ZodBoolean>;
|
|
196
|
+
}, "strip", z.ZodTypeAny, {
|
|
197
|
+
path: string;
|
|
198
|
+
pattern: string;
|
|
199
|
+
glob: string;
|
|
200
|
+
ignoreCase: boolean;
|
|
201
|
+
contextLines: number;
|
|
202
|
+
filesOnly: boolean;
|
|
203
|
+
maxResults?: number | undefined;
|
|
204
|
+
}, {
|
|
205
|
+
pattern: string;
|
|
206
|
+
path?: string | undefined;
|
|
207
|
+
maxResults?: number | undefined;
|
|
208
|
+
glob?: string | undefined;
|
|
209
|
+
ignoreCase?: boolean | undefined;
|
|
210
|
+
contextLines?: number | undefined;
|
|
211
|
+
filesOnly?: boolean | undefined;
|
|
212
|
+
}>;
|
|
213
|
+
execute: ({ pattern, path, glob: globPattern, ignoreCase, contextLines, maxResults, filesOnly }: {
|
|
214
|
+
pattern: string;
|
|
215
|
+
path: string;
|
|
216
|
+
glob: string;
|
|
217
|
+
ignoreCase: boolean;
|
|
218
|
+
contextLines: number;
|
|
219
|
+
maxResults?: number;
|
|
220
|
+
filesOnly: boolean;
|
|
221
|
+
}) => Promise<{
|
|
222
|
+
matches: never[];
|
|
223
|
+
count: number;
|
|
224
|
+
error: string;
|
|
225
|
+
files?: undefined;
|
|
226
|
+
truncated?: undefined;
|
|
227
|
+
} | {
|
|
228
|
+
matches: any[];
|
|
229
|
+
count: number;
|
|
230
|
+
files: string[];
|
|
231
|
+
truncated: boolean;
|
|
232
|
+
error?: undefined;
|
|
233
|
+
}>;
|
|
234
|
+
};
|
|
235
|
+
export declare const listDir: {
|
|
236
|
+
name: string;
|
|
237
|
+
description: string;
|
|
238
|
+
inputSchema: z.ZodObject<{
|
|
239
|
+
path: z.ZodDefault<z.ZodString>;
|
|
240
|
+
}, "strip", z.ZodTypeAny, {
|
|
241
|
+
path: string;
|
|
242
|
+
}, {
|
|
243
|
+
path?: string | undefined;
|
|
244
|
+
}>;
|
|
245
|
+
execute: ({ path }: {
|
|
246
|
+
path: string;
|
|
247
|
+
}) => Promise<{
|
|
248
|
+
name: string;
|
|
249
|
+
isDir: boolean;
|
|
250
|
+
}[]>;
|
|
251
|
+
};
|
|
252
|
+
export declare const runCommand: {
|
|
253
|
+
name: string;
|
|
254
|
+
description: string;
|
|
255
|
+
inputSchema: z.ZodObject<{
|
|
256
|
+
command: z.ZodString;
|
|
257
|
+
timeout: z.ZodOptional<z.ZodNumber>;
|
|
258
|
+
}, "strip", z.ZodTypeAny, {
|
|
259
|
+
command: string;
|
|
260
|
+
timeout?: number | undefined;
|
|
261
|
+
}, {
|
|
262
|
+
command: string;
|
|
263
|
+
timeout?: number | undefined;
|
|
264
|
+
}>;
|
|
265
|
+
execute: ({ command, timeout }: {
|
|
266
|
+
command: string;
|
|
267
|
+
timeout?: number;
|
|
268
|
+
}) => Promise<{
|
|
269
|
+
stdout: string;
|
|
270
|
+
stderr: string;
|
|
271
|
+
exitCode: number;
|
|
272
|
+
timedOut: boolean;
|
|
273
|
+
error?: undefined;
|
|
274
|
+
} | {
|
|
275
|
+
error: any;
|
|
276
|
+
stdout: any;
|
|
277
|
+
stderr: any;
|
|
278
|
+
exitCode: any;
|
|
279
|
+
timedOut: any;
|
|
280
|
+
}>;
|
|
281
|
+
};
|
|
282
|
+
export declare const deleteFile: {
|
|
283
|
+
name: string;
|
|
284
|
+
description: string;
|
|
285
|
+
inputSchema: z.ZodObject<{
|
|
286
|
+
path: z.ZodString;
|
|
287
|
+
}, "strip", z.ZodTypeAny, {
|
|
288
|
+
path: string;
|
|
289
|
+
}, {
|
|
290
|
+
path: string;
|
|
291
|
+
}>;
|
|
292
|
+
execute: (args: any) => Promise<string>;
|
|
293
|
+
};
|
|
294
|
+
export declare const gitTool: {
|
|
295
|
+
name: string;
|
|
296
|
+
description: string;
|
|
297
|
+
inputSchema: z.ZodObject<{
|
|
298
|
+
operation: z.ZodEnum<["status", "add", "commit", "diff", "log", "branch"]>;
|
|
299
|
+
cwd: z.ZodDefault<z.ZodString>;
|
|
300
|
+
files: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
|
|
301
|
+
message: z.ZodOptional<z.ZodString>;
|
|
302
|
+
}, "strip", z.ZodTypeAny, {
|
|
303
|
+
operation: "status" | "add" | "commit" | "diff" | "log" | "branch";
|
|
304
|
+
cwd: string;
|
|
305
|
+
message?: string | undefined;
|
|
306
|
+
files?: string[] | undefined;
|
|
307
|
+
}, {
|
|
308
|
+
operation: "status" | "add" | "commit" | "diff" | "log" | "branch";
|
|
309
|
+
message?: string | undefined;
|
|
310
|
+
files?: string[] | undefined;
|
|
311
|
+
cwd?: string | undefined;
|
|
312
|
+
}>;
|
|
313
|
+
execute: ({ operation, cwd, files, message }: {
|
|
314
|
+
operation: string;
|
|
315
|
+
cwd: string;
|
|
316
|
+
files?: string[];
|
|
317
|
+
message?: string;
|
|
318
|
+
}) => Promise<{
|
|
319
|
+
success: boolean;
|
|
320
|
+
output: string;
|
|
321
|
+
error?: undefined;
|
|
322
|
+
} | {
|
|
323
|
+
success: boolean;
|
|
324
|
+
error: any;
|
|
325
|
+
output?: undefined;
|
|
326
|
+
}>;
|
|
327
|
+
};
|
|
328
|
+
export declare const linter: {
|
|
329
|
+
name: string;
|
|
330
|
+
description: string;
|
|
331
|
+
inputSchema: z.ZodObject<{
|
|
332
|
+
path: z.ZodString;
|
|
333
|
+
}, "strip", z.ZodTypeAny, {
|
|
334
|
+
path: string;
|
|
335
|
+
}, {
|
|
336
|
+
path: string;
|
|
337
|
+
}>;
|
|
338
|
+
execute: ({ path }: {
|
|
339
|
+
path: string;
|
|
340
|
+
}) => Promise<{
|
|
341
|
+
passed: boolean;
|
|
342
|
+
errors: {
|
|
343
|
+
message: string;
|
|
344
|
+
}[];
|
|
345
|
+
language?: undefined;
|
|
346
|
+
warnings?: undefined;
|
|
347
|
+
output?: undefined;
|
|
348
|
+
file?: undefined;
|
|
349
|
+
} | {
|
|
350
|
+
passed: boolean;
|
|
351
|
+
language: string;
|
|
352
|
+
errors: never[];
|
|
353
|
+
warnings: never[];
|
|
354
|
+
output: string;
|
|
355
|
+
file?: undefined;
|
|
356
|
+
} | {
|
|
357
|
+
passed: boolean;
|
|
358
|
+
language: string;
|
|
359
|
+
errors: {
|
|
360
|
+
message: any;
|
|
361
|
+
line: number;
|
|
362
|
+
}[];
|
|
363
|
+
warnings: never[];
|
|
364
|
+
output: any;
|
|
365
|
+
file: string;
|
|
366
|
+
}>;
|
|
367
|
+
};
|
|
368
|
+
export declare const getCurrentBranch: (cwd: string) => Promise<string | null>;
|
|
369
|
+
export declare const getChangedFiles: (cwd: string) => Promise<string[]>;
|
|
370
|
+
export declare const getTrackedFiles: (cwd: string) => Promise<string[]>;
|
|
371
|
+
export declare const allBuiltins: ({
|
|
372
|
+
name: string;
|
|
373
|
+
description: string;
|
|
374
|
+
inputSchema: z.ZodObject<{
|
|
375
|
+
paths: z.ZodArray<z.ZodString, "many">;
|
|
376
|
+
}, "strip", z.ZodTypeAny, {
|
|
377
|
+
paths: string[];
|
|
378
|
+
}, {
|
|
379
|
+
paths: string[];
|
|
380
|
+
}>;
|
|
381
|
+
execute: (args: any) => Promise<{
|
|
382
|
+
error: string;
|
|
383
|
+
}[] | ({
|
|
384
|
+
path: any;
|
|
385
|
+
content: string;
|
|
386
|
+
error?: undefined;
|
|
387
|
+
} | {
|
|
388
|
+
path: any;
|
|
389
|
+
error: any;
|
|
390
|
+
content?: undefined;
|
|
391
|
+
})[]>;
|
|
392
|
+
} | {
|
|
393
|
+
name: string;
|
|
394
|
+
description: string;
|
|
395
|
+
inputSchema: z.ZodObject<{
|
|
396
|
+
files: z.ZodArray<z.ZodObject<{
|
|
397
|
+
path: z.ZodString;
|
|
398
|
+
content: z.ZodOptional<z.ZodString>;
|
|
399
|
+
searchReplace: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
400
|
+
search: z.ZodString;
|
|
401
|
+
replace: z.ZodString;
|
|
402
|
+
}, "strip", z.ZodTypeAny, {
|
|
403
|
+
search: string;
|
|
404
|
+
replace: string;
|
|
405
|
+
}, {
|
|
406
|
+
search: string;
|
|
407
|
+
replace: string;
|
|
408
|
+
}>, "many">>;
|
|
409
|
+
}, "strip", z.ZodTypeAny, {
|
|
410
|
+
path: string;
|
|
411
|
+
content?: string | undefined;
|
|
412
|
+
searchReplace?: {
|
|
413
|
+
search: string;
|
|
414
|
+
replace: string;
|
|
415
|
+
}[] | undefined;
|
|
416
|
+
}, {
|
|
417
|
+
path: string;
|
|
418
|
+
content?: string | undefined;
|
|
419
|
+
searchReplace?: {
|
|
420
|
+
search: string;
|
|
421
|
+
replace: string;
|
|
422
|
+
}[] | undefined;
|
|
423
|
+
}>, "many">;
|
|
424
|
+
}, "strip", z.ZodTypeAny, {
|
|
425
|
+
files: {
|
|
426
|
+
path: string;
|
|
427
|
+
content?: string | undefined;
|
|
428
|
+
searchReplace?: {
|
|
429
|
+
search: string;
|
|
430
|
+
replace: string;
|
|
431
|
+
}[] | undefined;
|
|
432
|
+
}[];
|
|
433
|
+
}, {
|
|
434
|
+
files: {
|
|
435
|
+
path: string;
|
|
436
|
+
content?: string | undefined;
|
|
437
|
+
searchReplace?: {
|
|
438
|
+
search: string;
|
|
439
|
+
replace: string;
|
|
440
|
+
}[] | undefined;
|
|
441
|
+
}[];
|
|
442
|
+
}>;
|
|
443
|
+
execute: (args: any) => Promise<({
|
|
444
|
+
success: boolean;
|
|
445
|
+
message: string;
|
|
446
|
+
path?: undefined;
|
|
447
|
+
} | {
|
|
448
|
+
path: any;
|
|
449
|
+
success: boolean;
|
|
450
|
+
message?: undefined;
|
|
451
|
+
} | {
|
|
452
|
+
path: any;
|
|
453
|
+
success: boolean;
|
|
454
|
+
message: any;
|
|
455
|
+
})[]>;
|
|
456
|
+
} | {
|
|
457
|
+
name: string;
|
|
458
|
+
description: string;
|
|
459
|
+
inputSchema: z.ZodObject<{
|
|
460
|
+
source_path: z.ZodString;
|
|
461
|
+
name: z.ZodString;
|
|
462
|
+
description: z.ZodString;
|
|
463
|
+
usage: z.ZodString;
|
|
464
|
+
scope: z.ZodDefault<z.ZodEnum<["local", "global"]>>;
|
|
465
|
+
}, "strip", z.ZodTypeAny, {
|
|
466
|
+
source_path: string;
|
|
467
|
+
name: string;
|
|
468
|
+
description: string;
|
|
469
|
+
usage: string;
|
|
470
|
+
scope: "local" | "global";
|
|
471
|
+
}, {
|
|
472
|
+
source_path: string;
|
|
473
|
+
name: string;
|
|
474
|
+
description: string;
|
|
475
|
+
usage: string;
|
|
476
|
+
scope?: "local" | "global" | undefined;
|
|
477
|
+
}>;
|
|
478
|
+
execute: ({ source_path, name, description, usage, scope }: {
|
|
479
|
+
source_path: string;
|
|
480
|
+
name: string;
|
|
481
|
+
description: string;
|
|
482
|
+
usage: string;
|
|
483
|
+
scope: string;
|
|
484
|
+
}) => Promise<string>;
|
|
485
|
+
} | {
|
|
486
|
+
name: string;
|
|
487
|
+
description: string;
|
|
488
|
+
inputSchema: z.ZodObject<{
|
|
489
|
+
url: z.ZodString;
|
|
490
|
+
convertToMarkdown: z.ZodDefault<z.ZodBoolean>;
|
|
491
|
+
timeout: z.ZodOptional<z.ZodNumber>;
|
|
492
|
+
}, "strip", z.ZodTypeAny, {
|
|
493
|
+
url: string;
|
|
494
|
+
convertToMarkdown: boolean;
|
|
495
|
+
timeout?: number | undefined;
|
|
496
|
+
}, {
|
|
497
|
+
url: string;
|
|
498
|
+
convertToMarkdown?: boolean | undefined;
|
|
499
|
+
timeout?: number | undefined;
|
|
500
|
+
}>;
|
|
501
|
+
execute: ({ url, convertToMarkdown, timeout }: {
|
|
502
|
+
url: string;
|
|
503
|
+
convertToMarkdown: boolean;
|
|
504
|
+
timeout?: number;
|
|
505
|
+
}) => Promise<{
|
|
506
|
+
url: string;
|
|
507
|
+
content: string;
|
|
508
|
+
contentType: string;
|
|
509
|
+
error?: undefined;
|
|
510
|
+
} | {
|
|
511
|
+
url: string;
|
|
512
|
+
error: any;
|
|
513
|
+
content?: undefined;
|
|
514
|
+
contentType?: undefined;
|
|
515
|
+
}>;
|
|
516
|
+
} | {
|
|
517
|
+
name: string;
|
|
518
|
+
description: string;
|
|
519
|
+
inputSchema: z.ZodObject<{
|
|
520
|
+
pattern: z.ZodString;
|
|
521
|
+
path: z.ZodDefault<z.ZodString>;
|
|
522
|
+
ignore: z.ZodDefault<z.ZodArray<z.ZodString, "many">>;
|
|
523
|
+
includeDirectories: z.ZodDefault<z.ZodBoolean>;
|
|
524
|
+
maxResults: z.ZodOptional<z.ZodNumber>;
|
|
525
|
+
}, "strip", z.ZodTypeAny, {
|
|
526
|
+
path: string;
|
|
527
|
+
pattern: string;
|
|
528
|
+
ignore: string[];
|
|
529
|
+
includeDirectories: boolean;
|
|
530
|
+
maxResults?: number | undefined;
|
|
531
|
+
}, {
|
|
532
|
+
pattern: string;
|
|
533
|
+
path?: string | undefined;
|
|
534
|
+
ignore?: string[] | undefined;
|
|
535
|
+
includeDirectories?: boolean | undefined;
|
|
536
|
+
maxResults?: number | undefined;
|
|
537
|
+
}>;
|
|
538
|
+
execute: ({ pattern, path, ignore, includeDirectories, maxResults }: {
|
|
539
|
+
pattern: string;
|
|
540
|
+
path: string;
|
|
541
|
+
ignore: string[];
|
|
542
|
+
includeDirectories: boolean;
|
|
543
|
+
maxResults?: number;
|
|
544
|
+
}) => Promise<{
|
|
545
|
+
matches: string[];
|
|
546
|
+
count: number;
|
|
547
|
+
truncated: boolean;
|
|
548
|
+
}>;
|
|
549
|
+
} | {
|
|
550
|
+
name: string;
|
|
551
|
+
description: string;
|
|
552
|
+
inputSchema: z.ZodObject<{
|
|
553
|
+
pattern: z.ZodString;
|
|
554
|
+
path: z.ZodDefault<z.ZodString>;
|
|
555
|
+
glob: z.ZodDefault<z.ZodString>;
|
|
556
|
+
ignoreCase: z.ZodDefault<z.ZodBoolean>;
|
|
557
|
+
contextLines: z.ZodDefault<z.ZodNumber>;
|
|
558
|
+
maxResults: z.ZodOptional<z.ZodNumber>;
|
|
559
|
+
filesOnly: z.ZodDefault<z.ZodBoolean>;
|
|
560
|
+
}, "strip", z.ZodTypeAny, {
|
|
561
|
+
path: string;
|
|
562
|
+
pattern: string;
|
|
563
|
+
glob: string;
|
|
564
|
+
ignoreCase: boolean;
|
|
565
|
+
contextLines: number;
|
|
566
|
+
filesOnly: boolean;
|
|
567
|
+
maxResults?: number | undefined;
|
|
568
|
+
}, {
|
|
569
|
+
pattern: string;
|
|
570
|
+
path?: string | undefined;
|
|
571
|
+
maxResults?: number | undefined;
|
|
572
|
+
glob?: string | undefined;
|
|
573
|
+
ignoreCase?: boolean | undefined;
|
|
574
|
+
contextLines?: number | undefined;
|
|
575
|
+
filesOnly?: boolean | undefined;
|
|
576
|
+
}>;
|
|
577
|
+
execute: ({ pattern, path, glob: globPattern, ignoreCase, contextLines, maxResults, filesOnly }: {
|
|
578
|
+
pattern: string;
|
|
579
|
+
path: string;
|
|
580
|
+
glob: string;
|
|
581
|
+
ignoreCase: boolean;
|
|
582
|
+
contextLines: number;
|
|
583
|
+
maxResults?: number;
|
|
584
|
+
filesOnly: boolean;
|
|
585
|
+
}) => Promise<{
|
|
586
|
+
matches: never[];
|
|
587
|
+
count: number;
|
|
588
|
+
error: string;
|
|
589
|
+
files?: undefined;
|
|
590
|
+
truncated?: undefined;
|
|
591
|
+
} | {
|
|
592
|
+
matches: any[];
|
|
593
|
+
count: number;
|
|
594
|
+
files: string[];
|
|
595
|
+
truncated: boolean;
|
|
596
|
+
error?: undefined;
|
|
597
|
+
}>;
|
|
598
|
+
} | {
|
|
599
|
+
name: string;
|
|
600
|
+
description: string;
|
|
601
|
+
inputSchema: z.ZodObject<{
|
|
602
|
+
path: z.ZodDefault<z.ZodString>;
|
|
603
|
+
}, "strip", z.ZodTypeAny, {
|
|
604
|
+
path: string;
|
|
605
|
+
}, {
|
|
606
|
+
path?: string | undefined;
|
|
607
|
+
}>;
|
|
608
|
+
execute: ({ path }: {
|
|
609
|
+
path: string;
|
|
610
|
+
}) => Promise<{
|
|
611
|
+
name: string;
|
|
612
|
+
isDir: boolean;
|
|
613
|
+
}[]>;
|
|
614
|
+
} | {
|
|
615
|
+
name: string;
|
|
616
|
+
description: string;
|
|
617
|
+
inputSchema: z.ZodObject<{
|
|
618
|
+
command: z.ZodString;
|
|
619
|
+
timeout: z.ZodOptional<z.ZodNumber>;
|
|
620
|
+
}, "strip", z.ZodTypeAny, {
|
|
621
|
+
command: string;
|
|
622
|
+
timeout?: number | undefined;
|
|
623
|
+
}, {
|
|
624
|
+
command: string;
|
|
625
|
+
timeout?: number | undefined;
|
|
626
|
+
}>;
|
|
627
|
+
execute: ({ command, timeout }: {
|
|
628
|
+
command: string;
|
|
629
|
+
timeout?: number;
|
|
630
|
+
}) => Promise<{
|
|
631
|
+
stdout: string;
|
|
632
|
+
stderr: string;
|
|
633
|
+
exitCode: number;
|
|
634
|
+
timedOut: boolean;
|
|
635
|
+
error?: undefined;
|
|
636
|
+
} | {
|
|
637
|
+
error: any;
|
|
638
|
+
stdout: any;
|
|
639
|
+
stderr: any;
|
|
640
|
+
exitCode: any;
|
|
641
|
+
timedOut: any;
|
|
642
|
+
}>;
|
|
643
|
+
} | {
|
|
644
|
+
name: string;
|
|
645
|
+
description: string;
|
|
646
|
+
inputSchema: z.ZodObject<{
|
|
647
|
+
path: z.ZodString;
|
|
648
|
+
}, "strip", z.ZodTypeAny, {
|
|
649
|
+
path: string;
|
|
650
|
+
}, {
|
|
651
|
+
path: string;
|
|
652
|
+
}>;
|
|
653
|
+
execute: (args: any) => Promise<string>;
|
|
654
|
+
} | {
|
|
655
|
+
name: string;
|
|
656
|
+
description: string;
|
|
657
|
+
inputSchema: z.ZodObject<{
|
|
658
|
+
operation: z.ZodEnum<["status", "add", "commit", "diff", "log", "branch"]>;
|
|
659
|
+
cwd: z.ZodDefault<z.ZodString>;
|
|
660
|
+
files: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
|
|
661
|
+
message: z.ZodOptional<z.ZodString>;
|
|
662
|
+
}, "strip", z.ZodTypeAny, {
|
|
663
|
+
operation: "status" | "add" | "commit" | "diff" | "log" | "branch";
|
|
664
|
+
cwd: string;
|
|
665
|
+
message?: string | undefined;
|
|
666
|
+
files?: string[] | undefined;
|
|
667
|
+
}, {
|
|
668
|
+
operation: "status" | "add" | "commit" | "diff" | "log" | "branch";
|
|
669
|
+
message?: string | undefined;
|
|
670
|
+
files?: string[] | undefined;
|
|
671
|
+
cwd?: string | undefined;
|
|
672
|
+
}>;
|
|
673
|
+
execute: ({ operation, cwd, files, message }: {
|
|
674
|
+
operation: string;
|
|
675
|
+
cwd: string;
|
|
676
|
+
files?: string[];
|
|
677
|
+
message?: string;
|
|
678
|
+
}) => Promise<{
|
|
679
|
+
success: boolean;
|
|
680
|
+
output: string;
|
|
681
|
+
error?: undefined;
|
|
682
|
+
} | {
|
|
683
|
+
success: boolean;
|
|
684
|
+
error: any;
|
|
685
|
+
output?: undefined;
|
|
686
|
+
}>;
|
|
687
|
+
} | {
|
|
688
|
+
name: string;
|
|
689
|
+
description: string;
|
|
690
|
+
inputSchema: z.ZodObject<{
|
|
691
|
+
path: z.ZodString;
|
|
692
|
+
}, "strip", z.ZodTypeAny, {
|
|
693
|
+
path: string;
|
|
694
|
+
}, {
|
|
695
|
+
path: string;
|
|
696
|
+
}>;
|
|
697
|
+
execute: ({ path }: {
|
|
698
|
+
path: string;
|
|
699
|
+
}) => Promise<{
|
|
700
|
+
passed: boolean;
|
|
701
|
+
errors: {
|
|
702
|
+
message: string;
|
|
703
|
+
}[];
|
|
704
|
+
language?: undefined;
|
|
705
|
+
warnings?: undefined;
|
|
706
|
+
output?: undefined;
|
|
707
|
+
file?: undefined;
|
|
708
|
+
} | {
|
|
709
|
+
passed: boolean;
|
|
710
|
+
language: string;
|
|
711
|
+
errors: never[];
|
|
712
|
+
warnings: never[];
|
|
713
|
+
output: string;
|
|
714
|
+
file?: undefined;
|
|
715
|
+
} | {
|
|
716
|
+
passed: boolean;
|
|
717
|
+
language: string;
|
|
718
|
+
errors: {
|
|
719
|
+
message: any;
|
|
720
|
+
line: number;
|
|
721
|
+
}[];
|
|
722
|
+
warnings: never[];
|
|
723
|
+
output: any;
|
|
724
|
+
file: string;
|
|
725
|
+
}>;
|
|
726
|
+
})[];
|