lotus-wisdom-mcp 0.8.4 → 0.8.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.
Files changed (3) hide show
  1. package/cli.js +6 -1
  2. package/dist/bundle.js +12 -11
  3. package/package.json +1 -1
package/cli.js CHANGED
@@ -1,3 +1,8 @@
1
1
  #!/usr/bin/env node
2
2
 
3
- import './dist/bundle.js';
3
+ import { startStdioServer } from './dist/bundle.js';
4
+
5
+ startStdioServer().catch((error) => {
6
+ console.error('Fatal error running server:', error);
7
+ process.exit(1);
8
+ });
package/dist/bundle.js CHANGED
@@ -33806,13 +33806,13 @@ var zodToJsonSchema = (schema, options) => {
33806
33806
  }, true) ?? parseAnyDef(refs)
33807
33807
  }), {}) : void 0;
33808
33808
  const name = typeof options === "string" ? options : options?.nameStrategy === "title" ? void 0 : options?.name;
33809
- const main2 = parseDef(schema._def, name === void 0 ? refs : {
33809
+ const main = parseDef(schema._def, name === void 0 ? refs : {
33810
33810
  ...refs,
33811
33811
  currentPath: [...refs.basePath, refs.definitionPath, name]
33812
33812
  }, false) ?? parseAnyDef(refs);
33813
33813
  const title = typeof options === "object" && options.name !== void 0 && options.nameStrategy === "title" ? options.name : void 0;
33814
33814
  if (title !== void 0) {
33815
- main2.title = title;
33815
+ main.title = title;
33816
33816
  }
33817
33817
  if (refs.flags.hasReferencedOpenAiAnyType) {
33818
33818
  if (!definitions) {
@@ -33833,9 +33833,9 @@ var zodToJsonSchema = (schema, options) => {
33833
33833
  }
33834
33834
  }
33835
33835
  const combined = name === void 0 ? definitions ? {
33836
- ...main2,
33836
+ ...main,
33837
33837
  [refs.definitionPath]: definitions
33838
- } : main2 : {
33838
+ } : main : {
33839
33839
  $ref: [
33840
33840
  ...refs.$refStrategy === "relative" ? [] : refs.basePath,
33841
33841
  refs.definitionPath,
@@ -33843,7 +33843,7 @@ var zodToJsonSchema = (schema, options) => {
33843
33843
  ].join("/"),
33844
33844
  [refs.definitionPath]: {
33845
33845
  ...definitions,
33846
- [name]: main2
33846
+ [name]: main
33847
33847
  }
33848
33848
  };
33849
33849
  if (refs.target === "jsonSchema7") {
@@ -36590,7 +36590,7 @@ var StdioServerTransport = class {
36590
36590
  };
36591
36591
 
36592
36592
  // index.ts
36593
- import { readFileSync } from "fs";
36593
+ import { existsSync, readFileSync, realpathSync } from "fs";
36594
36594
  import { dirname, join } from "path";
36595
36595
  import { fileURLToPath } from "url";
36596
36596
 
@@ -36833,7 +36833,7 @@ function structuredContentFor(result) {
36833
36833
  }
36834
36834
 
36835
36835
  // src/shared/version.ts
36836
- var VERSION = "0.8.4";
36836
+ var VERSION = "0.8.5";
36837
36837
 
36838
36838
  // src/shared/tool-defs.ts
36839
36839
  var SERVER_NAME = "lotus-wisdom";
@@ -37078,19 +37078,20 @@ function createServer() {
37078
37078
  registerLotusPrompts(server);
37079
37079
  return server;
37080
37080
  }
37081
- async function main() {
37081
+ async function startStdioServer() {
37082
37082
  const server = createServer();
37083
37083
  const transport = new StdioServerTransport();
37084
37084
  await server.connect(transport);
37085
37085
  console.error(`Lotus Wisdom MCP Server v${VERSION} running`);
37086
37086
  }
37087
- var isDirectRun = process.argv[1] && (process.argv[1].endsWith("bundle.js") || process.argv[1].endsWith("index.js") || process.argv[1].endsWith("index.ts") || process.argv[1].endsWith("cli.js"));
37087
+ var isDirectRun = process.argv[1] && existsSync(process.argv[1]) && realpathSync(process.argv[1]) === fileURLToPath(import.meta.url);
37088
37088
  if (isDirectRun) {
37089
- main().catch((error62) => {
37089
+ startStdioServer().catch((error62) => {
37090
37090
  console.error("Fatal error running server:", error62);
37091
37091
  process.exit(1);
37092
37092
  });
37093
37093
  }
37094
37094
  export {
37095
- createServer as default
37095
+ createServer as default,
37096
+ startStdioServer
37096
37097
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "lotus-wisdom-mcp",
3
- "version": "0.8.4",
3
+ "version": "0.8.5",
4
4
  "description": "Contemplative reasoning MCP server — Lotus Sutra wisdom framework with interactive ext-apps journey visualization.",
5
5
  "main": "dist/bundle.js",
6
6
  "module": "index.ts",