@seastudio/sdk 3.0.3 → 3.0.5

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.
@@ -1,1268 +1,1174 @@
1
1
  'use strict';
2
2
 
3
- var chunkTFOJLA2F_cjs = require('./chunk-TFOJLA2F.cjs');
3
+ var chunk3I7UM66P_cjs = require('./chunk-3I7UM66P.cjs');
4
4
 
5
- // src/mcp/seastudio/tools-plugin.ts
6
- var pluginManagementTools = [
5
+ // src/mcp/seastudio/tools-file.ts
6
+ function annotateTool(tool, annotations, outputSchema) {
7
+ return {
8
+ ...tool,
9
+ annotations,
10
+ ...outputSchema ? { outputSchema } : {}
11
+ };
12
+ }
13
+ var rootedPathEvidenceOutputSchema = {
14
+ type: "object",
15
+ properties: {
16
+ rootId: { type: "string" },
17
+ path: { type: "string" }
18
+ },
19
+ required: ["rootId", "path"]
20
+ };
21
+ var rootedWriteEvidenceOutputSchema = {
22
+ type: "object",
23
+ properties: {
24
+ rootId: { type: "string" },
25
+ path: { type: "string" },
26
+ written: { type: "boolean" }
27
+ },
28
+ required: ["rootId", "path", "written"]
29
+ };
30
+ var dualPathEvidenceOutputSchema = {
31
+ type: "object",
32
+ properties: {
33
+ sourceRootId: { type: "string" },
34
+ sourcePath: { type: "string" },
35
+ destRootId: { type: "string" },
36
+ destPath: { type: "string" }
37
+ },
38
+ required: ["sourceRootId", "sourcePath", "destRootId", "destPath"]
39
+ };
40
+ var batchFlattenCopyEvidenceOutputSchema = {
41
+ type: "object",
42
+ properties: {
43
+ sourceRootId: { type: "string" },
44
+ sourcePath: { type: "string" },
45
+ destRootId: { type: "string" },
46
+ destPath: { type: "string" },
47
+ copiedCount: { type: "number" },
48
+ totalCount: { type: "number" },
49
+ errors: { type: "array", items: { type: "object", additionalProperties: true } }
50
+ },
51
+ required: ["sourceRootId", "sourcePath", "destRootId", "destPath", "copiedCount", "totalCount", "errors"]
52
+ };
53
+ var fileDownloadEvidenceOutputSchema = {
54
+ type: "object",
55
+ properties: {
56
+ rootId: { type: "string" },
57
+ path: { type: "string" },
58
+ savedPath: { type: "string" },
59
+ size: { type: "number" }
60
+ },
61
+ required: ["rootId", "path", "savedPath", "size"]
62
+ };
63
+ var shellCommandEvidenceOutputSchema = {
64
+ type: "object",
65
+ properties: {
66
+ command: { type: "string" },
67
+ cwd: { type: "string" },
68
+ exitCode: { type: "number" },
69
+ stdout: { type: "string" },
70
+ stderr: { type: "string" },
71
+ error: { type: "string" },
72
+ durationMs: { type: "number" },
73
+ usedFallback: { type: "boolean" }
74
+ },
75
+ required: ["command", "exitCode", "stdout", "stderr"]
76
+ };
77
+ var shellSessionSnapshotEvidenceOutputSchema = {
78
+ type: "object",
79
+ properties: {
80
+ projectPath: { type: "string" },
81
+ cwd: { type: "string" },
82
+ promptLabel: { type: "string" },
83
+ isRunning: { type: "boolean" },
84
+ lastExitCode: { type: "number" },
85
+ lastDurationMs: { type: "number" },
86
+ lastCommandAt: { type: "number" },
87
+ historyCount: { type: "number" },
88
+ entryCount: { type: "number" }
89
+ },
90
+ required: ["projectPath", "cwd", "promptLabel", "isRunning", "historyCount", "entryCount"]
91
+ };
92
+ var fileTools = [
7
93
  annotateTool({
8
- name: "seastudio-plugin_list_official",
9
- description: "\u5217\u51FA Registry \u4E2D\u6240\u6709\u5B98\u65B9\u63D2\u4EF6\u3002\u8FD4\u56DE\u6BCF\u4E2A\u63D2\u4EF6\u7684 id\u3001name\u3001version\u3001description \u7B49\u4FE1\u606F\u3002",
94
+ name: "seastudio-file_get_selected",
95
+ description: "\u83B7\u53D6\u5F53\u524D\u6587\u4EF6\u89C6\u56FE\u9009\u4E2D\u7684\u6587\u4EF6\u6216\u76EE\u5F55\u3002\u9002\u7528\u4E8E\u7EED\u63A5\u201C\u5F53\u524D\u9009\u4E2D\u9879\u201D\u7684\u4E0A\u4E0B\u6587\u3002",
10
96
  inputSchema: {
11
97
  type: "object",
12
98
  properties: {}
13
99
  }
14
100
  }, {
15
101
  operationKind: "read",
16
- requiresExecutionEvidence: false
102
+ requiresExecutionEvidence: false,
103
+ rawDomain: "filesystem"
17
104
  }),
18
105
  annotateTool({
19
- name: "seastudio-plugin_list_installed",
20
- description: "\u5217\u51FA\u672C\u5730\u5DF2\u5B89\u88C5\u7684\u6240\u6709\u63D2\u4EF6\u3002\u8FD4\u56DE\u6BCF\u4E2A\u63D2\u4EF6\u7684 id\u3001name\u3001version\u3001enabled \u72B6\u6001\u7B49\u3002",
106
+ name: "seastudio-file_read",
107
+ description: "\u8BFB\u53D6\u6307\u5B9A\u6587\u4EF6\u5185\u5BB9\u3002\u9002\u7528\u4E8E\u67E5\u770B\u3001\u5F15\u7528\u6216\u5206\u6790\u5DF2\u77E5\u8DEF\u5F84\u7684\u6587\u4EF6\uFF0C\u4E0D\u4F1A\u4FEE\u6539\u9879\u76EE\u3002",
21
108
  inputSchema: {
22
109
  type: "object",
23
- properties: {}
110
+ properties: {
111
+ rootId: { type: "string", enum: ["workspace"], description: "\u6839\u76EE\u5F55 ID" },
112
+ path: { type: "string", description: "\u6587\u4EF6\u8DEF\u5F84\uFF08\u76F8\u5BF9\u4E8E rootId\uFF09" },
113
+ offset: { type: "number", description: "\u8D77\u59CB\u884C\u504F\u79FB\uFF08\u53EF\u9009\uFF09" },
114
+ limit: { type: "number", description: "\u8BFB\u53D6\u884C\u6570\u9650\u5236\uFF08\u53EF\u9009\uFF09" }
115
+ },
116
+ required: ["rootId", "path"]
24
117
  }
25
118
  }, {
26
119
  operationKind: "read",
27
- requiresExecutionEvidence: false
120
+ requiresExecutionEvidence: false,
121
+ rawDomain: "filesystem"
28
122
  }),
29
123
  annotateTool({
30
- name: "seastudio-plugin_install",
31
- description: "\u4ECE Registry \u5B89\u88C5\u6307\u5B9A\u63D2\u4EF6\u3002\u9700\u63D0\u4F9B\u63D2\u4EF6 id\uFF0C\u7CFB\u7EDF\u4F1A\u4ECE\u5B98\u65B9 Registry \u4E0B\u8F7D\u5E76\u5B89\u88C5\u3002",
124
+ name: "seastudio-file_write",
125
+ description: "\u5C06\u6587\u672C\u5185\u5BB9\u5199\u5165\u6307\u5B9A\u8DEF\u5F84\u3002\u4EC5\u5728\u9700\u8981\u771F\u5B9E\u521B\u5EFA\u6216\u4FEE\u6539\u6587\u4EF6\u65F6\u4F7F\u7528\uFF0C\u6210\u529F\u540E\u6587\u4EF6\u5185\u5BB9\u4F1A\u843D\u76D8\u3002",
32
126
  inputSchema: {
33
127
  type: "object",
34
128
  properties: {
35
- pluginId: { type: "string", description: "\u8981\u5B89\u88C5\u7684\u63D2\u4EF6 ID" }
129
+ rootId: { type: "string", enum: ["workspace"], description: "\u6839\u76EE\u5F55 ID" },
130
+ path: { type: "string", description: "\u6587\u4EF6\u8DEF\u5F84\uFF08\u76F8\u5BF9\u4E8E rootId\uFF09" },
131
+ content: { type: "string", description: "\u6587\u4EF6\u5185\u5BB9" }
36
132
  },
37
- required: ["pluginId"]
133
+ required: ["rootId", "path", "content"]
38
134
  }
39
135
  }, {
40
136
  operationKind: "mutate",
41
- requiresExecutionEvidence: true
42
- }),
137
+ requiresExecutionEvidence: true,
138
+ rawDomain: "workspace"
139
+ }, rootedWriteEvidenceOutputSchema),
43
140
  annotateTool({
44
- name: "seastudio-plugin_uninstall",
45
- description: "\u5378\u8F7D\u6307\u5B9A\u63D2\u4EF6\u3002\u9700\u63D0\u4F9B\u63D2\u4EF6 id\u3002",
141
+ name: "seastudio-file_list",
142
+ description: "\u5217\u51FA\u6307\u5B9A\u76EE\u5F55\u4E0B\u7684\u6587\u4EF6\u548C\u5B50\u76EE\u5F55\u3002\u9002\u7528\u4E8E\u5728\u6267\u884C\u8BFB\u5199\u524D\u786E\u8BA4\u76EE\u5F55\u7ED3\u6784\u6216\u5B9A\u4F4D\u76EE\u6807\u8DEF\u5F84\u3002",
46
143
  inputSchema: {
47
144
  type: "object",
48
145
  properties: {
49
- pluginId: { type: "string", description: "\u8981\u5378\u8F7D\u7684\u63D2\u4EF6 ID" }
146
+ rootId: { type: "string", enum: ["workspace"], description: "\u6839\u76EE\u5F55 ID" },
147
+ path: { type: "string", description: "\u76EE\u5F55\u8DEF\u5F84\uFF08\u76F8\u5BF9\u4E8E rootId\uFF09" }
50
148
  },
51
- required: ["pluginId"]
149
+ required: ["rootId", "path"]
52
150
  }
53
151
  }, {
54
- operationKind: "mutate",
55
- requiresExecutionEvidence: true
152
+ operationKind: "read",
153
+ requiresExecutionEvidence: false,
154
+ rawDomain: "filesystem"
56
155
  }),
57
156
  annotateTool({
58
- name: "seastudio-plugin_enable",
59
- description: "\u5728\u5F53\u524D\u9879\u76EE\u4E2D\u542F\u7528\u6307\u5B9A\u63D2\u4EF6\u3002\u9700\u63D0\u4F9B\u63D2\u4EF6 id\u3002",
157
+ name: "seastudio-file_delete",
158
+ description: "\u5220\u9664\u6307\u5B9A\u8DEF\u5F84\u7684\u6587\u4EF6\u6216\u76EE\u5F55\u3002\u4EC5\u5728\u7528\u6237\u660E\u786E\u8981\u6C42\u79FB\u9664\u76EE\u6807\u65F6\u4F7F\u7528\uFF0C\u6210\u529F\u540E\u76EE\u6807\u4F1A\u4ECE\u9879\u76EE\u4E2D\u6D88\u5931\u3002",
60
159
  inputSchema: {
61
160
  type: "object",
62
161
  properties: {
63
- pluginId: { type: "string", description: "\u8981\u542F\u7528\u7684\u63D2\u4EF6 ID" }
162
+ rootId: { type: "string", enum: ["workspace"], description: "\u6839\u76EE\u5F55 ID" },
163
+ path: { type: "string", description: "\u8981\u5220\u9664\u7684\u8DEF\u5F84\uFF08\u76F8\u5BF9\u4E8E rootId\uFF09" }
64
164
  },
65
- required: ["pluginId"]
165
+ required: ["rootId", "path"]
66
166
  }
67
167
  }, {
68
168
  operationKind: "mutate",
69
- requiresExecutionEvidence: true
70
- }),
169
+ requiresExecutionEvidence: true,
170
+ rawDomain: "workspace"
171
+ }, rootedPathEvidenceOutputSchema),
71
172
  annotateTool({
72
- name: "seastudio-plugin_disable",
73
- description: "\u5728\u5F53\u524D\u9879\u76EE\u4E2D\u7981\u7528\u6307\u5B9A\u63D2\u4EF6\u3002\u9700\u63D0\u4F9B\u63D2\u4EF6 id\u3002",
173
+ name: "seastudio-file_mkdir",
174
+ description: "\u521B\u5EFA\u76EE\u5F55\uFF08\u652F\u6301\u9012\u5F52\u521B\u5EFA\uFF09\u3002\u9002\u7528\u4E8E\u4E3A\u65B0\u6587\u4EF6\u6216\u5BFC\u51FA\u7ED3\u679C\u51C6\u5907\u76EE\u6807\u76EE\u5F55\u3002",
74
175
  inputSchema: {
75
176
  type: "object",
76
177
  properties: {
77
- pluginId: { type: "string", description: "\u8981\u7981\u7528\u7684\u63D2\u4EF6 ID" }
178
+ rootId: { type: "string", enum: ["workspace"], description: "\u6839\u76EE\u5F55 ID" },
179
+ path: { type: "string", description: "\u76EE\u5F55\u8DEF\u5F84\uFF08\u76F8\u5BF9\u4E8E rootId\uFF09" }
78
180
  },
79
- required: ["pluginId"]
181
+ required: ["rootId", "path"]
80
182
  }
81
183
  }, {
82
184
  operationKind: "mutate",
83
- requiresExecutionEvidence: true
84
- }),
185
+ requiresExecutionEvidence: true,
186
+ rawDomain: "workspace"
187
+ }, rootedPathEvidenceOutputSchema),
85
188
  annotateTool({
86
- name: "seastudio-plugin_get_status",
87
- description: "\u83B7\u53D6\u6307\u5B9A\u63D2\u4EF6\u7684\u5B89\u88C5\u72B6\u6001\u3002\u8FD4\u56DE\u662F\u5426\u5DF2\u5B89\u88C5\u3001\u7248\u672C\u3001\u662F\u5426\u542F\u7528\u3001UI \u7C7B\u578B\u7B49\u8BE6\u7EC6\u4FE1\u606F\u3002\u82E5\u672A\u5B89\u88C5\u5219\u68C0\u67E5 Registry \u4E2D\u662F\u5426\u5B58\u5728\u3002",
189
+ name: "seastudio-file_exists",
190
+ description: "\u68C0\u67E5\u6587\u4EF6\u6216\u76EE\u5F55\u662F\u5426\u5B58\u5728\u3002\u9002\u7528\u4E8E\u5728\u6267\u884C\u5199\u5165\u3001\u5220\u9664\u3001\u91CD\u547D\u540D\u524D\u505A\u524D\u7F6E\u5224\u65AD\u3002",
88
191
  inputSchema: {
89
192
  type: "object",
90
193
  properties: {
91
- pluginId: { type: "string", description: "\u8981\u67E5\u8BE2\u7684\u63D2\u4EF6 ID" }
194
+ rootId: { type: "string", enum: ["workspace"], description: "\u6839\u76EE\u5F55 ID" },
195
+ path: { type: "string", description: "\u8981\u68C0\u67E5\u7684\u8DEF\u5F84\uFF08\u76F8\u5BF9\u4E8E rootId\uFF09" }
92
196
  },
93
- required: ["pluginId"]
197
+ required: ["rootId", "path"]
94
198
  }
95
199
  }, {
96
200
  operationKind: "read",
97
- requiresExecutionEvidence: false
98
- })
99
- ];
100
- var pluginTabTools = [
201
+ requiresExecutionEvidence: false,
202
+ rawDomain: "workspace"
203
+ }),
101
204
  annotateTool({
102
- name: "seastudio-plugin_tab_list",
103
- description: "\u83B7\u53D6\u5F53\u524D\u6240\u6709\u6253\u5F00\u7684\u63D2\u4EF6\u6807\u7B7E\u9875\u3002\u8FD4\u56DE\u6BCF\u4E2A\u6807\u7B7E\u7684 instanceId\u3001pluginId\u3001title \u7B49\u3002",
205
+ name: "seastudio-file_stat",
206
+ description: "\u83B7\u53D6\u6587\u4EF6\u6216\u76EE\u5F55\u7684\u72B6\u6001\u4FE1\u606F\uFF0C\u5982\u7C7B\u578B\u3001\u5927\u5C0F\u548C\u4FEE\u6539\u65F6\u95F4\uFF0C\u7528\u4E8E\u5224\u65AD\u76EE\u6807\u5BF9\u8C61\u7279\u5F81\u3002",
104
207
  inputSchema: {
105
208
  type: "object",
106
- properties: {}
209
+ properties: {
210
+ rootId: { type: "string", enum: ["workspace"], description: "\u6839\u76EE\u5F55 ID" },
211
+ path: { type: "string", description: "\u6587\u4EF6\u8DEF\u5F84" }
212
+ },
213
+ required: ["rootId", "path"]
107
214
  }
108
215
  }, {
109
216
  operationKind: "read",
110
- requiresExecutionEvidence: false
217
+ requiresExecutionEvidence: false,
218
+ rawDomain: "filesystem"
111
219
  }),
