Documentation

Everything you need to know to master PorkiCoder — starting with Consult MCP, which gives Claude a built-in second opinion from a different lineage (Kimi & Gemini) mid-task, plus Agent Mode, keyboard shortcuts, and full model support.

The Marquee Feature

Consult MCP — A Second Opinion, Already Wired In

Open Claude Code in any PorkiCoder terminal tab and it already has two extra tools waiting — consult_kimi and consult_gemini — so it can reach sideways mid-task and ask a model of a different lineage for a real second opinion, without you ever leaving the session. There is nothing to install, nothing to configure, and the first dollars of consults are already paid for. No claude mcp add, no API keys to paste, no window-switching. It is just there.

Why a different lineage? Because re-asking the same model the same question is theater — it doesn't reconsider, it re-confirms, echoing its own training right back at you with extra confidence. Picture Claude several turns deep into a stubborn bug, the same fix failing the same way. Instead of you opening another tab to play telephone, Claude can sanity-check a refactor, break a multi-turn debugging stalemate, fact-check a claim, get UI & design help, do deep research, or reason over a large context — and get back an answer it didn't already believe. You stay in flow; Claude breaks the stalemate.

consult_kimi — Kimi K2.6
A fast, capable coding model from a different lineage than Claude, served on PorkiCoder's own US infrastructure. Because it wasn't trained the way Claude was, it doesn't share Claude's blind spots — ideal as a gut-check before a non-trivial refactor, a fresh pair of eyes on a stubborn bug, or to break a multi-turn debugging stalemate.
consult_gemini — Gemini 3.1 Pro
Google's flagship, on tap right inside the session — for UI & design help, fact-checks, deep research, and reasoning over large context. A genuinely independent read, not Claude grading its own homework.
Zero Setup — Auto-Registers on Every Launch
The bundled porkicoder-consult MCP server writes itself into your ~/.claude.json automatically every time PorkiCoder starts — idempotently, so it never clobbers your other MCP servers. No claude mcp add step, nothing to wire up. The tools are live in your next Claude Code session.
Tokens On the House — Already Paid For
Consults route through PorkiCoder's backend on a bundled quota. Free tier: $5/mo of consults. Premium ($20/mo): $15/mo of consults, combined across Gemini & Kimi. Exhaust the quota and consults fall back to your own API keys automatically — they never just stop working.
Nothing to Learn — Just Ask
Ask Claude in plain English — "consult Kimi on this approach" or "ask Gemini to fact-check this" — or simply let Claude reach for a consult on its own when it's unsure. No new syntax, no flags, no commands to memorize.

Agent Mode — Powered by Claude Agent SDK

Agent Mode is one of PorkiCoder's most powerful features — built on the official @anthropic-ai/claude-agent-sdk. It gives Claude autonomous access to your project filesystem, shell, and the web, while keeping you in control of every file write through human-in-the-loop diff review. Agent Mode also runs on Gemini and Kimi, not just Claude.

New in v1.14.0: Agent sessions now persist across restarts; Gemini and Kimi agents accept image attachments; you can set an optional per-run spend ceiling; Claude agents gain task tracking and can ask you a clarifying question mid-run; long-running commands stream their output live, and parallel tool calls group under one collapsible card.

How It Works
Agent Mode uses the Claude Agent SDK to run multi-step tool-use loops:

1. You describe the task — "Refactor the auth module", "Add dark mode", "Fix the failing test". Plain English.

2. The agent plans and acts — Claude autonomously calls tools: Read to understand files, Glob and Grep to search your codebase, Bash to run commands, WebSearch and WebFetch for documentation, and sub-Agent to delegate subtasks.

3. Diff review on every write — When the agent wants to edit or create a file, the change routes through a DiffReviewBridge into a Monaco Diff Editor modal. You see side-by-side diffs and accept or reject each change. Only approved writes are applied.

4. Adaptive thinking — Extended thinking is enabled with thinking deltas streamed live, so you can follow the agent's reasoning as it works through complex tasks.

5. Progress tracking — Toast-style progress cards show planning, tool calls, thinking, and completion events in real time.
Agent Tools
Read — Read any file in your project for context.

Glob — Find files by pattern (e.g., src/**/*.ts).

