Documentation

A practical guide to PorkiCoder, from first setup and daily workflows to Agent Mode, terminal agents, Consult MCP, Worktree Fan-Out, live preview, publishing, credits, settings, shortcuts, and troubleshooting.

Getting Started

Use this path for a first PorkiCoder session. PorkiCoder works as a normal editor, a chat surface, an autonomous agent workspace, and a terminal host for Claude Code, Codex, and opencode.

  1. 1
    Download and open PorkiCoder. Install from the home page, launch the app, and sign in so bundled credits, consult tools, publish-to-web, and MCP registration can attach to your account.
  2. 2
    Open a project folder. Pick the repository or static site you want to work on. Agent Mode, terminal sessions, live preview, and publish all use that folder as their working context.
  3. 3
    Choose how model calls are paid for. You can bring your own provider keys in Settings for zero PorkiCoder credit spend, use plan credits for server-funded model calls, and use the included monthly consult allowance for MCP second opinions.
  4. 4
    Start in Agent Mode for real work. Ask for a scoped change, let the agent read files and run commands, then approve or reject each diff before it writes to disk. Use Chat Mode only when you want a quick answer without tools.
  5. 5
    Preview, test, and publish. Launch Live Preview while the agent edits, run tests in the terminal, then publish a static project to a PorkiCoder subdomain or custom domain when it is ready.
The shortest useful prompt
Read this project, explain the architecture briefly, then suggest the safest first improvement. Do not edit files yet.
Run that once when you open an unfamiliar codebase. Then follow with a specific task when you are ready for changes.

First 10 Minutes

This is a compact tour of the main workflow. Each step maps to a deeper section below.

Ask a quick question Use Chat Mode for explanation, snippets, or planning when no files need to change.
Run a first agent task Switch to Agent Mode and ask for one small fix. Review the diff before accepting it.
Open Live Preview Click preview so Vite, a dev command, or the static server starts on a local port.
Launch a terminal agent Use Cmd+Shift+C for Claude Code or Cmd+Shift+O for opencode.
Ask for a second opinion Inside Claude Code, Codex, or opencode, ask it to consult Kimi, GLM, Gemini, or GPT.
Publish a static site Choose a subdomain, deploy public files, and republish when you make changes.

Choose Mode & Model

Start from the job, then choose the surface. You can always switch modes or ask a terminal agent to bring in a consult.

Task Use Why
Explain code, draft a small snippet, compare options Chat Mode Fast, streaming, no filesystem or shell access.
Fix a bug, refactor files, add a feature, run tests Agent Mode Reads the project, runs commands, and routes every write through diff review.
Edit a selected block in place Cmd+K Inline Edit Fast editor-native replacement with undo and optional diff review.
Run Claude Code, Codex, or opencode in a real shell Terminal Best when you want a dedicated coding-agent TUI plus normal shell commands.
Break a stalemate or review a risky plan Consult MCP Gets an independent model lineage without leaving the current terminal agent.
Compare multiple possible implementations Worktree Fan-Out Runs isolated candidates in parallel, then lets you judge and apply a winner.

Common Workflows

Build a feature

Describe the desired behavior, constraints, and files if you know them. Let Agent Mode inspect the code, ask it to make the smallest coherent change, review the diff, then run tests or preview.

Add saved filters to the dashboard. Read the existing filter code first, keep the UI consistent, and run the relevant tests before showing me the diff.

Fix a stubborn bug

Paste the error, reproduction steps, and expected behavior. If the same fix fails twice, ask the agent to consult Kimi or GLM before making another edit.

This test fails with the stack trace below. Reproduce it, explain the root cause, consult Kimi on the proposed fix, then patch it.

Review a risky change

Use a terminal agent with Consult MCP for a second opinion, or fan out multiple reviewers when the tradeoff is meaningful.

Review the current diff for correctness, security, and missing tests. Ask GLM for a second opinion on any high-risk issue.

Publish a site

Use Live Preview first, confirm the public files render correctly, then publish to a PorkiCoder subdomain. Add or connect a custom domain from Settings when needed.

Before publishing, inspect the static output, check that links and assets are relative, then deploy this project to my selected subdomain.

