opencode

Agentic coding inside Neovim · powered by DeepSeek

Cheatsheet Every nvim keymap, TUI key, CLI flag, and config field in one tabbed page
🧠
Concepts The agent loop, sessions, tools, plans, MCP, approval model
🎮
Practice Eight guided lessons — drive a simulated session from ask to multi-file edit
📖
opencode Docs Official documentation and reference

Survival kit

<leader>ooToggle the opencode panel from inside nvim
<leader>oaAsk about cursor (normal) / selection (visual)
<leader>o+Append the whole buffer to your next prompt
<leader>on / <leader>oiNew session / interrupt the running agent
Esc (in TUI)Interrupt the model mid-response
Ctrl+x then n / l / mTUI leader: new session / list sessions / pick model
opencodeLaunch the standalone TUI in your current directory
opencode run "..."One-shot prompt from the shell (no TUI)
opencode models deepseekList available DeepSeek models
opencode statsToken usage and cost totals
opencode auth listVerify providers + which env vars are picked up
config~/.config/opencode/opencode.jsonc
API key$DEEPSEEK_API_KEY from the 1P Bash Secrets item