112
220
  annotateTool({
113
- name: "seastudio-plugin_tab_get_active",
114
- description: "\u83B7\u53D6\u5F53\u524D\u805A\u7126\uFF08\u6FC0\u6D3B\uFF09\u7684\u63D2\u4EF6\u6807\u7B7E\u9875\u3002\u8FD4\u56DE\u8BE5\u6807\u7B7E\u7684 instanceId\u3001pluginId\u3001title\u3002",
221
+ name: "seastudio-file_info",
222
+ description: "\u83B7\u53D6\u6587\u4EF6\u6216\u76EE\u5F55\u7684\u8BE6\u7EC6\u4FE1\u606F\uFF0C\u5982\u7C7B\u578B\u3001\u5927\u5C0F\u3001\u4FEE\u6539\u65F6\u95F4\u548C MIME\uFF0C\u7528\u4E8E\u5728\u8BFB\u53D6\u524D\u505A\u5224\u65AD\u3002",
115
223
  inputSchema: {
116
224
  type: "object",
117
- properties: {}
225
+ properties: {
226
+ rootId: { type: "string", enum: ["workspace"], description: "\u6839\u76EE\u5F55 ID" },
227
+ path: { type: "string", description: "\u6587\u4EF6\u6216\u76EE\u5F55\u8DEF\u5F84" }
228
+ },
229
+ required: ["rootId", "path"]
118
230
  }
119
231
  }, {
120
232
  operationKind: "read",
121
- requiresExecutionEvidence: false
233
+ requiresExecutionEvidence: false,
234
+ rawDomain: "filesystem"
122
235
  }),
123
236
  annotateTool({
124
- name: "seastudio-plugin_tab_open",
125
- description: "\u4E3A\u6307\u5B9A\u63D2\u4EF6\u65B0\u5EFA\u4E00\u4E2A\u6807\u7B7E\u9875\u5E76\u6FC0\u6D3B\u3002\u9700\u63D0\u4F9B\u63D2\u4EF6 id\u3002",
237
+ name: "seastudio-file_search",
238
+ description: "\u5728\u6307\u5B9A root \u4E2D\u6309 query \u641C\u7D22\u6587\u4EF6\u5185\u5BB9\uFF0C\u53EF\u9009\u9650\u5B9A\u5B50\u8DEF\u5F84\u548C glob\u3002",
126
239
  inputSchema: {
127
240
  type: "object",
128
241
  properties: {
129
- pluginId: { type: "string", description: "\u8981\u6253\u5F00\u6807\u7B7E\u9875\u7684\u63D2\u4EF6 ID" }
242
+ rootId: { type: "string", enum: ["workspace"], description: "\u6839\u76EE\u5F55 ID" },
243
+ query: { type: "string", description: "\u641C\u7D22\u5185\u5BB9\u6216\u6A21\u5F0F" },
244
+ path: { type: "string", description: "\u76F8\u5BF9 root \u7684\u641C\u7D22\u5B50\u8DEF\u5F84\uFF08\u53EF\u9009\uFF09" },
245
+ glob: { type: "string", description: "\u6587\u4EF6 glob \u6A21\u5F0F\uFF08\u53EF\u9009\uFF09" },
246
+ headLimit: { type: "number", description: "\u8FD4\u56DE\u7ED3\u679C\u6570\u91CF\u9650\u5236\uFF08\u53EF\u9009\uFF09" }
130
247
  },
131
- required: ["pluginId"]
248
+ required: ["rootId", "query"]
132
249
  }
133
250
  }, {
134
- operationKind: "mutate",
135
- requiresExecutionEvidence: true
251
+ operationKind: "read",
252
+ requiresExecutionEvidence: false,
253
+ rawDomain: "filesystem"
136
254
  }),
137
255
  annotateTool({
138
- name: "seastudio-plugin_tab_switch",
139
- description: "\u5207\u6362\u5230\u6307\u5B9A\u7684\u63D2\u4EF6\u6807\u7B7E\u9875\u3002\u9700\u63D0\u4F9B\u6807\u7B7E\u5B9E\u4F8B ID\uFF08instanceId\uFF09\u3002",
256
+ name: "seastudio-file_rename",
257
+ description: "\u91CD\u547D\u540D\u6587\u4EF6\u6216\u76EE\u5F55\u3002\u4EC5\u5728\u7528\u6237\u660E\u786E\u8981\u6C42\u6539\u540D\u65F6\u4F7F\u7528\uFF0C\u6210\u529F\u540E\u539F\u8DEF\u5F84\u4F1A\u53D8\u66F4\u4E3A\u65B0\u540D\u79F0\u3002",
140
258
  inputSchema: {
141
259
  type: "object",
142
260
  properties: {
143
- instanceId: { type: "string", description: "\u8981\u5207\u6362\u5230\u7684\u6807\u7B7E\u5B9E\u4F8B ID" }
261
+ rootId: { type: "string", enum: ["workspace"], description: "\u6839\u76EE\u5F55 ID" },
262
+ path: { type: "string", description: "\u539F\u8DEF\u5F84\uFF08\u76F8\u5BF9\u4E8E rootId\uFF09" },
263
+ newName: { type: "string", description: "\u65B0\u540D\u79F0" }
144
264
  },
145
- required: ["instanceId"]
265
+ required: ["rootId", "path", "newName"]
146
266
  }
147
267
  }, {
148
268
  operationKind: "mutate",
149
- requiresExecutionEvidence: true
150
- }),
269
+ requiresExecutionEvidence: true,
270
+ rawDomain: "workspace"
271
+ }, rootedPathEvidenceOutputSchema),
151
272
  annotateTool({
152
- name: "seastudio-plugin_tab_close",
153
- description: "\u5173\u95ED\u6307\u5B9A\u7684\u63D2\u4EF6\u6807\u7B7E\u9875\u3002\u9700\u63D0\u4F9B\u6807\u7B7E\u5B9E\u4F8B ID\uFF08instanceId\uFF09\u3002",
273
+ name: "seastudio-file_move",
274
+ description: "\u5C06\u6E90\u8DEF\u5F84\u79FB\u52A8\u5230\u76EE\u6807\u8DEF\u5F84\u3002\u8DEF\u5F84\u7EDF\u4E00\u4F7F\u7528 rootId + path\u3002",
154
275
  inputSchema: {
155
276
  type: "object",
156
277
  properties: {
157
- instanceId: { type: "string", description: "\u8981\u5173\u95ED\u7684\u6807\u7B7E\u5B9E\u4F8B ID" }
278
+ sourceRootId: { type: "string", enum: ["workspace"], description: "\u6E90\u6839\u76EE\u5F55 ID" },
279
+ sourcePath: { type: "string", description: "\u6E90\u8DEF\u5F84\uFF08\u76F8\u5BF9\u4E8E sourceRootId\uFF09" },
280
+ destRootId: { type: "string", enum: ["workspace"], description: "\u76EE\u6807\u6839\u76EE\u5F55 ID" },
281
+ destPath: { type: "string", description: "\u76EE\u6807\u8DEF\u5F84\uFF08\u76F8\u5BF9\u4E8E destRootId\uFF09" }
158
282
  },
159
- required: ["instanceId"]
283
+ required: ["sourceRootId", "sourcePath", "destRootId", "destPath"]
160
284
  }
161
285
  }, {
162
286
  operationKind: "mutate",
163
- requiresExecutionEvidence: true
164
- }),
165
- annotateTool({
166
- name: "seastudio-plugin_tab_get_status",
167
- description: "\u83B7\u53D6\u6307\u5B9A\u63D2\u4EF6\u7684\u6807\u7B7E\u72B6\u6001\u3002\u8FD4\u56DE\u8BE5\u63D2\u4EF6\u6253\u5F00\u4E86\u51E0\u4E2A\u6807\u7B7E\u3001\u5404\u6807\u7B7E\u7684 instanceId/title\u3001\u54EA\u4E2A\u662F\u5F53\u524D\u805A\u7126\u6001\u3002",
287
+ requiresExecutionEvidence: true,
288
+ rawDomain: "workspace"
289
+ }, dualPathEvidenceOutputSchema),
290
+ annotateTool({
291
+ name: "seastudio-file_copy_to",
292
+ description: "\u5C06\u6E90\u8DEF\u5F84\u590D\u5236\u5230\u76EE\u6807\u8DEF\u5F84\u3002\u8DEF\u5F84\u7EDF\u4E00\u4F7F\u7528 rootId + path\u3002",
168
293
  inputSchema: {
169
294
  type: "object",
170
295
  properties: {
171
- pluginId: { type: "string", description: "\u8981\u67E5\u8BE2\u6807\u7B7E\u72B6\u6001\u7684\u63D2\u4EF6 ID" }
296
+ sourceRootId: { type: "string", enum: ["workspace"], description: "\u6E90\u6839\u76EE\u5F55 ID" },
297
+ sourcePath: { type: "string", description: "\u6E90\u8DEF\u5F84\uFF08\u76F8\u5BF9\u4E8E sourceRootId\uFF09" },
298
+ destRootId: { type: "string", enum: ["workspace"], description: "\u76EE\u6807\u6839\u76EE\u5F55 ID" },
299
+ destPath: { type: "string", description: "\u76EE\u6807\u8DEF\u5F84\uFF08\u76F8\u5BF9\u4E8E destRootId\uFF09" }
172
300
  },
173
- required: ["pluginId"]
174
- }
175
- }, {
176
- operationKind: "read",
177
- requiresExecutionEvidence: false
178
- })
179
- ];
180
-
181
- // src/mcp/seastudio/tools-agent.ts
182
- var agentManagementTools = [
183
- annotateTool({
184
- name: "seastudio-agent_list_official",
185
- description: "\u5217\u51FA Registry \u4E2D\u6240\u6709\u5B98\u65B9 Agent\u3002\u8FD4\u56DE\u6BCF\u4E2A Agent \u7684 id\u3001name\u3001version\u3001description \u7B49\u4FE1\u606F\u3002",
186
- inputSchema: {
187
- type: "object",
188
- properties: {}
301
+ required: ["sourceRootId", "sourcePath", "destRootId", "destPath"]
189
302
  }
190
303
  }, {
191
- operationKind: "read",
192
- requiresExecutionEvidence: false
193
- }),
304
+ operationKind: "mutate",
305
+ requiresExecutionEvidence: true,
306
+ rawDomain: "workspace"
307
+ }, dualPathEvidenceOutputSchema),
194
308
  annotateTool({
195
- name: "seastudio-agent_list_installed",
196
- description: "\u5217\u51FA\u672C\u5730\u5DF2\u5B89\u88C5\u7684\u6240\u6709 Agent\u3002\u8FD4\u56DE\u6BCF\u4E2A Agent \u7684 id\u3001name\u3001version\u3001enabled \u72B6\u6001\u7B49\u3002",
309
+ name: "seastudio-file_get_url",
310
+ description: "\u83B7\u53D6\u6307\u5B9A\u6839\u76EE\u5F55\u4E2D\u6587\u4EF6\u7684\u53EF\u8BBF\u95EE URL\uFF0C\u9002\u7528\u4E8E\u4E8C\u8FDB\u5236\u6587\u4EF6\u7684\u6D4F\u89C8\u5668\u7AEF\u8BFB\u53D6\u3002",
197
311
  inputSchema: {
198
312
  type: "object",
199
- properties: {}
313
+ properties: {
314
+ rootId: { type: "string", enum: ["workspace"], description: "\u6839\u76EE\u5F55 ID" },
315
+ path: { type: "string", description: "\u6587\u4EF6\u8DEF\u5F84\uFF08\u76F8\u5BF9\u4E8E rootId\uFF09" }
316
+ },
317
+ required: ["rootId", "path"]
200
318
  }
201
319
  }, {
202
320
  operationKind: "read",
203
- requiresExecutionEvidence: false
321
+ requiresExecutionEvidence: false,
322
+ rawDomain: "filesystem"
204
323
  }),
205
324
  annotateTool({
206
- name: "seastudio-agent_install",
207
- description: "\u4ECE Registry \u5B89\u88C5\u6307\u5B9A Agent\u3002\u9700\u63D0\u4F9B Agent id\uFF0C\u7CFB\u7EDF\u4F1A\u4ECE\u5B98\u65B9 Registry \u4E0B\u8F7D\u5E76\u5B89\u88C5\u3002",
325
+ name: "seastudio-file_download",
326
+ description: "\u4ECE\u8FDC\u7A0B URL \u4E0B\u8F7D\u6587\u4EF6\u5230\u6307\u5B9A\u6839\u76EE\u5F55\u548C\u8DEF\u5F84\u3002\u4EC5\u5728\u9700\u8981\u771F\u5B9E\u5F15\u5165\u8FDC\u7AEF\u8D44\u6E90\u65F6\u4F7F\u7528\u3002",
208
327
  inputSchema: {
209
328
  type: "object",
210
329
  properties: {
211
- agentId: { type: "string", description: "\u8981\u5B89\u88C5\u7684 Agent ID" }
330
+ rootId: { type: "string", enum: ["workspace"], description: "\u6839\u76EE\u5F55 ID" },
331
+ path: { type: "string", description: "\u4FDD\u5B58\u76EE\u5F55\u8DEF\u5F84\uFF08\u76F8\u5BF9\u4E8E rootId\uFF09" },
332
+ url: { type: "string", description: "\u8FDC\u7A0B\u6587\u4EF6 URL" },
333
+ filenameHint: { type: "string", description: "\u6587\u4EF6\u540D\u63D0\u793A\uFF08\u53EF\u9009\uFF09" }
212
334
  },
213
- required: ["agentId"]
335
+ required: ["rootId", "path", "url"]
214
336
  }
215
337
  }, {
216
338
  operationKind: "mutate",
217
- requiresExecutionEvidence: true
218
- }),
339
+ requiresExecutionEvidence: true,
340
+ rawDomain: "filesystem"
341
+ }, fileDownloadEvidenceOutputSchema),
219
342
  annotateTool({
220
- name: "seastudio-agent_uninstall",
221
- description: "\u5378\u8F7D\u6307\u5B9A Agent\u3002\u9700\u63D0\u4F9B Agent id\u3002",
343
+ name: "seastudio-file_write_binary",
344
+ description: "\u5C06 base64 \u7F16\u7801\u7684\u4E8C\u8FDB\u5236\u5185\u5BB9\u5199\u5165\u6307\u5B9A\u8DEF\u5F84\uFF0C\u9002\u7528\u4E8E xlsx/xls \u7B49\u4E8C\u8FDB\u5236\u6587\u4EF6\u7684\u4FDD\u5B58\u3002",
222
345
  inputSchema: {
223
346
  type: "object",
224
347
  properties: {
225
- agentId: { type: "string", description: "\u8981\u5378\u8F7D\u7684 Agent ID" }
348
+ rootId: { type: "string", enum: ["workspace"], description: "\u6839\u76EE\u5F55 ID" },
349
+ path: { type: "string", description: "\u6587\u4EF6\u8DEF\u5F84\uFF08\u76F8\u5BF9\u4E8E rootId\uFF09" },
350
+ base64: { type: "string", description: "base64 \u7F16\u7801\u7684\u6587\u4EF6\u5185\u5BB9" }
226
351
  },
227
- required: ["agentId"]
352
+ required: ["rootId", "path", "base64"]
228
353
  }
229
354
  }, {
230
355
  operationKind: "mutate",
231
- requiresExecutionEvidence: true
356
+ requiresExecutionEvidence: true,
357
+ rawDomain: "workspace"
232
358
  }),
233
359
  annotateTool({
234
- name: "seastudio-agent_enable",
235
- description: "\u5728\u5F53\u524D\u9879\u76EE\u4E2D\u542F\u7528\u6307\u5B9A Agent\u3002\u9700\u63D0\u4F9B Agent id\u3002",
360
+ name: "seastudio-file_read_binary",
361
+ description: "\u8BFB\u53D6\u4E8C\u8FDB\u5236\u6587\u4EF6\u5E76\u8FD4\u56DE base64 \u7F16\u7801\u5185\u5BB9\uFF0C\u9002\u7528\u4E8E xlsx/xls \u7B49\u4E8C\u8FDB\u5236\u6587\u4EF6\u7684\u8BFB\u53D6\u3002",
236
362
  inputSchema: {
237
363
  type: "object",
238
364
  properties: {
239
- agentId: { type: "string", description: "\u8981\u542F\u7528\u7684 Agent ID" }
365
+ rootId: { type: "string", enum: ["workspace"], description: "\u6839\u76EE\u5F55 ID" },
366
+ path: { type: "string", description: "\u6587\u4EF6\u8DEF\u5F84\uFF08\u76F8\u5BF9\u4E8E rootId\uFF09" }
240
367
  },
241
- required: ["agentId"]
368
+ required: ["rootId", "path"]
242
369
  }
243
370
  }, {
244
- operationKind: "mutate",
245
- requiresExecutionEvidence: true
371
+ operationKind: "read",
372
+ rawDomain: "filesystem"
246
373
  }),