Grep — Search file contents with regex across your codebase.

Bash — Run shell commands: install packages, run tests, git operations, build steps.

WebSearch — Search the web for documentation, APIs, or error solutions.

WebFetch — Fetch content from URLs for context.

Sub-Agent — Spawn child agents to handle subtasks in parallel.

Edit / Write — File modifications routed through human-in-the-loop diff review.
Human-in-the-Loop Guarantees
Every file write from Agent Mode goes through a blocking async bridge. Only one diff review is shown at a time (serialized queue), with a 5-minute timeout to prevent stalls. The agent pauses until you approve — your codebase is never modified without your explicit consent.
Autopilot Mode NEW in v1.5.6
Trust the agent on routine work? Toggle the shield-check button in the chat header to enable Autopilot Mode. File writes and edits apply automatically without the diff preview modal — but every change still surfaces in the activity toast (with a ⚡ icon to distinguish autopilot writes from reviewed ones), so you stay informed without being interrupted. Your toggle persists across restarts. Works for both Claude Agent SDK and Gemini Agent.
Resumable Sessions
Agent sessions are persisted per thread ID. You can close PorkiCoder, reopen it, and resume a multi-step agent task exactly where you left off — no lost context, no repeated work.
Project Instructions (porki.md)
Drop a porki.md file in your project root and the agent will load it as persistent project-level instructions. Use it to describe your codebase conventions, architecture, key files, and preferences — the agent reads it before every task so it always has the right context.
Preview Error Auto-Send
When your Live Preview hits a runtime error, PorkiCoder automatically sends the error to the AI so it can diagnose and fix the issue — no more copy-pasting stack traces.
Pro Tip
Agent Mode works best when you give it clear, scoped tasks. For broad refactors, the agent will use sub-agents to parallelize work. You can also attach elements (images, files) directly into the chat for richer context alongside whatever the agent discovers on its own.

Publish-to-Web

Premium users can publish any project as a live site at <name>.porkicoder.com — directly from the IDE with one click.

How It Works
1. Choose a subdomain — Pick a name and your site goes live at <name>.porkicoder.com.

2. One-click deploy — PorkiCoder uploads your project's public files to the server automatically.

3. Instant updates — Re-publish anytime to push changes live.
Details
Premium feature — Available to all paid subscribers at no extra cost.

Static sites — Supports HTML, CSS, JS, and static assets. Perfect for portfolios, demos, and prototypes.

Automatic provisioning — Subdomain routing and HTTPS are handled for you.
Pro Tip
Combine Publish-to-Web with Agent Mode — ask the agent to build a landing page, then publish it live without leaving PorkiCoder.

Live Preview

Live Preview lets you see your project running directly inside PorkiCoder without leaving the editor. Click the preview button to launch your project on a local port (19100–19110) and start working visually.

Smart Project Detection
PorkiCoder automatically detects your project type and picks the best preview strategy:

Vite projects — Uses Vite's native dev server with full HMR support.

Dev command projects — Next.js, Nuxt, CRA, and others run via npm run dev with auto port detection.

Static sites — Served with a built-in HTTP server and WebSocket-based live reload.
Key Features
Auto-reload — File changes trigger instant browser refresh, debounced for rapid multi-file saves from the AI agent.

Framework-aware — Detects package managers (npm, yarn, pnpm, bun) and respects each framework's conventions.

Graceful fallback — If Vite or a dev command fails, PorkiCoder falls back to static serving automatically.

Zero config — No setup required. Open a project, hit preview, and it works.
Pro Tip
Live Preview works seamlessly with Agent Mode. When the agent modifies files, the preview auto-reloads so you can see changes in real time without switching windows.

Terminal

PorkiCoder's built-in terminal supports up to 6 concurrent sessions — perfect for running multiple Claude Code instances, dev servers, and build tools side by side.

Multi-Session Management
Each terminal session gets its own tab with a cyberpunk color palette (6 auto-assigned colors) and a colored left border strip for quick visual identification.

Activity indicators — Background tabs show a pulsing green dot when receiving output; turns amber 2 seconds after output stops; clears when the tab is focused.

