@gbozee/ultimate 0.0.2-72 → 0.0.2-74
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/dist/frontend-index.d.ts +13 -0
- package/dist/frontend-index.js +66 -17
- package/dist/index.cjs +69 -17
- package/dist/index.d.ts +16 -0
- package/dist/index.js +1754 -1722
- package/dist/mcp-client.cjs +8870 -0
- package/dist/mcp-client.js +55 -81
- package/dist/mcp-server.cjs +65911 -0
- package/dist/mcp-server.js +1742 -1703
- package/package.json +4 -1
package/dist/mcp-client.js
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
|
+
import { createRequire } from "node:module";
|
|
1
2
|
var __create = Object.create;
|
|
2
3
|
var __getProtoOf = Object.getPrototypeOf;
|
|
3
4
|
var __defProp = Object.defineProperty;
|
|
4
5
|
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
5
|
-
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
6
6
|
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
7
7
|
var __toESM = (mod, isNodeMode, target) => {
|
|
8
8
|
target = mod != null ? __create(__getProtoOf(mod)) : {};
|
|
@@ -15,36 +15,14 @@ var __toESM = (mod, isNodeMode, target) => {
|
|
|
15
15
|
});
|
|
16
16
|
return to;
|
|
17
17
|
};
|
|
18
|
-
var __moduleCache = /* @__PURE__ */ new WeakMap;
|
|
19
|
-
var __toCommonJS = (from) => {
|
|
20
|
-
var entry = __moduleCache.get(from), desc;
|
|
21
|
-
if (entry)
|
|
22
|
-
return entry;
|
|
23
|
-
entry = __defProp({}, "__esModule", { value: true });
|
|
24
|
-
if (from && typeof from === "object" || typeof from === "function")
|
|
25
|
-
__getOwnPropNames(from).map((key) => !__hasOwnProp.call(entry, key) && __defProp(entry, key, {
|
|
26
|
-
get: () => from[key],
|
|
27
|
-
enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable
|
|
28
|
-
}));
|
|
29
|
-
__moduleCache.set(from, entry);
|
|
30
|
-
return entry;
|
|
31
|
-
};
|
|
32
18
|
var __commonJS = (cb, mod) => () => (mod || cb((mod = { exports: {} }).exports, mod), mod.exports);
|
|
33
|
-
var
|
|
34
|
-
for (var name in all)
|
|
35
|
-
__defProp(target, name, {
|
|
36
|
-
get: all[name],
|
|
37
|
-
enumerable: true,
|
|
38
|
-
configurable: true,
|
|
39
|
-
set: (newValue) => all[name] = () => newValue
|
|
40
|
-
});
|
|
41
|
-
};
|
|
19
|
+
var __require = /* @__PURE__ */ createRequire(import.meta.url);
|
|
42
20
|
|
|
43
21
|
// node_modules/isexe/windows.js
|
|
44
|
-
var require_windows = __commonJS((
|
|
45
|
-
|
|
22
|
+
var require_windows = __commonJS((exports, module) => {
|
|
23
|
+
module.exports = isexe;
|
|
46
24
|
isexe.sync = sync;
|
|
47
|
-
var fs =
|
|
25
|
+
var fs = __require("fs");
|
|
48
26
|
function checkPathExt(path2, options) {
|
|
49
27
|
var pathext = options.pathExt !== undefined ? options.pathExt : process.env.PATHEXT;
|
|
50
28
|
if (!pathext) {
|
|
@@ -79,10 +57,10 @@ var require_windows = __commonJS((exports2, module2) => {
|
|
|
79
57
|
});
|
|
80
58
|
|
|
81
59
|
// node_modules/isexe/mode.js
|
|
82
|
-
var require_mode = __commonJS((
|
|
83
|
-
|
|
60
|
+
var require_mode = __commonJS((exports, module) => {
|
|
61
|
+
module.exports = isexe;
|
|
84
62
|
isexe.sync = sync;
|
|
85
|
-
var fs =
|
|
63
|
+
var fs = __require("fs");
|
|
86
64
|
function isexe(path2, options, cb) {
|
|
87
65
|
fs.stat(path2, function(er, stat) {
|
|
88
66
|
cb(er, er ? false : checkStat(stat, options));
|
|
@@ -110,15 +88,15 @@ var require_mode = __commonJS((exports2, module2) => {
|
|
|
110
88
|
});
|
|
111
89
|
|
|
112
90
|
// node_modules/isexe/index.js
|
|
113
|
-
var require_isexe = __commonJS((
|
|
114
|
-
var fs =
|
|
91
|
+
var require_isexe = __commonJS((exports, module) => {
|
|
92
|
+
var fs = __require("fs");
|
|
115
93
|
var core;
|
|
116
94
|
if (process.platform === "win32" || global.TESTING_WINDOWS) {
|
|
117
95
|
core = require_windows();
|
|
118
96
|
} else {
|
|
119
97
|
core = require_mode();
|
|
120
98
|
}
|
|
121
|
-
|
|
99
|
+
module.exports = isexe;
|
|
122
100
|
isexe.sync = sync;
|
|
123
101
|
function isexe(path2, options, cb) {
|
|
124
102
|
if (typeof options === "function") {
|
|
@@ -163,9 +141,9 @@ var require_isexe = __commonJS((exports2, module2) => {
|
|
|
163
141
|
});
|
|
164
142
|
|
|
165
143
|
// node_modules/which/which.js
|
|
166
|
-
var require_which = __commonJS((
|
|
144
|
+
var require_which = __commonJS((exports, module) => {
|
|
167
145
|
var isWindows = process.platform === "win32" || process.env.OSTYPE === "cygwin" || process.env.OSTYPE === "msys";
|
|
168
|
-
var path2 =
|
|
146
|
+
var path2 = __require("path");
|
|
169
147
|
var COLON = isWindows ? ";" : ":";
|
|
170
148
|
var isexe = require_isexe();
|
|
171
149
|
var getNotFoundError = (cmd) => Object.assign(new Error(`not found: ${cmd}`), { code: "ENOENT" });
|
|
@@ -250,12 +228,12 @@ var require_which = __commonJS((exports2, module2) => {
|
|
|
250
228
|
return null;
|
|
251
229
|
throw getNotFoundError(cmd);
|
|
252
230
|
};
|
|
253
|
-
|
|
231
|
+
module.exports = which;
|
|
254
232
|
which.sync = whichSync;
|
|
255
233
|
});
|
|
256
234
|
|
|
257
235
|
// node_modules/path-key/index.js
|
|
258
|
-
var require_path_key = __commonJS((
|
|
236
|
+
var require_path_key = __commonJS((exports, module) => {
|
|
259
237
|
var pathKey = (options = {}) => {
|
|
260
238
|
const environment = options.env || process.env;
|
|
261
239
|
const platform = options.platform || process.platform;
|
|
@@ -264,13 +242,13 @@ var require_path_key = __commonJS((exports2, module2) => {
|
|
|
264
242
|
}
|
|
265
243
|
return Object.keys(environment).reverse().find((key) => key.toUpperCase() === "PATH") || "Path";
|
|
266
244
|
};
|
|
267
|
-
|
|
268
|
-
|
|
245
|
+
module.exports = pathKey;
|
|
246
|
+
module.exports.default = pathKey;
|
|
269
247
|
});
|
|
270
248
|
|
|
271
249
|
// node_modules/cross-spawn/lib/util/resolveCommand.js
|
|
272
|
-
var require_resolveCommand = __commonJS((
|
|
273
|
-
var path2 =
|
|
250
|
+
var require_resolveCommand = __commonJS((exports, module) => {
|
|
251
|
+
var path2 = __require("path");
|
|
274
252
|
var which = require_which();
|
|
275
253
|
var getPathKey = require_path_key();
|
|
276
254
|
function resolveCommandAttempt(parsed, withoutPathExt) {
|
|
@@ -304,11 +282,11 @@ var require_resolveCommand = __commonJS((exports2, module2) => {
|
|
|
304
282
|
function resolveCommand(parsed) {
|
|
305
283
|
return resolveCommandAttempt(parsed) || resolveCommandAttempt(parsed, true);
|
|
306
284
|
}
|
|
307
|
-
|
|
285
|
+
module.exports = resolveCommand;
|
|
308
286
|
});
|
|
309
287
|
|
|
310
288
|
// node_modules/cross-spawn/lib/util/escape.js
|
|
311
|
-
var require_escape = __commonJS((
|
|
289
|
+
var require_escape = __commonJS((exports, module) => {
|
|
312
290
|
var metaCharsRegExp = /([()\][%!^"`<>&|;, *?])/g;
|
|
313
291
|
function escapeCommand(arg) {
|
|
314
292
|
arg = arg.replace(metaCharsRegExp, "^$1");
|
|
@@ -325,19 +303,19 @@ var require_escape = __commonJS((exports2, module2) => {
|
|
|
325
303
|
}
|
|
326
304
|
return arg;
|
|
327
305
|
}
|
|
328
|
-
|
|
329
|
-
|
|
306
|
+
exports.command = escapeCommand;
|
|
307
|
+
exports.argument = escapeArgument;
|
|
330
308
|
});
|
|
331
309
|
|
|
332
310
|
// node_modules/shebang-regex/index.js
|
|
333
|
-
var require_shebang_regex = __commonJS((
|
|
334
|
-
|
|
311
|
+
var require_shebang_regex = __commonJS((exports, module) => {
|
|
312
|
+
module.exports = /^#!(.*)/;
|
|
335
313
|
});
|
|
336
314
|
|
|
337
315
|
// node_modules/shebang-command/index.js
|
|
338
|
-
var require_shebang_command = __commonJS((
|
|
316
|
+
var require_shebang_command = __commonJS((exports, module) => {
|
|
339
317
|
var shebangRegex = require_shebang_regex();
|
|
340
|
-
|
|
318
|
+
module.exports = (string = "") => {
|
|
341
319
|
const match = string.match(shebangRegex);
|
|
342
320
|
if (!match) {
|
|
343
321
|
return null;
|
|
@@ -352,8 +330,8 @@ var require_shebang_command = __commonJS((exports2, module2) => {
|
|
|
352
330
|
});
|
|
353
331
|
|
|
354
332
|
// node_modules/cross-spawn/lib/util/readShebang.js
|
|
355
|
-
var require_readShebang = __commonJS((
|
|
356
|
-
var fs =
|
|
333
|
+
var require_readShebang = __commonJS((exports, module) => {
|
|
334
|
+
var fs = __require("fs");
|
|
357
335
|
var shebangCommand = require_shebang_command();
|
|
358
336
|
function readShebang(command) {
|
|
359
337
|
const size = 150;
|
|
@@ -367,12 +345,12 @@ var require_readShebang = __commonJS((exports2, module2) => {
|
|
|
367
345
|
}
|
|
368
346
|
return shebangCommand(buffer.toString());
|
|
369
347
|
}
|
|
370
|
-
|
|
348
|
+
module.exports = readShebang;
|
|
371
349
|
});
|
|
372
350
|
|
|
373
351
|
// node_modules/cross-spawn/lib/parse.js
|
|
374
|
-
var require_parse = __commonJS((
|
|
375
|
-
var path2 =
|
|
352
|
+
var require_parse = __commonJS((exports, module) => {
|
|
353
|
+
var path2 = __require("path");
|
|
376
354
|
var resolveCommand = require_resolveCommand();
|
|
377
355
|
var escape = require_escape();
|
|
378
356
|
var readShebang = require_readShebang();
|
|
@@ -426,11 +404,11 @@ var require_parse = __commonJS((exports2, module2) => {
|
|
|
426
404
|
};
|
|
427
405
|
return options.shell ? parsed : parseNonShell(parsed);
|
|
428
406
|
}
|
|
429
|
-
|
|
407
|
+
module.exports = parse;
|
|
430
408
|
});
|
|
431
409
|
|
|
432
410
|
// node_modules/cross-spawn/lib/enoent.js
|
|
433
|
-
var require_enoent = __commonJS((
|
|
411
|
+
var require_enoent = __commonJS((exports, module) => {
|
|
434
412
|
var isWin = process.platform === "win32";
|
|
435
413
|
function notFoundError(original, syscall) {
|
|
436
414
|
return Object.assign(new Error(`${syscall} ${original.command} ENOENT`), {
|
|
@@ -468,7 +446,7 @@ var require_enoent = __commonJS((exports2, module2) => {
|
|
|
468
446
|
}
|
|
469
447
|
return null;
|
|
470
448
|
}
|
|
471
|
-
|
|
449
|
+
module.exports = {
|
|
472
450
|
hookChildProcess,
|
|
473
451
|
verifyENOENT,
|
|
474
452
|
verifyENOENTSync,
|
|
@@ -477,8 +455,8 @@ var require_enoent = __commonJS((exports2, module2) => {
|
|
|
477
455
|
});
|
|
478
456
|
|
|
479
457
|
// node_modules/cross-spawn/index.js
|
|
480
|
-
var require_cross_spawn = __commonJS((
|
|
481
|
-
var cp =
|
|
458
|
+
var require_cross_spawn = __commonJS((exports, module) => {
|
|
459
|
+
var cp = __require("child_process");
|
|
482
460
|
var parse = require_parse();
|
|
483
461
|
var enoent = require_enoent();
|
|
484
462
|
function spawn(command, args, options) {
|
|
@@ -493,20 +471,13 @@ var require_cross_spawn = __commonJS((exports2, module2) => {
|
|
|
493
471
|
result.error = result.error || enoent.verifyENOENTSync(result.status, parsed);
|
|
494
472
|
return result;
|
|
495
473
|
}
|
|
496
|
-
|
|
497
|
-
|
|
498
|
-
|
|
499
|
-
|
|
500
|
-
|
|
474
|
+
module.exports = spawn;
|
|
475
|
+
module.exports.spawn = spawn;
|
|
476
|
+
module.exports.sync = spawnSync;
|
|
477
|
+
module.exports._parse = parse;
|
|
478
|
+
module.exports._enoent = enoent;
|
|
501
479
|
});
|
|
502
480
|
|
|
503
|
-
// src/mcp-client.ts
|
|
504
|
-
var exports_mcp_client = {};
|
|
505
|
-
__export(exports_mcp_client, {
|
|
506
|
-
main: () => main
|
|
507
|
-
});
|
|
508
|
-
module.exports = __toCommonJS(exports_mcp_client);
|
|
509
|
-
|
|
510
481
|
// node_modules/@anthropic-ai/sdk/internal/tslib.mjs
|
|
511
482
|
function __classPrivateFieldSet(receiver, state, value, kind, f) {
|
|
512
483
|
if (kind === "m")
|
|
@@ -8578,9 +8549,9 @@ class Client extends Protocol {
|
|
|
8578
8549
|
}
|
|
8579
8550
|
|
|
8580
8551
|
// node_modules/@modelcontextprotocol/sdk/dist/esm/client/stdio.js
|
|
8581
|
-
var import_cross_spawn = __toESM(require_cross_spawn());
|
|
8582
|
-
|
|
8583
|
-
|
|
8552
|
+
var import_cross_spawn = __toESM(require_cross_spawn(), 1);
|
|
8553
|
+
import process2 from "node:process";
|
|
8554
|
+
import { PassThrough } from "node:stream";
|
|
8584
8555
|
|
|
8585
8556
|
// node_modules/@modelcontextprotocol/sdk/dist/esm/shared/stdio.js
|
|
8586
8557
|
class ReadBuffer {
|
|
@@ -8613,7 +8584,7 @@ function serializeMessage(message) {
|
|
|
8613
8584
|
}
|
|
8614
8585
|
|
|
8615
8586
|
// node_modules/@modelcontextprotocol/sdk/dist/esm/client/stdio.js
|
|
8616
|
-
var DEFAULT_INHERITED_ENV_VARS =
|
|
8587
|
+
var DEFAULT_INHERITED_ENV_VARS = process2.platform === "win32" ? [
|
|
8617
8588
|
"APPDATA",
|
|
8618
8589
|
"HOMEDRIVE",
|
|
8619
8590
|
"HOMEPATH",
|
|
@@ -8629,7 +8600,7 @@ var DEFAULT_INHERITED_ENV_VARS = import_node_process.default.platform === "win32
|
|
|
8629
8600
|
function getDefaultEnvironment() {
|
|
8630
8601
|
const env = {};
|
|
8631
8602
|
for (const key of DEFAULT_INHERITED_ENV_VARS) {
|
|
8632
|
-
const value =
|
|
8603
|
+
const value = process2.env[key];
|
|
8633
8604
|
if (value === undefined) {
|
|
8634
8605
|
continue;
|
|
8635
8606
|
}
|
|
@@ -8648,7 +8619,7 @@ class StdioClientTransport {
|
|
|
8648
8619
|
this._stderrStream = null;
|
|
8649
8620
|
this._serverParams = server;
|
|
8650
8621
|
if (server.stderr === "pipe" || server.stderr === "overlapped") {
|
|
8651
|
-
this._stderrStream = new
|
|
8622
|
+
this._stderrStream = new PassThrough;
|
|
8652
8623
|
}
|
|
8653
8624
|
}
|
|
8654
8625
|
async start() {
|
|
@@ -8662,7 +8633,7 @@ class StdioClientTransport {
|
|
|
8662
8633
|
stdio: ["pipe", "pipe", (_c = this._serverParams.stderr) !== null && _c !== undefined ? _c : "inherit"],
|
|
8663
8634
|
shell: false,
|
|
8664
8635
|
signal: this._abortController.signal,
|
|
8665
|
-
windowsHide:
|
|
8636
|
+
windowsHide: process2.platform === "win32" && isElectron(),
|
|
8666
8637
|
cwd: this._serverParams.cwd
|
|
8667
8638
|
});
|
|
8668
8639
|
this._process.on("error", (error2) => {
|
|
@@ -8741,11 +8712,11 @@ class StdioClientTransport {
|
|
|
8741
8712
|
}
|
|
8742
8713
|
}
|
|
8743
8714
|
function isElectron() {
|
|
8744
|
-
return "type" in
|
|
8715
|
+
return "type" in process2;
|
|
8745
8716
|
}
|
|
8746
8717
|
|
|
8747
8718
|
// src/mcp-client.ts
|
|
8748
|
-
|
|
8719
|
+
import readline from "readline/promises";
|
|
8749
8720
|
|
|
8750
8721
|
class MCPClient {
|
|
8751
8722
|
mcp;
|
|
@@ -8828,7 +8799,7 @@ class MCPClient {
|
|
|
8828
8799
|
`);
|
|
8829
8800
|
}
|
|
8830
8801
|
async chatLoop() {
|
|
8831
|
-
const rl =
|
|
8802
|
+
const rl = readline.createInterface({
|
|
8832
8803
|
input: process.stdin,
|
|
8833
8804
|
output: process.stdout
|
|
8834
8805
|
});
|
|
@@ -8868,3 +8839,6 @@ async function main(api_key) {
|
|
|
8868
8839
|
process.exit(0);
|
|
8869
8840
|
}
|
|
8870
8841
|
}
|
|
8842
|
+
export {
|
|
8843
|
+
main
|
|
8844
|
+
};
|