setup
Interactive wizards for plain CLI and OpenClaw integration.
emend setup
Interactive wizards that write credentials and provider keys to ~/.emend/.env and — for the integration commands — install hooks into the host tool. Use init if you just want the CLI configured; use the integration commands when you also want Emend wired into OpenClaw.
emend setup init
Configure Emend without installing any integration. Writes EMEND_URL / EMEND_API_KEY / LLM provider keys / storage backend to ~/.emend/.env. Run this if you're using the emend CLI directly from your shell.
emend setup init [--skip-llm]| Prop | Type |
|---|---|
--skip-llm | flag |
What it asks
| Field | Detail |
|---|---|
| Storage | Choose one of: Local SQLite — local Emend server, no extra credentials. Local OSS with a custom URL — prompts for the OSS server URL and optional API key. |
| LLM provider | Pick from OpenAI, Anthropic, Gemini, DeepSeek, OpenRouter, MiniMax, DashScope, xAI, Moonshot, or ZAI. Writes the provider's API key env var (e.g. OPENAI_API_KEY) into the .env. Skipped when --skip-llm is set. |
| Embedding provider | If the chosen LLM provider does not support embeddings (everything except OpenAI and Gemini), you are prompted to pick an embedding-capable provider separately. |
emend setup openclaw
Install (or remove) the openclaw-smart integration for OpenClaw. Registers the emend-openclaw-smart plugin into openClaw, writes the openclaw CLI path and the OPENCLAW_SMART_USE_LOCAL_CLI=1 opt-in to ~/.emend/.env, and runs the plugin's first-run installer so the next session doesn't pay a cold-install cost.
emend setup openclaw [--uninstall] [--repair] [--purge] [--embedding=auto|local|openai|gemini]| Prop | Type |
|---|---|
--uninstall | flag |
--purge | flag |
--repair | flag |
--embedding | auto | local | openai | gemini |
Prerequisites
openclawCLI on your PATH (install from openclaw.ai). The setup wizard captures its absolute path and writes it toOPENCLAW_BINso the emend backend'sopenclaw_providerLiteLLM plugin can spawn it for extraction.
What gets installed
- The
emend-openclaw-smartplugin into openClaw's plugin registry. ~/.emend/.envkeys:OPENCLAW_BIN(absolute path) andOPENCLAW_SMART_USE_LOCAL_CLI=1.~/.openclaw-smart/state directory (sessions, install markers, logs).- A
~/.emend/openclaw-plugin-rootsymlink to the active plugin install so slash commands resolve to one stable path.
Skill commands
After install, the plugin exposes five user-invokable skills inside openClaw:
| Skill | What it does |
|---|---|
| emend | Always-on contract: trust injected context, cite with [oc:…], stay quiet |
| learn | Force-publish the current session for immediate extraction |
| show | Print currently-known skills + preferences for this project as markdown |
| dashboard | Open the local emend web UI (http://localhost:3001) |
| restart | Restart the local emend backend cleanly |
| clear-all | Delete all locally-stored skills + preferences (destructive, prompts first) |
Next steps after install
emend services start(the SessionStart hook also auto-starts the backend).openclaw gateway restart.- Start a conversation — openclaw-smart will capture and learn automatically.