247
374
  annotateTool({
248
- name: "seastudio-agent_disable",
249
- description: "\u5728\u5F53\u524D\u9879\u76EE\u4E2D\u7981\u7528\u6307\u5B9A Agent\u3002\u9700\u63D0\u4F9B Agent id\u3002",
375
+ name: "seastudio-file_copy",
376
+ description: "\u590D\u5236\u6587\u4EF6\u8DEF\u5F84\u5230\u526A\u8D34\u677F\uFF08\u7528\u4E8E\u540E\u7EED\u7C98\u8D34\uFF09",
250
377
  inputSchema: {
251
378
  type: "object",
252
379
  properties: {
253
- agentId: { type: "string", description: "\u8981\u7981\u7528\u7684 Agent ID" }
380
+ rootId: { type: "string", enum: ["workspace"], description: "\u6839\u76EE\u5F55 ID" },
381
+ path: { type: "string", description: "\u6587\u4EF6\u8DEF\u5F84\uFF08\u76F8\u5BF9\u4E8E rootId\uFF09" }
254
382
  },
255
- required: ["agentId"]
383
+ required: ["rootId", "path"]
256
384
  }
257
385
  }, {
258
- operationKind: "mutate",
259
- requiresExecutionEvidence: true
260
- }),
386
+ operationKind: "system",
387
+ requiresExecutionEvidence: true,
388
+ rawDomain: "workspace"
389
+ }, rootedPathEvidenceOutputSchema),
261
390
  annotateTool({
262
- name: "seastudio-agent_get_status",
263
- description: "\u83B7\u53D6\u6307\u5B9A Agent \u7684\u5B89\u88C5\u72B6\u6001\u3002\u8FD4\u56DE\u662F\u5426\u5DF2\u5B89\u88C5\u3001\u7248\u672C\u3001\u662F\u5426\u542F\u7528\u3001\u540E\u7AEF\u6A21\u5F0F\u7B49\u8BE6\u7EC6\u4FE1\u606F\u3002\u82E5\u672A\u5B89\u88C5\u5219\u68C0\u67E5 Registry \u4E2D\u662F\u5426\u5B58\u5728\u3002",
391
+ name: "seastudio-file_paste",
392
+ description: "\u4ECE\u526A\u8D34\u677F\u7C98\u8D34\u6587\u4EF6/\u6587\u4EF6\u5939",
264
393
  inputSchema: {
265
394
  type: "object",
266
395
  properties: {
267
- agentId: { type: "string", description: "\u8981\u67E5\u8BE2\u7684 Agent ID" }
396
+ rootId: { type: "string", enum: ["workspace"], description: "\u6839\u76EE\u5F55 ID" },
397
+ path: { type: "string", description: "\u76EE\u6807\u76EE\u5F55\u8DEF\u5F84\uFF08\u76F8\u5BF9\u4E8E rootId\uFF09" }
268
398
  },
269
- required: ["agentId"]
399
+ required: ["rootId", "path"]
270
400
  }
271
401
  }, {
272
- operationKind: "read",
273
- requiresExecutionEvidence: false
274
- })
275
- ];
276
- var agentTabTools = [
402
+ operationKind: "system",
403
+ requiresExecutionEvidence: true,
404
+ rawDomain: "workspace"
405
+ }, rootedPathEvidenceOutputSchema),
277
406
  annotateTool({
278
- name: "seastudio-agent_tab_list",
279
- description: "\u83B7\u53D6\u5F53\u524D\u6240\u6709\u6253\u5F00\u7684 Agent \u6807\u7B7E\u9875\u3002\u8FD4\u56DE\u6BCF\u4E2A\u6807\u7B7E\u7684 instanceId\u3001agentId\u3001name \u7B49\u3002",
407
+ name: "seastudio-file_clipboard_check",
408
+ description: "\u68C0\u67E5\u526A\u8D34\u677F\u662F\u5426\u6709\u6709\u6548\u7684\u6587\u4EF6\u8DEF\u5F84",
280
409
  inputSchema: {
281
410
  type: "object",
282
411
  properties: {}
283
412
  }
284
413
  }, {
285
414
  operationKind: "read",
286
- requiresExecutionEvidence: false
415
+ requiresExecutionEvidence: false,
416
+ rawDomain: "workspace"
287
417
  }),
288
418
  annotateTool({
289
- name: "seastudio-agent_tab_get_active",
290
- description: "\u83B7\u53D6\u5F53\u524D\u805A\u7126\uFF08\u6FC0\u6D3B\uFF09\u7684 Agent \u6807\u7B7E\u9875\u3002\u8FD4\u56DE\u8BE5\u6807\u7B7E\u7684 instanceId\u3001agentId\u3001name\u3002",
419
+ name: "seastudio-file_copy_path",
420
+ description: "\u590D\u5236\u6587\u4EF6\u8DEF\u5F84\u6587\u672C\u5230\u526A\u8D34\u677F",
291
421
  inputSchema: {
292
422
  type: "object",
293
- properties: {}
423
+ properties: {
424
+ rootId: { type: "string", enum: ["workspace"], description: "\u6839\u76EE\u5F55 ID" },
425
+ path: { type: "string", description: "\u6587\u4EF6\u8DEF\u5F84\uFF08\u76F8\u5BF9\u4E8E rootId\uFF09" }
426
+ },
427
+ required: ["rootId", "path"]
294
428
  }
295
429
  }, {
296
- operationKind: "read",
297
- requiresExecutionEvidence: false
298
- }),
430
+ operationKind: "system",
431
+ requiresExecutionEvidence: true,
432
+ rawDomain: "workspace"
433
+ }, rootedPathEvidenceOutputSchema),
299
434
  annotateTool({
300
- name: "seastudio-agent_tab_open",
301
- description: "\u4E3A\u6307\u5B9A Agent \u65B0\u5EFA\u4E00\u4E2A\u6807\u7B7E\u9875\u5E76\u6FC0\u6D3B\u3002\u9700\u63D0\u4F9B Agent id\u3002",
435
+ name: "seastudio-file_trash",
436
+ description: "\u5C06\u6587\u4EF6\u6216\u6587\u4EF6\u5939\u79FB\u52A8\u5230\u7CFB\u7EDF\u56DE\u6536\u7AD9\u3002\u4EC5\u5728\u7528\u6237\u660E\u786E\u8981\u6C42\u79FB\u9664\u76EE\u6807\u4F46\u4FDD\u7559\u53EF\u6062\u590D\u6027\u65F6\u4F7F\u7528\u3002",
302
437
  inputSchema: {
303
438
  type: "object",
304
439
  properties: {
305
- agentId: { type: "string", description: "\u8981\u6253\u5F00\u6807\u7B7E\u9875\u7684 Agent ID" }
440
+ rootId: { type: "string", enum: ["workspace"], description: "\u6839\u76EE\u5F55 ID" },
441
+ path: { type: "string", description: "\u6587\u4EF6\u8DEF\u5F84\uFF08\u76F8\u5BF9\u4E8E rootId\uFF09" }
306
442
  },
307
- required: ["agentId"]
443
+ required: ["rootId", "path"]
308
444
  }
309
445
  }, {
310
446
  operationKind: "mutate",
311
- requiresExecutionEvidence: true
312
- }),
447
+ requiresExecutionEvidence: true,
448
+ rawDomain: "workspace"
449
+ }, rootedPathEvidenceOutputSchema),
313
450
  annotateTool({
314
- name: "seastudio-agent_tab_switch",
315
- description: "\u5207\u6362\u5230\u6307\u5B9A\u7684 Agent \u6807\u7B7E\u9875\u3002\u9700\u63D0\u4F9B\u6807\u7B7E\u5B9E\u4F8B ID\uFF08instanceId\uFF09\u3002",
451
+ name: "seastudio-code_search",
452
+ description: "\u5728\u9879\u76EE\u4E2D\u6309\u6A21\u5F0F\u641C\u7D22\u4EE3\u7801\u6216\u6587\u672C\u5185\u5BB9\u3002\u9002\u7528\u4E8E\u5B9A\u4F4D\u5B9A\u4E49\u3001\u8C03\u7528\u70B9\u6216\u6587\u672C\u7247\u6BB5\uFF0C\u4E0D\u4F1A\u4FEE\u6539\u6587\u4EF6\u3002",
316
453
  inputSchema: {
317
454
  type: "object",
318
455
  properties: {
319
- instanceId: { type: "string", description: "\u8981\u5207\u6362\u5230\u7684\u6807\u7B7E\u5B9E\u4F8B ID" }
456
+ pattern: { type: "string", description: "\u641C\u7D22\u6A21\u5F0F\uFF08\u6B63\u5219\u8868\u8FBE\u5F0F\uFF09" },
457
+ path: { type: "string", description: "\u641C\u7D22\u8DEF\u5F84" },
458
+ glob: { type: "string", description: "\u6587\u4EF6 glob \u6A21\u5F0F" },
459
+ headLimit: { type: "number", description: "\u8FD4\u56DE\u7ED3\u679C\u6570\u91CF\u9650\u5236" }
320
460
  },
321
- required: ["instanceId"]
461
+ required: ["pattern"]
322
462
  }
323
463
  }, {
324
- operationKind: "mutate",
325
- requiresExecutionEvidence: true
464
+ operationKind: "read",
465
+ requiresExecutionEvidence: false,
466
+ rawDomain: "workspace"
326
467
  }),
327
468
  annotateTool({
328
- name: "seastudio-agent_tab_close",
329
- description: "\u5173\u95ED\u6307\u5B9A\u7684 Agent \u6807\u7B7E\u9875\u3002\u9700\u63D0\u4F9B\u6807\u7B7E\u5B9E\u4F8B ID\uFF08instanceId\uFF09\u3002",
469
+ name: "seastudio-file_batch_flatten_preview",
470
+ description: "\u9884\u89C8\u6587\u4EF6\u5939\u5185\u6240\u6709\u6587\u4EF6\uFF08\u7528\u4E8E\u6279\u91CF\u5E73\u94FA\u590D\u5236\uFF09\u3002\u8DEF\u5F84\u7EDF\u4E00\u4F7F\u7528 rootId + path\u3002",
330
471
  inputSchema: {
331
472
  type: "object",
332
473
  properties: {
333
- instanceId: { type: "string", description: "\u8981\u5173\u95ED\u7684\u6807\u7B7E\u5B9E\u4F8B ID" }
474
+ sourceRootId: { type: "string", enum: ["workspace"], description: "\u6E90\u6839\u76EE\u5F55 ID" },
475
+ sourcePath: { type: "string", description: "\u6E90\u76EE\u5F55\u8DEF\u5F84\uFF08\u76F8\u5BF9\u4E8E sourceRootId\uFF09" }
334
476
  },
335
- required: ["instanceId"]
477
+ required: ["sourceRootId", "sourcePath"]
336
478
  }
337
479
  }, {
338
- operationKind: "mutate",
339
- requiresExecutionEvidence: true
480
+ operationKind: "read",
481
+ requiresExecutionEvidence: false,
482
+ rawDomain: "workspace"
340
483
  }),
341
484
  annotateTool({
342
- name: "seastudio-agent_tab_get_status",
343
- description: "\u83B7\u53D6\u6307\u5B9A Agent \u7684\u6807\u7B7E\u72B6\u6001\u3002\u8FD4\u56DE\u8BE5 Agent \u6253\u5F00\u4E86\u51E0\u4E2A\u6807\u7B7E\u3001\u5404\u6807\u7B7E\u7684 instanceId/name\u3001\u54EA\u4E2A\u662F\u5F53\u524D\u805A\u7126\u6001\u3002",
485
+ name: "seastudio-file_batch_flatten_copy",
486
+ description: "\u6279\u91CF\u5E73\u94FA\u590D\u5236\u6587\u4EF6\u5939\u5185\u6240\u6709\u6587\u4EF6\u5230\u76EE\u6807\u76EE\u5F55\u3002\u8DEF\u5F84\u7EDF\u4E00\u4F7F\u7528 rootId + path\u3002",
344
487
  inputSchema: {
345
488
  type: "object",
346
489
  properties: {
347
- agentId: { type: "string", description: "\u8981\u67E5\u8BE2\u6807\u7B7E\u72B6\u6001\u7684 Agent ID" }
490
+ sourceRootId: { type: "string", enum: ["workspace"], description: "\u6E90\u6839\u76EE\u5F55 ID" },
491
+ sourcePath: { type: "string", description: "\u6E90\u76EE\u5F55\u8DEF\u5F84\uFF08\u76F8\u5BF9\u4E8E sourceRootId\uFF09" },
492
+ destRootId: { type: "string", enum: ["workspace"], description: "\u76EE\u6807\u6839\u76EE\u5F55 ID" },
493
+ destPath: { type: "string", description: "\u76EE\u6807\u76EE\u5F55\u8DEF\u5F84\uFF08\u76F8\u5BF9\u4E8E destRootId\uFF09" },
494
+ taskId: { type: "string", description: "\u4EFB\u52A1 ID\uFF08\u7528\u4E8E\u8FDB\u5EA6\u901A\u77E5\uFF09" }
348
495
  },
349
- required: ["agentId"]
496
+ required: ["sourceRootId", "sourcePath", "destRootId", "destPath"]
350
497
  }
351
498
  }, {
352
- operationKind: "read",
353
- requiresExecutionEvidence: false
354
- })
499
+ operationKind: "mutate",
500
+ requiresExecutionEvidence: true,
501
+ rawDomain: "workspace"
502
+ }, batchFlattenCopyEvidenceOutputSchema)
355
503
  ];
356
504
 