Install & Requirements

  • PorkiCoder app: install the desktop build from the home page and sign in to use account-backed credits, consult allowance, publish-to-web, and auto-registered MCP tools.
  • Project folder: open a local folder. Git is strongly recommended, and Worktree Fan-Out requires a git repository.
  • Provider keys: optional for BYOK usage. Add keys in Settings when you want model calls billed directly by the provider instead of using PorkiCoder credits or bundled quota.
  • Terminal agents: install the CLIs you want to run, such as Claude Code, Codex, or opencode. Launch them from a PorkiCoder terminal so the bundled MCP server and token bridge are available.
  • Publishing: publish-to-web is for static files and static assets. Custom domains are managed from Settings and may require DNS/SSL provisioning time.
The Marquee Feature

Consult MCP — A Second Opinion, Already Wired In

Open Claude Code in any PorkiCoder terminal tab and it already has six consult tools waiting — consult_kimi, consult_kimi27, consult_kimi27_fast, consult_glm52, consult_gemini, and consult_gpt5 — 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_kimi27 — Kimi K2.7 Code
Kimi's newest code-focused thinking model, routed through PorkiCoder's authenticated Baseten-backed proxy. Reach for it when the question is implementation-heavy, K2.6 was not enough, or Claude wants a deeper code review from the Kimi lineage.
consult_kimi27_fast — Kimi K2.7 Code fast path
The fast K2.7 Code path for code-review-sized questions and implementation checks. It streams through the same Baseten-backed proxy and automatically falls back to Kimi K2.6 on the Baseten path if K2.7 is unavailable.
consult_glm52 — GLM-5.2
Z.AI's long-context reasoning model, served through PorkiCoder's Baseten-backed proxy with thinking enabled. Use it for large-context reviews, implementation tradeoffs, and second opinions where a million-token window matters.
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, ~/.codex/config.toml, and ~/.config/opencode/opencode.json automatically every time PorkiCoder starts — idempotently, so it never clobbers your other MCP servers. PorkiCoder also wires a local token bridge so signed-in sessions use the bundled server proxy instead of asking for provider keys. No claude mcp add step, no manual Codex or opencode config edit. The tools are live in your next Claude Code, Codex, or opencode 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 & GLM. If the bundled quota is exhausted, supported consult paths use your configured provider keys where available; otherwise PorkiCoder tells you what needs attention instead of failing silently.
Good Consult Prompts
Ask Kimi to review this refactor plan for correctness and simpler alternatives before editing.
Ask GLM to inspect the full context and look for hidden migration risks.
Ask Gemini to check the UI copy and layout approach from a product-design angle.
Use consults when the next step is expensive, risky, or stuck. For routine edits, Agent Mode can usually keep going without one.
Nothing to Learn — Just Ask
Ask Claude in plain English — "consult Kimi on this approach", "ask GLM to review the long context", 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.
Baseten Integration Docs
PorkiCoder uses Baseten-backed Kimi K2.7 Code, Kimi K2.6, and GLM-5.2 paths across consult tools, fan-out, opencode, and in-app model routing, with proxy-first access for signed-in users and BYOK fallback where available. Read the dedicated Baseten integration guide.

Worktree Fan-Out UPDATED in v2.9.2

Worktree Fan-Out lets Claude Code, Codex, or opencode take one task prompt and run it across 2-5 isolated git worktrees from a PorkiCoder-managed terminal. Each candidate gets its own branch, cwd, model run, status, diff, and cleanup path, while your source worktree stays unchanged until a winner patch is applied. If terminal fan-out starts from a dirty source worktree, PorkiCoder creates a visible local checkpoint commit first so candidates branch from a clean, reviewable base.