Auto-named tabs — Run your first non-trivial command in a new terminal tab and a fast model (Kimi K2.6 with thinking off) picks a 1–3 word label for you in under a second — "Run Tests", "SSH Prod", "Tail Logs". Trivial heads (cd, ls, pwd, clear) skip the call; tabs you've manually renamed or that came pre-named are left alone. Launching an interactive coding agent (claude, aider, gemini, codex, cody) defers naming by one round — your first prompt to the agent becomes the basis for the label, so a Claude Code session about a login bug gets named "Login Bug", not "Launch Claude". Slash commands (/effort, /model, an unrecognized /command) and the trust-folder prompt you answer right after launching are skipped too, so a config keystroke never beats your real question to the name.

Manual rename — Double-click any tab title to inline-edit the name. Only manual renames persist across sessions — auto-generated labels live in memory for the current run and re-derive freshly next time, so yesterday's tab doesn't haunt today's session. A manual rename mid-flight always beats the AI guess.

Quick Claude Code launch — The robot button (Cmd+Shift+C) creates a new named "claude" tab and starts the CLI automatically.
Split View & Chat Bridge
Multi-Panel Split View — Toggle the split view button to show all terminals in a CSS grid (up to 3 columns). The active terminal is highlighted with its tab color. Click any panel to focus it.

Send to Chat — Captures the active terminal's recent output (or current selection) and pre-fills it as a code block in the chat input.

@terminal mention — Type @terminal in the chat input for autocomplete that injects the terminal buffer as inline context to the LLM.

Detach / Reattach — Pop any terminal into a separate window and bring it back. All features (split view, activity dots) work in detached windows too.
Terminal Keyboard Shortcuts
Cmd+1-9 — Switch to terminal tab 1–9 (when terminal is focused; switches models when chat is focused).

Cmd+Shift+[ / Cmd+Shift+] — Cycle to previous / next terminal tab.

Cmd+Shift+C — Quick-launch a new Claude Code session.
Editor — Cmd+K Inline Edit NEW in v1.8.0
Select code in the editor, press Cmd+K, describe the change in plain English, and the replacement streams in place from Kimi K2.6. Esc mid-stream restores the original; Cmd+Z after the edit completes reverts the whole thing in one keystroke.

Settings → Cmd+K Inline Edit lets you pick the default model (Kimi K2.6 / Gemini 3.5 Flash / Claude Haiku / Sonnet), choose live-replace vs diff-modal review mode, and set a line cap that auto-switches large selections to diff modal.
Rock-Solid Lifecycle NEW in v1.5.8
A full reliability pass closed every race and leak we could find in the terminal controller: destroy now serializes with in-flight init/restart so closing a tab mid-startup can't crash or leak a PTY, restart preserves the original cwd after a project switch, the detached-window activity dot correctly decays from green to amber to idle, and the xterm readiness/cleanup paths no longer leak listeners on a destroy-during-init. If you ever saw a terminal freeze, spawn in the wrong folder, or leak when you closed a tab fast — that should all be gone.

Chat Mode vs Agent Mode

PorkiCoder has two modes, and Agent Mode is the default. Pick the right one for the task in front of you.

Agent Mode
Best for: Real work — multi-step tasks, multi-file edits, refactors, anything that needs to read and change files.

The AI works autonomously with full tool access (read, search, run commands, edit and write files). Every file change is shown to you as a diff to accept or reject before it touches disk. Available on all five providers — Claude, Gemini, Kimi, Grok, and GPT.
Chat Mode
Best for: Quick questions and explanations — "what does this do?", a fast snippet, a one-off.

A lightweight, streaming Q&A lane with no file or tool access. Code comes back in normal code blocks with a Copy button. Need it applied? Switch to Agent Mode and it's done with a reviewed diff.
Pro Tip
Stay in Agent Mode for almost everything — it's the default for a reason. Drop into Chat Mode when you just want a fast answer and don't need anything written to disk.

Keyboard Shortcuts