357
- // src/mcp/seastudio/tools.ts
358
- function annotateTool(tool, annotations, outputSchema) {
359
- return {
360
- ...tool,
361
- annotations,
362
- ...outputSchema ? { outputSchema } : {}
363
- };
364
- }
365
- var rootedPathEvidenceOutputSchema = {
366
- type: "object",
367
- properties: {
368
- rootId: { type: "string" },
369
- path: { type: "string" }
370
- },
371
- required: ["rootId", "path"]
372
- };
373
- var rootedWriteEvidenceOutputSchema = {
374
- type: "object",
375
- properties: {
376
- rootId: { type: "string" },
377
- path: { type: "string" },
378
- written: { type: "boolean" }
379
- },
380
- required: ["rootId", "path", "written"]
381
- };
382
- var dualPathEvidenceOutputSchema = {
383
- type: "object",
384
- properties: {
385
- sourceRootId: { type: "string" },
386
- sourcePath: { type: "string" },
387
- destRootId: { type: "string" },
388
- destPath: { type: "string" }
389
- },
390
- required: ["sourceRootId", "sourcePath", "destRootId", "destPath"]
391
- };
392
- var batchFlattenCopyEvidenceOutputSchema = {
393
- type: "object",
394
- properties: {
395
- sourceRootId: { type: "string" },
396
- sourcePath: { type: "string" },
397
- destRootId: { type: "string" },
398
- destPath: { type: "string" },
399
- copiedCount: { type: "number" },
400
- totalCount: { type: "number" },
401
- errors: { type: "array", items: { type: "object", additionalProperties: true } }
402
- },
403
- required: ["sourceRootId", "sourcePath", "destRootId", "destPath", "copiedCount", "totalCount", "errors"]
404
- };
405
- var fileDownloadEvidenceOutputSchema = {
406
- type: "object",
407
- properties: {
408
- rootId: { type: "string" },
409
- path: { type: "string" },
410
- savedPath: { type: "string" },
411
- size: { type: "number" }
412
- },
413
- required: ["rootId", "path", "savedPath", "size"]
414
- };
415
- var shellCommandEvidenceOutputSchema = {
416
- type: "object",
417
- properties: {
418
- command: { type: "string" },
419
- cwd: { type: "string" },
420
- exitCode: { type: "number" },
421
- stdout: { type: "string" },
422
- stderr: { type: "string" },
423
- error: { type: "string" },
424
- durationMs: { type: "number" },
425
- usedFallback: { type: "boolean" }
426
- },
427
- required: ["command", "exitCode", "stdout", "stderr"]
428
- };
429
- var shellSessionSnapshotEvidenceOutputSchema = {
430
- type: "object",
431
- properties: {
432
- projectPath: { type: "string" },
433
- cwd: { type: "string" },
434
- promptLabel: { type: "string" },
435
- isRunning: { type: "boolean" },
436
- lastExitCode: { type: "number" },
437
- lastDurationMs: { type: "number" },
438
- lastCommandAt: { type: "number" },
439
- historyCount: { type: "number" },
440
- entryCount: { type: "number" }
441
- },
442
- required: ["projectPath", "cwd", "promptLabel", "isRunning", "historyCount", "entryCount"]
443
- };
444
- var fileTools = [
445
- annotateTool({
446
- name: "seastudio-file_get_selected",
447
- description: "\u83B7\u53D6\u5F53\u524D\u6587\u4EF6\u89C6\u56FE\u9009\u4E2D\u7684\u6587\u4EF6\u6216\u76EE\u5F55\u3002\u9002\u7528\u4E8E\u7EED\u63A5\u201C\u5F53\u524D\u9009\u4E2D\u9879\u201D\u7684\u4E0A\u4E0B\u6587\u3002",
448
- inputSchema: {
449
- type: "object",
450
- properties: {}
451
- }
452
- }, {
453
- operationKind: "read",
454
- requiresExecutionEvidence: false,
455
- rawDomain: "filesystem"
456
- }),
457
- annotateTool({
458
- name: "seastudio-file_read",
459
- description: "\u8BFB\u53D6\u6307\u5B9A\u6587\u4EF6\u5185\u5BB9\u3002\u9002\u7528\u4E8E\u67E5\u770B\u3001\u5F15\u7528\u6216\u5206\u6790\u5DF2\u77E5\u8DEF\u5F84\u7684\u6587\u4EF6\uFF0C\u4E0D\u4F1A\u4FEE\u6539\u9879\u76EE\u3002",
460
- inputSchema: {
461
- type: "object",
462
- properties: {
463
- rootId: { type: "string", enum: ["workspace"], description: "\u6839\u76EE\u5F55 ID" },
464
- path: { type: "string", description: "\u6587\u4EF6\u8DEF\u5F84\uFF08\u76F8\u5BF9\u4E8E rootId\uFF09" },
465
- offset: { type: "number", description: "\u8D77\u59CB\u884C\u504F\u79FB\uFF08\u53EF\u9009\uFF09" },
466
- limit: { type: "number", description: "\u8BFB\u53D6\u884C\u6570\u9650\u5236\uFF08\u53EF\u9009\uFF09" }
467
- },
468
- required: ["rootId", "path"]
469
- }
470
- }, {
471
- operationKind: "read",
472
- requiresExecutionEvidence: false,
473
- rawDomain: "filesystem"
474
- }),
505
+ // src/mcp/seastudio/tools-shell.ts
506
+ var shellTools = [
475
507
  annotateTool({
476
- name: "seastudio-file_write",
477
- description: "\u5C06\u6587\u672C\u5185\u5BB9\u5199\u5165\u6307\u5B9A\u8DEF\u5F84\u3002\u4EC5\u5728\u9700\u8981\u771F\u5B9E\u521B\u5EFA\u6216\u4FEE\u6539\u6587\u4EF6\u65F6\u4F7F\u7528\uFF0C\u6210\u529F\u540E\u6587\u4EF6\u5185\u5BB9\u4F1A\u843D\u76D8\u3002",
508
+ name: "seastudio-shell_execute",
509
+ description: "\u5728\u9879\u76EE\u76EE\u5F55\u4E0B\u6267\u884C Shell \u547D\u4EE4\u3002\u4EC5\u5728\u786E\u5B9E\u9700\u8981\u547D\u4EE4\u884C\u80FD\u529B\u65F6\u4F7F\u7528\uFF0C\u526F\u4F5C\u7528\u53D6\u51B3\u4E8E\u547D\u4EE4\u672C\u8EAB\u3002",
478
510
  inputSchema: {
479
511
  type: "object",
480
512
  properties: {
481
- rootId: { type: "string", enum: ["workspace"], description: "\u6839\u76EE\u5F55 ID" },
482
- path: { type: "string", description: "\u6587\u4EF6\u8DEF\u5F84\uFF08\u76F8\u5BF9\u4E8E rootId\uFF09" },
483
- content: { type: "string", description: "\u6587\u4EF6\u5185\u5BB9" }
513
+ command: { type: "string", description: "\u8981\u6267\u884C\u7684\u547D\u4EE4" },
514
+ cwd: { type: "string", description: "\u5DE5\u4F5C\u76EE\u5F55\uFF08\u53EF\u9009\uFF0C\u9ED8\u8BA4\u4E3A\u9879\u76EE\u6839\u76EE\u5F55\uFF09" },
515
+ timeout: { type: "number", description: "\u8D85\u65F6\u65F6\u95F4\uFF08\u6BEB\u79D2\uFF0C\u53EF\u9009\uFF09" }
484
516
  },
485
- required: ["rootId", "path", "content"]
517
+ required: ["command"]
486
518
  }
487
519
  }, {
488
- operationKind: "mutate",
520
+ operationKind: "system",
489
521
  requiresExecutionEvidence: true,
490
- rawDomain: "workspace"
491
- }, rootedWriteEvidenceOutputSchema),
522
+ rawDomain: "shell"
523
+ }, shellCommandEvidenceOutputSchema),
492
524
  annotateTool({
493
- name: "seastudio-file_list",
494
- description: "\u5217\u51FA\u6307\u5B9A\u76EE\u5F55\u4E0B\u7684\u6587\u4EF6\u548C\u5B50\u76EE\u5F55\u3002\u9002\u7528\u4E8E\u5728\u6267\u884C\u8BFB\u5199\u524D\u786E\u8BA4\u76EE\u5F55\u7ED3\u6784\u6216\u5B9A\u4F4D\u76EE\u6807\u8DEF\u5F84\u3002",
525
+ name: "seastudio-shell_session_get",
526
+ description: "\u83B7\u53D6\u5F53\u524D Shell \u4F1A\u8BDD\u5FEB\u7167\uFF0C\u5305\u62EC cwd\u3001\u8FD0\u884C\u72B6\u6001\u3001\u6700\u8FD1\u4E00\u6B21\u6267\u884C\u4FE1\u606F\u548C prompt \u6807\u7B7E\u3002",
495
527
  inputSchema: {
496
528
  type: "object",
497
- properties: {
498
- rootId: { type: "string", enum: ["workspace"], description: "\u6839\u76EE\u5F55 ID" },
499
- path: { type: "string", description: "\u76EE\u5F55\u8DEF\u5F84\uFF08\u76F8\u5BF9\u4E8E rootId\uFF09" }
500
- },
501
- required: ["rootId", "path"]
529
+ properties: {}
502
530
  }
503
531
  }, {
504
532
  operationKind: "read",
505
533
  requiresExecutionEvidence: false,
506
- rawDomain: "filesystem"
507
- }),
508
- annotateTool({
509
- name: "seastudio-file_delete",
510
- description: "\u5220\u9664\u6307\u5B9A\u8DEF\u5F84\u7684\u6587\u4EF6\u6216\u76EE\u5F55\u3002\u4EC5\u5728\u7528\u6237\u660E\u786E\u8981\u6C42\u79FB\u9664\u76EE\u6807\u65F6\u4F7F\u7528\uFF0C\u6210\u529F\u540E\u76EE\u6807\u4F1A\u4ECE\u9879\u76EE\u4E2D\u6D88\u5931\u3002",
511
- inputSchema: {
512
- type: "object",
513
- properties: {
514
- rootId: { type: "string", enum: ["workspace"], description: "\u6839\u76EE\u5F55 ID" },
515
- path: { type: "string", description: "\u8981\u5220\u9664\u7684\u8DEF\u5F84\uFF08\u76F8\u5BF9\u4E8E rootId\uFF09" }
516
- },
517
- required: ["rootId", "path"]
518
- }
519
- }, {
520
- operationKind: "mutate",
521
- requiresExecutionEvidence: true,
522
- rawDomain: "workspace"
523
- }, rootedPathEvidenceOutputSchema),
524
- annotateTool({
525
- name: "seastudio-file_mkdir",
526
- description: "\u521B\u5EFA\u76EE\u5F55\uFF08\u652F\u6301\u9012\u5F52\u521B\u5EFA\uFF09\u3002\u9002\u7528\u4E8E\u4E3A\u65B0\u6587\u4EF6\u6216\u5BFC\u51FA\u7ED3\u679C\u51C6\u5907\u76EE\u6807\u76EE\u5F55\u3002",
527
- inputSchema: {
528
- type: "object",
529
- properties: {
530
- rootId: { type: "string", enum: ["workspace"], description: "\u6839\u76EE\u5F55 ID" },
531
- path: { type: "string", description: "\u76EE\u5F55\u8DEF\u5F84\uFF08\u76F8\u5BF9\u4E8E rootId\uFF09" }
532
- },
533
- required: ["rootId", "path"]
534
- }
534
+ rawDomain: "shell"
535
535
  }, {
536
- operationKind: "mutate",
537
- requiresExecutionEvidence: true,
538
- rawDomain: "workspace"
539
- }, rootedPathEvidenceOutputSchema),
540
- annotateTool({
541
- name: "seastudio-file_exists",
542
- description: "\u68C0\u67E5\u6587\u4EF6\u6216\u76EE\u5F55\u662F\u5426\u5B58\u5728\u3002\u9002\u7528\u4E8E\u5728\u6267\u884C\u5199\u5165\u3001\u5220\u9664\u3001\u91CD\u547D\u540D\u524D\u505A\u524D\u7F6E\u5224\u65AD\u3002",
543
- inputSchema: {
544
- type: "object",
545
- properties: {
546
- rootId: { type: "string", enum: ["workspace"], description: "\u6839\u76EE\u5F55 ID" },
547
- path: { type: "string", description: "\u8981\u68C0\u67E5\u7684\u8DEF\u5F84\uFF08\u76F8\u5BF9\u4E8E rootId\uFF09" }
548
- },
549
- required: ["rootId", "path"]
536
+ type: "object",
537
+ properties: {
538
+ projectPath: { type: "string" },
539
+ cwd: { type: "string" },
540
+ promptLabel: { type: "string" },
541
+ isRunning: { type: "boolean" },
542
+ lastExitCode: { type: "number" },
543
+ lastDurationMs: { type: "number" },
544
+ lastCommandAt: { type: "number" },
545
+ historyCount: { type: "number" },
546
+ entryCount: { type: "number" }
550
547
  }
551
- }, {
552
- operationKind: "read",
553
- requiresExecutionEvidence: false,
554
- rawDomain: "workspace"
555
548
  }),
556
549
  annotateTool({
557
- name: "seastudio-file_stat",
558
- description: "\u83B7\u53D6\u6587\u4EF6\u6216\u76EE\u5F55\u7684\u72B6\u6001\u4FE1\u606F\uFF0C\u5982\u7C7B\u578B\u3001\u5927\u5C0F\u548C\u4FEE\u6539\u65F6\u95F4\uFF0C\u7528\u4E8E\u5224\u65AD\u76EE\u6807\u5BF9\u8C61\u7279\u5F81\u3002",
550
+ name: "seastudio-shell_session_get_entries",
551
+ description: "\u8BFB\u53D6\u5F53\u524D Shell \u4F1A\u8BDD\u8F93\u51FA\u6D41\uFF0C\u7528\u4E8E\u83B7\u53D6\u5386\u53F2\u547D\u4EE4\u3001stdout\u3001stderr \u4E0E meta \u4FE1\u606F\u3002",
559
552
  inputSchema: {
560
553
  type: "object",
561
554
  properties: {
562
- rootId: { type: "string", enum: ["workspace"], description: "\u6839\u76EE\u5F55 ID" },
563
- path: { type: "string", description: "\u6587\u4EF6\u8DEF\u5F84" }
564
- },
565
- required: ["rootId", "path"]
555
+ limit: { type: "number", description: "\u8FD4\u56DE\u6700\u8FD1\u591A\u5C11\u6761\u8BB0\u5F55\uFF0C\u9ED8\u8BA4 200\u3002" }
556
+ }
566
557
  }
567
558
  }, {
568
559
  operationKind: "read",
569
560
  requiresExecutionEvidence: false,
570
- rawDomain: "filesystem"
571
- }),
572
- annotateTool({
573
- name: "seastudio-file_info",
574
- description: "\u83B7\u53D6\u6587\u4EF6\u6216\u76EE\u5F55\u7684\u8BE6\u7EC6\u4FE1\u606F\uFF0C\u5982\u7C7B\u578B\u3001\u5927\u5C0F\u3001\u4FEE\u6539\u65F6\u95F4\u548C MIME\uFF0C\u7528\u4E8E\u5728\u8BFB\u53D6\u524D\u505A\u5224\u65AD\u3002",
575
- inputSchema: {
576
- type: "object",
577
- properties: {
578
- rootId: { type: "string", enum: ["workspace"], description: "\u6839\u76EE\u5F55 ID" },
579
- path: { type: "string", description: "\u6587\u4EF6\u6216\u76EE\u5F55\u8DEF\u5F84" }
580
- },
581
- required: ["rootId", "path"]
582
- }
561
+ rawDomain: "shell"
583
562
  }, {
584
- operationKind: "read",
585
- requiresExecutionEvidence: false,
586
- rawDomain: "filesystem"
563
+ type: "object",
564
+ properties: {
565
+ entries: {
566
+ type: "array",
567
+ items: {
568
+ type: "object",
569
+ properties: {
570
+ id: { type: "number" },
571
+ level: { type: "string" },
572
+ content: { type: "string" },
573
+ createdAt: { type: "number" }
574
+ }
575
+ }
576
+ }
577
+ }
587
578
  }),
588
579
  annotateTool({
589
- name: "seastudio-file_search",
590
- description: "\u5728\u6307\u5B9A root \u4E2D\u6309 query \u641C\u7D22\u6587\u4EF6\u5185\u5BB9\uFF0C\u53EF\u9009\u9650\u5B9A\u5B50\u8DEF\u5F84\u548C glob\u3002",
580
+ name: "seastudio-shell_session_run_command",
581
+ description: "\u5728\u5F53\u524D Shell \u4F1A\u8BDD\u4E0A\u4E0B\u6587\u4E2D\u6267\u884C\u547D\u4EE4\uFF0C\u4F1A\u66F4\u65B0\u4F1A\u8BDD cwd\u3001\u5386\u53F2\u4E0E\u8F93\u51FA\u6D41\u3002",
591
582
  inputSchema: {
592
583
  type: "object",
593
584
  properties: {
594
- rootId: { type: "string", enum: ["workspace"], description: "\u6839\u76EE\u5F55 ID" },
595
- query: { type: "string", description: "\u641C\u7D22\u5185\u5BB9\u6216\u6A21\u5F0F" },
596
- path: { type: "string", description: "\u76F8\u5BF9 root \u7684\u641C\u7D22\u5B50\u8DEF\u5F84\uFF08\u53EF\u9009\uFF09" },
597
- glob: { type: "string", description: "\u6587\u4EF6 glob \u6A21\u5F0F\uFF08\u53EF\u9009\uFF09" },
598
- headLimit: { type: "number", description: "\u8FD4\u56DE\u7ED3\u679C\u6570\u91CF\u9650\u5236\uFF08\u53EF\u9009\uFF09" }
585
+ command: { type: "string", description: "\u8981\u6267\u884C\u7684\u547D\u4EE4" },
586
+ cwd: { type: "string", description: "\u53EF\u9009\uFF0C\u8986\u76D6\u5F53\u524D\u4F1A\u8BDD\u5DE5\u4F5C\u76EE\u5F55" },
587
+ timeout: { type: "number", description: "\u53EF\u9009\uFF0C\u8D85\u65F6\u65F6\u95F4\uFF08\u6BEB\u79D2\uFF09" }
599
588
  },
600
- required: ["rootId", "query"]
589
+ required: ["command"]
601
590
  }
602
591
  }, {
603
- operationKind: "read",
604
- requiresExecutionEvidence: false,
605
- rawDomain: "filesystem"
606
- }),
592
+ operationKind: "system",
593
+ requiresExecutionEvidence: true,
594
+ rawDomain: "shell"
595
+ }, shellCommandEvidenceOutputSchema),
607
596
  annotateTool({
608
- name: "seastudio-file_rename",
609
- description: "\u91CD\u547D\u540D\u6587\u4EF6\u6216\u76EE\u5F55\u3002\u4EC5\u5728\u7528\u6237\u660E\u786E\u8981\u6C42\u6539\u540D\u65F6\u4F7F\u7528\uFF0C\u6210\u529F\u540E\u539F\u8DEF\u5F84\u4F1A\u53D8\u66F4\u4E3A\u65B0\u540D\u79F0\u3002",
597
+ name: "seastudio-shell_session_set_cwd",
598
+ description: "\u76F4\u63A5\u8BBE\u7F6E\u5F53\u524D Shell \u4F1A\u8BDD\u5DE5\u4F5C\u76EE\u5F55\uFF0C\u4E0D\u6267\u884C\u547D\u4EE4\u3002",
610
599
  inputSchema: {
611
600
  type: "object",
612
601
  properties: {
613
- rootId: { type: "string", enum: ["workspace"], description: "\u6839\u76EE\u5F55 ID" },
614
- path: { type: "string", description: "\u539F\u8DEF\u5F84\uFF08\u76F8\u5BF9\u4E8E rootId\uFF09" },
615
- newName: { type: "string", description: "\u65B0\u540D\u79F0" }
602
+ cwd: { type: "string", description: "\u76EE\u6807\u5DE5\u4F5C\u76EE\u5F55" }
616
603
  },
617
- required: ["rootId", "path", "newName"]
604
+ required: ["cwd"]
618
605
  }
619
606
  }, {
620
607
  operationKind: "mutate",
621
608
  requiresExecutionEvidence: true,
622
- rawDomain: "workspace"
623
- }, rootedPathEvidenceOutputSchema),
609
+ rawDomain: "shell"
610
+ }, shellSessionSnapshotEvidenceOutputSchema),
624
611
  annotateTool({
625
- name: "seastudio-file_move",
626
- description: "\u5C06\u6E90\u8DEF\u5F84\u79FB\u52A8\u5230\u76EE\u6807\u8DEF\u5F84\u3002\u8DEF\u5F84\u7EDF\u4E00\u4F7F\u7528 rootId + path\u3002",
612
+ name: "seastudio-shell_session_clear",
613
+ description: "\u6E05\u7A7A\u5F53\u524D Shell \u4F1A\u8BDD\u8F93\u51FA\u6D41\uFF0C\u4FDD\u7559\u4F1A\u8BDD\u4E0A\u4E0B\u6587\u4E0E\u547D\u4EE4\u5386\u53F2\u3002",
627
614
  inputSchema: {
628
615
  type: "object",
629
- properties: {
630
- sourceRootId: { type: "string", enum: ["workspace"], description: "\u6E90\u6839\u76EE\u5F55 ID" },
631
- sourcePath: { type: "string", description: "\u6E90\u8DEF\u5F84\uFF08\u76F8\u5BF9\u4E8E sourceRootId\uFF09" },
632
- destRootId: { type: "string", enum: ["workspace"], description: "\u76EE\u6807\u6839\u76EE\u5F55 ID" },
633
- destPath: { type: "string", description: "\u76EE\u6807\u8DEF\u5F84\uFF08\u76F8\u5BF9\u4E8E destRootId\uFF09" }
634
- },
635
- required: ["sourceRootId", "sourcePath", "destRootId", "destPath"]
616
+ properties: {}
636
617
  }
637
618
  }, {
638
619
  operationKind: "mutate",
639
620
  requiresExecutionEvidence: true,
640
- rawDomain: "workspace"
641
- }, dualPathEvidenceOutputSchema),
621
+ rawDomain: "shell"
622
+ }, shellSessionSnapshotEvidenceOutputSchema),
642
623
  annotateTool({
643
- name: "seastudio-file_copy_to",
644
- description: "\u5C06\u6E90\u8DEF\u5F84\u590D\u5236\u5230\u76EE\u6807\u8DEF\u5F84\u3002\u8DEF\u5F84\u7EDF\u4E00\u4F7F\u7528 rootId + path\u3002",
624
+ name: "seastudio-shell_session_reset",
625
+ description: "\u91CD\u7F6E\u5F53\u524D Shell \u4F1A\u8BDD\uFF0Ccwd \u56DE\u5230\u9879\u76EE\u76EE\u5F55\u5E76\u6E05\u7A7A\u8F93\u51FA\u3001\u5386\u53F2\u4E0E\u6700\u8FD1\u6267\u884C\u72B6\u6001\u3002",
645
626
  inputSchema: {
646
627
  type: "object",
647
- properties: {
648
- sourceRootId: { type: "string", enum: ["workspace"], description: "\u6E90\u6839\u76EE\u5F55 ID" },
649
- sourcePath: { type: "string", description: "\u6E90\u8DEF\u5F84\uFF08\u76F8\u5BF9\u4E8E sourceRootId\uFF09" },
650
- destRootId: { type: "string", enum: ["workspace"], description: "\u76EE\u6807\u6839\u76EE\u5F55 ID" },
651
- destPath: { type: "string", description: "\u76EE\u6807\u8DEF\u5F84\uFF08\u76F8\u5BF9\u4E8E destRootId\uFF09" }
652
- },
653
- required: ["sourceRootId", "sourcePath", "destRootId", "destPath"]
628
+ properties: {}
654
629
  }
655
630
  }, {
656
631
  operationKind: "mutate",
657
632
  requiresExecutionEvidence: true,
658
- rawDomain: "workspace"
659
- }, dualPathEvidenceOutputSchema),
633
+ rawDomain: "shell"
634
+ }, shellSessionSnapshotEvidenceOutputSchema)
635
+ ];
636
+
637
+ // src/mcp/seastudio/tools-aigc.ts
638
+ var seaCloudTools = [
660
639
  annotateTool({
661
- name: "seastudio-file_get_url",
662
- description: "\u83B7\u53D6\u6307\u5B9A\u6839\u76EE\u5F55\u4E2D\u6587\u4EF6\u7684\u53EF\u8BBF\u95EE URL\uFF0C\u9002\u7528\u4E8E\u4E8C\u8FDB\u5236\u6587\u4EF6\u7684\u6D4F\u89C8\u5668\u7AEF\u8BFB\u53D6\u3002",
640
+ name: "seastudio-seacloud_list_models",
641
+ description: "\u5217\u51FA SeaCloud \u63A8\u7406\u7F51\u5173\u53EF\u7528\u7684\u591A\u6A21\u6001\u751F\u6210\u6A21\u578B\u53CA\u5176\u53C2\u6570 schema\u3002\u53EF\u6309 tag \u8FC7\u6EE4\uFF08\u5982 vidu\u3001tencent\u3001musicfy \u7B49\uFF09\u3002\u8FD4\u56DE\u6BCF\u4E2A\u6A21\u578B\u7684\u540D\u79F0\u3001\u6807\u7B7E\u548C\u53EF\u7528\u7684 body \u53C2\u6570\u5B9A\u4E49\u3002",
663
642
  inputSchema: {
664
643
  type: "object",
665
644
  properties: {
666
- rootId: { type: "string", enum: ["workspace"], description: "\u6839\u76EE\u5F55 ID" },
667
- path: { type: "string", description: "\u6587\u4EF6\u8DEF\u5F84\uFF08\u76F8\u5BF9\u4E8E rootId\uFF09" }
668
- },
669
- required: ["rootId", "path"]
645
+ tag: { type: "string", description: '\u6309\u6807\u7B7E\u8FC7\u6EE4\u6A21\u578B\uFF08\u53EF\u9009\uFF09\uFF0C\u5982 "vidu"\u3001"musicfy"\u3001"tencent" \u7B49' }
646
+ }
670
647
  }
671
648
  }, {
672
649
  operationKind: "read",
673
650
  requiresExecutionEvidence: false,
674
- rawDomain: "filesystem"
651
+ rawDomain: "asset"
675
652
  }),
