CLI Reference
Invocation
# Via bun script
bun run cli <command> [subcommand] [args] [--flags]
# As installed binary
melian <command> [subcommand] [args] [--flags]All server-dependent commands connect to http://127.0.0.1:3000 by default. Override with --port <number>.
Quick Start
# First-time setup wizard
melian setup
# Start the server
melian start
# Interactive chat
melian chat
# One-shot question
melian ask "What's on my calendar today?"
# Server health
melian statusCommands
setup
Interactive first-time configuration wizard. Creates ~/.melian/ with config files.
melian setupPrompts for: LLM endpoint URL, Qdrant URL, server port, your name and interests. Optionally configures email accounts and iMessage (macOS only). Creates config.yaml, mcp.json, and personality.yaml.
start / dev
melian start # Production server
melian dev # Watch mode with auto-reloadchat
Interactive REPL chat session. Streams responses from the server, displays tool calls inline.
melian chat- Prompt:
> - Tool calls shown as
[calling archival_memory_search...] - Spirit shifts shown as
✦ spirit shifted - Exit with Ctrl+C
ask
One-shot question, no REPL. Useful for scripting and piping.
melian ask "Summarize my unread emails"
melian ask "Turn off the garage lights"memory
melian memory core # Show all core memory sections
melian memory search <query> # Search archival + recall memorySearch returns archival results with similarity scores and recall results with timestamps.
jobs
melian jobs list # List all jobs with status
melian jobs create --name "reminder" \
--schedule "daily at 9am" \
--prompt "Remind me to check email" # Create a job
melian jobs log <name-or-id> # Show run history
melian jobs run <name-or-id> # Trigger immediately
melian jobs pause <name-or-id> # Disable
melian jobs resume <name-or-id> # Enable
melian jobs delete <name-or-id> # Removemelian email accounts # List accounts with connection status
melian email setup <account-name> # Configure/test account (OAuth for Gmail)
melian email check # Check all accounts for new mail
melian email summary # Show important unread (importance >= 0.6)
melian email search <query> # Search emails
melian email read <id> # Display full email body
melian email drafts # List pending drafts
melian email drafts approve <id> # Send a draft
melian email drafts discard <id> # Delete a draft
melian email send --account personal \
--to "[email protected]" \
--subject "Hello" \
--body "Message body" # Send directlyimessage
macOS only. Requires a running server with iMessage enabled.
melian imessage status # Watcher status, contacts, last message
melian imessage history [limit] # Recent messages (default: 20)
melian imessage last [limit] # Recent agent responses (default: 1)
melian imessage send <message> # Send test messagecalendar
melian calendar today # Today's events
melian calendar week # This week, grouped by day
melian calendar drafts # Pending event drafts
melian calendar drafts approve <id> # Create event from draft
melian calendar drafts reject <id> # Discard draft
melian calendar sync # Force sync from Google Calendaranalytics
melian analytics # 24h summary (default)
melian analytics summary --window 7d # Last 7 days
melian analytics summary --since 2026-04-01 # Since date
melian analytics tokens # Token usage by context
melian analytics tools # Tool call breakdown
melian analytics models # Per-model statistics
melian analytics jobs # Job execution metricsSummary output includes: total requests, tokens in/out, average response time, error rate, top tools, model stats, breakdown by context (cli, web, imessage, cron).
mcp
melian mcp list # List servers with status and tool counts
melian mcp tools # List all tools from connected servers
melian mcp add [name] # Interactive server configuration
melian mcp remove <name> # Delete server configmcp add prompts for transport type (stdio or http), command/URL, args, and environment variables. Saves to ~/.melian/mcp.json.
models
melian modelsLists available models from the LLM endpoint with per-model metrics: request count, average response time, tokens/second, success rate.
config
melian config edit # Open ~/.melian/config.yaml in $EDITOR
melian config validate # Validate YAML/JSON syntax of config filesvalidate checks config.yaml, mcp.json, and personality.yaml.
service
Install Melian as a system service that starts on login.
melian service install # Install + start (launchd on macOS, systemd on Linux)
melian service uninstall # Remove service
melian service start # Start service
melian service stop # Stop service
melian service restart # Stop + start
melian service status # Check if running (shows PID)attention
melian attention list [limit] # Show attention events (default: 20)
melian attention stats # Counts by classification and source
melian attention seed # Seed reference embeddings from seeds.yamlattention list displays: timestamp, state, actor, classification (with source and confidence), and body snippet. Reads directly from the local SQLite database (no server required).
Global Flags
| Flag | Default | Description |
|---|---|---|
--port <number> |
3000 |
Override server port for all commands |
--help |
Show help text |
Server-Independent Commands
Most commands require a running server. These do not:
setupcreates config filesconfig edit/validateoperates on files directlyservice install/uninstall/start/stop/statusmanages the processmcp add/removeedits~/.melian/mcp.jsonattention list/stats/seedreads local SQLite