monomind 1.5.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/monomind.js +50 -0
- package/package.json +64 -0
package/bin/monomind.js
ADDED
|
@@ -0,0 +1,50 @@
|
|
|
1
|
+
#!/usr/bin/env node
|
|
2
|
+
// Monomind CLI - thin wrapper around @monomind/cli with monomind branding
|
|
3
|
+
import { fileURLToPath, pathToFileURL } from 'node:url';
|
|
4
|
+
import { dirname, resolve, join } from 'node:path';
|
|
5
|
+
import { existsSync } from 'node:fs';
|
|
6
|
+
|
|
7
|
+
const __dirname = dirname(fileURLToPath(import.meta.url));
|
|
8
|
+
|
|
9
|
+
// Walk up from monomind/bin/ to find @monomind/cli in node_modules
|
|
10
|
+
function findCliPath() {
|
|
11
|
+
let dir = resolve(__dirname, '..');
|
|
12
|
+
for (let i = 0; i < 10; i++) {
|
|
13
|
+
const candidate = join(dir, 'node_modules', '@monomind', 'cli', 'bin', 'cli.js');
|
|
14
|
+
if (existsSync(candidate)) return dir;
|
|
15
|
+
const parent = dirname(dir);
|
|
16
|
+
if (parent === dir) break;
|
|
17
|
+
dir = parent;
|
|
18
|
+
}
|
|
19
|
+
return null;
|
|
20
|
+
}
|
|
21
|
+
|
|
22
|
+
// Convert path to file:// URL for cross-platform ESM import (Windows requires this)
|
|
23
|
+
function toImportURL(filePath) {
|
|
24
|
+
return pathToFileURL(filePath).href;
|
|
25
|
+
}
|
|
26
|
+
|
|
27
|
+
const pkgDir = findCliPath();
|
|
28
|
+
const cliBase = pkgDir
|
|
29
|
+
? join(pkgDir, 'node_modules', '@monomind', 'cli')
|
|
30
|
+
: resolve(__dirname, '../../packages/@monomind/cli');
|
|
31
|
+
|
|
32
|
+
// MCP mode: delegate to cli.js directly (branding irrelevant for JSON-RPC)
|
|
33
|
+
const cliArgs = process.argv.slice(2);
|
|
34
|
+
const isExplicitMCP = cliArgs.length >= 1 && cliArgs[0] === 'mcp' && (cliArgs.length === 1 || cliArgs[1] === 'start');
|
|
35
|
+
const isMCPMode = !process.stdin.isTTY && (process.argv.length === 2 || isExplicitMCP);
|
|
36
|
+
|
|
37
|
+
if (isMCPMode) {
|
|
38
|
+
await import(toImportURL(join(cliBase, 'bin', 'cli.js')));
|
|
39
|
+
} else {
|
|
40
|
+
// CLI mode: use monomind branding
|
|
41
|
+
const { CLI } = await import(toImportURL(join(cliBase, 'dist', 'src', 'index.js')));
|
|
42
|
+
const cli = new CLI({
|
|
43
|
+
name: 'monomind',
|
|
44
|
+
description: 'Monomind - AI Agent Orchestration Platform',
|
|
45
|
+
});
|
|
46
|
+
cli.run().catch((error) => {
|
|
47
|
+
console.error('Fatal error:', error.message);
|
|
48
|
+
process.exit(1);
|
|
49
|
+
});
|
|
50
|
+
}
|
package/package.json
ADDED
|
@@ -0,0 +1,64 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "monomind",
|
|
3
|
+
"version": "1.5.3",
|
|
4
|
+
"description": "Monomind - Enterprise AI agent orchestration platform. Deploy 60+ specialized agents in coordinated swarms with self-learning, fault-tolerant consensus, vector memory, and MCP integration",
|
|
5
|
+
"main": "bin/monomind.js",
|
|
6
|
+
"type": "module",
|
|
7
|
+
"bin": {
|
|
8
|
+
"monomind": "./bin/monomind.js"
|
|
9
|
+
},
|
|
10
|
+
"homepage": "https://github.com/nokhodian/monomind#readme",
|
|
11
|
+
"bugs": {
|
|
12
|
+
"url": "https://github.com/nokhodian/monomind/issues",
|
|
13
|
+
"email": "nokhodian@gmail.com"
|
|
14
|
+
},
|
|
15
|
+
"funding": {
|
|
16
|
+
"type": "github",
|
|
17
|
+
"url": "https://github.com/sponsors/nokhodian"
|
|
18
|
+
},
|
|
19
|
+
"files": [
|
|
20
|
+
"bin/**",
|
|
21
|
+
"README.md",
|
|
22
|
+
"LICENSE"
|
|
23
|
+
],
|
|
24
|
+
"scripts": {},
|
|
25
|
+
"dependencies": {
|
|
26
|
+
"@monomind/cli": ">=1.0.0"
|
|
27
|
+
},
|
|
28
|
+
"engines": {
|
|
29
|
+
"node": ">=20.0.0"
|
|
30
|
+
},
|
|
31
|
+
"repository": {
|
|
32
|
+
"type": "git",
|
|
33
|
+
"url": "https://github.com/nokhodian/monomind.git",
|
|
34
|
+
"directory": "monomind"
|
|
35
|
+
},
|
|
36
|
+
"keywords": [
|
|
37
|
+
"monomind",
|
|
38
|
+
"claude",
|
|
39
|
+
"claude-code",
|
|
40
|
+
"anthropic",
|
|
41
|
+
"ai",
|
|
42
|
+
"ai-agents",
|
|
43
|
+
"multi-agent",
|
|
44
|
+
"agent-orchestration",
|
|
45
|
+
"swarm-intelligence",
|
|
46
|
+
"swarm",
|
|
47
|
+
"mcp",
|
|
48
|
+
"model-context-protocol",
|
|
49
|
+
"cli",
|
|
50
|
+
"developer-tools",
|
|
51
|
+
"enterprise",
|
|
52
|
+
"self-learning"
|
|
53
|
+
],
|
|
54
|
+
"author": {
|
|
55
|
+
"name": "nokhodian",
|
|
56
|
+
"email": "nokhodian@gmail.com",
|
|
57
|
+
"url": "https://github.com/nokhodian"
|
|
58
|
+
},
|
|
59
|
+
"license": "MIT",
|
|
60
|
+
"publishConfig": {
|
|
61
|
+
"access": "public",
|
|
62
|
+
"tag": "latest"
|
|
63
|
+
}
|
|
64
|
+
}
|