Run Parallel Candidates
Start with fanout_run and a prompt. By default, PorkiCoder rotates workers across GLM-5.2, Kimi K2.7 Code, and Codex high effort, then repeats as needed. You can choose one model for every worker, pass an explicit model mix, set a worker count, stagger launches, and cap the shared fan-out budget.
Inspect and Compare
Use fanout_status to watch progress, fanout_list to find recent runs, fanout_diff to compare candidate changes, and fanout_open_candidate to inspect a candidate workspace directly in PorkiCoder. Friendly selectors like latest, c1, A, and winner keep agents from passing raw IDs around.
Judge, Apply, and Clean Up
fanout_judge asks an evaluator model to review candidate diffs and optional verification output. In recommend-only mode it stores a winner for follow-up; with explicit confirmation, fanout_apply_winner applies that patch back to the source worktree as unstaged changes. Loser worktrees are discarded by default after patch snapshots are saved, and fanout_discard remains available when you want to remove a specific candidate manually.
Minimal Fan-Out Walkthrough
Ask your terminal agent for the whole loop in plain English:
Fan out three candidate fixes for this failing test, wait for them, compare the diffs, judge the winner, then apply the winner as unstaged changes.
If you are driving the tools directly, the usual sequence is fanout_run, fanout_status, fanout_diff, fanout_judge, and fanout_apply_winner. Use fanout_list when you need to find a previous run and fanout_stop if active candidates should be cancelled.
Dirty Worktree Checkpoints
Checkpoint commits are intentionally conservative: PorkiCoder refuses likely secrets, detached HEADs, in-progress Git operations, and dirty submodules unless the agent explicitly opts into those cases. The checkpoint summary records the before and after commit IDs, and failed setup attempts roll back the checkpoint when HEAD is still on the generated commit.
Available Across Claude Code, Codex, and opencode
Fan-out tools are exposed through the bundled porkicoder-consult MCP server in Claude Code, Codex, and opencode. PorkiCoder keeps the loopback bridge credentials in a local 0600 token file while the app is running, so globally registered MCP sessions can create, inspect, judge, apply, and discard managed fan-out worktrees without per-terminal setup.

Built-in Terminal Skills UPDATED in v2.10.1

PorkiCoder now includes the core long-running workflow skills out of the box for terminal agents. Fresh installs get managed copies of big-deployment, full-hog-mode, feat-pig, and fix-bugs for Claude Code, Codex, and opencode without a separate skill repo clone.

Installed on Launch
On startup, PorkiCoder refreshes managed skill copies under ~/.claude/skills, ~/.codex/skills, ~/.agents/skills, and ~/.config/opencode/skills. Existing user-owned skill folders are left alone; only directories marked as PorkiCoder-managed are replaced.
Ready in Terminal Agents
Claude Code sees the normal Claude skill layout, Codex sees normal Codex skills, and opencode receives the bundled skill path plus generated terminal command adapters. The same skill names are available whether the user starts from a new PC or an existing setup.
Full-Hog Mode Review Bench
full-hog-mode now sends architecture and hard-design questions to GLM-5.2, visual and spatial UI work to Gemini, and bug finding/review to GLM-5.2 plus Kimi K2.7 Code in parallel via PorkiCoder fan-out. The final gate runs GLM-5.2, Kimi K2.7 Code, and the local code-review pass before ship.

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, Kimi, and GLM-5.2, including Kimi K2.7 Code, 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 (as of v2.7.0, set it under Settings → Agent 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.
Daily Agent Workflow
  1. Scope the run: ask for one feature, bug, review, or refactor at a time. Mention files, commands, and acceptance criteria when you know them.
  2. Let the agent inspect first: for unfamiliar code, ask it to summarize the plan before editing.
  3. Review diffs deliberately: accept good changes, reject risky ones, then ask for a narrower follow-up if needed.
  4. Verify in the same loop: have the agent run tests, start Live Preview, or inspect terminal output before calling the task done.
  5. Use Autopilot sparingly: enable it for repetitive trusted edits; switch back to reviewed diffs for broad changes or unfamiliar files.
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, opencode) 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.

Quick OpenCode launch — The terminal button (Cmd+Shift+O) creates a new named "opencode" tab and starts the OpenCode TUI 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.

Cmd+Shift+O — Quick-launch a new OpenCode session.

Cmd+Shift+. — Toggle between the fullscreen terminal (terminal-first) and the classic IDE layout.
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.

Cmd+K Inline Edit

Cmd+K is the fastest way to change a selected block without starting a full agent run. Select code in the editor, press Cmd+K, describe the edit, and PorkiCoder streams the replacement in place.

Use It For
Small transformations, local refactors, doc comments, type fixes, guard clauses, and focused rewrites where the selected code already contains enough context.
Controls
Esc restores the original while streaming. Cmd+Z after completion reverts the whole edit. Settings → Cmd+K Inline Edit lets you choose the default model, live replacement versus diff-modal review, and the line cap for switching to diff review.
When to use Agent Mode instead
If the edit depends on multiple files, tests, generated code, package installs, or project-wide conventions, ask Agent Mode to inspect the repo and propose a diff instead of using a selection-only Cmd+K edit.

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 six model families — Claude, Gemini, Kimi, GLM, 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 + O Quick-launch a new OpenCode terminal session
  • CMD + SHIFT + . Toggle between the fullscreen terminal (terminal-first) and the classic IDE layout
  • 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.