676
653
  annotateTool({
677
- name: "seastudio-file_download",
678
- description: "\u4ECE\u8FDC\u7A0B URL \u4E0B\u8F7D\u6587\u4EF6\u5230\u6307\u5B9A\u6839\u76EE\u5F55\u548C\u8DEF\u5F84\u3002\u4EC5\u5728\u9700\u8981\u771F\u5B9E\u5F15\u5165\u8FDC\u7AEF\u8D44\u6E90\u65F6\u4F7F\u7528\u3002",
654
+ name: "seastudio-seacloud_create_task",
655
+ description: "\u901A\u8FC7 SeaCloud \u63A8\u7406\u7F51\u5173\u521B\u5EFA\u591A\u6A21\u6001\u751F\u6210\u4EFB\u52A1\u3002\u9700\u6307\u5B9A\u6A21\u578B\u540D\u79F0\u548C\u5BF9\u5E94\u53C2\u6570\uFF0C\u53C2\u6570\u683C\u5F0F\u53C2\u7167 list_models \u8FD4\u56DE\u7684 schema\u3002\u8FD4\u56DE task_id \u7528\u4E8E\u540E\u7EED\u67E5\u8BE2\u3002",
679
656
  inputSchema: {
680
657
  type: "object",
681
658
  properties: {
682
- rootId: { type: "string", enum: ["workspace"], description: "\u6839\u76EE\u5F55 ID" },
683
- path: { type: "string", description: "\u4FDD\u5B58\u76EE\u5F55\u8DEF\u5F84\uFF08\u76F8\u5BF9\u4E8E rootId\uFF09" },
684
- url: { type: "string", description: "\u8FDC\u7A0B\u6587\u4EF6 URL" },
685
- filenameHint: { type: "string", description: "\u6587\u4EF6\u540D\u63D0\u793A\uFF08\u53EF\u9009\uFF09" }
659
+ model: { type: "string", description: "\u6A21\u578B\u540D\u79F0\uFF08\u6765\u81EA list_models \u8FD4\u56DE\u7684 model \u5B57\u6BB5\uFF09" },
660
+ params: { type: "object", description: "\u6A21\u578B\u53C2\u6570\uFF08\u6765\u81EA list_models \u8FD4\u56DE\u7684\u53C2\u6570 schema\uFF09" },
661
+ dash_scope: { type: "boolean", description: "\u662F\u5426\u89E3\u9664\u533A\u57DF\u9650\u5236\uFF0C\u9ED8\u8BA4 true" },
662
+ moderation: { type: "boolean", description: "\u662F\u5426\u89E3\u9664\u529F\u80FD\u9650\u5236\uFF0C\u9ED8\u8BA4 false" }
686
663
  },
687
- required: ["rootId", "path", "url"]
664
+ required: ["model", "params"]
688
665
  }
689
666
  }, {
690
667
  operationKind: "mutate",
691
- requiresExecutionEvidence: true,
692
- rawDomain: "filesystem"
693
- }, fileDownloadEvidenceOutputSchema),
668
+ requiresExecutionEvidence: false,
669
+ rawDomain: "asset"
670
+ }),
694
671
  annotateTool({
695
- name: "seastudio-file_write_binary",
696
- description: "\u5C06 base64 \u7F16\u7801\u7684\u4E8C\u8FDB\u5236\u5185\u5BB9\u5199\u5165\u6307\u5B9A\u8DEF\u5F84\uFF0C\u9002\u7528\u4E8E xlsx/xls \u7B49\u4E8C\u8FDB\u5236\u6587\u4EF6\u7684\u4FDD\u5B58\u3002",
672
+ name: "seastudio-seacloud_query_task",
673
+ description: '\u67E5\u8BE2 SeaCloud \u751F\u6210\u4EFB\u52A1\u7684\u72B6\u6001\u548C\u7ED3\u679C\u3002status \u4E3A "completed" \u65F6 output \u4E2D\u5305\u542B\u751F\u6210\u7684\u8D44\u6E90 URL\uFF0C"in_progress" \u8868\u793A\u4ECD\u5728\u5904\u7406\uFF0C"failed" \u8868\u793A\u5931\u8D25\u3002',
697
674
  inputSchema: {
698
675
  type: "object",
699
676
  properties: {
700
- rootId: { type: "string", enum: ["workspace"], description: "\u6839\u76EE\u5F55 ID" },
701
- path: { type: "string", description: "\u6587\u4EF6\u8DEF\u5F84\uFF08\u76F8\u5BF9\u4E8E rootId\uFF09" },
702
- base64: { type: "string", description: "base64 \u7F16\u7801\u7684\u6587\u4EF6\u5185\u5BB9" }
677
+ task_id: { type: "string", description: "\u4EFB\u52A1 ID\uFF08\u7531 create_task \u8FD4\u56DE\uFF09" }
703
678
  },
704
- required: ["rootId", "path", "base64"]
679
+ required: ["task_id"]
705
680
  }
706
681
  }, {
707
- operationKind: "mutate",
708
- requiresExecutionEvidence: true,
709
- rawDomain: "workspace"
682
+ operationKind: "read",
683
+ requiresExecutionEvidence: false,
684
+ rawDomain: "asset"
685
+ })
686
+ ];
687
+
688
+ // src/mcp/seastudio/client.ts
689
+ async function callTool(name, args = {}) {
690
+ return chunk3I7UM66P_cjs.getDefaultClient().callTool(name, args);
691
+ }
692
+ async function request(method, params) {
693
+ return chunk3I7UM66P_cjs.getDefaultClient().request(method, params);
694
+ }
695
+ async function callToolText(name, args = {}) {
696
+ return chunk3I7UM66P_cjs.getDefaultClient().callToolText(name, args);
697
+ }
698
+ function usesAbsolutePathMode(mode) {
699
+ return mode === "absolute";
700
+ }
701
+ function getPathBasename(path) {
702
+ const trimmed = path.replace(/[\\/]+$/g, "");
703
+ if (!trimmed) return "";
704
+ const parts = trimmed.split(/[\\/]/).filter(Boolean);
705
+ return parts[parts.length - 1] ?? "";
706
+ }
707
+ function joinWorkspacePath(dir, name) {
708
+ const normalizedDir = dir.replace(/\\/g, "/").replace(/\/+$/g, "");
709
+ const normalizedName = name.replace(/^\/+/g, "");
710
+ return normalizedDir ? `${normalizedDir}/${normalizedName}` : normalizedName;
711
+ }
712
+ var seastudio = {
713
+ roots: {
714
+ list: () => request("roots/list")
715
+ },
716
+ file: {
717
+ getSelected: () => callTool("seastudio-file_get_selected", {}),
718
+ read: (path, options) => callTool("seastudio-file_read", {
719
+ rootId: options?.rootId ?? "workspace",
720
+ path,
721
+ ...typeof options?.offset === "number" ? { offset: options.offset } : {},
722
+ ...typeof options?.limit === "number" ? { limit: options.limit } : {}
723
+ }),
724
+ write: (path, content, options) => callTool("seastudio-file_write", { rootId: options?.rootId ?? "workspace", path, content }),
725
+ list: (path = "", options) => callTool("seastudio-file_list", {
726
+ rootId: options?.rootId ?? "workspace",
727
+ path
728
+ }),
729
+ delete: (path, options) => callTool("seastudio-file_delete", { rootId: options?.rootId ?? "workspace", path }),
730
+ mkdir: (path, options) => callTool("seastudio-file_mkdir", { rootId: options?.rootId ?? "workspace", path }),
731
+ exists: (path, options) => callTool("seastudio-file_exists", { rootId: options?.rootId ?? "workspace", path }),
732
+ stat: (path, options) => callTool("seastudio-file_stat", {
733
+ rootId: options?.rootId ?? "workspace",
734
+ path
735
+ }),
736
+ info: (path, options) => callTool("seastudio-file_info", {
737
+ rootId: options?.rootId ?? "workspace",
738
+ path
739
+ }),
740
+ search: (query, options) => callTool("seastudio-file_search", {
741
+ query,
742
+ rootId: options?.rootId ?? "workspace",
743
+ path: options?.path ?? "",
744
+ ...options?.glob ? { glob: options.glob } : {},
745
+ ...typeof options?.headLimit === "number" ? { headLimit: options.headLimit } : {}
746
+ }),
747
+ codeSearch: (pattern, path, glob, headLimit) => callTool("seastudio-code_search", { pattern, path, glob, headLimit }),
748
+ rename: (path, newName, options) => callTool("seastudio-file_rename", { rootId: options?.rootId ?? "workspace", path, newName }),
749
+ move: (sourcePath, destDir, options) => {
750
+ if (usesAbsolutePathMode(options?.sourcePathMode) || usesAbsolutePathMode(options?.destPathMode)) {
751
+ return callTool("seastudio-file_move", { sourcePath, destDir, ...options });
752
+ }
753
+ const srcRoot = options?.sourceRootId ?? "workspace";
754
+ const dstRoot = options?.destRootId ?? srcRoot;
755
+ return callTool("seastudio-file_move", {
756
+ sourceRootId: srcRoot,
757
+ sourcePath,
758
+ destRootId: dstRoot,
759
+ destPath: joinWorkspacePath(destDir, getPathBasename(sourcePath))
760
+ });
761
+ },
762
+ copyTo: (sourcePath, destDir, options) => {
763
+ if (usesAbsolutePathMode(options?.sourcePathMode) || usesAbsolutePathMode(options?.destPathMode)) {
764
+ return callTool("seastudio-file_copy_to", { sourcePath, destDir, ...options });
765
+ }
766
+ const srcRoot = options?.sourceRootId ?? "workspace";
767
+ const dstRoot = options?.destRootId ?? srcRoot;
768
+ return callTool("seastudio-file_copy_to", {
769
+ sourceRootId: srcRoot,
770
+ sourcePath,
771
+ destRootId: dstRoot,
772
+ destPath: joinWorkspacePath(destDir, getPathBasename(sourcePath))
773
+ });
774
+ },
775
+ copy: (path, options) => callTool("seastudio-file_copy", { rootId: options?.rootId ?? "workspace", path }),
776
+ paste: (path = "", options) => callTool("seastudio-file_paste", { rootId: options?.rootId ?? "workspace", path }),
777
+ clipboardCheck: () => callTool("seastudio-file_clipboard_check", {}),
778
+ copyPath: (path, options) => callTool("seastudio-file_copy_path", { rootId: options?.rootId ?? "workspace", path }),
779
+ trash: (path, options) => callTool("seastudio-file_trash", { rootId: options?.rootId ?? "workspace", path }),
780
+ batchFlattenPreview: (sourcePath, options) => {
781
+ if (usesAbsolutePathMode(options?.sourcePathMode)) {
782
+ return callTool("seastudio-file_batch_flatten_preview", { sourcePath, ...options });
783
+ }
784
+ return callTool("seastudio-file_batch_flatten_preview", {
785
+ sourceRootId: options?.sourceRootId ?? "workspace",
786
+ sourcePath
787
+ });
788
+ },
789
+ batchFlattenCopy: (sourcePath, destDir, taskId, options) => {
790
+ if (usesAbsolutePathMode(options?.sourcePathMode) || usesAbsolutePathMode(options?.destPathMode)) {
791
+ return callTool("seastudio-file_batch_flatten_copy", { sourcePath, destDir, taskId, ...options });
792
+ }
793
+ const srcRoot = options?.sourceRootId ?? "workspace";
794
+ const dstRoot = options?.destRootId ?? srcRoot;
795
+ return callTool("seastudio-file_batch_flatten_copy", {
796
+ sourceRootId: srcRoot,
797
+ sourcePath,
798
+ destRootId: dstRoot,
799
+ destPath: destDir,
800
+ ...typeof taskId === "string" ? { taskId } : {}
801
+ });
802
+ },
803
+ getUrl: (path, options) => callTool("seastudio-file_get_url", { rootId: options?.rootId ?? "workspace", path }),
804
+ download: (url, path, filenameHint, options) => callTool("seastudio-file_download", { rootId: options?.rootId ?? "workspace", path, url, filenameHint }),
805
+ writeBinary: (path, base64, options) => callTool("seastudio-file_write_binary", { rootId: options?.rootId ?? "workspace", path, base64 }),
806
+ readBinary: (path, options) => callTool("seastudio-file_read_binary", { rootId: options?.rootId ?? "workspace", path })
807
+ },
808
+ shell: {
809
+ execute: (command, cwd, timeout) => callTool("seastudio-shell_execute", { command, cwd, timeout }),
810
+ session: {
811
+ get: () => callTool("seastudio-shell_session_get", {}),
812
+ getEntries: (limit) => callTool("seastudio-shell_session_get_entries", { limit }),
813
+ runCommand: (command, cwd, timeout) => callTool("seastudio-shell_session_run_command", { command, cwd, timeout }),
814
+ setCwd: (cwd) => callTool("seastudio-shell_session_set_cwd", { cwd }),
815
+ clear: () => callTool("seastudio-shell_session_clear", {}),
816
+ reset: () => callTool("seastudio-shell_session_reset", {})
817
+ }
818
+ }
819
+ };
820
+
821
+ // src/mcp/seastudio/tools-plugin.ts
822
+ var pluginManagementTools = [
823
+ annotateTool({
824
+ name: "seastudio-plugin_list_official",
825
+ description: "\u5217\u51FA Registry \u4E2D\u6240\u6709\u5B98\u65B9\u63D2\u4EF6\u3002\u8FD4\u56DE\u6BCF\u4E2A\u63D2\u4EF6\u7684 id\u3001name\u3001version\u3001description \u7B49\u4FE1\u606F\u3002",
826
+ inputSchema: {
827
+ type: "object",
828
+ properties: {}
829
+ }
830
+ }, {
831
+ operationKind: "read",
832
+ requiresExecutionEvidence: false
710
833
  }),
711
834
  annotateTool({
712
- name: "seastudio-file_read_binary",
713
- description: "\u8BFB\u53D6\u4E8C\u8FDB\u5236\u6587\u4EF6\u5E76\u8FD4\u56DE base64 \u7F16\u7801\u5185\u5BB9\uFF0C\u9002\u7528\u4E8E xlsx/xls \u7B49\u4E8C\u8FDB\u5236\u6587\u4EF6\u7684\u8BFB\u53D6\u3002",
835
+ name: "seastudio-plugin_list_installed",
836
+ description: "\u5217\u51FA\u672C\u5730\u5DF2\u5B89\u88C5\u7684\u6240\u6709\u63D2\u4EF6\u3002\u8FD4\u56DE\u6BCF\u4E2A\u63D2\u4EF6\u7684 id\u3001name\u3001version\u3001enabled \u72B6\u6001\u7B49\u3002",
714
837
  inputSchema: {
715
838
  type: "object",
716
- properties: {
717
- rootId: { type: "string", enum: ["workspace"], description: "\u6839\u76EE\u5F55 ID" },
718
- path: { type: "string", description: "\u6587\u4EF6\u8DEF\u5F84\uFF08\u76F8\u5BF9\u4E8E rootId\uFF09" }
719
- },
720
- required: ["rootId", "path"]
839
+ properties: {}
721
840
  }
722
841
  }, {
723
842
  operationKind: "read",
724
- rawDomain: "filesystem"
725
- })
726
- ];
727
- var shellTools = [
843
+ requiresExecutionEvidence: false
844
+ }),
728
845
  annotateTool({
729
- name: "seastudio-shell_execute",
730
- description: "\u5728\u9879\u76EE\u76EE\u5F55\u4E0B\u6267\u884C Shell \u547D\u4EE4\u3002\u4EC5\u5728\u786E\u5B9E\u9700\u8981\u547D\u4EE4\u884C\u80FD\u529B\u65F6\u4F7F\u7528\uFF0C\u526F\u4F5C\u7528\u53D6\u51B3\u4E8E\u547D\u4EE4\u672C\u8EAB\u3002",
846
+ name: "seastudio-plugin_install",
847
+ description: "\u4ECE Registry \u5B89\u88C5\u6307\u5B9A\u63D2\u4EF6\u3002\u9700\u63D0\u4F9B\u63D2\u4EF6 id\uFF0C\u7CFB\u7EDF\u4F1A\u4ECE\u5B98\u65B9 Registry \u4E0B\u8F7D\u5E76\u5B89\u88C5\u3002",
731
848
  inputSchema: {
732
849
  type: "object",
733
850
  properties: {
734
- command: { type: "string", description: "\u8981\u6267\u884C\u7684\u547D\u4EE4" },
735
- cwd: { type: "string", description: "\u5DE5\u4F5C\u76EE\u5F55\uFF08\u53EF\u9009\uFF0C\u9ED8\u8BA4\u4E3A\u9879\u76EE\u6839\u76EE\u5F55\uFF09" },
736
- timeout: { type: "number", description: "\u8D85\u65F6\u65F6\u95F4\uFF08\u6BEB\u79D2\uFF0C\u53EF\u9009\uFF09" }
851
+ pluginId: { type: "string", description: "\u8981\u5B89\u88C5\u7684\u63D2\u4EF6 ID" }
737
852
  },
738
- required: ["command"]
853
+ required: ["pluginId"]
739
854
  }
740
855
  }, {
741
- operationKind: "system",
742
- requiresExecutionEvidence: true,
743
- rawDomain: "shell"
744
- }, shellCommandEvidenceOutputSchema),
856
+ operationKind: "mutate",
857
+ requiresExecutionEvidence: true
858
+ }),
745
859
  annotateTool({
746
- name: "seastudio-shell_session_get",
747
- description: "\u83B7\u53D6\u5F53\u524D Shell \u4F1A\u8BDD\u5FEB\u7167\uFF0C\u5305\u62EC cwd\u3001\u8FD0\u884C\u72B6\u6001\u3001\u6700\u8FD1\u4E00\u6B21\u6267\u884C\u4FE1\u606F\u548C prompt \u6807\u7B7E\u3002",
860
+ name: "seastudio-plugin_uninstall",
861
+ description: "\u5378\u8F7D\u6307\u5B9A\u63D2\u4EF6\u3002\u9700\u63D0\u4F9B\u63D2\u4EF6 id\u3002",
748
862
  inputSchema: {
749
863
  type: "object",
750
- properties: {}
864
+ properties: {
865
+ pluginId: { type: "string", description: "\u8981\u5378\u8F7D\u7684\u63D2\u4EF6 ID" }
866
+ },
867
+ required: ["pluginId"]
751
868
  }
752
869
  }, {
753
- operationKind: "read",
754
- requiresExecutionEvidence: false,
755
- rawDomain: "shell"
756
- }, {
757
- type: "object",
758
- properties: {
759
- projectPath: { type: "string" },
760
- cwd: { type: "string" },
761
- promptLabel: { type: "string" },
762
- isRunning: { type: "boolean" },
763
- lastExitCode: { type: "number" },
764
- lastDurationMs: { type: "number" },
765
- lastCommandAt: { type: "number" },
766
- historyCount: { type: "number" },
767
- entryCount: { type: "number" }
768
- }
870
+ operationKind: "mutate",
871
+ requiresExecutionEvidence: true
769
872
  }),
