@seastudio/sdk 3.0.1 → 3.0.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/bin/seastudio.js +0 -0
- package/dist/chunk-D7ONFXVY.js +98 -0
- package/dist/chunk-EIOFZMTC.cjs +109 -0
- package/dist/{chunk-AGBZJGTY.cjs → chunk-SUF5BPSK.cjs} +3 -1
- package/dist/{chunk-DDVRUPMZ.js → chunk-XU5GEWWL.js} +3 -1
- package/dist/develop-tool/cli/index.cjs +79 -7
- package/dist/develop-tool/cli/index.js +79 -7
- package/dist/index.cjs +42 -167
- package/dist/index.d.cts +2 -6
- package/dist/index.d.ts +2 -6
- package/dist/index.js +2 -7
- package/dist/mcp/core/index.d.cts +2 -2
- package/dist/mcp/core/index.d.ts +2 -2
- package/dist/mcp/index.cjs +27 -152
- package/dist/mcp/index.d.cts +12 -77
- package/dist/mcp/index.d.ts +12 -77
- package/dist/mcp/index.js +2 -7
- package/dist/mcp/seastudio/index.cjs +18 -18
- package/dist/mcp/seastudio/index.d.cts +34 -2
- package/dist/mcp/seastudio/index.d.ts +34 -2
- package/dist/mcp/seastudio/index.js +1 -1
- package/dist/{types-Clgf5gBf.d.cts → types-B32sUvc0.d.cts} +10 -2
- package/dist/{types-Clgf5gBf.d.ts → types-B32sUvc0.d.ts} +10 -2
- package/package.json +2 -22
- package/src/develop-tool/templates/plugin/frontend/package.json.tmpl +1 -1
- package/src/develop-tool/templates/plugin/frontend/src/main.tsx +3 -0
- package/src/develop-tool/templates/plugin/frontend/src/mcp-entry.ts.tmpl +12 -0
- package/dist/chunk-4ITOR5QE.js +0 -901
- package/dist/chunk-CSXDT47Y.cjs +0 -105
- package/dist/chunk-CVF4QHS6.cjs +0 -436
- package/dist/chunk-DSOSHJH2.js +0 -643
- package/dist/chunk-FLATZQA2.js +0 -174
- package/dist/chunk-HJJTBVKQ.cjs +0 -909
- package/dist/chunk-ISI2OLPI.cjs +0 -179
- package/dist/chunk-MYURVLGP.cjs +0 -165
- package/dist/chunk-QD4KISXM.js +0 -160
- package/dist/chunk-SNGU4SHO.cjs +0 -654
- package/dist/chunk-V7MNKGS7.js +0 -94
- package/dist/chunk-Z7LV7DCO.js +0 -429
- package/dist/mcp/plugin-editor/index.cjs +0 -47
- package/dist/mcp/plugin-editor/index.d.cts +0 -98
- package/dist/mcp/plugin-editor/index.d.ts +0 -98
- package/dist/mcp/plugin-editor/index.js +0 -2
- package/dist/mcp/plugin-excel/index.cjs +0 -31
- package/dist/mcp/plugin-excel/index.d.cts +0 -86
- package/dist/mcp/plugin-excel/index.d.ts +0 -86
- package/dist/mcp/plugin-excel/index.js +0 -2
- package/dist/mcp/plugin-preview/index.cjs +0 -23
- package/dist/mcp/plugin-preview/index.d.cts +0 -109
- package/dist/mcp/plugin-preview/index.d.ts +0 -109
- package/dist/mcp/plugin-preview/index.js +0 -2
- package/dist/mcp/plugin-seaflow/index.cjs +0 -35
- package/dist/mcp/plugin-seaflow/index.d.cts +0 -318
- package/dist/mcp/plugin-seaflow/index.d.ts +0 -318
- package/dist/mcp/plugin-seaflow/index.js +0 -2
- package/dist/tools-LMW67LIY.js +0 -2
- package/dist/tools-TU7PBMDO.cjs +0 -23
package/dist/chunk-FLATZQA2.js
DELETED
|
@@ -1,174 +0,0 @@
|
|
|
1
|
-
import { getDefaultClient } from './chunk-ANWOL7SM.js';
|
|
2
|
-
|
|
3
|
-
// src/mcp/plugin-shell/tools.ts
|
|
4
|
-
function annotateTool(tool, annotations, outputSchema) {
|
|
5
|
-
return {
|
|
6
|
-
...tool,
|
|
7
|
-
annotations,
|
|
8
|
-
...outputSchema ? { outputSchema } : {}
|
|
9
|
-
};
|
|
10
|
-
}
|
|
11
|
-
var shellCommandEvidenceOutputSchema = {
|
|
12
|
-
type: "object",
|
|
13
|
-
properties: {
|
|
14
|
-
command: { type: "string" },
|
|
15
|
-
cwd: { type: "string" },
|
|
16
|
-
exitCode: { type: "number" },
|
|
17
|
-
stdout: { type: "string" },
|
|
18
|
-
stderr: { type: "string" },
|
|
19
|
-
error: { type: "string" },
|
|
20
|
-
durationMs: { type: "number" },
|
|
21
|
-
usedFallback: { type: "boolean" }
|
|
22
|
-
},
|
|
23
|
-
required: ["command", "exitCode", "stdout", "stderr", "durationMs", "usedFallback"]
|
|
24
|
-
};
|
|
25
|
-
var shellSessionSnapshotEvidenceOutputSchema = {
|
|
26
|
-
type: "object",
|
|
27
|
-
properties: {
|
|
28
|
-
projectPath: { type: "string" },
|
|
29
|
-
cwd: { type: "string" },
|
|
30
|
-
promptLabel: { type: "string" },
|
|
31
|
-
isRunning: { type: "boolean" },
|
|
32
|
-
lastExitCode: { type: "number" },
|
|
33
|
-
lastDurationMs: { type: "number" },
|
|
34
|
-
lastCommandAt: { type: "number" },
|
|
35
|
-
historyCount: { type: "number" },
|
|
36
|
-
entryCount: { type: "number" }
|
|
37
|
-
},
|
|
38
|
-
required: ["projectPath", "cwd", "promptLabel", "isRunning", "historyCount", "entryCount"]
|
|
39
|
-
};
|
|
40
|
-
var sessionTools = [
|
|
41
|
-
annotateTool({
|
|
42
|
-
name: "shell-get_session",
|
|
43
|
-
description: "\u83B7\u53D6\u5F53\u524D Shell \u4F1A\u8BDD\u5FEB\u7167\uFF0C\u5305\u62EC projectPath\u3001cwd\u3001\u8FD0\u884C\u72B6\u6001\u3001\u6700\u8FD1\u4E00\u6B21\u6267\u884C\u7ED3\u679C\u548C prompt \u4FE1\u606F\u3002",
|
|
44
|
-
inputSchema: {
|
|
45
|
-
type: "object",
|
|
46
|
-
properties: {}
|
|
47
|
-
}
|
|
48
|
-
}, {
|
|
49
|
-
operationKind: "read",
|
|
50
|
-
requiresExecutionEvidence: false,
|
|
51
|
-
rawDomain: "shell"
|
|
52
|
-
}, {
|
|
53
|
-
type: "object",
|
|
54
|
-
properties: {
|
|
55
|
-
projectPath: { type: "string" },
|
|
56
|
-
cwd: { type: "string" },
|
|
57
|
-
promptLabel: { type: "string" },
|
|
58
|
-
isRunning: { type: "boolean" },
|
|
59
|
-
lastExitCode: { type: "number" },
|
|
60
|
-
lastDurationMs: { type: "number" },
|
|
61
|
-
lastCommandAt: { type: "number" },
|
|
62
|
-
historyCount: { type: "number" },
|
|
63
|
-
entryCount: { type: "number" }
|
|
64
|
-
}
|
|
65
|
-
}),
|
|
66
|
-
annotateTool({
|
|
67
|
-
name: "shell-get_entries",
|
|
68
|
-
description: "\u8BFB\u53D6\u5F53\u524D Shell \u8F93\u51FA\u6D41\uFF0C\u7528\u4E8E\u7406\u89E3\u5386\u53F2\u547D\u4EE4\u3001stdout\u3001stderr \u548C meta \u4FE1\u606F\u3002",
|
|
69
|
-
inputSchema: {
|
|
70
|
-
type: "object",
|
|
71
|
-
properties: {
|
|
72
|
-
limit: {
|
|
73
|
-
type: "number",
|
|
74
|
-
description: "\u53EF\u9009\uFF0C\u8FD4\u56DE\u6700\u8FD1\u591A\u5C11\u6761\u8BB0\u5F55\uFF0C\u9ED8\u8BA4 200\u3002"
|
|
75
|
-
}
|
|
76
|
-
}
|
|
77
|
-
}
|
|
78
|
-
}, {
|
|
79
|
-
operationKind: "read",
|
|
80
|
-
requiresExecutionEvidence: false,
|
|
81
|
-
rawDomain: "shell"
|
|
82
|
-
}, {
|
|
83
|
-
type: "object",
|
|
84
|
-
properties: {
|
|
85
|
-
entries: {
|
|
86
|
-
type: "array",
|
|
87
|
-
items: {
|
|
88
|
-
type: "object",
|
|
89
|
-
properties: {
|
|
90
|
-
id: { type: "number" },
|
|
91
|
-
level: { type: "string" },
|
|
92
|
-
content: { type: "string" },
|
|
93
|
-
createdAt: { type: "number" }
|
|
94
|
-
}
|
|
95
|
-
}
|
|
96
|
-
}
|
|
97
|
-
}
|
|
98
|
-
})
|
|
99
|
-
];
|
|
100
|
-
var commandTools = [
|
|
101
|
-
annotateTool({
|
|
102
|
-
name: "shell-run_command",
|
|
103
|
-
description: "\u5728\u5F53\u524D Shell \u4F1A\u8BDD\u4E0A\u4E0B\u6587\u4E2D\u6267\u884C\u547D\u4EE4\u3002\u652F\u6301 cwd / timeout\uFF0C\u547D\u4EE4\u7ED3\u679C\u4F1A\u5199\u5165 Shell \u8F93\u51FA\u6D41\u5E76\u8FD4\u56DE\u6267\u884C\u8BE6\u60C5\u3002",
|
|
104
|
-
inputSchema: {
|
|
105
|
-
type: "object",
|
|
106
|
-
properties: {
|
|
107
|
-
command: { type: "string", description: "\u8981\u6267\u884C\u7684\u547D\u4EE4" },
|
|
108
|
-
cwd: { type: "string", description: "\u53EF\u9009\uFF0C\u8986\u76D6\u5F53\u524D\u4F1A\u8BDD\u5DE5\u4F5C\u76EE\u5F55" },
|
|
109
|
-
timeout: { type: "number", description: "\u53EF\u9009\uFF0C\u8D85\u65F6\u65F6\u95F4\uFF08\u6BEB\u79D2\uFF09" }
|
|
110
|
-
},
|
|
111
|
-
required: ["command"]
|
|
112
|
-
}
|
|
113
|
-
}, {
|
|
114
|
-
operationKind: "system",
|
|
115
|
-
requiresExecutionEvidence: true,
|
|
116
|
-
rawDomain: "shell"
|
|
117
|
-
}, shellCommandEvidenceOutputSchema),
|
|
118
|
-
annotateTool({
|
|
119
|
-
name: "shell-set_cwd",
|
|
120
|
-
description: "\u8BBE\u7F6E\u5F53\u524D Shell \u4F1A\u8BDD\u7684\u5DE5\u4F5C\u76EE\u5F55\uFF0C\u4E0D\u6267\u884C\u547D\u4EE4\u3002\u7528\u4E8E\u663E\u5F0F\u5207\u6362\u4E0A\u4E0B\u6587\u76EE\u5F55\u3002",
|
|
121
|
-
inputSchema: {
|
|
122
|
-
type: "object",
|
|
123
|
-
properties: {
|
|
124
|
-
cwd: { type: "string", description: "\u76EE\u6807\u5DE5\u4F5C\u76EE\u5F55" }
|
|
125
|
-
},
|
|
126
|
-
required: ["cwd"]
|
|
127
|
-
}
|
|
128
|
-
}, {
|
|
129
|
-
operationKind: "mutate",
|
|
130
|
-
requiresExecutionEvidence: true,
|
|
131
|
-
rawDomain: "shell"
|
|
132
|
-
}, shellSessionSnapshotEvidenceOutputSchema),
|
|
133
|
-
annotateTool({
|
|
134
|
-
name: "shell-clear_output",
|
|
135
|
-
description: "\u6E05\u7A7A\u5F53\u524D Shell \u8F93\u51FA\u6D41\uFF0C\u4F46\u4FDD\u7559\u4F1A\u8BDD\u4E0A\u4E0B\u6587\u548C\u547D\u4EE4\u5386\u53F2\u3002",
|
|
136
|
-
inputSchema: {
|
|
137
|
-
type: "object",
|
|
138
|
-
properties: {}
|
|
139
|
-
}
|
|
140
|
-
}, {
|
|
141
|
-
operationKind: "mutate",
|
|
142
|
-
requiresExecutionEvidence: true,
|
|
143
|
-
rawDomain: "shell"
|
|
144
|
-
}, shellSessionSnapshotEvidenceOutputSchema),
|
|
145
|
-
annotateTool({
|
|
146
|
-
name: "shell-reset_session",
|
|
147
|
-
description: "\u91CD\u7F6E\u5F53\u524D Shell \u4F1A\u8BDD\uFF0Ccwd \u56DE\u5230 projectPath\uFF0C\u6E05\u7A7A\u8F93\u51FA\u548C\u6700\u8FD1\u4E00\u6B21\u6267\u884C\u72B6\u6001\u3002",
|
|
148
|
-
inputSchema: {
|
|
149
|
-
type: "object",
|
|
150
|
-
properties: {}
|
|
151
|
-
}
|
|
152
|
-
}, {
|
|
153
|
-
operationKind: "mutate",
|
|
154
|
-
requiresExecutionEvidence: true,
|
|
155
|
-
rawDomain: "shell"
|
|
156
|
-
}, shellSessionSnapshotEvidenceOutputSchema)
|
|
157
|
-
];
|
|
158
|
-
var tools = [
|
|
159
|
-
...sessionTools,
|
|
160
|
-
...commandTools
|
|
161
|
-
];
|
|
162
|
-
async function callTool(name, args = {}) {
|
|
163
|
-
return getDefaultClient().callTool(name, args);
|
|
164
|
-
}
|
|
165
|
-
var shellPlugin = {
|
|
166
|
-
getSession: () => callTool("shell-get_session", {}),
|
|
167
|
-
getEntries: (limit) => callTool("shell-get_entries", { limit }),
|
|
168
|
-
runCommand: (command, cwd, timeout) => callTool("shell-run_command", { command, cwd, timeout }),
|
|
169
|
-
setCwd: (cwd) => callTool("shell-set_cwd", { cwd }),
|
|
170
|
-
clearOutput: () => callTool("shell-clear_output", {}),
|
|
171
|
-
resetSession: () => callTool("shell-reset_session", {})
|
|
172
|
-
};
|
|
173
|
-
|
|
174
|
-
export { commandTools, sessionTools, shellPlugin, tools };
|