Master these shortcuts to navigate PorkiCoder like a pro:

  • CMD + M Toggle between Chat and Agent mode
  • CMD + 1 Switch to Model 1 (cycle through available models)
  • CMD + 2 Switch to Model 2 (cycle through available models)
  • CMD + N Switch to Model N (cycle through available models)
  • CMD + W Toggle web search (available on all models)
  • CMD + ↑ Increase effort level (Low → Medium → High → Max)
  • CMD + ↓ Decrease effort level (Max → High → Medium → Low)
  • CMD + SHIFT + C Quick-launch a new Claude Code terminal session
  • CMD + SHIFT + [ Previous terminal tab
  • CMD + SHIFT + ] Next terminal tab
Web Search & Effort Controls
Web search is now available across all models from OpenAI, Gemini, and Anthropic. Use CMD + W to toggle it on or off.

All models also support Low, Medium, High, and Max effort settings, with Claude Opus 4.8 adding an extra XHigh tier between High and Max. The current level is displayed as green bars in chatview. Use CMD + ↑ and CMD + ↓ to adjust effort from the keyboard.

AI Model Support

PorkiCoder supports multiple AI providers and models, giving you the flexibility to choose the best tool for each task.

  • Kimi K2.6 in Agent Mode NEW in v1.6.0: Moonshot's kimi-k2-thinking-turbo now drives the full Agent Mode tool loop — Read, Glob, Grep, Bash, WebSearch, WebFetch, sub-Agent — with thinking maxed out and human-in-the-loop diff review unchanged. Pick Kimi from the model selector with Agent Mode on.
  • Claude Opus 4.8 NEW in v1.13.0: Anthropic's latest and most capable Opus — the Claude option everywhere, across Agent Mode, chat, and the apply-diff path, with summarized thinking streaming live in the UI. Opus 4.8 also introduces the XHigh effort tier between High and Max (Low → Med → High → XHi → Max), Anthropic's recommended starting point for long-horizon coding and agentic runs. (Kimi K2.6 is the default in v2.0; pick Opus 4.8 from the model selector when you want it.)
  • Agent Mode on every provider NEW in v2.0: All five providers — Claude, Gemini, Kimi, Grok, and GPT — now drive the full Agent Mode tool loop (Read, Glob, Grep, Bash, WebSearch, WebFetch, sub-Agent) with human-reviewed file writes.
  • Chat Mode: A fast, no-tools Q&A lane for quick questions and snippets, available on any model.
  • Web Search: Available on all models — OpenAI, Gemini, Anthropic, and more.
  • Effort Controls: All models support Low, Medium, High, and Max effort settings, shown as green bars in chatview. Claude Opus 4.8 adds an extra XHigh tier between High and Max.
  • Quick Switching: Use CMD + 1, CMD + 2, etc. to cycle through your configured models instantly.
Model Compatibility
Different models excel at different tasks. Experiment with various models to find what works best for your specific use case. Some models are faster, others are more accurate, and some handle specific programming languages better.

Getting Started

Before you can start coding with AI, you'll need to configure your API keys. PorkiCoder is a Bring Your Own API Key solution.

  • Open the Settings Modal (usually accessible from the menu or toolbar)
  • Add your API keys for the providers you want to use (Anthropic, Google, etc.)
  • You only pay a flat $20/month for the IDE
  • All API usage costs are directly between you and your provider - no markups!
Transparent Pricing
We charge a simple $20/month flat fee for the IDE. Your API usage is your own cost. This means you save 15-20% compared to other AI coding tools that markup your API costs. What you see on your provider's bill is what you pay - no hidden fees, ever.
Usage & Cost Tracking
Every request's token count and estimated USD cost is tracked per model, so you're never guessing what your providers are charging. Open the Settings modal to see your current month's usage and spend at a glance — handy for keeping BYOK costs in check across Claude, Gemini, Kimi, GPT, and Grok.

Tips & Best Practices

  • Stay in Agent Mode (the default) for most work — it reads, edits, and runs commands for you, then shows every file change as a reviewable diff.
  • Drop into Chat Mode for quick questions and snippets when you don't need anything written to disk.
  • Switch models frequently - different models have different strengths.
  • Enable web search (CMD + W) on any model when working with recent frameworks or documentation.
  • Use CMD + ↑ / ↓ to quickly adjust effort level — higher effort = more thorough (and more costly) responses.
  • Always provide full context in your prompts for better results.
  • Review AI-generated changes before applying them to your codebase.
  • Keep your API keys secure and never share them.