Skip to content

CLI Interface

EdgeCrab is driven entirely from the terminal. This page covers every entry point: the interactive TUI, one-shot prompts, global flags, subcommands, and in-session slash commands.

All information here is sourced directly from crates/edgecrab-cli/src/cli_args.rs and crates/edgecrab-cli/src/commands.rs.


Terminal window
edgecrab

Opens the full ratatui TUI with streaming tool output, message history, slash command autocomplete, and the status bar.

Terminal window
edgecrab "summarise the git log for today"

Sends a single prompt. Streams the response. Exits when done.

Terminal window
# Suppress banner and TUI — only LLM output goes to stdout
edgecrab --quiet "list all TODO comments in src/"
# Pipe-friendly
edgecrab -q "find all functions with no error handling" | grep -i "unwrap"

The TUI has three areas:

  1. Banner — shows model, toolset, working directory, and active skills on startup
  2. Conversation stream — scrollable output area with streaming tool execution feed
  3. Input prompt — fixed at the bottom with slash-command autocomplete

A persistent status bar sits above the input area, updating in real time:

🦀 copilot/gpt-4.1-mini │ 8.4K/128K │ [████░░░░░░] 7% │ 12m
ColumnDescription
Model nameCurrent model (provider/model)
Token countContext tokens used / max window
Context barVisual fill indicator
DurationElapsed session time

Context color coding: green < 50%, yellow 50–80%, orange 80–95%, red ≥ 95%.

As the agent works, each tool call appears in the conversation stream:

┊ 💻 terminal ls -la (0.3s)
┊ 🔍 web_search (1.2s)
┊ 📄 read_file src/main.rs (0.1s)

Use /verbose to cycle display modes: off → new → all → verbose.


All flags defined in CliArgs in cli_args.rs. They work with every subcommand.

edgecrab [OPTIONS] [PROMPT]
FlagShortDescription
--model <provider/model>-mOverride LLM for this session
--toolset <list>Active toolsets (comma-separated alias or name)
--session <id>-sResume a specific session by ID
--continue [title]-CContinue the most recent CLI session (optionally by title)
--resume <id-or-title>-rResume a session by ID or title
--quiet-qQuiet mode — print result and exit, no TUI
--config <path>-cConfig file path (default: ~/.edgecrab/config.yaml)
--debugEnable debug logging
--no-bannerSkip ASCII banner display
--worktree-wRun in an isolated git worktree
--skill <name>-SPreload a skill (may repeat or comma-separate)
--profile <name>-pRun under a specific named profile
Terminal window
edgecrab --model openai/gpt-4.1-mini "explain this PR"
edgecrab --model anthropic/claude-opus-4-5 "refactor this function"
edgecrab --model ollama/llama3.3 "offline mode"
edgecrab -m deepseek/deepseek-chat "fast, cost-effective"
# Full provider/model format: <provider>/<model-name>
edgecrab -m copilot/gpt-4.1-mini
edgecrab -m gemini/gemini-2.5-flash

Available toolset aliases (from toolsets.rs):

AliasTools included
codingfile + terminal + web + meta
allevery tool
fileread_file, write_file, patch, search_files
terminalterminal, run_process, list_processes, kill_process
webweb_search, web_extract, web_crawl
browserall browser_* tools
memorymemory_read, memory_write, honcho_*
skillsskills_list, skills_categories, skill_view, skill_manage, skills_hub
metamanage_todo_list, clarify
schedulingmanage_cron_jobs
delegationdelegate_task
code_executionexecute_code
sessionsession_search
mcpmcp_list_tools, mcp_call_tool, mcp_list_resources, mcp_read_resource, mcp_list_prompts, mcp_get_prompt
Terminal window
edgecrab --toolset file,terminal "run tests and fix errors"
edgecrab --toolset web "research recent Rust async changes"
edgecrab --toolset coding "full coding workflow"
edgecrab --toolset all "enable everything"
edgecrab --toolset browser,web "scrape and summarize"

