Skip to content
Closed
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 14 additions & 0 deletions mempalace/cli.py
Original file line number Diff line number Diff line change
Expand Up @@ -226,6 +226,13 @@ def cmd_repair(args):
print(f"\n{'=' * 55}\n")


def cmd_mcp(args):
"""Launch the MemPalace MCP server (reads/writes via JSON-RPC on stdio)."""
from .mcp_server import main as mcp_main

mcp_main()


def cmd_hook(args):
"""Run hook logic: reads JSON from stdin, outputs JSON to stdout."""
from .hooks_cli import run_hook
Expand Down Expand Up @@ -494,6 +501,12 @@ def main():
for instr_name in ["init", "search", "mine", "help", "status"]:
instructions_sub.add_parser(instr_name, help=f"Output {instr_name} instructions")

# mcp
sub.add_parser(
"mcp",
help="Start the MemPalace MCP server (for Claude Desktop, Cursor, ChatGPT etc.)",
)

# repair
sub.add_parser(
"repair",
Expand Down Expand Up @@ -535,6 +548,7 @@ def main():
"wake-up": cmd_wakeup,
"repair": cmd_repair,
"status": cmd_status,
"mcp": cmd_mcp,
}
dispatch[args.command](args)

Expand Down