opencode Backend NEW in v2.6.0

PorkiCoder can drive the open-source opencode agent as a second agent backend. Install opencode (brew install anomalyco/tap/opencode or npm i -g opencode-ai), pick opencode in the model selector, and go — no API key needed. The model runs through PorkiCoder's server and spends from your visible PorkiCoder credit balance on credit plans, separate from your consult allowance.

  • Seven server-funded models: Kimi K2.6 (default), Kimi K2.7 Code, GLM-5.2, Gemini 3.5 Flash, Gemini 3.1 Pro, Grok 4.3, and GPT‑5.5 — switch in opencode's model picker and your choice is respected in agent chat too. Credit-plan users spend from the same Settings credit balance; users outside the credit system keep the legacy small monthly safety quota. (For Claude, use Claude Code or PorkiCoder's built-in Claude agent mode, which drive it natively with prompt caching.)
  • Diff review unchanged: every file write opencode attempts goes through PorkiCoder's accept/reject modal before touching disk.
  • Embedded terminals included: use the OpenCode terminal button or run opencode in any PorkiCoder terminal to get the same PorkiCoder provider automatically.
  • Claude skill compatibility: PorkiCoder mirrors valid Claude skills into an OpenCode-compatible temporary config when opencode needs stricter frontmatter, without modifying your real skill folders.
  • Rate-limit resilience: transient proxy and Baseten-backed model rate-limit failures retry with bounded backoff, while opencode's lightweight summaries use Gemini so background work does not compete with your main Kimi turn.
  • BYO fallback: if the server proxy is unavailable, your own opencode auth login configuration is used instead.
Heads up: opencode's shell commands run outside PorkiCoder's sandbox
PorkiCoder gates opencode's file writes, but opencode's own Bash tool executes outside PorkiCoder's tool runtime — treat opencode as an external agent, the same trust level as running it standalone.

AI Model Support

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

Need Good starting point Notes
Fast everyday coding Kimi K2.6 Default fast path for many coding tasks and inline edits.
Harder code reasoning Kimi K2.7 Code or Claude Opus 4.8 Use higher effort for broad refactors, subtle bugs, or complex architecture changes.
Long-context review GLM-5.2 Useful when the decision depends on many files or a large history of context.
Design, product, and research Gemini Good for UI critique, copy, docs, and web-grounded research tasks.
Terminal-agent work Claude Code, Codex, or opencode Run the CLI inside PorkiCoder, then use bundled consult and fan-out MCP tools as needed.
  • GLM-5.2 NEW in v2.8.3: Pick GLM-5.2 in Chat or Agent Mode, choose it from opencode's PorkiCoder model picker, or call consult_glm52 from Claude Code, Codex, and opencode. It runs through PorkiCoder's Baseten-backed proxy with thinking enabled and a million-token context window.
  • Kimi K2.7 Code fast consults NEW in v2.8.0: Use consult_kimi27_fast from Claude Code, Codex, or opencode when you want the newest Kimi code model with a faster response path. It streams through PorkiCoder's Baseten-backed proxy and falls back to Kimi K2.6 if K2.7 is unavailable.
  • Kimi K2.7 Code UPDATED in v2.8.1: Pick Kimi K2.7 Code in Chat or Agent Mode for Kimi's newest code-focused thinking model. It runs through PorkiCoder's authenticated Baseten-backed proxy for signed-in users, while Kimi K2.6 remains the fast default path.
  • opencode backend with 7 server-funded models UPDATED in v2.8.3: Pick opencode in the model selector to drive the open-source opencode agent through PorkiCoder's server — Kimi K2.6, Kimi K2.7 Code, GLM-5.2, Gemini 3.5 Flash, Gemini 3.1 Pro, Grok 4.3, and GPT‑5.5, no API key required. On credit plans, opencode spends from your visible credit balance. See the opencode Backend section.
  • 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 model family UPDATED in v2.8.3: Claude, Gemini, Kimi, GLM, 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.

Credits & Pricing

PorkiCoder supports both BYOK and server-funded model usage. BYOK calls use your configured provider keys and cost zero PorkiCoder credits. Server-funded calls spend from plan credits, top-ups, or the dedicated consult allowance depending on the surface.

