Skip to content

CLI

CLI and Service Management

Use the Wenlan CLI to install the runtime, manage the daemon, inspect status, search memory, and wire MCP clients.

Qi-Xuan LuUpdated 5 min read

At a glance

01

The wenlan CLI is the terminal control surface for setup, diagnostics, service management, recall, search, store, spaces, models, keys, and MCP config.

02

The daemon still owns memory. The CLI talks to that daemon instead of writing the database directly.

01

Install the runtime

For non-Claude Code clients, start by installing the local Wenlan runtime. This puts the CLI, daemon, and MCP connector under ~/.wenlan/bin.

Claude Code plugin users can usually run /init instead; it verifies the same local runtime and MCP route from inside Claude Code.

Terminal

npx -y wenlan setup

02

Check the daemon

The daemon listens on 127.0.0.1:7878 and owns storage, search, pages, graph context, and distill cycles. Use status for a quick health check and doctor for a fuller setup report.

Service installation is per-user. Wenlan uses launchd on macOS, systemd user units on Linux, and a Task Scheduler logon task on Windows.

Service commands

wenlan status
wenlan doctor
wenlan install
wenlan uninstall

03

Use memory from the terminal

The CLI can recall, search, store, and list memory from scripts or from a plain terminal session. It is useful when you need a repeatable diagnostic or when your current tool does not expose Wenlan commands directly.

Use specific queries. Project names, feature names, people, and decisions usually retrieve better context than generic phrases.

Daily CLI

wenlan recall "wenlan website positioning"
wenlan search "MCP setup"
wenlan store "We chose spaces for client separation" --type decision
wenlan list --limit 10

04

Wire MCP clients

After setup, use wenlan mcp add to configure a supported MCP client. The command writes or previews the client-specific config that launches the local wenlan-mcp connector.

Use --dry-run when you want to inspect the generated config before changing a client settings file.

MCP setup

~/.wenlan/bin/wenlan mcp add codex
~/.wenlan/bin/wenlan mcp add cursor --dry-run

05

When to use the CLI

Use Claude Code slash commands for the richest daily workflow. Use MCP tools from clients that support them. Use the CLI for setup, diagnostics, scripts, service management, and cases where a client UI hides too much detail.

All three paths reach the same daemon, so they should agree on memory state when setup is healthy.

Next

Updates and Uninstall

Refresh Wenlan's local runtime, verify version health, restart MCP clients, and remove the service without losing data by accident.

Read next