Creates a temporary branch and worktree under .worktrees/ in the current repository, then runs EdgeCrab from that isolated directory. This lets you run multiple agents in parallel on the same repo without conflicts:

Terminal window
# Terminal 1 — refactor auth
edgecrab -w "refactor authentication to use JWT"
# Terminal 2 — parallel feature work
edgecrab -w "add rate limiting to the API"

Each invocation gets its own worktree and branch automatically. Clean worktrees are removed on exit; dirty ones are kept for manual recovery.

Preload one or more skills into the system prompt before the first turn:

Terminal window
edgecrab -S code-review "review the PR"
edgecrab -S security,testing "audit the codebase"
edgecrab --skill security --skill testing "audit"

Skills are loaded from ~/.edgecrab/skills/<name>/SKILL.md. See Skills System.

Terminal window
edgecrab -C # resume the most recent CLI session
edgecrab -C "auth refactor" # resume latest session matching that title
edgecrab -r abc123 # resume by session ID
edgecrab --session abc123 # also by session ID

All subcommands defined in Command enum in cli_args.rs:

edgecrab setup [section] [--force] — interactive setup wizard
edgecrab doctor — diagnostics check
edgecrab migrate [--dry-run] — hermes → edgecrab migration
edgecrab acp — ACP stdio server for editors
edgecrab version — detailed version info
edgecrab whatsapp — pair and configure WhatsApp bridge
edgecrab status — high-level runtime status summary
edgecrab sessions <sub> — session management
edgecrab config <sub> — inspect or modify config.yaml
edgecrab tools <sub> — inspect registered tools and toolsets
edgecrab mcp <sub> — manage MCP servers
edgecrab plugins <sub> — manage installed plugins
edgecrab cron <sub> — manage scheduled prompts
edgecrab gateway <sub> — run and manage messaging gateway
edgecrab skills <sub> — manage agent skills
edgecrab profile <sub> — manage named profiles
edgecrab completion <shell> — generate shell completion script
Terminal window
edgecrab setup # full interactive wizard
edgecrab setup model # model & provider section only
edgecrab setup tools # toolsets configuration
edgecrab setup gateway # messaging platform wiring
edgecrab setup agent # agent & behaviour settings
edgecrab setup --force # overwrite existing config from scratch

Checks config, env vars, API key presence, and provider connectivity:

EdgeCrab Doctor
────────────────────────────────────────────────────────────────
✓ Config file /Users/you/.edgecrab/config.yaml
✓ State directory /Users/you/.edgecrab/
✓ Memories directory /Users/you/.edgecrab/memories/
✓ Skills directory /Users/you/.edgecrab/skills/
✓ GitHub Copilot GITHUB_TOKEN set
✓ OpenAI OPENAI_API_KEY set
✗ Anthropic ANTHROPIC_API_KEY not set
✓ Provider ping copilot/gpt-4.1-mini → OK (312 ms)
────────────────────────────────────────────────────────────────
1 warning(s). Run `edgecrab setup` to configure missing providers.

Import config, memories, skills, and env from a hermes-agent installation:

Terminal window
edgecrab migrate --dry-run # preview what will be migrated
edgecrab migrate # execute migration

See Migrating from Hermes.

Starts the ACP (Agent Communication Protocol) JSON-RPC 2.0 server on stdin/stdout. Used by VS Code, Zed, JetBrains, and other ACP-compatible editors:

Terminal window
edgecrab acp

See ACP Integration.