Path What it covers How it is billed
Bring your own keys Chat, Agent Mode, and supported provider calls using keys you add in Settings. No PorkiCoder credit spend; the provider bills you directly.
Included consult allowance MCP consults for Gemini, Kimi, and GLM through the bundled server proxy. $5/mo on Free; $15/mo on Premium/paid plans where available.
Basic Pig Monthly server-funded usage for users who do not want to manage every provider key. $20/mo with 10 credits each month.
Full Hog Higher monthly server-funded usage for heavier agent and opencode work. $200/mo with 150 credits each month.
Top-ups Additional server-funded balance for bursts of work. $25 / $50 / $100 top-ups; top-up credits do not expire.
opencode through PorkiCoder Server-funded opencode model turns. Reserves and settles against the same visible credit balance on credit plans.
Where to find it
Open Settings → Credits to see your balance and plan, subscribe to a plan, or buy a top-up. Claude in Agent Mode now runs on the Anthropic API and is metered like every other model — the integrated terminal still uses your own Claude Code subscription when you type claude there.
Usage & Cost Tracking
Every request's token count and estimated USD cost is tracked per model, so you are not guessing what model calls cost. Open Settings to see current usage, credit balance, plan state, and provider-key configuration.

Settings Map

Most configuration lives in Settings. Use this as a quick map when a feature mentions a key, spend limit, domain, or model default.

Setting area Use it for
API Keys Add BYOK credentials for providers you want billed directly to you.
Credits View balance, subscribe to a plan, buy top-ups, and inspect server-funded usage.
Agent spend ceiling Set a per-run cap so long agent work cannot spend past the ceiling you choose.
Cmd+K Inline Edit Choose default model, live-edit versus diff-review mode, and the large-selection line cap.
Custom Domains Buy, import, connect, transfer, or monitor domains attached to published sites.
Usage Track token counts and estimated cost by model and surface.

MCP Tools Reference

The bundled porkicoder-consult MCP server exposes consult and fan-out tools to Claude Code, Codex, and opencode. Launch terminal agents from PorkiCoder so the auto-registration and local token bridge are active.

Tool Use it for
consult_kimi Fast coding second opinions, refactor sanity checks, and debugging stalemates.
consult_kimi27 / consult_kimi27_fast Deeper Kimi K2.7 Code review, with the fast path for smaller implementation checks.
consult_glm52 Large-context architecture, migration, and implementation tradeoff review.
consult_gemini UI, product, design, research, and broad-context review.
consult_gpt5 High-rigor review for subtle correctness, security, or algorithmic questions.
fanout_run Create isolated candidate worktrees for one task prompt.
fanout_status, fanout_list, fanout_diff Track progress and compare candidate changes using friendly selectors like latest, c1, and winner.
fanout_judge, fanout_apply_winner, fanout_discard, fanout_stop Evaluate candidates, apply a selected patch, clean up worktrees, or cancel active runs.

Troubleshooting

Symptom What to check Fix
MCP tools are missing in Claude Code, Codex, or opencode PorkiCoder is running, you launched the terminal agent after PorkiCoder started, and the CLI is using your normal user config. Restart PorkiCoder, open a fresh terminal tab, then launch the agent again so auto-registration and the token bridge refresh.
A consult says quota or auth is unavailable Your account session, bundled consult allowance, and any configured fallback provider keys. Sign in again, check Settings → Credits, or add the relevant provider key for BYOK fallback where supported.
Fan-out refuses to start The source folder is a git repo, HEAD is attached to a branch, no git operation is in progress, and no likely secrets or dirty submodules must be checkpointed. Commit or stash sensitive changes manually, finish the git operation, or ask the agent to run fan-out after the source tree is clean enough to checkpoint.
Agent Mode appears stuck A diff review modal, long-running shell command, clarifying question, or spend ceiling warning may be waiting for input. Check the activity cards and any modal, then approve/reject the diff, answer the question, or stop the run and resume with a narrower prompt.
Live Preview does not start Project type detection, package install state, dev command errors, and port availability in the 19100-19110 range. Run the dev command in a terminal to see the error, install dependencies, or let PorkiCoder fall back to static serving for plain HTML/CSS/JS sites.
opencode is not available The opencode CLI is installed and on your shell path. Install it with brew install anomalyco/tap/opencode or npm i -g opencode-ai, then open a new PorkiCoder terminal.
Publishing fails Account plan, selected subdomain, static output files, auth session, and any custom-domain provisioning state. Retry after signing in, choose an available subdomain, verify the project has static files to upload, and check Settings → Custom Domains for DNS/SSL status.

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.