@lumenflow/mcp 3.1.2 → 3.2.0
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/package.json +5 -5
- package/dist/bin.d.ts +0 -16
- package/dist/bin.d.ts.map +0 -1
- package/dist/bin.js.map +0 -1
- package/dist/cli-runner.d.ts +0 -58
- package/dist/cli-runner.d.ts.map +0 -1
- package/dist/cli-runner.js +0 -164
- package/dist/cli-runner.js.map +0 -1
- package/dist/index.d.ts +0 -37
- package/dist/index.d.ts.map +0 -1
- package/dist/index.js.map +0 -1
- package/dist/mcp-constants.d.ts +0 -173
- package/dist/mcp-constants.d.ts.map +0 -1
- package/dist/mcp-constants.js +0 -193
- package/dist/mcp-constants.js.map +0 -1
- package/dist/resources.d.ts +0 -53
- package/dist/resources.d.ts.map +0 -1
- package/dist/resources.js +0 -131
- package/dist/resources.js.map +0 -1
- package/dist/runtime-cache.d.ts +0 -7
- package/dist/runtime-cache.d.ts.map +0 -1
- package/dist/runtime-cache.js +0 -28
- package/dist/runtime-cache.js.map +0 -1
- package/dist/runtime-tool-resolver.constants.d.ts +0 -33
- package/dist/runtime-tool-resolver.constants.d.ts.map +0 -1
- package/dist/runtime-tool-resolver.constants.js +0 -35
- package/dist/runtime-tool-resolver.constants.js.map +0 -1
- package/dist/runtime-tool-resolver.d.ts +0 -5
- package/dist/runtime-tool-resolver.d.ts.map +0 -1
- package/dist/runtime-tool-resolver.js +0 -2030
- package/dist/runtime-tool-resolver.js.map +0 -1
- package/dist/server.d.ts +0 -58
- package/dist/server.d.ts.map +0 -1
- package/dist/server.js +0 -219
- package/dist/server.js.map +0 -1
- package/dist/tools/agent-tools.d.ts +0 -18
- package/dist/tools/agent-tools.d.ts.map +0 -1
- package/dist/tools/agent-tools.js +0 -235
- package/dist/tools/agent-tools.js.map +0 -1
- package/dist/tools/context-tools.d.ts +0 -13
- package/dist/tools/context-tools.d.ts.map +0 -1
- package/dist/tools/context-tools.js +0 -58
- package/dist/tools/context-tools.js.map +0 -1
- package/dist/tools/flow-tools.d.ts +0 -22
- package/dist/tools/flow-tools.d.ts.map +0 -1
- package/dist/tools/flow-tools.js +0 -130
- package/dist/tools/flow-tools.js.map +0 -1
- package/dist/tools/initiative-tools.d.ts +0 -34
- package/dist/tools/initiative-tools.d.ts.map +0 -1
- package/dist/tools/initiative-tools.js +0 -420
- package/dist/tools/initiative-tools.js.map +0 -1
- package/dist/tools/memory-tools.d.ts +0 -58
- package/dist/tools/memory-tools.d.ts.map +0 -1
- package/dist/tools/memory-tools.js +0 -523
- package/dist/tools/memory-tools.js.map +0 -1
- package/dist/tools/orchestration-tools.d.ts +0 -18
- package/dist/tools/orchestration-tools.d.ts.map +0 -1
- package/dist/tools/orchestration-tools.js +0 -202
- package/dist/tools/orchestration-tools.js.map +0 -1
- package/dist/tools/parity-tools.d.ts +0 -122
- package/dist/tools/parity-tools.d.ts.map +0 -1
- package/dist/tools/parity-tools.js +0 -1479
- package/dist/tools/parity-tools.js.map +0 -1
- package/dist/tools/runtime-task-constants.d.ts +0 -19
- package/dist/tools/runtime-task-constants.d.ts.map +0 -1
- package/dist/tools/runtime-task-constants.js +0 -21
- package/dist/tools/runtime-task-constants.js.map +0 -1
- package/dist/tools/runtime-task-tools.d.ts +0 -10
- package/dist/tools/runtime-task-tools.d.ts.map +0 -1
- package/dist/tools/runtime-task-tools.js +0 -116
- package/dist/tools/runtime-task-tools.js.map +0 -1
- package/dist/tools/setup-tools.d.ts +0 -34
- package/dist/tools/setup-tools.d.ts.map +0 -1
- package/dist/tools/setup-tools.js +0 -254
- package/dist/tools/setup-tools.js.map +0 -1
- package/dist/tools/validation-tools.d.ts +0 -26
- package/dist/tools/validation-tools.d.ts.map +0 -1
- package/dist/tools/validation-tools.js +0 -180
- package/dist/tools/validation-tools.js.map +0 -1
- package/dist/tools/wu-tools.d.ts +0 -101
- package/dist/tools/wu-tools.d.ts.map +0 -1
- package/dist/tools/wu-tools.js +0 -964
- package/dist/tools/wu-tools.js.map +0 -1
- package/dist/tools-shared.d.ts +0 -250
- package/dist/tools-shared.d.ts.map +0 -1
- package/dist/tools-shared.js +0 -403
- package/dist/tools-shared.js.map +0 -1
- package/dist/tools.d.ts +0 -97
- package/dist/tools.d.ts.map +0 -1
- package/dist/tools.js +0 -248
- package/dist/tools.js.map +0 -1
- package/dist/worktree-enforcement.d.ts +0 -32
- package/dist/worktree-enforcement.d.ts.map +0 -1
- package/dist/worktree-enforcement.js +0 -154
- package/dist/worktree-enforcement.js.map +0 -1
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@lumenflow/mcp",
|
|
3
|
-
"version": "3.
|
|
3
|
+
"version": "3.2.0",
|
|
4
4
|
"description": "MCP stdio server for LumenFlow workflow framework",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"lumenflow",
|
|
@@ -53,10 +53,10 @@
|
|
|
53
53
|
"dependencies": {
|
|
54
54
|
"@modelcontextprotocol/sdk": "^1.26.0",
|
|
55
55
|
"zod": "^4.3.6",
|
|
56
|
-
"@lumenflow/kernel": "3.
|
|
57
|
-
"@lumenflow/
|
|
58
|
-
"@lumenflow/
|
|
59
|
-
"@lumenflow/
|
|
56
|
+
"@lumenflow/kernel": "3.2.0",
|
|
57
|
+
"@lumenflow/metrics": "3.2.0",
|
|
58
|
+
"@lumenflow/core": "3.2.0",
|
|
59
|
+
"@lumenflow/memory": "3.2.0"
|
|
60
60
|
},
|
|
61
61
|
"devDependencies": {
|
|
62
62
|
"@vitest/coverage-v8": "^4.0.18",
|
package/dist/bin.d.ts
DELETED
|
@@ -1,16 +0,0 @@
|
|
|
1
|
-
#!/usr/bin/env node
|
|
2
|
-
/**
|
|
3
|
-
* @file bin.ts
|
|
4
|
-
* @description CLI entry point for @lumenflow/mcp
|
|
5
|
-
*
|
|
6
|
-
* WU-1412: MCP server runs via npx @lumenflow/mcp over stdio
|
|
7
|
-
*
|
|
8
|
-
* Usage:
|
|
9
|
-
* npx @lumenflow/mcp
|
|
10
|
-
*
|
|
11
|
-
* Environment variables:
|
|
12
|
-
* LUMENFLOW_PROJECT_ROOT - Project root directory
|
|
13
|
-
* LUMENFLOW_MCP_LOG_LEVEL - Log level (debug, info, warn, error)
|
|
14
|
-
*/
|
|
15
|
-
export {};
|
|
16
|
-
//# sourceMappingURL=bin.d.ts.map
|
package/dist/bin.d.ts.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"bin.d.ts","sourceRoot":"","sources":["../src/bin.ts"],"names":[],"mappings":";AAGA;;;;;;;;;;;;GAYG"}
|
package/dist/bin.js.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"bin.js","sourceRoot":"","sources":["../src/bin.ts"],"names":[],"mappings":";AACA,iCAAiC;AACjC,yCAAyC;AACzC;;;;;;;;;;;;GAYG;AAEH,OAAO,EAAE,eAAe,EAAiB,MAAM,aAAa,CAAC;AAE7D;;GAEG;AACH,SAAS,GAAG,CAAC,OAAe;IAC1B,OAAO,CAAC,MAAM,CAAC,KAAK,CAAC,GAAG,OAAO,IAAI,CAAC,CAAC;AACvC,CAAC;AAED;;GAEG;AACH,KAAK,UAAU,IAAI;IACjB,MAAM,WAAW,GAAG,OAAO,CAAC,GAAG,CAAC,sBAAsB,CAAC;IACvD,MAAM,QAAQ,GAAG,OAAO,CAAC,GAAG,CAAC,uBAA+C,CAAC;IAE7E,MAAM,MAAM,GAAG,eAAe,CAAC;QAC7B,WAAW;QACX,QAAQ;KACT,CAAC,CAAC;IAEH,0DAA0D;IAC1D,IAAI,QAAQ,KAAK,OAAO,IAAI,QAAQ,KAAK,MAAM,EAAE,CAAC;QAChD,GAAG,CAAC,yCAAyC,CAAC,CAAC;QAC/C,GAAG,CAAC,kCAAkC,MAAM,CAAC,MAAM,CAAC,WAAW,EAAE,CAAC,CAAC;QACnE,GAAG,CAAC,+BAA+B,MAAM,CAAC,MAAM,CAAC,QAAQ,EAAE,C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C,GAAG,YAAY,KAAK,CAAC,CAAC,CAAC,GAAG,CAAC,OAAO,CAAC,CAAC,CAAC,MAAM,CAAC,GAAG,CAAC,EAAE,CAAC,CAAC;IACzF,OAAO,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC;AAClB,CAAC,CAAC,CAAC"}
|
package/dist/cli-runner.d.ts
DELETED
|
@@ -1,58 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* CLI runner options
|
|
3
|
-
*/
|
|
4
|
-
export interface CliRunnerOptions {
|
|
5
|
-
/** Working directory for command execution (defaults to process.cwd()) */
|
|
6
|
-
projectRoot?: string;
|
|
7
|
-
/** Command timeout in milliseconds (defaults to 120000 = 2 minutes) */
|
|
8
|
-
timeout?: number;
|
|
9
|
-
/** Additional environment variables */
|
|
10
|
-
env?: Record<string, string>;
|
|
11
|
-
}
|
|
12
|
-
/**
|
|
13
|
-
* CLI runner result
|
|
14
|
-
*/
|
|
15
|
-
export interface CliRunnerResult {
|
|
16
|
-
/** Whether the command succeeded (exit code 0) */
|
|
17
|
-
success: boolean;
|
|
18
|
-
/** Standard output */
|
|
19
|
-
stdout: string;
|
|
20
|
-
/** Standard error output */
|
|
21
|
-
stderr: string;
|
|
22
|
-
/** Exit code (if available) */
|
|
23
|
-
exitCode?: number;
|
|
24
|
-
/** Error object (if command failed) */
|
|
25
|
-
error?: {
|
|
26
|
-
message: string;
|
|
27
|
-
code?: string | number;
|
|
28
|
-
};
|
|
29
|
-
}
|
|
30
|
-
/**
|
|
31
|
-
* Build ordered command candidates (canonical first, then compatibility aliases).
|
|
32
|
-
*/
|
|
33
|
-
export declare function getCommandCandidates(command: string): string[];
|
|
34
|
-
/**
|
|
35
|
-
* Execute a LumenFlow CLI command
|
|
36
|
-
*
|
|
37
|
-
* @param command - CLI command to execute (e.g., 'wu:status', 'wu:claim', 'gates')
|
|
38
|
-
* @param args - Command arguments
|
|
39
|
-
* @param options - Execution options
|
|
40
|
-
* @returns Command execution result
|
|
41
|
-
*
|
|
42
|
-
* @example
|
|
43
|
-
* // Get WU status
|
|
44
|
-
* const result = await runCliCommand('wu:status', ['--id', 'WU-1412', '--json']);
|
|
45
|
-
*
|
|
46
|
-
* @example
|
|
47
|
-
* // Run gates
|
|
48
|
-
* const result = await runCliCommand('gates', ['--docs-only']);
|
|
49
|
-
*/
|
|
50
|
-
export declare function runCliCommand(command: string, args?: string[], options?: CliRunnerOptions): Promise<CliRunnerResult>;
|
|
51
|
-
/**
|
|
52
|
-
* Parse JSON output from a CLI command
|
|
53
|
-
*
|
|
54
|
-
* @param result - CLI runner result
|
|
55
|
-
* @returns Parsed JSON data or null if parsing fails
|
|
56
|
-
*/
|
|
57
|
-
export declare function parseJsonOutput<T>(result: CliRunnerResult): T | null;
|
|
58
|
-
//# sourceMappingURL=cli-runner.d.ts.map
|
package/dist/cli-runner.d.ts.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"cli-runner.d.ts","sourceRoot":"","sources":["../src/cli-runner.ts"],"names":[],"mappings":"AAsBA;;GAEG;AACH,MAAM,WAAW,gBAAgB;IAC/B,0EAA0E;IAC1E,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,uEAAuE;IACvE,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,uCAAuC;IACvC,GAAG,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC;CAC9B;AAED;;GAEG;AACH,MAAM,WAAW,eAAe;IAC9B,kDAAkD;IAClD,OAAO,EAAE,OAAO,CAAC;IACjB,sBAAsB;IACtB,MAAM,EAAE,MAAM,CAAC;IACf,4BAA4B;IAC5B,MAAM,EAAE,MAAM,CAAC;IACf,+BAA+B;IAC/B,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,uCAAuC;IACvC,KAAK,CAAC,EAAE;QACN,OAAO,EAAE,MAAM,CAAC;QAChB,IAAI,CAAC,EAAE,MAAM,GAAG,MAAM,CAAC;KACxB,CAAC;CACH;AAwBD;;GAEG;AACH,wBAAgB,oBAAoB,CAAC,OAAO,EAAE,MAAM,GAAG,MAAM,EAAE,CAQ9D;AAwED;;;;;;;;;;;;;;;GAeG;AACH,wBAAsB,aAAa,CACjC,OAAO,EAAE,MAAM,EACf,IAAI,GAAE,MAAM,EAAO,EACnB,OAAO,GAAE,gBAAqB,GAC7B,OAAO,CAAC,eAAe,CAAC,CA6B1B;AAED;;;;;GAKG;AACH,wBAAgB,eAAe,CAAC,CAAC,EAAE,MAAM,EAAE,eAAe,GAAG,CAAC,GAAG,IAAI,CAUpE"}
|
package/dist/cli-runner.js
DELETED
|
@@ -1,164 +0,0 @@
|
|
|
1
|
-
// Copyright (c) 2026 Hellmai Ltd
|
|
2
|
-
// SPDX-License-Identifier: AGPL-3.0-only
|
|
3
|
-
/**
|
|
4
|
-
* @file cli-runner.ts
|
|
5
|
-
* @description CLI runner utility for shelling out to LumenFlow CLI commands
|
|
6
|
-
*
|
|
7
|
-
* WU-1412: MCP server uses CLI shell-out for write operations (wu_create, wu_claim, wu_done, gates_run)
|
|
8
|
-
* Read operations use @lumenflow/core directly for better performance and type safety.
|
|
9
|
-
*
|
|
10
|
-
* This module provides a safe, consistent way to execute CLI commands with:
|
|
11
|
-
* - Timeout support
|
|
12
|
-
* - Project root configuration
|
|
13
|
-
* - Proper error handling
|
|
14
|
-
* - Structured output
|
|
15
|
-
*/
|
|
16
|
-
import { execFile } from 'node:child_process';
|
|
17
|
-
import { promisify } from 'node:util';
|
|
18
|
-
const execFileAsync = promisify(execFile);
|
|
19
|
-
/**
|
|
20
|
-
* Default timeout for CLI commands (2 minutes)
|
|
21
|
-
*/
|
|
22
|
-
const DEFAULT_TIMEOUT_MS = 120000;
|
|
23
|
-
/**
|
|
24
|
-
* Canonical-first command fallback matrix.
|
|
25
|
-
*
|
|
26
|
-
* When a canonical command is unavailable in a target project (missing script),
|
|
27
|
-
* retry with compatibility aliases to preserve low-cost backwards compatibility.
|
|
28
|
-
*/
|
|
29
|
-
const COMMAND_FALLBACKS = {
|
|
30
|
-
'agent:session-end': ['agent:session:end'],
|
|
31
|
-
'initiative:bulk-assign': ['initiative:bulk-assign-wus'],
|
|
32
|
-
lumenflow: ['lumenflow:init', 'lumenflow-init'],
|
|
33
|
-
gates: ['lumenflow:gates', 'lumenflow-gates'],
|
|
34
|
-
validate: ['lumenflow:validate', 'lumenflow-validate'],
|
|
35
|
-
'lumenflow:release': ['release'],
|
|
36
|
-
'docs:sync': ['lumenflow:docs-sync', 'lumenflow-docs-sync'],
|
|
37
|
-
'sync:templates': ['lumenflow:sync-templates', 'lumenflow-sync-templates'],
|
|
38
|
-
};
|
|
39
|
-
/**
|
|
40
|
-
* Build ordered command candidates (canonical first, then compatibility aliases).
|
|
41
|
-
*/
|
|
42
|
-
export function getCommandCandidates(command) {
|
|
43
|
-
const seen = new Set();
|
|
44
|
-
const ordered = [command, ...(COMMAND_FALLBACKS[command] || [])];
|
|
45
|
-
return ordered.filter((candidate) => {
|
|
46
|
-
if (seen.has(candidate))
|
|
47
|
-
return false;
|
|
48
|
-
seen.add(candidate);
|
|
49
|
-
return true;
|
|
50
|
-
});
|
|
51
|
-
}
|
|
52
|
-
/**
|
|
53
|
-
* Returns true when the command failed because the script/command wasn't found.
|
|
54
|
-
*/
|
|
55
|
-
function isMissingCommandFailure(result) {
|
|
56
|
-
const detail = `${result.stderr}\n${result.error?.message || ''}`;
|
|
57
|
-
return (/ERR_PNPM_NO_SCRIPT/i.test(detail) ||
|
|
58
|
-
/Command\s+["'][^"']+["']\s+not\s+found/i.test(detail) ||
|
|
59
|
-
/Unknown command/i.test(detail) ||
|
|
60
|
-
/No matching command found/i.test(detail));
|
|
61
|
-
}
|
|
62
|
-
/**
|
|
63
|
-
* Execute a single pnpm command without fallback behavior.
|
|
64
|
-
*/
|
|
65
|
-
async function runSingleCommand(command, args = [], options = {}) {
|
|
66
|
-
const projectRoot = options.projectRoot || process.cwd();
|
|
67
|
-
const timeout = options.timeout ?? DEFAULT_TIMEOUT_MS;
|
|
68
|
-
// Use pnpm to run the command
|
|
69
|
-
const pnpmPath = 'pnpm';
|
|
70
|
-
const pnpmArgs = [command, ...args];
|
|
71
|
-
try {
|
|
72
|
-
const { stdout, stderr } = await execFileAsync(pnpmPath, pnpmArgs, {
|
|
73
|
-
cwd: projectRoot,
|
|
74
|
-
timeout,
|
|
75
|
-
env: {
|
|
76
|
-
...process.env,
|
|
77
|
-
...options.env,
|
|
78
|
-
// Ensure we're in non-interactive mode
|
|
79
|
-
CI: 'true',
|
|
80
|
-
// Pass through project root
|
|
81
|
-
LUMENFLOW_PROJECT_ROOT: projectRoot,
|
|
82
|
-
},
|
|
83
|
-
maxBuffer: 10 * 1024 * 1024, // 10MB buffer
|
|
84
|
-
});
|
|
85
|
-
return {
|
|
86
|
-
success: true,
|
|
87
|
-
stdout: stdout.trim(),
|
|
88
|
-
stderr: stderr.trim(),
|
|
89
|
-
exitCode: 0,
|
|
90
|
-
};
|
|
91
|
-
}
|
|
92
|
-
catch (err) {
|
|
93
|
-
const error = err;
|
|
94
|
-
return {
|
|
95
|
-
success: false,
|
|
96
|
-
stdout: error.stdout?.trim() || '',
|
|
97
|
-
stderr: error.stderr?.trim() || '',
|
|
98
|
-
exitCode: typeof error.code === 'number' ? error.code : 1,
|
|
99
|
-
error: {
|
|
100
|
-
message: error.message,
|
|
101
|
-
code: error.code,
|
|
102
|
-
},
|
|
103
|
-
};
|
|
104
|
-
}
|
|
105
|
-
}
|
|
106
|
-
/**
|
|
107
|
-
* Execute a LumenFlow CLI command
|
|
108
|
-
*
|
|
109
|
-
* @param command - CLI command to execute (e.g., 'wu:status', 'wu:claim', 'gates')
|
|
110
|
-
* @param args - Command arguments
|
|
111
|
-
* @param options - Execution options
|
|
112
|
-
* @returns Command execution result
|
|
113
|
-
*
|
|
114
|
-
* @example
|
|
115
|
-
* // Get WU status
|
|
116
|
-
* const result = await runCliCommand('wu:status', ['--id', 'WU-1412', '--json']);
|
|
117
|
-
*
|
|
118
|
-
* @example
|
|
119
|
-
* // Run gates
|
|
120
|
-
* const result = await runCliCommand('gates', ['--docs-only']);
|
|
121
|
-
*/
|
|
122
|
-
export async function runCliCommand(command, args = [], options = {}) {
|
|
123
|
-
const candidates = getCommandCandidates(command);
|
|
124
|
-
let lastFailure = null;
|
|
125
|
-
for (let i = 0; i < candidates.length; i++) {
|
|
126
|
-
const candidate = candidates[i];
|
|
127
|
-
if (!candidate)
|
|
128
|
-
continue;
|
|
129
|
-
const result = await runSingleCommand(candidate, args, options);
|
|
130
|
-
if (result.success) {
|
|
131
|
-
return result;
|
|
132
|
-
}
|
|
133
|
-
lastFailure = result;
|
|
134
|
-
const hasFallbackRemaining = i < candidates.length - 1;
|
|
135
|
-
if (!hasFallbackRemaining || !isMissingCommandFailure(result)) {
|
|
136
|
-
return result;
|
|
137
|
-
}
|
|
138
|
-
}
|
|
139
|
-
return (lastFailure || {
|
|
140
|
-
success: false,
|
|
141
|
-
stdout: '',
|
|
142
|
-
stderr: 'Command execution failed',
|
|
143
|
-
exitCode: 1,
|
|
144
|
-
error: { message: 'Command execution failed' },
|
|
145
|
-
});
|
|
146
|
-
}
|
|
147
|
-
/**
|
|
148
|
-
* Parse JSON output from a CLI command
|
|
149
|
-
*
|
|
150
|
-
* @param result - CLI runner result
|
|
151
|
-
* @returns Parsed JSON data or null if parsing fails
|
|
152
|
-
*/
|
|
153
|
-
export function parseJsonOutput(result) {
|
|
154
|
-
if (!result.success || !result.stdout) {
|
|
155
|
-
return null;
|
|
156
|
-
}
|
|
157
|
-
try {
|
|
158
|
-
return JSON.parse(result.stdout);
|
|
159
|
-
}
|
|
160
|
-
catch {
|
|
161
|
-
return null;
|
|
162
|
-
}
|
|
163
|
-
}
|
|
164
|
-
//# sourceMappingURL=cli-runner.js.map
|
package/dist/cli-runner.js.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"cli-runner.js","sourceRoot":"","sources":["../src/cli-runner.ts"],"names":[],"mappings":"AAAA,iCAAiC;A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,CAAC;IAED,OAAO,CACL,WAAW,IAAI;QACb,OAAO,EAAE,KAAK;QACd,MAAM,EAAE,EAAE;QACV,MAAM,EAAE,0BAA0B;QAClC,QAAQ,EAAE,CAAC;QACX,KAAK,EAAE,EAAE,OAAO,EAAE,0BAA0B,EAAE;KAC/C,CACF,CAAC;AACJ,CAAC;AAED;;;;;GAKG;AACH,MAAM,UAAU,eAAe,CAAI,MAAuB;IACxD,IAAI,CAAC,MAAM,CAAC,OAAO,IAAI,CAAC,MAAM,CAAC,MAAM,EAAE,CAAC;QACtC,OAAO,IAAI,CAAC;IACd,CAAC;IAED,IAAI,CAAC;QACH,OAAO,IAAI,CAAC,KAAK,CAAC,MAAM,CAAC,MAAM,CAAM,CAAC;IACxC,CAAC;IAAC,MAAM,CAAC;QACP,OAAO,IAAI,CAAC;IACd,CAAC;AACH,CAAC"}
|
package/dist/index.d.ts
DELETED
|
@@ -1,37 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* @lumenflow/mcp - MCP stdio server for LumenFlow workflow framework
|
|
3
|
-
* @module @lumenflow/mcp
|
|
4
|
-
*
|
|
5
|
-
* WU-1412: Provides MCP server with LumenFlow tools and resources.
|
|
6
|
-
*
|
|
7
|
-
* Tools:
|
|
8
|
-
* - context_get: Get current LumenFlow context
|
|
9
|
-
* - wu_list: List all Work Units
|
|
10
|
-
* - wu_status: Get WU status
|
|
11
|
-
* - wu_create: Create a new WU
|
|
12
|
-
* - wu_claim: Claim a WU
|
|
13
|
-
* - wu_done: Complete a WU
|
|
14
|
-
* - gates_run: Run quality gates
|
|
15
|
-
*
|
|
16
|
-
* Resources:
|
|
17
|
-
* - lumenflow://context: Current context
|
|
18
|
-
* - lumenflow://wu/{id}: WU by ID
|
|
19
|
-
* - lumenflow://backlog: Current backlog
|
|
20
|
-
*
|
|
21
|
-
* @example
|
|
22
|
-
* ```typescript
|
|
23
|
-
* import { createMcpServer } from '@lumenflow/mcp';
|
|
24
|
-
*
|
|
25
|
-
* const server = createMcpServer({
|
|
26
|
-
* projectRoot: '/path/to/project',
|
|
27
|
-
* logLevel: 'info',
|
|
28
|
-
* });
|
|
29
|
-
*
|
|
30
|
-
* await server.start();
|
|
31
|
-
* ```
|
|
32
|
-
*/
|
|
33
|
-
export { createMcpServer, type McpServer, type McpServerConfig, type LogLevel } from './server.js';
|
|
34
|
-
export { allTools, contextGetTool, wuListTool, wuStatusTool, wuCreateTool, wuClaimTool, wuDoneTool, gatesRunTool, type ToolDefinition, type ToolResult, } from './tools.js';
|
|
35
|
-
export { allResources, staticResources, resourceTemplates, contextResource, wuResource, backlogResource, type ResourceDefinition, type ResourceResult, } from './resources.js';
|
|
36
|
-
export { runCliCommand, parseJsonOutput, type CliRunnerOptions, type CliRunnerResult, } from './cli-runner.js';
|
|
37
|
-
//# sourceMappingURL=index.d.ts.map
|
package/dist/index.d.ts.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAGA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA+BG;AAGH,OAAO,EAAE,eAAe,EAAE,KAAK,SAAS,EAAE,KAAK,eAAe,EAAE,KAAK,QAAQ,EAAE,MAAM,aAAa,CAAC;AAGnG,OAAO,EACL,QAAQ,EACR,cAAc,EACd,UAAU,EACV,YAAY,EACZ,YAAY,EACZ,WAAW,EACX,UAAU,EACV,YAAY,EACZ,KAAK,cAAc,EACnB,KAAK,UAAU,GAChB,MAAM,YAAY,CAAC;AAGpB,OAAO,EACL,YAAY,EACZ,eAAe,EACf,iBAAiB,EACjB,eAAe,EACf,UAAU,EACV,eAAe,EACf,KAAK,kBAAkB,EACvB,KAAK,cAAc,GACpB,MAAM,gBAAgB,CAAC;AAGxB,OAAO,EACL,aAAa,EACb,eAAe,EACf,KAAK,gBAAgB,EACrB,KAAK,eAAe,GACrB,MAAM,iBAAiB,CAAC"}
|
package/dist/index.js.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,iCAAiC;AACjC,yCAAyC;AAEzC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA+BG;AAEH,SAAS;AACT,OAAO,EAAE,eAAe,EAAuD,MAAM,aAAa,CAAC;AAEnG,QAAQ;AACR,OAAO,EACL,QAAQ,EACR,cAAc,EACd,UAAU,EACV,YAAY,EACZ,YAAY,EACZ,WAAW,EACX,UAAU,EACV,YAAY,GAGb,MAAM,YAAY,CAAC;AAEpB,YAAY;AACZ,OAAO,EACL,YAAY,EACZ,eAAe,EACf,iBAAiB,EACjB,eAAe,EACf,UAAU,EACV,eAAe,GAGhB,MAAM,gBAAgB,CAAC;AAExB,aAAa;AACb,OAAO,EACL,aAAa,EACb,eAAe,GAGhB,MAAM,iBAAiB,CAAC"}
|
package/dist/mcp-constants.d.ts
DELETED
|
@@ -1,173 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* @file mcp-constants.ts
|
|
3
|
-
* @description Typed source-of-truth constants for MCP governed literal families.
|
|
4
|
-
*
|
|
5
|
-
* Governed families:
|
|
6
|
-
* 1. CLI command names — canonical map of all commands dispatched via runCliCommand/executeViaPack
|
|
7
|
-
* 2. Cross-boundary metadata keys — keys used in ExecutionContext.metadata across modules
|
|
8
|
-
*
|
|
9
|
-
* Scoping rule: CLI flags are governed in tools-shared.ts (CliArgs). Only flags
|
|
10
|
-
* appearing in 3 or more tool definitions are centralized there. Tool-local flags
|
|
11
|
-
* (< 3 uses) remain as local string literals.
|
|
12
|
-
*
|
|
13
|
-
* WU-1851: Initial governance module.
|
|
14
|
-
*/
|
|
15
|
-
/**
|
|
16
|
-
* Canonical CLI command name constants.
|
|
17
|
-
*
|
|
18
|
-
* Every string passed to `runCliCommand()`, `executeViaPack()`, or used in
|
|
19
|
-
* `fallback.command` MUST reference a value from this object.
|
|
20
|
-
*
|
|
21
|
-
* Organized by domain to match tool file groupings.
|
|
22
|
-
*/
|
|
23
|
-
export declare const CliCommands: {
|
|
24
|
-
readonly WU_STATUS: "wu:status";
|
|
25
|
-
readonly WU_CREATE: "wu:create";
|
|
26
|
-
readonly WU_CLAIM: "wu:claim";
|
|
27
|
-
readonly WU_SANDBOX: "wu:sandbox";
|
|
28
|
-
readonly WU_DONE: "wu:done";
|
|
29
|
-
readonly WU_BLOCK: "wu:block";
|
|
30
|
-
readonly WU_UNBLOCK: "wu:unblock";
|
|
31
|
-
readonly WU_EDIT: "wu:edit";
|
|
32
|
-
readonly WU_RELEASE: "wu:release";
|
|
33
|
-
readonly WU_RECOVER: "wu:recover";
|
|
34
|
-
readonly WU_REPAIR: "wu:repair";
|
|
35
|
-
readonly WU_DEPS: "wu:deps";
|
|
36
|
-
readonly WU_PREP: "wu:prep";
|
|
37
|
-
readonly WU_PREFLIGHT: "wu:preflight";
|
|
38
|
-
readonly WU_PRUNE: "wu:prune";
|
|
39
|
-
readonly WU_DELETE: "wu:delete";
|
|
40
|
-
readonly WU_CLEANUP: "wu:cleanup";
|
|
41
|
-
readonly WU_BRIEF: "wu:brief";
|
|
42
|
-
readonly WU_DELEGATE: "wu:delegate";
|
|
43
|
-
readonly WU_VALIDATE: "wu:validate";
|
|
44
|
-
readonly WU_INFER_LANE: "wu:infer-lane";
|
|
45
|
-
readonly WU_UNLOCK_LANE: "wu:unlock-lane";
|
|
46
|
-
readonly WU_PROTO: "wu:proto";
|
|
47
|
-
readonly WU_LIST: "wu:list";
|
|
48
|
-
readonly GATES: "gates";
|
|
49
|
-
readonly STATE_BOOTSTRAP: "state:bootstrap";
|
|
50
|
-
readonly STATE_CLEANUP: "state:cleanup";
|
|
51
|
-
readonly STATE_DOCTOR: "state:doctor";
|
|
52
|
-
readonly BACKLOG_PRUNE: "backlog:prune";
|
|
53
|
-
readonly DOCS_SYNC: "docs:sync";
|
|
54
|
-
readonly SYNC_TEMPLATES: "sync:templates";
|
|
55
|
-
readonly LUMENFLOW: "lumenflow";
|
|
56
|
-
readonly LANE_HEALTH: "lane:health";
|
|
57
|
-
readonly LANE_SUGGEST: "lane:suggest";
|
|
58
|
-
readonly SIGNAL_CLEANUP: "signal:cleanup";
|
|
59
|
-
readonly CONFIG_SET: "config:set";
|
|
60
|
-
readonly CONFIG_GET: "config:get";
|
|
61
|
-
readonly FILE_READ: "file:read";
|
|
62
|
-
readonly FILE_WRITE: "file:write";
|
|
63
|
-
readonly FILE_EDIT: "file:edit";
|
|
64
|
-
readonly FILE_DELETE: "file:delete";
|
|
65
|
-
readonly GIT_STATUS: "git:status";
|
|
66
|
-
readonly GIT_DIFF: "git:diff";
|
|
67
|
-
readonly GIT_LOG: "git:log";
|
|
68
|
-
readonly GIT_BRANCH: "git:branch";
|
|
69
|
-
readonly INIT_PLAN: "init:plan";
|
|
70
|
-
readonly PLAN_CREATE: "plan:create";
|
|
71
|
-
readonly PLAN_EDIT: "plan:edit";
|
|
72
|
-
readonly PLAN_LINK: "plan:link";
|
|
73
|
-
readonly PLAN_PROMOTE: "plan:promote";
|
|
74
|
-
readonly LUMENFLOW_DOCTOR: "lumenflow:doctor";
|
|
75
|
-
readonly LUMENFLOW_INTEGRATE: "lumenflow:integrate";
|
|
76
|
-
readonly LUMENFLOW_UPGRADE: "lumenflow:upgrade";
|
|
77
|
-
readonly LUMENFLOW_RELEASE: "lumenflow:release";
|
|
78
|
-
readonly LUMENFLOW_VALIDATE: "lumenflow:validate";
|
|
79
|
-
readonly VALIDATE: "validate";
|
|
80
|
-
readonly VALIDATE_AGENT_SKILLS: "validate:agent-skills";
|
|
81
|
-
readonly VALIDATE_AGENT_SYNC: "validate:agent-sync";
|
|
82
|
-
readonly VALIDATE_BACKLOG_SYNC: "validate:backlog-sync";
|
|
83
|
-
readonly VALIDATE_SKILLS_SPEC: "validate:skills-spec";
|
|
84
|
-
readonly INITIATIVE_LIST: "initiative:list";
|
|
85
|
-
readonly INITIATIVE_STATUS: "initiative:status";
|
|
86
|
-
readonly INITIATIVE_CREATE: "initiative:create";
|
|
87
|
-
readonly INITIATIVE_EDIT: "initiative:edit";
|
|
88
|
-
readonly INITIATIVE_ADD_WU: "initiative:add-wu";
|
|
89
|
-
readonly INITIATIVE_REMOVE_WU: "initiative:remove-wu";
|
|
90
|
-
readonly INITIATIVE_BULK_ASSIGN: "initiative:bulk-assign";
|
|
91
|
-
readonly INITIATIVE_PLAN: "initiative:plan";
|
|
92
|
-
readonly ORCHESTRATE_INITIATIVE: "orchestrate:initiative";
|
|
93
|
-
readonly ORCHESTRATE_INIT_STATUS: "orchestrate:init-status";
|
|
94
|
-
readonly ORCHESTRATE_MONITOR: "orchestrate:monitor";
|
|
95
|
-
readonly DELEGATION_LIST: "delegation:list";
|
|
96
|
-
readonly AGENT_SESSION: "agent:session";
|
|
97
|
-
readonly AGENT_SESSION_END: "agent:session-end";
|
|
98
|
-
readonly AGENT_LOG_ISSUE: "agent:log-issue";
|
|
99
|
-
readonly AGENT_ISSUES_QUERY: "agent:issues-query";
|
|
100
|
-
readonly MEM_INIT: "mem:init";
|
|
101
|
-
readonly MEM_START: "mem:start";
|
|
102
|
-
readonly MEM_READY: "mem:ready";
|
|
103
|
-
readonly MEM_CHECKPOINT: "mem:checkpoint";
|
|
104
|
-
readonly MEM_CLEANUP: "mem:cleanup";
|
|
105
|
-
readonly MEM_CONTEXT: "mem:context";
|
|
106
|
-
readonly MEM_CREATE: "mem:create";
|
|
107
|
-
readonly MEM_DELETE: "mem:delete";
|
|
108
|
-
readonly MEM_EXPORT: "mem:export";
|
|
109
|
-
readonly MEM_INBOX: "mem:inbox";
|
|
110
|
-
readonly MEM_SIGNAL: "mem:signal";
|
|
111
|
-
readonly MEM_SUMMARIZE: "mem:summarize";
|
|
112
|
-
readonly MEM_TRIAGE: "mem:triage";
|
|
113
|
-
readonly MEM_RECOVER: "mem:recover";
|
|
114
|
-
readonly CONTEXT_GET: "context:get";
|
|
115
|
-
readonly FLOW_BOTTLENECKS: "flow:bottlenecks";
|
|
116
|
-
readonly FLOW_REPORT: "flow:report";
|
|
117
|
-
readonly METRICS_SNAPSHOT: "metrics:snapshot";
|
|
118
|
-
readonly LUMENFLOW_METRICS: "lumenflow:metrics";
|
|
119
|
-
readonly METRICS: "metrics";
|
|
120
|
-
};
|
|
121
|
-
export type CliCommandName = (typeof CliCommands)[keyof typeof CliCommands];
|
|
122
|
-
/**
|
|
123
|
-
* Metadata key constants used in ExecutionContext.metadata across MCP modules.
|
|
124
|
-
* These cross module boundaries and must be consistent.
|
|
125
|
-
*/
|
|
126
|
-
export declare const MetadataKeys: {
|
|
127
|
-
readonly PROJECT_ROOT: "project_root";
|
|
128
|
-
readonly INVOCATION_MODE: "invocation_mode";
|
|
129
|
-
};
|
|
130
|
-
export type MetadataKey = (typeof MetadataKeys)[keyof typeof MetadataKeys];
|
|
131
|
-
/**
|
|
132
|
-
* Environment variables used by MCP runtime execution policy.
|
|
133
|
-
*/
|
|
134
|
-
export declare const McpEnvironmentVariables: {
|
|
135
|
-
readonly MIGRATION_COMPAT_MODE: "LUMENFLOW_MCP_MIGRATION_COMPAT_MODE";
|
|
136
|
-
};
|
|
137
|
-
/**
|
|
138
|
-
* Compatibility modes for executeViaPack migration fallback behavior.
|
|
139
|
-
*
|
|
140
|
-
* - compat: allow temporary CLI fallback for migration-only reasons
|
|
141
|
-
* - strict: fail closed when runtime cannot serve migration-only tools
|
|
142
|
-
*/
|
|
143
|
-
export declare const MigrationCompatModes: {
|
|
144
|
-
readonly COMPAT: "compat";
|
|
145
|
-
readonly STRICT: "strict";
|
|
146
|
-
};
|
|
147
|
-
export type MigrationCompatMode = (typeof MigrationCompatModes)[keyof typeof MigrationCompatModes];
|
|
148
|
-
/**
|
|
149
|
-
* Canonical migration fallback error codes used by executeViaPack guardrails.
|
|
150
|
-
*/
|
|
151
|
-
export declare const MigrationFallbackErrorCodes: {
|
|
152
|
-
readonly DISABLED: "MCP_MIGRATION_FALLBACK_DISABLED";
|
|
153
|
-
readonly EXECUTION_FAILED: "MCP_MIGRATION_FALLBACK_ERROR";
|
|
154
|
-
};
|
|
155
|
-
export type MigrationFallbackErrorCode = (typeof MigrationFallbackErrorCodes)[keyof typeof MigrationFallbackErrorCodes];
|
|
156
|
-
/**
|
|
157
|
-
* Structured reasons for migration fallback attempts.
|
|
158
|
-
*/
|
|
159
|
-
export declare const MigrationFallbackReasons: {
|
|
160
|
-
readonly RUNTIME_INIT_FAILED: "runtime_init_failed";
|
|
161
|
-
readonly RUNTIME_TOOL_NOT_FOUND: "runtime_tool_not_found";
|
|
162
|
-
};
|
|
163
|
-
export type MigrationFallbackReason = (typeof MigrationFallbackReasons)[keyof typeof MigrationFallbackReasons];
|
|
164
|
-
/**
|
|
165
|
-
* Structured outcomes for migration fallback telemetry events.
|
|
166
|
-
*/
|
|
167
|
-
export declare const MigrationFallbackOutcomes: {
|
|
168
|
-
readonly SUCCEEDED: "succeeded";
|
|
169
|
-
readonly FAILED: "failed";
|
|
170
|
-
readonly BLOCKED: "blocked";
|
|
171
|
-
};
|
|
172
|
-
export type MigrationFallbackOutcome = (typeof MigrationFallbackOutcomes)[keyof typeof MigrationFallbackOutcomes];
|
|
173
|
-
//# sourceMappingURL=mcp-constants.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"mcp-constants.d.ts","sourceRoot":"","sources":["../src/mcp-constants.ts"],"names":[],"mappings":"AAGA;;;;;;;;;;;;;GAaG;AAMH;;;;;;;GAOG;AACH,eAAO,MAAM,WAAW;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CA8Hd,CAAC;AAEX,MAAM,MAAM,cAAc,GAAG,CAAC,OAAO,WAAW,CAAC,CAAC,MAAM,OAAO,WAAW,CAAC,CAAC;AAM5E;;;GAGG;AACH,eAAO,MAAM,YAAY;;;CAGf,CAAC;AAEX,MAAM,MAAM,WAAW,GAAG,CAAC,OA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