View on GitHub →

local-model-plugin-cc

Claude Code review and rescue workflows backed by local models

  • JavaScript
  • Shell
  • Claude Code Plugin SDK
  • codex CLI

A Claude Code plugin that delegates code review, adversarial review, and coding rescue tasks to local models through the codex CLI.

Problem

How do you bring Codex-style review and rescue workflows into Claude Code while keeping model execution local through Ollama, LM Studio, or custom OpenAI-compatible endpoints?

Approach

The plugin acts as a thin broker between Claude Code commands and OpenAI’s codex CLI. Instead of requiring a hosted model provider, it points Codex at a local model server with ephemeral model_providers CLI overrides for Ollama, LM Studio, or a custom OpenAI-compatible endpoint.

/local:setup detects common local servers, lets the user pick a model, and smoke-tests the configuration. /local:review and /local:adversarial-review run codex exec review in a read-only sandbox for structured, file-grounded findings. /local:rescue delegates implementation work under a workspace-write sandbox, then applies a post-hoc diff-safety check before treating the job as usable.

Background job commands (/local:status, /local:result, and /local:cancel) make longer local-model runs manageable without adding a separate agent runtime or generated configuration layer.

Outcome

A local-model counterpart to openai/codex-plugin-cc that keeps Claude Code workflows close to the user’s machine while still relying on Codex’s sandboxing, tool loop, and review behavior.

Architecture

Claude Code commands call broker scripts in the plugin package, which invoke the codex CLI with per-run provider overrides and sandbox settings. Tests use Node’s built-in test runner with a fake codex binary fixture so CI can validate command behavior without a live local model server.