Pi Code for VS CodeA visual VS Code wrapper around the Pi coding agent — built as a friendly UI for non-engineers and as a smooth landing pad for anyone moving over from Claude Code who wants the same familiar ergonomics, extra quality-of-life features, and the freedom to use any AI model behind the scenes.
Why Pi Code?
FeaturesChat panels as editor tabsEach chat opens as a normal editor-area webview panel. Split the editor, drag the tab between groups, move it into a separate window, or close and reopen it from the launcher's history. Multi-tab sessionsRun several agent sessions in parallel. Conversation history, tracked file changes, and checkpoint state are isolated per tab. Tool visibilityEvery tool call (file reads/writes/edits, shell, glob/grep, web search, fetch) renders as an expandable card with arguments and results, streamed in real time. Inline diffs and rollbackFile modifications are tracked automatically. Review unified diffs inline or open them in VS Code's native diff editor. Undo a single file or every change at once. CheckpointsEvery user message creates a checkpoint. Roll the workspace back to any earlier turn, then redo to bring changes back. The conversation history is preserved so you can branch from any point. Tool approvalBy default each tool call pauses for an inline approval card with the tool name and arguments preview. Approve, reject, or enable auto-approve to let the agent run uninterrupted. Streaming with thinkingWatch the agent reason in real time with collapsible thinking blocks. Cycle through Image attachmentsPaste, drop, or pick images via the paperclip button. Previews stay in chat history; image-capable models receive them inline. Workspace
|
| Shortcut | Action |
|---|---|
Ctrl+Shift+L (Cmd+Shift+L) |
Reveal the active chat panel, or focus the launcher if no chat is open |
Ctrl+Shift+N (Cmd+Shift+N) |
Open a new chat as an editor tab |
Enter |
Send prompt, or queue a message while streaming |
Ctrl+Enter (Cmd+Enter) |
Steer the agent mid-generation |
Escape |
Stop the current generation |
Commands
All commands are available from the command palette (Ctrl+Shift+P):
- Pi Code: New Chat — open a fresh agent session as an editor tab
- Pi Code: Session History — reveal the launcher with previous sessions
- Pi Code: Stop Generation — abort the current streaming response
- Pi Code: Select Model — choose an AI model
- Pi Code: Toggle Thinking Level — cycle through thinking verbosity levels
- Pi Code: Focus Chat — reveal the active chat panel, or fall back to the launcher
- Pi Code: Open Settings — open the Pi Code settings page
Settings
Settings can be configured through the dedicated settings page (gear icon in the launcher) or via VS Code's standard settings editor.
| Setting | Type | Default | Description |
|---|---|---|---|
pi-code.apiProvider |
string |
"" |
Preferred AI provider. Leave empty for auto-detect. |
pi-code.apiBaseUrl |
string |
"" |
Custom API base URL for proxies or self-hosted endpoints |
pi-code.defaultModel |
string |
"" |
Default model ID for new sessions |
pi-code.thinkingLevel |
string |
off |
Default thinking level (off, minimal, low, medium, high) |
pi-code.autoApproveTools |
boolean |
false |
Auto-approve tool executions without confirmation |
pi-code.allowedTools |
string[] |
[] |
Restrict which tools the agent can use. Empty = allow all. |
pi-code.autoSaveSessions |
boolean |
true |
Automatically persist sessions |
pi-code.sessionStoragePath |
string |
"" |
Custom session storage path. Empty = workspace .pi/. |
pi-code.contextUsageWarningThreshold |
number |
80 |
Warn when context usage exceeds this percentage |
pi-code.fileMentions.enabled |
boolean |
true |
Enable @ file mentions in chat input |
pi-code.fileMentions.useDefaultExcludes |
boolean |
true |
Use built-in exclude patterns for @ mention indexing |
pi-code.fileMentions.exclude |
string[] |
[] |
Extra glob patterns to exclude from @ mention suggestions |
pi-code.fileMentions.maxSuggestions |
number |
30 |
Maximum @ mention suggestions to show |
pi-code.fileMentions.configPath |
string |
.pi/file-mentions.json |
Workspace-relative config file for @ mention indexing |
pi-code.todo.defaultEnabled |
boolean |
true |
Enable the per-chat ToDo for new chats by default |
pi-code.todo.promptGuidelines |
string |
(multiline) | Prompt guidelines for the ToDo tool |
pi-code.userMessageGlowColor |
string |
#00aaff |
Glow colour around user messages in the chat |
pi-code.userMessageGlowOpacity |
number |
40 |
Glow opacity, 0–100 |
API keys are managed through the settings page and stored via VS Code's SecretStorage, never in settings.json.
Privacy
API keys and OAuth tokens are stored exclusively in VS Code's SecretStorage — never written to settings.json or any plaintext file. The extension itself contacts only the AI provider you configure (and, if you use the bundled web tools, the chosen search backend). No telemetry is sent to the publisher.
Credits
Pi Code embeds Mario Zechner's Pi coding agent SDK. Icons by Royyan Wijaya on Flaticon.
License
MIT. Source code, contribution guidelines, architecture notes, and changelog: GitHub repository.
