local-codex
БесплатноЗапускает вложенные скриптыНе проверенLaunches and manages the local OpenAI Codex CLI as a non-interactive coding sub-agent via ChatGPT OAuth, never API keys. Use to delegate coding tasks to…
от daymade★ 1 556 звёзд на GitHubОб этом скилле
Local Codex
Delegate coding tasks to the local OpenAI Codex CLI agent using the authorized ChatGPT account's OAuth access.
When to Use
- User wants to generate, refactor, or review code via Codex
- User wants to run
codex execfor non-interactive tasks - User wants to use Codex's non-interactive coding agent capabilities
- User mentions "codex", "run codex", "delegate to codex"
Authentication (ChatGPT OAuth)
CRITICAL: Use ChatGPT OAuth through the selected credential store. Do NOT set OPENAI_API_KEY, CODEX_API_KEY, or pass API keys for this workflow (the bundled wrapper strips both environment variables before launching Codex). Keep the authentication route separate from the account's allowance and extra Credit policy; OAuth does not guarantee that long work cannot consume extra Credit.
- Resolve the actual
CODEX_HOMEand store; the desktop app and CLI can share credentials. - For a session managed by a project's Account Manager, enter that project's routine-switch SOP first. Use its deployed operation with the explicit target SID or its documented current-session form; let that operation perform its own binding checks. Query and recover the original request ID. Missing deployed behavior goes to a separately scoped repair, not builds, upgrades or broad quota refreshes inside the routine switch. An unknown managed request stays with that manager; it does not authorize raw RPC or a new login.
- For other login, account switching or token recovery, read the OAuth guide. For a running native owner, compare its account with the saved login first; choose saved-login adoption, token recovery or new authorization from the observed state. Retain independent-grant recovery, explicit single-owner transfers and separate access, process-adoption and business-continuation checks.
- Before a native quota query, read refresh ownership; a nominally read-only query can refresh credentials.
- For quota-driven continuation on another authorized account, use the included-usage check before substantial execution; cached login or a new default file is not that check.
Codex CLI Path
The skill auto-detects Codex CLI in this order:
CODEX_BINenv var, if set — explicit override. A non-executable path fails loudly instead of silently falling through to a different build (that would make whatever the wrapper measured unattributable).which codex— the executable first on the wrapper process's PATH, including npm global installs under nvm (~/.nvm/versions/node/*/bin/codex). This lookup does not execute an interactive shell's alias or function./Applications/ChatGPT.app/Contents/Resources/codex-cli/bin/codex— the copy bundled inside ChatGPT.app, fallback only. Its version tracks the Desktop app and can diverge from the npm build, so it is deliberately last.
If a bad CODEX_BIN was set, the wrapper exits 1 with
{"error": "CODEX_BIN not executable", "path": <value>} — the offending value is in
the error itself, and searched_paths is not emitted for this case (no other search
step ran). If neither PATH nor the app bundle has a codex, the wrapper exits 1 with
the actual search order in searched_paths.
Whichever binary wins, attribute behaviour to it by versioning the binary that
ran. An unrelated shell's codex --version may resolve another entry, which is
the wrong build to quote when the fallback picked the app-bundled one. Use the
codex_path field from the wrapper's status output:
"<codex_path from status output>" --version
Before using this wrapper, resolve the user's ordinary CLI entry. When that entry
is a shell function or launcher supplying network/auth context, use it through
its owning shell instead of silently substituting the discovered binary. On macOS
zsh, inspect with /bin/zsh -lic 'command -v codex; codex --version', then run
codex inside that same shell mode. Put the finite timeout around the shell
process: gtimeout … codex resolves an executable and cannot call a shell function.
The bundled Python wrapper does not reproduce shell initialization or support
every native flag; use native CLI invocation when those capabilities are required.
Executable identity baseline (opt-in)
Before an expensive build, resume or recovery claim that depends on which codex entry is in play, freeze the identity once and compare it at claim time; never refresh a baseline to make a comparison pass.
# Freeze once, before the work (add --watch-file for owner-selected configs):
python3 scripts/entry_identity.py snapshot --output <task-owned-baseline.json>
# Compare before the expensive claim:
python3 scripts/entry_identity.py check --baseline
Установить local-codex в Claude Code и Claude Desktop
Зарегайся, чтобы установить скилл
Создай бесплатный аккаунт, чтобы открыть команду установки и сохранить скилл в библиотеку.
- Открой команду установки в одну строку
- Сохраняй скиллы в синхронизируемую библиотеку
- Уведомления, когда скиллы обновляются
Разрешённые инструменты
Инструменты, которые скиллу разрешено вызывать.
Без ограничений — скилл может использовать любой инструмент.
Вложенные файлы
FAQ
Что делает скилл local-codex?
Launches and manages the local OpenAI Codex CLI as a non-interactive coding sub-agent via ChatGPT OAuth, never API keys. Use to delegate coding tasks to Codex, run codex exec, generate or refactor code, or get a Codex code review; phrases like 'codex', 'run codex', 'codex exec', 'delegate to codex'. Also route here for local Codex upgrades (including prereleases), shared app-server daemon lifecycle and fault recovery: daemon restart, Codex hooks or spawns failing with 'Too many open files', fd exhaustion diagnostics; phrases like 'codex daemon', 'daemon 重启', 'Too many open files'.
Как установить скилл local-codex?
Скопируй папку скилла в ~/.claude/skills (вкладка Claude Code выше делает это одной командой), либо поставь как плагин.
Скилл local-codex запускает скрипты?
Да, скилл несёт исполняемые скрипты. Проверь исходник перед установкой.
Похожие скиллы
mcp-builder
Guide for creating high-quality MCP (Model Context Protocol) servers that enable LLMs to interact with external services through well-designed tools. Use when…
от Anthropicclaude-api
Reference for the Claude API / Anthropic SDK — model ids, pricing, params, streaming, tool use, MCP, agents, caching, token counting, model migration. TRIGGER…
от Anthropicalgorithmic-art
Creating algorithmic art using p5.js with seeded randomness and interactive parameter exploration. Use this when users request creating art using code…
от Anthropicmcp-integration
This skill should be used when the user asks to "add MCP server", "integrate MCP", "configure MCP in plugin", "use .mcp.json", "set up Model Context…
от Anthropic