Terminal window
edgecrab sessions list [--limit N] [--source <platform>]
edgecrab sessions browse [--query <text>] [--limit N]
edgecrab sessions export <id> [--output <file>] [--format markdown|jsonl]
edgecrab sessions delete <id>
edgecrab sessions rename <id> <new title…>
edgecrab sessions prune [--older-than N] [--source <platform>] [--yes]
edgecrab sessions stats
Terminal window
edgecrab config show # print active config as YAML
edgecrab config edit # open config.yaml in $EDITOR
edgecrab config set <key> <value>
edgecrab config path # print config.yaml path
edgecrab config env-path # print .env file path
Terminal window
edgecrab tools list # list all registered tools and toolsets
edgecrab tools enable <name> # enable a toolset in config
edgecrab tools disable <name> # disable a toolset in config
Terminal window
edgecrab mcp list # list configured MCP servers
edgecrab mcp add <name> <command> [args…] # add or update a server
edgecrab mcp remove <name> # remove a server
Terminal window
edgecrab cron list [--all]
edgecrab cron status
edgecrab cron tick # run due jobs once and exit
edgecrab cron create "<schedule>" "<prompt>" [--name <n>] [--skill <s>] [--repeat N] [--deliver local|<platform>:<chat_id>]
edgecrab cron edit <id> [--schedule …] [--prompt …] [--name …] [--skill …]
edgecrab cron pause <id>
edgecrab cron resume <id>
edgecrab cron run <id> # run immediately
edgecrab cron remove <id>

Cron schedule examples: "every 1 hour", "0 9 * * mon-fri", "every 30 minutes".

Terminal window
edgecrab gateway start [--foreground] # start gateway process
edgecrab gateway stop # stop gateway
edgecrab gateway restart
edgecrab gateway status # show runtime status
edgecrab gateway configure [platform] # interactive wizard

Platforms: telegram, discord, slack, signal, whatsapp.

Terminal window
edgecrab profile list # list all profiles (* = active)
edgecrab profile use <name> # set active profile
edgecrab profile create <name> [--clone]
edgecrab profile delete <name>
edgecrab profile show [name] # show profile config
edgecrab profile path [name] # print profile home directory

Profiles live at ~/.edgecrab/profiles/<name>/ with isolated config.yaml, .env, SOUL.md, memories/, skills/, and state.db. See Profiles.

Terminal window
edgecrab skills list [--category <cat>]
edgecrab skills view <name>
edgecrab skills install <path-or-url>
edgecrab skills remove <name>
Terminal window
edgecrab completion bash >> ~/.bashrc
edgecrab completion zsh >> ~/.zshrc

When you exit a CLI session, a resume command is printed:

Resume this session with:
edgecrab --resume 20260403_143052_a1b2c3
Session: 20260403_143052_a1b2c3
Duration: 12m 34s
Messages: 28 (5 user, 18 tool calls)

Resume options:

Terminal window
edgecrab --continue # resume the most recent CLI session
edgecrab -C # short form
edgecrab -C "auth refactor" # resume named session (latest in lineage)
edgecrab --resume 20260403_143052_a1b2c3 # resume by session ID
edgecrab -r "auth refactor" # resume by title

All sessions are stored in ~/.edgecrab/state.db (SQLite WAL). Each session records:

  • Session metadata (ID, title, timestamps, token counters, source platform)
  • Full message history (user + assistant + tool calls)
  • Lineage across resumed/compressed sessions
  • Full-text search indexes for session_search tool

Run a prompt in a separate background session while you continue using the CLI:

/background Analyze the logs in /var/log and summarize any errors from today

EdgeCrab immediately confirms the task:

🔄 Background task #1 started: "Analyze the logs in /var/log..."
Task ID: bg_143022_a1b2c3

When the task finishes, the result appears as a panel:

╭─ 🦀 EdgeCrab (background #1) ──────────────────────────────────╮
│ Found 3 errors in syslog from today: │
│ 1. OOM killer invoked at 03:22 — killed nginx │
│ 2. Disk I/O error on /dev/sda1 at 07:15 │
│ 3. Failed SSH login attempts from 192.168.1.50 at 14:30 │
╰─────────────────────────────────────────────────────────────────╯

Background sessions inherit your model, toolsets, and reasoning settings. They are fully isolated — no shared history with the foreground session.


All 42 slash commands sourced from CommandResult enum in commands.rs. Type / in the input bar to see autocomplete.

Skills installed in ~/.edgecrab/skills/ are automatically registered as slash commands.

CommandDescription
/helpList all slash commands
/quitExit EdgeCrab
/clearClear visible output area
/newStart fresh session (clears history)
/statusShow current session status
/versionShow version info
/session <id-or-title>Load or create a session
/retryRetry the last prompt
/undoUndo last message pair
/stopStop current generation
/historyShow message history
/saveSave session to disk
/export [format]Export as markdown or JSONL
/title <text>Set session title
/resume <id>Resume a saved session
CommandDescription
/model <provider/model>Hot-swap LLM mid-session
/provider <name>Switch provider
/reasoning <off|low|medium|high>Set reasoning effort
/stream <on|off>Toggle streaming mode
CommandDescription
/config [key] [value]Show or set config values
/promptShow the current system prompt
/verboseCycle tool progress: off → new → all → verbose
/personality <name>Switch agent personality
/statusbar <on|off>Toggle the status bar
CommandDescription
/toolsList all available tools
/toolsetsList toolset aliases and members
/reload-mcpHot-reload MCP servers without restart
/pluginsList installed plugins
/memoryShow all memory files
CommandDescription
/costShow token cost for this session
/usageCumulative API usage stats
/compressManually compress conversation history
/insightsShow session insights summary
CommandDescription
/queue <prompt>Queue a prompt to run after current finishes
/background <prompt>Run prompt as isolated background session
/rollbackRoll back to last checkpoint (shadow git)
CommandDescription
/themeReload theme from ~/.edgecrab/skin.yaml
/pasteEnter multi-line paste mode
CommandDescription
/platformsList connected messaging platforms
/approveApprove pending gateway action
/denyDeny pending gateway action
/sethomeSet gateway home channel
/updateUpdate EdgeCrab binary
/cronShow scheduled jobs
/voiceToggle voice I/O mode
/doctorRun diagnostics inline

All shortcuts sourced from the /help text in commands.rs.

KeyAction
EnterSubmit prompt
Shift+EnterInsert newline (multi-line input)
Ctrl+CClear input / cancel generation / exit (on empty)
Ctrl+DExit (on empty input)
Ctrl+LClear screen
Ctrl+UClear input line
TabAccept autocomplete / slash command
Up / DownScroll through command history
RightAccept ghost autocomplete hint
PgUp / PgDnScroll output buffer
Shift+Up / Shift+DownScroll output 3 rows
Alt+Up / Alt+DownScroll output 5 rows
Ctrl+HomeJump to top of output
Ctrl+End / Ctrl+GJump to bottom (live view)
Ctrl+MToggle mouse capture / selection mode

Use Shift+Enter to add a newline inside the input bar:

❯ Write a function that:<Shift+Enter>
1. Takes a list of numbers<Shift+Enter>
2. Returns the sum

Alternatively, end a line with \ (backslash continuation):

❯ First line \
Second line

Key EDGECRAB_* env vars (from config.rs: apply_env_overrides):

VariableDescription
EDGECRAB_MODELOverride default model
EDGECRAB_MAX_ITERATIONSOverride max agent iterations (default: 90)
EDGECRAB_TIMEZONEOverride timezone (IANA format)
EDGECRAB_SAVE_TRAJECTORIESEnable trajectory logging (1/true/yes)
EDGECRAB_SKIP_CONTEXT_FILESSkip auto-loading context files
EDGECRAB_SKIP_MEMORYDisable all memory for this session
EDGECRAB_GATEWAY_HOSTGateway bind host
EDGECRAB_GATEWAY_PORTGateway bind port
EDGECRAB_TTS_PROVIDERTTS provider override
EDGECRAB_TTS_VOICETTS voice override
EDGECRAB_REASONING_EFFORTReasoning effort (low, medium, high, xhigh)
EDGECRAB_HOMEOverride ~/.edgecrab home directory
EDGECRAB_MANAGEDSet 1 to block config writes (managed deployments)

See Configuration Reference for all config keys.