770
873
  annotateTool({
771
- name: "seastudio-shell_session_get_entries",
772
- description: "\u8BFB\u53D6\u5F53\u524D Shell \u4F1A\u8BDD\u8F93\u51FA\u6D41\uFF0C\u7528\u4E8E\u83B7\u53D6\u5386\u53F2\u547D\u4EE4\u3001stdout\u3001stderr \u4E0E meta \u4FE1\u606F\u3002",
874
+ name: "seastudio-plugin_enable",
875
+ description: "\u5728\u5F53\u524D\u9879\u76EE\u4E2D\u542F\u7528\u6307\u5B9A\u63D2\u4EF6\u3002\u9700\u63D0\u4F9B\u63D2\u4EF6 id\u3002",
773
876
  inputSchema: {
774
877
  type: "object",
775
878
  properties: {
776
- limit: { type: "number", description: "\u8FD4\u56DE\u6700\u8FD1\u591A\u5C11\u6761\u8BB0\u5F55\uFF0C\u9ED8\u8BA4 200\u3002" }
777
- }
879
+ pluginId: { type: "string", description: "\u8981\u542F\u7528\u7684\u63D2\u4EF6 ID" }
880
+ },
881
+ required: ["pluginId"]
778
882
  }
779
883
  }, {
780
- operationKind: "read",
781
- requiresExecutionEvidence: false,
782
- rawDomain: "shell"
783
- }, {
784
- type: "object",
785
- properties: {
786
- entries: {
787
- type: "array",
788
- items: {
789
- type: "object",
790
- properties: {
791
- id: { type: "number" },
792
- level: { type: "string" },
793
- content: { type: "string" },
794
- createdAt: { type: "number" }
795
- }
796
- }
797
- }
798
- }
884
+ operationKind: "mutate",
885
+ requiresExecutionEvidence: true
799
886
  }),
800
887
  annotateTool({
801
- name: "seastudio-shell_session_run_command",
802
- description: "\u5728\u5F53\u524D Shell \u4F1A\u8BDD\u4E0A\u4E0B\u6587\u4E2D\u6267\u884C\u547D\u4EE4\uFF0C\u4F1A\u66F4\u65B0\u4F1A\u8BDD cwd\u3001\u5386\u53F2\u4E0E\u8F93\u51FA\u6D41\u3002",
888
+ name: "seastudio-plugin_disable",
889
+ description: "\u5728\u5F53\u524D\u9879\u76EE\u4E2D\u7981\u7528\u6307\u5B9A\u63D2\u4EF6\u3002\u9700\u63D0\u4F9B\u63D2\u4EF6 id\u3002",
803
890
  inputSchema: {
804
891
  type: "object",
805
892
  properties: {
806
- command: { type: "string", description: "\u8981\u6267\u884C\u7684\u547D\u4EE4" },
807
- cwd: { type: "string", description: "\u53EF\u9009\uFF0C\u8986\u76D6\u5F53\u524D\u4F1A\u8BDD\u5DE5\u4F5C\u76EE\u5F55" },
808
- timeout: { type: "number", description: "\u53EF\u9009\uFF0C\u8D85\u65F6\u65F6\u95F4\uFF08\u6BEB\u79D2\uFF09" }
893
+ pluginId: { type: "string", description: "\u8981\u7981\u7528\u7684\u63D2\u4EF6 ID" }
809
894
  },
810
- required: ["command"]
895
+ required: ["pluginId"]
811
896
  }
812
897
  }, {
813
- operationKind: "system",
814
- requiresExecutionEvidence: true,
815
- rawDomain: "shell"
816
- }, shellCommandEvidenceOutputSchema),
898
+ operationKind: "mutate",
899
+ requiresExecutionEvidence: true
900
+ }),
817
901
  annotateTool({
818
- name: "seastudio-shell_session_set_cwd",
819
- description: "\u76F4\u63A5\u8BBE\u7F6E\u5F53\u524D Shell \u4F1A\u8BDD\u5DE5\u4F5C\u76EE\u5F55\uFF0C\u4E0D\u6267\u884C\u547D\u4EE4\u3002",
902
+ name: "seastudio-plugin_get_status",
903
+ description: "\u83B7\u53D6\u6307\u5B9A\u63D2\u4EF6\u7684\u5B89\u88C5\u72B6\u6001\u3002\u8FD4\u56DE\u662F\u5426\u5DF2\u5B89\u88C5\u3001\u7248\u672C\u3001\u662F\u5426\u542F\u7528\u3001UI \u7C7B\u578B\u7B49\u8BE6\u7EC6\u4FE1\u606F\u3002\u82E5\u672A\u5B89\u88C5\u5219\u68C0\u67E5 Registry \u4E2D\u662F\u5426\u5B58\u5728\u3002",
820
904
  inputSchema: {
821
905
  type: "object",
822
906
  properties: {
823
- cwd: { type: "string", description: "\u76EE\u6807\u5DE5\u4F5C\u76EE\u5F55" }
907
+ pluginId: { type: "string", description: "\u8981\u67E5\u8BE2\u7684\u63D2\u4EF6 ID" }
824
908
  },
825
- required: ["cwd"]
909
+ required: ["pluginId"]
826
910
  }
827
911
  }, {
828
- operationKind: "mutate",
829
- requiresExecutionEvidence: true,
830
- rawDomain: "shell"
831
- }, shellSessionSnapshotEvidenceOutputSchema),
912
+ operationKind: "read",
913
+ requiresExecutionEvidence: false
914
+ })
915
+ ];
916
+ var pluginTabTools = [
832
917
  annotateTool({
833
- name: "seastudio-shell_session_clear",
834
- description: "\u6E05\u7A7A\u5F53\u524D Shell \u4F1A\u8BDD\u8F93\u51FA\u6D41\uFF0C\u4FDD\u7559\u4F1A\u8BDD\u4E0A\u4E0B\u6587\u4E0E\u547D\u4EE4\u5386\u53F2\u3002",
918
+ name: "seastudio-plugin_tab_list",
919
+ description: "\u83B7\u53D6\u5F53\u524D\u6240\u6709\u6253\u5F00\u7684\u63D2\u4EF6\u6807\u7B7E\u9875\u3002\u8FD4\u56DE\u6BCF\u4E2A\u6807\u7B7E\u7684 instanceId\u3001pluginId\u3001title \u7B49\u3002",
835
920
  inputSchema: {
836
921
  type: "object",
837
922
  properties: {}
838
923
  }
839
924
  }, {
840
- operationKind: "mutate",
841
- requiresExecutionEvidence: true,
842
- rawDomain: "shell"
843
- }, shellSessionSnapshotEvidenceOutputSchema),
925
+ operationKind: "read",
926
+ requiresExecutionEvidence: false
927
+ }),
844
928
  annotateTool({
845
- name: "seastudio-shell_session_reset",
846
- description: "\u91CD\u7F6E\u5F53\u524D Shell \u4F1A\u8BDD\uFF0Ccwd \u56DE\u5230\u9879\u76EE\u76EE\u5F55\u5E76\u6E05\u7A7A\u8F93\u51FA\u3001\u5386\u53F2\u4E0E\u6700\u8FD1\u6267\u884C\u72B6\u6001\u3002",
929
+ name: "seastudio-plugin_tab_get_active",
930
+ description: "\u83B7\u53D6\u5F53\u524D\u805A\u7126\uFF08\u6FC0\u6D3B\uFF09\u7684\u63D2\u4EF6\u6807\u7B7E\u9875\u3002\u8FD4\u56DE\u8BE5\u6807\u7B7E\u7684 instanceId\u3001pluginId\u3001title\u3002",
847
931
  inputSchema: {
848
932
  type: "object",
849
933
  properties: {}
850
934
  }
851
935
  }, {
852
- operationKind: "mutate",
853
- requiresExecutionEvidence: true,
854
- rawDomain: "shell"
855
- }, shellSessionSnapshotEvidenceOutputSchema)
856
- ];
857
- var gitTools = [
936
+ operationKind: "read",
937
+ requiresExecutionEvidence: false
938
+ }),
858
939
  annotateTool({
859
- name: "seastudio-git_status",
860
- description: "\u83B7\u53D6\u5F53\u524D Git \u4ED3\u5E93\u72B6\u6001\uFF0C\u7528\u4E8E\u786E\u8BA4\u5DE5\u4F5C\u533A\u4FEE\u6539\u3001\u672A\u8DDF\u8E2A\u6587\u4EF6\u548C\u6682\u5B58\u72B6\u6001\u3002",
940
+ name: "seastudio-plugin_tab_open",
941
+ description: "\u4E3A\u6307\u5B9A\u63D2\u4EF6\u65B0\u5EFA\u4E00\u4E2A\u6807\u7B7E\u9875\u5E76\u6FC0\u6D3B\u3002\u9700\u63D0\u4F9B\u63D2\u4EF6 id\u3002",
861
942
  inputSchema: {
862
943
  type: "object",
863
- properties: {}
944
+ properties: {
945
+ pluginId: { type: "string", description: "\u8981\u6253\u5F00\u6807\u7B7E\u9875\u7684\u63D2\u4EF6 ID" }
946
+ },
947
+ required: ["pluginId"]
864
948
  }
865
949
  }, {
866
- operationKind: "read",
867
- requiresExecutionEvidence: false,
868
- rawDomain: "git"
950
+ operationKind: "mutate",
951
+ requiresExecutionEvidence: true
869
952
  }),
