A fast, modern Neovim configuration with a built-in AI coding agent. It combines a lean plugin set, coherent keybindings, and a Cursor-style agent sidebar powered by pi, so you can chat with an agent that reads, edits, and runs code in your project while you keep editing as usual.
- Agent sidebar (pi): a chat panel where AI agents do real work in your codebase
- Blazingly fast: minimal plugins, no bloat, quick startup
- LSP ready: completion, diagnostics, formatting, and go-to navigation out of the box
- Treesitter: modern syntax highlighting and parsing
- Telescope: fuzzy finding for files, text, buffers, and symbols
- Coherent keybindings: mnemonic namespaces designed to build muscle memory
- One command installation: a single script sets up everything
The star of this config is pi.nvim, a hand-rolled integration of the pi coding agent, built into lua/pi/. It gives you an experience similar to Cursor, inside Neovim.
The sidebar is not a chatbot that only answers questions. Each tab runs a full autonomous coding agent that can:
- Read your code: it explores the project with read, grep, find, and ls tools
- Edit files directly: it writes and patches files in your working tree
- Run shell commands: it executes builds, tests, and scripts, and reacts to their output
- Work in multi-step loops: it plans, acts, observes results, and continues until the task is done
- Stream everything live: you watch tool calls and reasoning appear in real time
Every tool call shows up as a compact status line in the transcript:
✓ read src/main.go
✓ bash go test ./...
✗ edit src/api.go
│ failed: no match
▶ grep TODO
The agent runs as a background process, completely decoupled from the UI:
- You can close the sidebar while the agent works, it keeps going
- You can edit, navigate, and search files while tasks run
- Multiple agents can run in parallel, one per tab
- Background tabs show a working indicator, so nothing gets lost
Every tab runs in one of two modes:
- Agent mode (default): full tool access, the agent reads, edits, and executes
- Plan mode: read-only tools plus a planning prompt, the agent investigates the codebase and produces a step-by-step plan without touching any files
Toggle with <Space>ap. The conversation is preserved when switching modes.
- Each tab is an independent pi session with its own process and context
- Create tabs with
<Space>an, close with<Space>ax, cycle with<Space>a]and<Space>a[ - Closed tabs are saved to history, reopen any past session with
<Space>ahand continue where you left off - Sessions persist on disk in pi's own session format
<Space>amopens a model picker listing every model you have configured in pi:Pi cycle-modelcycles through available models- Model choice is per tab, so different tabs can use different models
The transcript renders as markdown with treesitter highlighting. Fenced code blocks get full syntax highlighting for their language, and render-markdown.nvim decorates headings, lists, and inline code.
| Command | Action |
|---|---|
:Pi |
toggle the sidebar |
:Pi focus |
open and focus the chat input |
:Pi new [name] |
new tab (new session) |
:Pi close |
close current tab (saved to history) |
:Pi next / :Pi prev |
cycle tabs |
:Pi tab <n> |
jump to tab n |
:Pi history |
reopen a past session |
:Pi model |
model picker |
:Pi cycle-model |
cycle models |
:Pi mode |
toggle agent/plan mode |
:Pi abort |
abort the current run |
:Pi send <text> |
send a prompt programmatically |
Configure the sidebar in init.lua:
require("pi").setup({
side = "right", -- "left" or "right"
width = 64, -- sidebar width
auto_focus = false, -- focus input when opening
default_mode = "agent", -- "agent" or "plan"
default_model = nil, -- e.g. "anthropic/claude-sonnet-4:medium"
render = {
show_thinking = true, -- show reasoning blocks
show_tool_output = false, -- compact tool lines (errors always show)
max_tool_lines = 12, -- output tail length
},
})- Neovim 0.10 or later
- Git
- A C compiler (gcc or clang, for treesitter parsers)
- Node.js and npm (for the pi coding agent)
- An API key for at least one LLM provider (Anthropic, OpenAI, Google, and others)
curl -fsSL https://raw.githubusercontent.com/PythonHacker24/awesomevim/main/install.sh | bashThe script backs up any existing config, clones the repo, installs all plugins and treesitter parsers headlessly, and installs the pi CLI if npm is available.
After installing, authenticate pi once:
pi # follow the login prompts, or set ANTHROPIC_API_KEY / OPENAI_API_KEY etc.# 1. clone the config
git clone https://github.com/PythonHacker24/awesomevim.git ~/.config/nvim
# 2. install packer
git clone --depth 1 https://github.com/wbthomason/packer.nvim \
~/.local/share/nvim/site/pack/packer/start/packer.nvim
# 3. install plugins
nvim --headless -c "lua require('core.packer')" \
-c "autocmd User PackerComplete quitall" -c "PackerSync"
# 4. install the pi coding agent
npm install -g @earendil-works/pi-coding-agentLeader is Space. The scheme is mnemonic: leader, namespace letter, action letter. The most used actions get instant chords.
| Key | Action |
|---|---|
<Space><Space> |
find files |
Ctrl-\ |
toggle floating terminal (works inside the terminal too) |
Ctrl-n |
toggle file tree |
<Space>aa |
toggle agent sidebar |
| Key | Action |
|---|---|
<Space>ff |
files |
<Space>fg |
live grep |
<Space>fw |
grep word under cursor |
<Space>fb |
buffers |
<Space>fr |
recent files |
<Space>fs |
fuzzy search in buffer |
<Space>fd |
diagnostics |
<Space>fh |
help tags |
<Space>fc |
commands |
| Key | Action |
|---|---|
gd |
definition |
gr |
references |
gi |
implementation |
gy |
type definition |
K |
hover documentation |
| Key | Action |
|---|---|
<Space>ss |
document symbols |
<Space>sw |
workspace symbols |
| Key | Action |
|---|---|
<Space>tt |
floating terminal |
<Space>th |
horizontal terminal |
<Space>tv |
vertical terminal |
<Esc><Esc> |
(in terminal) back to normal mode |
| Key | Action |
|---|---|
<Space>aa |
toggle sidebar |
<Space>ai |
focus chat input |
<Space>an |
new tab (session) |
<Space>ax |
close tab (saved to history) |
<Space>a] / <Space>a[ |
next / previous tab |
<Space>ah |
reopen session from history |
<Space>am |
model picker |
<Space>ap |
toggle plan/agent mode |
Inside the sidebar:
| Key | Action |
|---|---|
<CR> |
send message (in input box) |
Ctrl-j |
newline in input |
Ctrl-c |
abort the current run |
q |
close sidebar |
i |
jump to input |
gt / gT |
next / previous tab |
| Key | Action |
|---|---|
<Space>e |
focus file tree |
<Space>u |
undotree |
<Space>F |
LSP format |
<Space>/ |
toggle comment (normal and visual) |
<Space>mp |
toggle markdown rendering |
| Key | Action |
|---|---|
Ctrl-u / Ctrl-d |
half page up / down |
Ctrl-b / Ctrl-f |
full page up / down |
zt / zz / zb |
scroll cursor to top / center / bottom |
init.lua entry point
install.sh one command installer
lua/
core/
options.lua editor options
keymaps.lua all keybindings
colors.lua colorscheme with persistence
packer.lua plugin declarations
plugins/ per-plugin configuration
treesitter.lua, telescope via keymaps, lsp.lua, nvim-tree.lua,
toggleterm.lua, lualine.lua, neoscroll.lua, hover.lua, startup.lua
pi/ the agent sidebar plugin
init.lua setup, :Pi command, keymaps
rpc.lua JSONL RPC client for pi subprocesses
session.lua one tab = one independent agent process
manager.lua tabs, history, mode and model actions
ui.lua sidebar windows, tabline, input
render.lua transcript to markdown rendering
history.lua persistent session index
extras/
latex.lua :Renderlatex command
Managed with packer.nvim:
- telescope.nvim fuzzy finder
- nvim-treesitter syntax highlighting
- mason.nvim LSP server installer
- nvim-cmp completion
- nvim-tree file explorer
- toggleterm.nvim terminal
- lualine.nvim statusline
- render-markdown.nvim markdown decorations
- Comment.nvim commenting
- undotree undo history
- neoscroll.nvim smooth scrolling
- go.nvim and nvim-dap-go Go development
- catppuccin and gruvbox themes
- Add a
use { ... }entry inlua/core/packer.lua - Run
:lua require("core.packer") - Run
:PackerSync
Open an issue in the issues tab with:
- steps to reproduce
- error messages (
:messagesin Neovim) - your OS and Neovim version (
nvim --version)
Pull requests are welcome.
This project is licensed under the MIT License.