870
953
  annotateTool({
871
- name: "seastudio-git_diff",
872
- description: "\u83B7\u53D6 Git \u5DEE\u5F02\uFF0C\u7528\u4E8E\u67E5\u770B\u6307\u5B9A\u6587\u4EF6\u6216\u6682\u5B58\u533A\u7684\u6539\u52A8\u5185\u5BB9\uFF0C\u4E0D\u4F1A\u4FEE\u6539\u4ED3\u5E93\u3002",
954
+ name: "seastudio-plugin_tab_switch",
955
+ description: "\u5207\u6362\u5230\u6307\u5B9A\u7684\u63D2\u4EF6\u6807\u7B7E\u9875\u3002\u9700\u63D0\u4F9B\u6807\u7B7E\u5B9E\u4F8B ID\uFF08instanceId\uFF09\u3002",
873
956
  inputSchema: {
874
957
  type: "object",
875
958
  properties: {
876
- staged: { type: "boolean", description: "\u662F\u5426\u53EA\u663E\u793A\u6682\u5B58\u7684\u66F4\u6539" },
877
- path: { type: "string", description: "\u6307\u5B9A\u6587\u4EF6\u8DEF\u5F84\uFF08\u53EF\u9009\uFF09" }
878
- }
959
+ instanceId: { type: "string", description: "\u8981\u5207\u6362\u5230\u7684\u6807\u7B7E\u5B9E\u4F8B ID" }
960
+ },
961
+ required: ["instanceId"]
879
962
  }
880
963
  }, {
881
- operationKind: "read",
882
- requiresExecutionEvidence: false,
883
- rawDomain: "git"
884
- })
885
- ];
886
- var clipboardTools = [
964
+ operationKind: "mutate",
965
+ requiresExecutionEvidence: true
966
+ }),
887
967
  annotateTool({
888
- name: "seastudio-file_copy",
889
- description: "\u590D\u5236\u6587\u4EF6\u8DEF\u5F84\u5230\u526A\u8D34\u677F\uFF08\u7528\u4E8E\u540E\u7EED\u7C98\u8D34\uFF09",
968
+ name: "seastudio-plugin_tab_close",
969
+ description: "\u5173\u95ED\u6307\u5B9A\u7684\u63D2\u4EF6\u6807\u7B7E\u9875\u3002\u9700\u63D0\u4F9B\u6807\u7B7E\u5B9E\u4F8B ID\uFF08instanceId\uFF09\u3002",
890
970
  inputSchema: {
891
971
  type: "object",
892
972
  properties: {
893
- rootId: { type: "string", enum: ["workspace"], description: "\u6839\u76EE\u5F55 ID" },
894
- path: { type: "string", description: "\u6587\u4EF6\u8DEF\u5F84\uFF08\u76F8\u5BF9\u4E8E rootId\uFF09" }
973
+ instanceId: { type: "string", description: "\u8981\u5173\u95ED\u7684\u6807\u7B7E\u5B9E\u4F8B ID" }
895
974
  },
896
- required: ["rootId", "path"]
975
+ required: ["instanceId"]
897
976
  }
898
977
  }, {
899
- operationKind: "system",
900
- requiresExecutionEvidence: true,
901
- rawDomain: "workspace"
902
- }, rootedPathEvidenceOutputSchema),
978
+ operationKind: "mutate",
979
+ requiresExecutionEvidence: true
980
+ }),
903
981
  annotateTool({
904
- name: "seastudio-file_paste",
905
- description: "\u4ECE\u526A\u8D34\u677F\u7C98\u8D34\u6587\u4EF6/\u6587\u4EF6\u5939",
982
+ name: "seastudio-plugin_tab_get_status",
983
+ description: "\u83B7\u53D6\u6307\u5B9A\u63D2\u4EF6\u7684\u6807\u7B7E\u72B6\u6001\u3002\u8FD4\u56DE\u8BE5\u63D2\u4EF6\u6253\u5F00\u4E86\u51E0\u4E2A\u6807\u7B7E\u3001\u5404\u6807\u7B7E\u7684 instanceId/title\u3001\u54EA\u4E2A\u662F\u5F53\u524D\u805A\u7126\u6001\u3002",
906
984
  inputSchema: {
907
985
  type: "object",
908
986
  properties: {
909
- rootId: { type: "string", enum: ["workspace"], description: "\u6839\u76EE\u5F55 ID" },
910
- path: { type: "string", description: "\u76EE\u6807\u76EE\u5F55\u8DEF\u5F84\uFF08\u76F8\u5BF9\u4E8E rootId\uFF09" }
987
+ pluginId: { type: "string", description: "\u8981\u67E5\u8BE2\u6807\u7B7E\u72B6\u6001\u7684\u63D2\u4EF6 ID" }
911
988
  },
912
- required: ["rootId", "path"]
989
+ required: ["pluginId"]
913
990
  }
914
991
  }, {
915
- operationKind: "system",
916
- requiresExecutionEvidence: true,
917
- rawDomain: "workspace"
918
- }, rootedPathEvidenceOutputSchema),
992
+ operationKind: "read",
993
+ requiresExecutionEvidence: false
994
+ })
995
+ ];
996
+
997
+ // src/mcp/seastudio/tools-agent.ts
998
+ var agentManagementTools = [
919
999
  annotateTool({
920
- name: "seastudio-file_clipboard_check",
921
- description: "\u68C0\u67E5\u526A\u8D34\u677F\u662F\u5426\u6709\u6709\u6548\u7684\u6587\u4EF6\u8DEF\u5F84",
1000
+ name: "seastudio-agent_list_official",
1001
+ description: "\u5217\u51FA Registry \u4E2D\u6240\u6709\u5B98\u65B9 Agent\u3002\u8FD4\u56DE\u6BCF\u4E2A Agent \u7684 id\u3001name\u3001version\u3001description \u7B49\u4FE1\u606F\u3002",
922
1002
  inputSchema: {
923
1003
  type: "object",
924
1004
  properties: {}
925
1005
  }
926
1006
  }, {
927
1007
  operationKind: "read",
928
- requiresExecutionEvidence: false,
929
- rawDomain: "workspace"
1008
+ requiresExecutionEvidence: false
930
1009
  }),
931
1010
  annotateTool({
932
- name: "seastudio-file_copy_path",
933
- description: "\u590D\u5236\u6587\u4EF6\u8DEF\u5F84\u6587\u672C\u5230\u526A\u8D34\u677F",
1011
+ name: "seastudio-agent_list_installed",
1012
+ description: "\u5217\u51FA\u672C\u5730\u5DF2\u5B89\u88C5\u7684\u6240\u6709 Agent\u3002\u8FD4\u56DE\u6BCF\u4E2A Agent \u7684 id\u3001name\u3001version\u3001enabled \u72B6\u6001\u7B49\u3002",
934
1013
  inputSchema: {
935
1014
  type: "object",
936
- properties: {
937
- rootId: { type: "string", enum: ["workspace"], description: "\u6839\u76EE\u5F55 ID" },
938
- path: { type: "string", description: "\u6587\u4EF6\u8DEF\u5F84\uFF08\u76F8\u5BF9\u4E8E rootId\uFF09" }
939
- },
940
- required: ["rootId", "path"]
1015
+ properties: {}
941
1016
  }
942
1017
  }, {
943
- operationKind: "system",
944
- requiresExecutionEvidence: true,
945
- rawDomain: "workspace"
946
- }, rootedPathEvidenceOutputSchema),
1018
+ operationKind: "read",
1019
+ requiresExecutionEvidence: false
1020
+ }),
947
1021
  annotateTool({
948
- name: "seastudio-file_trash",
949
- description: "\u5C06\u6587\u4EF6\u6216\u6587\u4EF6\u5939\u79FB\u52A8\u5230\u7CFB\u7EDF\u56DE\u6536\u7AD9\u3002\u4EC5\u5728\u7528\u6237\u660E\u786E\u8981\u6C42\u79FB\u9664\u76EE\u6807\u4F46\u4FDD\u7559\u53EF\u6062\u590D\u6027\u65F6\u4F7F\u7528\u3002",
1022
+ name: "seastudio-agent_install",
1023
+ description: "\u4ECE Registry \u5B89\u88C5\u6307\u5B9A Agent\u3002\u9700\u63D0\u4F9B Agent id\uFF0C\u7CFB\u7EDF\u4F1A\u4ECE\u5B98\u65B9 Registry \u4E0B\u8F7D\u5E76\u5B89\u88C5\u3002",
950
1024
  inputSchema: {
951
1025
  type: "object",
952
1026
  properties: {
953
- rootId: { type: "string", enum: ["workspace"], description: "\u6839\u76EE\u5F55 ID" },
954
- path: { type: "string", description: "\u6587\u4EF6\u8DEF\u5F84\uFF08\u76F8\u5BF9\u4E8E rootId\uFF09" }
1027
+ agentId: { type: "string", description: "\u8981\u5B89\u88C5\u7684 Agent ID" }
955
1028
  },
956
- required: ["rootId", "path"]
1029
+ required: ["agentId"]
957
1030
  }
958
1031
  }, {
959
1032
  operationKind: "mutate",
960
- requiresExecutionEvidence: true,
961
- rawDomain: "workspace"
962
- }, rootedPathEvidenceOutputSchema)
963
- ];
964
- var codeQualityTools = [
1033
+ requiresExecutionEvidence: true
1034
+ }),
965
1035
  annotateTool({
966
- name: "seastudio-run_test",
967
- description: "\u8FD0\u884C\u9879\u76EE\u6D4B\u8BD5",
1036
+ name: "seastudio-agent_uninstall",
1037
+ description: "\u5378\u8F7D\u6307\u5B9A Agent\u3002\u9700\u63D0\u4F9B Agent id\u3002",
968
1038
  inputSchema: {
969
1039
  type: "object",
970
1040
  properties: {
971
- command: { type: "string", description: "\u81EA\u5B9A\u4E49\u6D4B\u8BD5\u547D\u4EE4" },
972
- timeout: { type: "number", description: "\u8D85\u65F6\u65F6\u95F4\uFF08\u6BEB\u79D2\uFF09" }
973
- }
1041
+ agentId: { type: "string", description: "\u8981\u5378\u8F7D\u7684 Agent ID" }
1042
+ },
1043
+ required: ["agentId"]
974
1044
  }
975
1045
  }, {
976
- operationKind: "system",
977
- requiresExecutionEvidence: true,
978
- rawDomain: "shell"
979
- }, shellCommandEvidenceOutputSchema),
1046
+ operationKind: "mutate",
1047
+ requiresExecutionEvidence: true
1048
+ }),
980
1049
  annotateTool({
981
- name: "seastudio-run_typecheck",
982
- description: "\u8FD0\u884C\u7C7B\u578B\u68C0\u67E5",
1050
+ name: "seastudio-agent_enable",
1051
+ description: "\u5728\u5F53\u524D\u9879\u76EE\u4E2D\u542F\u7528\u6307\u5B9A Agent\u3002\u9700\u63D0\u4F9B Agent id\u3002",
983
1052
  inputSchema: {
984
1053
  type: "object",
985
1054
  properties: {
986
- command: { type: "string", description: "\u81EA\u5B9A\u4E49\u7C7B\u578B\u68C0\u67E5\u547D\u4EE4" },
987
- timeout: { type: "number", description: "\u8D85\u65F6\u65F6\u95F4\uFF08\u6BEB\u79D2\uFF09" }
988
- }
1055
+ agentId: { type: "string", description: "\u8981\u542F\u7528\u7684 Agent ID" }
1056
+ },
1057
+ required: ["agentId"]
989
1058
  }
990
1059
  }, {
991
- operationKind: "system",
992
- requiresExecutionEvidence: true,
993
- rawDomain: "shell"
994
- }, shellCommandEvidenceOutputSchema),
1060
+ operationKind: "mutate",
1061
+ requiresExecutionEvidence: true
1062
+ }),
995
1063
  annotateTool({
996
- name: "seastudio-run_lint",
997
- description: "\u8FD0\u884C\u4EE3\u7801\u68C0\u67E5",
1064
+ name: "seastudio-agent_disable",
1065
+ description: "\u5728\u5F53\u524D\u9879\u76EE\u4E2D\u7981\u7528\u6307\u5B9A Agent\u3002\u9700\u63D0\u4F9B Agent id\u3002",
998
1066
  inputSchema: {
999
1067
  type: "object",
1000
1068
  properties: {
1001
- command: { type: "string", description: "\u81EA\u5B9A\u4E49 lint \u547D\u4EE4" },
1002
- timeout: { type: "number", description: "\u8D85\u65F6\u65F6\u95F4\uFF08\u6BEB\u79D2\uFF09" }
1003
- }
1069
+ agentId: { type: "string", description: "\u8981\u7981\u7528\u7684 Agent ID" }
1070
+ },
1071
+ required: ["agentId"]
1004
1072
  }
1005
1073
  }, {
1006
- operationKind: "system",
1007
- requiresExecutionEvidence: true,
1008
- rawDomain: "shell"
1009
- }, shellCommandEvidenceOutputSchema),
1074
+ operationKind: "mutate",
1075
+ requiresExecutionEvidence: true
1076
+ }),
1010
1077
  annotateTool({
1011
- name: "seastudio-code_search",
1012
- description: "\u5728\u9879\u76EE\u4E2D\u6309\u6A21\u5F0F\u641C\u7D22\u4EE3\u7801\u6216\u6587\u672C\u5185\u5BB9\u3002\u9002\u7528\u4E8E\u5B9A\u4F4D\u5B9A\u4E49\u3001\u8C03\u7528\u70B9\u6216\u6587\u672C\u7247\u6BB5\uFF0C\u4E0D\u4F1A\u4FEE\u6539\u6587\u4EF6\u3002",
1078
+ name: "seastudio-agent_get_status",
1079
+ description: "\u83B7\u53D6\u6307\u5B9A Agent \u7684\u5B89\u88C5\u72B6\u6001\u3002\u8FD4\u56DE\u662F\u5426\u5DF2\u5B89\u88C5\u3001\u7248\u672C\u3001\u662F\u5426\u542F\u7528\u3001\u540E\u7AEF\u6A21\u5F0F\u7B49\u8BE6\u7EC6\u4FE1\u606F\u3002\u82E5\u672A\u5B89\u88C5\u5219\u68C0\u67E5 Registry \u4E2D\u662F\u5426\u5B58\u5728\u3002",
1013
1080
  inputSchema: {
1014
1081
  type: "object",
1015
1082
  properties: {
1016
- pattern: { type: "string", description: "\u641C\u7D22\u6A21\u5F0F\uFF08\u6B63\u5219\u8868\u8FBE\u5F0F\uFF09" },
1017
- path: { type: "string", description: "\u641C\u7D22\u8DEF\u5F84" },
1018
- glob: { type: "string", description: "\u6587\u4EF6 glob \u6A21\u5F0F" },
1019
- headLimit: { type: "number", description: "\u8FD4\u56DE\u7ED3\u679C\u6570\u91CF\u9650\u5236" }
1083
+ agentId: { type: "string", description: "\u8981\u67E5\u8BE2\u7684 Agent ID" }
1020
1084
  },
1021
- required: ["pattern"]
1085
+ required: ["agentId"]
1022
1086
  }
1023
1087
  }, {
1024
1088
  operationKind: "read",
1025
- requiresExecutionEvidence: false,
1026
- rawDomain: "workspace"
1089
+ requiresExecutionEvidence: false
1027
1090
  })
1028
1091
  ];
1029
- var batchFileTools = [
1092
+ var agentTabTools = [
1030
1093
  annotateTool({
1031
- name: "seastudio-file_batch_flatten_preview",
1032
- description: "\u9884\u89C8\u6587\u4EF6\u5939\u5185\u6240\u6709\u6587\u4EF6\uFF08\u7528\u4E8E\u6279\u91CF\u5E73\u94FA\u590D\u5236\uFF09\u3002\u8DEF\u5F84\u7EDF\u4E00\u4F7F\u7528 rootId + path\u3002",
1094
+ name: "seastudio-agent_tab_list",
1095
+ description: "\u83B7\u53D6\u5F53\u524D\u6240\u6709\u6253\u5F00\u7684 Agent \u6807\u7B7E\u9875\u3002\u8FD4\u56DE\u6BCF\u4E2A\u6807\u7B7E\u7684 instanceId\u3001agentId\u3001name \u7B49\u3002",
1033
1096
  inputSchema: {
1034
1097
  type: "object",
1035
- properties: {
1036
- sourceRootId: { type: "string", enum: ["workspace"], description: "\u6E90\u6839\u76EE\u5F55 ID" },
1037
- sourcePath: { type: "string", description: "\u6E90\u76EE\u5F55\u8DEF\u5F84\uFF08\u76F8\u5BF9\u4E8E sourceRootId\uFF09" }
1038
- },
1039
- required: ["sourceRootId", "sourcePath"]
1098
+ properties: {}
1040
1099
  }
1041
1100
  }, {
1042
1101
  operationKind: "read",
1043
- requiresExecutionEvidence: false,
1044
- rawDomain: "workspace"
1102
+ requiresExecutionEvidence: false
1045
1103
  }),
1046
1104
  annotateTool({
1047
- name: "seastudio-file_batch_flatten_copy",
1048
- description: "\u6279\u91CF\u5E73\u94FA\u590D\u5236\u6587\u4EF6\u5939\u5185\u6240\u6709\u6587\u4EF6\u5230\u76EE\u6807\u76EE\u5F55\u3002\u8DEF\u5F84\u7EDF\u4E00\u4F7F\u7528 rootId + path\u3002",
1105
+ name: "seastudio-agent_tab_get_active",
1106
+ description: "\u83B7\u53D6\u5F53\u524D\u805A\u7126\uFF08\u6FC0\u6D3B\uFF09\u7684 Agent \u6807\u7B7E\u9875\u3002\u8FD4\u56DE\u8BE5\u6807\u7B7E\u7684 instanceId\u3001agentId\u3001name\u3002",
1107
+ inputSchema: {
1108
+ type: "object",
1109
+ properties: {}
1110
+ }
1111
+ }, {
1112
+ operationKind: "read",
1113
+ requiresExecutionEvidence: false
1114
+ }),
1115
+ annotateTool({
1116
+ name: "seastudio-agent_tab_open",
1117
+ description: "\u4E3A\u6307\u5B9A Agent \u65B0\u5EFA\u4E00\u4E2A\u6807\u7B7E\u9875\u5E76\u6FC0\u6D3B\u3002\u9700\u63D0\u4F9B Agent id\u3002",
1049
1118
  inputSchema: {
1050
1119
  type: "object",
1051
1120
  properties: {
1052
- sourceRootId: { type: "string", enum: ["workspace"], description: "\u6E90\u6839\u76EE\u5F55 ID" },
1053
- sourcePath: { type: "string", description: "\u6E90\u76EE\u5F55\u8DEF\u5F84\uFF08\u76F8\u5BF9\u4E8E sourceRootId\uFF09" },
1054
- destRootId: { type: "string", enum: ["workspace"], description: "\u76EE\u6807\u6839\u76EE\u5F55 ID" },
1055
- destPath: { type: "string", description: "\u76EE\u6807\u76EE\u5F55\u8DEF\u5F84\uFF08\u76F8\u5BF9\u4E8E destRootId\uFF09" },
1056
- taskId: { type: "string", description: "\u4EFB\u52A1 ID\uFF08\u7528\u4E8E\u8FDB\u5EA6\u901A\u77E5\uFF09" }
1121
+ agentId: { type: "string", description: "\u8981\u6253\u5F00\u6807\u7B7E\u9875\u7684 Agent ID" }
1057
1122
  },
1058
- required: ["sourceRootId", "sourcePath", "destRootId", "destPath"]
1123
+ required: ["agentId"]
1059
1124
  }
1060
1125
  }, {
1061
1126
  operationKind: "mutate",
1062
- requiresExecutionEvidence: true,
1063
- rawDomain: "workspace"
1064
- }, batchFlattenCopyEvidenceOutputSchema)
1065
- ];
1066
- var seaCloudTools = [
1127
+ requiresExecutionEvidence: true
1128
+ }),
1067
1129
  annotateTool({
1068
- name: "seastudio-seacloud_list_models",
1069
- description: "\u5217\u51FA SeaCloud \u63A8\u7406\u7F51\u5173\u53EF\u7528\u7684\u591A\u6A21\u6001\u751F\u6210\u6A21\u578B\u53CA\u5176\u53C2\u6570 schema\u3002\u53EF\u6309 tag \u8FC7\u6EE4\uFF08\u5982 vidu\u3001tencent\u3001musicfy \u7B49\uFF09\u3002\u8FD4\u56DE\u6BCF\u4E2A\u6A21\u578B\u7684\u540D\u79F0\u3001\u6807\u7B7E\u548C\u53EF\u7528\u7684 body \u53C2\u6570\u5B9A\u4E49\u3002",
1130
+ name: "seastudio-agent_tab_switch",
1131
+ description: "\u5207\u6362\u5230\u6307\u5B9A\u7684 Agent \u6807\u7B7E\u9875\u3002\u9700\u63D0\u4F9B\u6807\u7B7E\u5B9E\u4F8B ID\uFF08instanceId\uFF09\u3002",
1070
1132
  inputSchema: {
1071
1133
  type: "object",
1072
1134
  properties: {
1073
- tag: { type: "string", description: '\u6309\u6807\u7B7E\u8FC7\u6EE4\u6A21\u578B\uFF08\u53EF\u9009\uFF09\uFF0C\u5982 "vidu"\u3001"musicfy"\u3001"tencent" \u7B49' }
1074
- }
1135
+ instanceId: { type: "string", description: "\u8981\u5207\u6362\u5230\u7684\u6807\u7B7E\u5B9E\u4F8B ID" }
1136
+ },
1137
+ required: ["instanceId"]
1075
1138
  }
1076
1139
  }, {
1077
- operationKind: "read",
1078
- requiresExecutionEvidence: false,
1079
- rawDomain: "asset"
1140
+ operationKind: "mutate",
1141
+ requiresExecutionEvidence: true
1080
1142
  }),
1081
1143
  annotateTool({
1082
- name: "seastudio-seacloud_create_task",
1083
- description: "\u901A\u8FC7 SeaCloud \u63A8\u7406\u7F51\u5173\u521B\u5EFA\u591A\u6A21\u6001\u751F\u6210\u4EFB\u52A1\u3002\u9700\u6307\u5B9A\u6A21\u578B\u540D\u79F0\u548C\u5BF9\u5E94\u53C2\u6570\uFF0C\u53C2\u6570\u683C\u5F0F\u53C2\u7167 list_models \u8FD4\u56DE\u7684 schema\u3002\u8FD4\u56DE task_id \u7528\u4E8E\u540E\u7EED\u67E5\u8BE2\u3002",
1144
+ name: "seastudio-agent_tab_close",
1145
+ description: "\u5173\u95ED\u6307\u5B9A\u7684 Agent \u6807\u7B7E\u9875\u3002\u9700\u63D0\u4F9B\u6807\u7B7E\u5B9E\u4F8B ID\uFF08instanceId\uFF09\u3002",
1084
1146
  inputSchema: {
1085
1147
  type: "object",
1086
1148
  properties: {
1087
- model: { type: "string", description: "\u6A21\u578B\u540D\u79F0\uFF08\u6765\u81EA list_models \u8FD4\u56DE\u7684 model \u5B57\u6BB5\uFF09" },
1088
- params: { type: "object", description: "\u6A21\u578B\u53C2\u6570\uFF08\u6765\u81EA list_models \u8FD4\u56DE\u7684\u53C2\u6570 schema\uFF09" },
1089
- dash_scope: { type: "boolean", description: "\u662F\u5426\u89E3\u9664\u533A\u57DF\u9650\u5236\uFF0C\u9ED8\u8BA4 true" },
1090
- moderation: { type: "boolean", description: "\u662F\u5426\u89E3\u9664\u529F\u80FD\u9650\u5236\uFF0C\u9ED8\u8BA4 false" }
1149
+ instanceId: { type: "string", description: "\u8981\u5173\u95ED\u7684\u6807\u7B7E\u5B9E\u4F8B ID" }
1091
1150
  },
1092
- required: ["model", "params"]
1151
+ required: ["instanceId"]
1093
1152
  }
1094
1153
  }, {
1095
1154
  operationKind: "mutate",
1096
- requiresExecutionEvidence: false,
1097
- rawDomain: "asset"
1155
+ requiresExecutionEvidence: true
1098
1156
  }),
1099
1157
  annotateTool({
1100
- name: "seastudio-seacloud_query_task",
1101
- description: '\u67E5\u8BE2 SeaCloud \u751F\u6210\u4EFB\u52A1\u7684\u72B6\u6001\u548C\u7ED3\u679C\u3002status \u4E3A "completed" \u65F6 output \u4E2D\u5305\u542B\u751F\u6210\u7684\u8D44\u6E90 URL\uFF0C"in_progress" \u8868\u793A\u4ECD\u5728\u5904\u7406\uFF0C"failed" \u8868\u793A\u5931\u8D25\u3002',
1158
+ name: "seastudio-agent_tab_get_status",
1159
+ description: "\u83B7\u53D6\u6307\u5B9A Agent \u7684\u6807\u7B7E\u72B6\u6001\u3002\u8FD4\u56DE\u8BE5 Agent \u6253\u5F00\u4E86\u51E0\u4E2A\u6807\u7B7E\u3001\u5404\u6807\u7B7E\u7684 instanceId/name\u3001\u54EA\u4E2A\u662F\u5F53\u524D\u805A\u7126\u6001\u3002",
1102
1160
  inputSchema: {
1103
1161
  type: "object",
1104
1162
  properties: {
1105
- task_id: { type: "string", description: "\u4EFB\u52A1 ID\uFF08\u7531 create_task \u8FD4\u56DE\uFF09" }
1163
+ agentId: { type: "string", description: "\u8981\u67E5\u8BE2\u6807\u7B7E\u72B6\u6001\u7684 Agent ID" }
1106
1164
  },
1107
- required: ["task_id"]
1165
+ required: ["agentId"]
1108
1166
  }
1109
1167
  }, {
1110
1168
  operationKind: "read",
1111
- requiresExecutionEvidence: false,
1112
- rawDomain: "asset"
1169
+ requiresExecutionEvidence: false
1113
1170
  })
1114
1171
  ];
1115
- var allTools = [
1116
- ...fileTools,
1117
- ...shellTools,
1118
- ...gitTools,
1119
- ...clipboardTools,
1120
- ...codeQualityTools,
1121
- ...batchFileTools,
1122
- ...seaCloudTools,
1123
- ...pluginManagementTools,
1124
- ...agentManagementTools,
1125
- ...pluginTabTools,
1126
- ...agentTabTools
1127
- ];
1128
- var tools = allTools;
1129
- async function callTool(name, args = {}) {
1130
- return chunkTFOJLA2F_cjs.getDefaultClient().callTool(name, args);
1131
- }
1132
- async function request(method, params) {
1133
- return chunkTFOJLA2F_cjs.getDefaultClient().request(method, params);
1134
- }
1135
- function usesAbsolutePathMode(mode) {
1136
- return mode === "absolute";
1137
- }
1138
- function getPathBasename(path) {
1139
- const trimmed = path.replace(/[\\/]+$/g, "");
1140
- if (!trimmed) return "";
1141
- const parts = trimmed.split(/[\\/]/).filter(Boolean);
1142
- return parts[parts.length - 1] ?? "";
1143
- }
1144
- function joinWorkspacePath(dir, name) {
1145
- const normalizedDir = dir.replace(/\\/g, "/").replace(/\/+$/g, "");
1146
- const normalizedName = name.replace(/^\/+/g, "");
1147
- return normalizedDir ? `${normalizedDir}/${normalizedName}` : normalizedName;
1148
- }
1149
- var seastudio = {
1150
- roots: {
1151
- list: () => request("roots/list")
1152
- },
1153
- file: {
1154
- getSelected: () => callTool("seastudio-file_get_selected", {}),
1155
- read: (path, options) => callTool("seastudio-file_read", {
1156
- rootId: options?.rootId ?? "workspace",
1157
- path,
1158
- ...typeof options?.offset === "number" ? { offset: options.offset } : {},
1159
- ...typeof options?.limit === "number" ? { limit: options.limit } : {}
1160
- }),
1161
- write: (path, content, options) => callTool("seastudio-file_write", { rootId: options?.rootId ?? "workspace", path, content }),
1162
- list: (path, options) => callTool("seastudio-file_list", {
1163
- rootId: options?.rootId ?? "workspace",
1164
- path: typeof path === "string" ? path : ""
1165
- }),
1166
- delete: (path, options) => callTool("seastudio-file_delete", { rootId: options?.rootId ?? "workspace", path }),
1167
- mkdir: (path, options) => callTool("seastudio-file_mkdir", { rootId: options?.rootId ?? "workspace", path }),
1168
- exists: (path, options) => callTool("seastudio-file_exists", { rootId: options?.rootId ?? "workspace", path }),
1169
- stat: (path, options) => callTool("seastudio-file_stat", {
1170
- rootId: options?.rootId ?? "workspace",
1171
- path
1172
- }),
1173
- info: (path, options) => callTool("seastudio-file_info", {
1174
- rootId: options?.rootId ?? "workspace",
1175
- path
1176
- }),
1177
- search: (query, options) => callTool("seastudio-file_search", {
1178
- query,
1179
- rootId: options?.rootId ?? "workspace",
1180
- path: options?.path ?? "",
1181
- ...options?.glob ? { glob: options.glob } : {},
1182
- ...typeof options?.headLimit === "number" ? { headLimit: options.headLimit } : {}
1183
- }),
1184
- rename: (path, newName, options) => callTool("seastudio-file_rename", { rootId: options?.rootId ?? "workspace", path, newName }),
1185
- move: (sourcePath, destDir, options) => {
1186
- if (usesAbsolutePathMode(options?.sourcePathMode) || usesAbsolutePathMode(options?.destPathMode)) {
1187
- return callTool("seastudio-file_move", { sourcePath, destDir, ...options });
1188
- }
1189
- const srcRoot = options?.sourceRootId ?? "workspace";
1190
- const dstRoot = options?.destRootId ?? srcRoot;
1191
- return callTool("seastudio-file_move", {
1192
- sourceRootId: srcRoot,
1193
- sourcePath,
1194
- destRootId: dstRoot,
1195
- destPath: joinWorkspacePath(destDir, getPathBasename(sourcePath))
1196
- });
1197
- },
1198
- copyTo: (sourcePath, destDir, options) => {
1199
- if (usesAbsolutePathMode(options?.sourcePathMode) || usesAbsolutePathMode(options?.destPathMode)) {
1200
- return callTool("seastudio-file_copy_to", { sourcePath, destDir, ...options });
1201
- }
1202
- const srcRoot = options?.sourceRootId ?? "workspace";
1203
- const dstRoot = options?.destRootId ?? srcRoot;
1204
- return callTool("seastudio-file_copy_to", {
1205
- sourceRootId: srcRoot,
1206
- sourcePath,
1207
- destRootId: dstRoot,
1208
- destPath: joinWorkspacePath(destDir, getPathBasename(sourcePath))
1209
- });
1210
- },
1211
- copy: (path, options) => callTool("seastudio-file_copy", { rootId: options?.rootId ?? "workspace", path }),
1212
- paste: (path = "", options) => callTool("seastudio-file_paste", { rootId: options?.rootId ?? "workspace", path }),
1213
- clipboardCheck: () => callTool("seastudio-file_clipboard_check", {}),
1214
- copyPath: (path, options) => callTool("seastudio-file_copy_path", { rootId: options?.rootId ?? "workspace", path }),
1215
- trash: (path, options) => callTool("seastudio-file_trash", { rootId: options?.rootId ?? "workspace", path }),
1216
- batchFlattenPreview: (sourcePath, options) => {
1217
- if (usesAbsolutePathMode(options?.sourcePathMode)) {
1218
- return callTool("seastudio-file_batch_flatten_preview", { sourcePath, ...options });
1219
- }
1220
- return callTool("seastudio-file_batch_flatten_preview", {
1221
- sourceRootId: options?.sourceRootId ?? "workspace",
1222
- sourcePath
1223
- });
1224
- },
1225
- batchFlattenCopy: (sourcePath, destDir, taskId, options) => {
1226
- if (usesAbsolutePathMode(options?.sourcePathMode) || usesAbsolutePathMode(options?.destPathMode)) {
1227
- return callTool("seastudio-file_batch_flatten_copy", { sourcePath, destDir, taskId, ...options });
1228
- }
1229
- const srcRoot = options?.sourceRootId ?? "workspace";
1230
- const dstRoot = options?.destRootId ?? srcRoot;
1231
- return callTool("seastudio-file_batch_flatten_copy", {
1232
- sourceRootId: srcRoot,
1233
- sourcePath,
1234
- destRootId: dstRoot,
1235
- destPath: destDir,
1236
- ...typeof taskId === "string" ? { taskId } : {}
1237
- });
1238
- },
1239
- getUrl: (path, options) => callTool("seastudio-file_get_url", { rootId: options?.rootId ?? "workspace", path }),
1240
- download: (url, path, filenameHint, options) => callTool("seastudio-file_download", { rootId: options?.rootId ?? "workspace", path, url, filenameHint }),
1241
- writeBinary: (path, base64, options) => callTool("seastudio-file_write_binary", { rootId: options?.rootId ?? "workspace", path, base64 }),
1242
- readBinary: (path, options) => callTool("seastudio-file_read_binary", { rootId: options?.rootId ?? "workspace", path })
1243
- },
1244
- shell: {
1245
- execute: (command, cwd, timeout) => callTool("seastudio-shell_execute", { command, cwd, timeout }),
1246
- session: {
1247
- get: () => callTool("seastudio-shell_session_get", {}),
1248
- getEntries: (limit) => callTool("seastudio-shell_session_get_entries", { limit }),
1249
- runCommand: (command, cwd, timeout) => callTool("seastudio-shell_session_run_command", { command, cwd, timeout }),
1250
- setCwd: (cwd) => callTool("seastudio-shell_session_set_cwd", { cwd }),
1251
- clear: () => callTool("seastudio-shell_session_clear", {}),
1252
- reset: () => callTool("seastudio-shell_session_reset", {})
1253
- }
1254
- },
1255
- git: {
1256
- status: () => callTool("seastudio-git_status", {}),
1257
- diff: (staged, path) => callTool("seastudio-git_diff", { staged, path })
1258
- },
1259
- codeQuality: {
1260
- runTest: (command, timeout) => callTool("seastudio-run_test", { command, timeout }),
1261
- runTypecheck: (command, timeout) => callTool("seastudio-run_typecheck", { command, timeout }),
1262
- runLint: (command, timeout) => callTool("seastudio-run_lint", { command, timeout }),
1263
- codeSearch: (pattern, path, glob, headLimit) => callTool("seastudio-code_search", { pattern, path, glob, headLimit })
1264
- }
1265
- };
1266
1172
 
1267
1173
  // src/mcp/seastudio/notifications.ts
1268
1174
  var SeastudioRequests = {
@@ -1278,6 +1184,10 @@ var SeastudioRequests = {
1278
1184
  var SeastudioNotifications = {
1279
1185
  /** 文件系统变化通知(fs.watch 触发) */
1280
1186
  FILES_CHANGED: "files:changed",
1187
+ /** 文件或目录被重命名/移动 */
1188
+ FILE_RENAMED: "file:renamed",
1189
+ /** 文件或目录被删除/移入回收站 */
1190
+ FILE_DELETED: "file:deleted",
1281
1191
  /** 根目录变化通知 */
1282
1192
  ROOTS_CHANGED: "roots:changed",
1283
1193
  /** 文件打开请求,可广播也可定向 */
@@ -1294,20 +1204,38 @@ var SeastudioNotifications = {
1294
1204
  PROPOSAL_FEEDBACK: "seastudio:proposal-feedback"
1295
1205
  };
1296
1206
 
1207
+ // src/mcp/seastudio/index.ts
1208
+ var allTools = [
1209
+ ...fileTools,
1210
+ ...shellTools,
1211
+ ...seaCloudTools,
1212
+ ...pluginManagementTools,
1213
+ ...agentManagementTools,
1214
+ ...pluginTabTools,
1215
+ ...agentTabTools
1216
+ ];
1217
+ var tools = allTools;
1218
+
1297
1219
  exports.SeastudioNotifications = SeastudioNotifications;
1298
1220
  exports.SeastudioRequests = SeastudioRequests;
1299
1221
  exports.agentManagementTools = agentManagementTools;
1300
1222
  exports.agentTabTools = agentTabTools;
1301
1223
  exports.allTools = allTools;
1302
1224
  exports.annotateTool = annotateTool;
1303
- exports.batchFileTools = batchFileTools;
1304
- exports.clipboardTools = clipboardTools;
1305
- exports.codeQualityTools = codeQualityTools;
1225
+ exports.batchFlattenCopyEvidenceOutputSchema = batchFlattenCopyEvidenceOutputSchema;
1226
+ exports.callTool = callTool;
1227
+ exports.callToolText = callToolText;
1228
+ exports.dualPathEvidenceOutputSchema = dualPathEvidenceOutputSchema;
1229
+ exports.fileDownloadEvidenceOutputSchema = fileDownloadEvidenceOutputSchema;
1306
1230
  exports.fileTools = fileTools;
1307
- exports.gitTools = gitTools;
1308
1231
  exports.pluginManagementTools = pluginManagementTools;
1309
1232
  exports.pluginTabTools = pluginTabTools;
1233
+ exports.request = request;
1234
+ exports.rootedPathEvidenceOutputSchema = rootedPathEvidenceOutputSchema;
1235
+ exports.rootedWriteEvidenceOutputSchema = rootedWriteEvidenceOutputSchema;
1310
1236
  exports.seaCloudTools = seaCloudTools;
1311
1237
  exports.seastudio = seastudio;
1238
+ exports.shellCommandEvidenceOutputSchema = shellCommandEvidenceOutputSchema;
1239
+ exports.shellSessionSnapshotEvidenceOutputSchema = shellSessionSnapshotEvidenceOutputSchema;
1312
1240
  exports.shellTools = shellTools;
1313
1241
  exports.tools = tools;