[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"skill:01M75CG7ZG8DQHFRAHNARNSJEX":3,"skill-same:01M75CG7ZG8DQHFRAHNARNSJEX":48},{"skillNo":4,"name":5,"nameZh":6,"description":7,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":9,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":15,"categories":16,"keywords":17,"publishedAt":18,"linkOnly":19,"markdownContent":20,"markdownBody":21,"frontMatter":22,"refName":25,"commitSha":26,"skillDirectory":27,"forksCount":28,"repositoryHtmlUrl":29,"repositoryHomepageUrl":30,"ownerHtmlUrl":31,"ownerBlogUrl":32,"ownerDescription":6,"updatedAt":33,"install":34,"resources":47},"01M75CG7ZG8DQHFRAHNARNSJEX","consult",null,"Cross-tool AI consultation. Use when user asks to 'consult gemini', 'ask codex', 'get second opinion', 'cross-check with claude', 'consult another AI', 'ask opencode', 'copilot opinion', or wants a second opinion from a different AI tool.","agisota\u002Fold-one","agisota","https:\u002F\u002Favatars.githubusercontent.com\u002Fu\u002F121413592?v=4","01M75B4BRNT67EC1NDRT8QZEP2","01M75B4BS7QR9VP580MSCPTS3X",3,"MIT","https:\u002F\u002Fgithub.com\u002Fagisota\u002Fold-one\u002Fblob\u002Fmain\u002Fskills\u002Fconsult\u002FSKILL.md",[],[],"2026-11-12 13:55:43",false,"---\nname: consult\ndescription: \"Cross-tool AI consultation. Use when user asks to 'consult gemini', 'ask codex', 'get second opinion', 'cross-check with claude', 'consult another AI', 'ask opencode', 'copilot opinion', or wants a second opinion from a different AI tool.\"\nversion: 5.1.0\nargument-hint: \"[question] [--tool] [--effort] [--model] [--context] [--continue]\"\n---\n\n# consult\n\nCross-tool AI consultation: query another AI CLI tool and return the response.\n\n## When to Use\n\nInvoke this skill when:\n- User wants a second opinion from a different AI tool\n- User asks to consult, ask, or cross-check with gemini\u002Fcodex\u002Fclaude\u002Fopencode\u002Fcopilot\n- User needs to compare responses across AI tools\n- User wants to validate a decision with an external AI\n\n## Arguments\n\nParse from `$ARGUMENTS`:\n\n| Flag | Values | Default | Description |\n|------|--------|---------|-------------|\n| `--tool` | gemini, codex, claude, opencode, copilot | (picker) | Target tool |\n| `--effort` | low, medium, high, max | medium | Thinking effort level |\n| `--model` | any model name | (from effort) | Override model selection |\n| `--context` | diff, file=PATH, none | none | Auto-include context |\n| `--continue` | (flag) or SESSION_ID | false | Resume previous session |\n\nQuestion text is everything in `$ARGUMENTS` except the flags above.\n\n## Provider Configurations\n\n### Claude\n\n```\nCommand: env -u CLAUDECODE claude -p \"QUESTION\" --output-format json --model \"MODEL\" --max-turns TURNS --allowedTools \"Read,Glob,Grep\"\nSession resume: --resume \"SESSION_ID\"\n```\n\nModels: claude-haiku-4-5, claude-sonnet-4-6, claude-opus-4-6\n\n| Effort | Model | Max Turns |\n|--------|-------|-----------|\n| low | claude-haiku-4-5 | 1 |\n| medium | claude-sonnet-4-6 | 3 |\n| high | claude-opus-4-6 | 5 |\n| max | claude-opus-4-6 | 10 |\n\n**Parse output**: `JSON.parse(stdout).result`\n**Session ID**: `JSON.parse(stdout).session_id`\n**Continuable**: Yes\n**ACP adapter**: `npx -y @anthropic-ai\u002Fclaude-code-acp` (see ACP Transport section)\n\n### Gemini\n\n```\nCommand: gemini -p \"QUESTION\" --output-format json -m \"MODEL\"\nSession resume: --resume \"SESSION_ID\"\n```\n\nModels: gemini-2.5-flash, gemini-2.5-pro, gemini-3-flash-preview, gemini-3-pro-preview, gemini-3.1-pro-preview\n\n| Effort | Model |\n|--------|-------|\n| low | gemini-3-flash-preview |\n| medium | gemini-3-flash-preview |\n| high | gemini-3.1-pro-preview |\n| max | gemini-3.1-pro-preview |\n\n**Parse output**: `JSON.parse(stdout).response`\n**Session ID**: `JSON.parse(stdout).session_id`\n**Continuable**: Yes (via `--resume`)\n**ACP adapter**: `gemini` (native ACP - Gemini CLI is ACP-compatible)\n\n### Codex\n\n```\nCommand: codex exec \"QUESTION\" --json -m \"MODEL\" {SKIP_GIT_FLAG} -c model_reasoning_effort=\"LEVEL\"\nSession resume: codex exec resume \"SESSION_ID\" \"QUESTION\" --json -m \"MODEL\" {SKIP_GIT_FLAG} -c model_reasoning_effort=\"LEVEL\"\nSession resume (latest): codex exec resume --last \"QUESTION\" --json -m \"MODEL\" {SKIP_GIT_FLAG} -c model_reasoning_effort=\"LEVEL\"\n```\n\nNote: `codex exec` is the non-interactive\u002Fheadless mode. There is no `-q` flag. The TUI mode is `codex` (no subcommand).\n`{SKIP_GIT_FLAG}` is resolved by the trust gate in Command Building Step 1b:\n- inside trusted git repo: empty string\n- trusted non-repo execution: `--skip-git-repo-check`\n\nModels: gpt-5.3-codex\n\n| Effort | Model | Reasoning |\n|--------|-------|-----------|\n| low | gpt-5.3-codex | low |\n| medium | gpt-5.3-codex | medium |\n| high | gpt-5.3-codex | high |\n| max | gpt-5.3-codex | high |\n\n**Parse output**: `JSON.parse(stdout).message` or raw text\n**Session ID**: Codex prints a resume hint at session end (e.g., `codex resume SESSION_ID`). Extract the session ID from stdout or from `JSON.parse(stdout).session_id` if available.\n**Continuable**: Yes. Sessions are stored as JSONL rollout files at `~\u002F.codex\u002Fsessions\u002F`. Non-interactive resume uses `codex exec resume \"SESSION_ID\" \"follow-up prompt\" --json -m \"MODEL\" {SKIP_GIT_FLAG} -c model_reasoning_effort=\"LEVEL\"`. Use `--last` instead of a session ID to resume the most recent session.\n**ACP adapter**: `npx -y @zed-industries\u002Fcodex-acp` (see ACP Transport section)\n\n### OpenCode\n\n```\nCommand: opencode run \"QUESTION\" --format json --model \"MODEL\" --variant \"VARIANT\"\nSession resume: opencode run \"QUESTION\" --format json --model \"MODEL\" --variant \"VARIANT\" --continue (most recent) or --session \"SESSION_ID\"\nWith thinking: add --thinking flag\n```\n\nModels: 75+ via providers (format: `provider\u002Fmodel`). Key providers: `opencode\u002F` (free), `github-copilot\u002F`, `amazon-bedrock\u002F`, `google\u002F`. Examples: `github-copilot\u002Fgemini-3.1-pro-preview`, `opencode\u002Fbig-pickle`, `amazon-bedrock\u002Fanthropic.claude-opus-4-6-v1`. Run `opencode models` to list all.\n\nFree models: `opencode\u002Fbig-pickle`, `opencode\u002Fgpt-5-nano`, `opencode\u002Fminimax-m2.5-free`, `opencode\u002Ftrinity-large-preview-free`\n\n| Effort | Model | Variant |\n|--------|-------|---------|\n| low | (user-selected or default) | low |\n| medium | (user-selected or default) | medium |\n| high | (user-selected or default) | high |\n| max | (user-selected or default) | high + --thinking |\n\n**Parse output**: OpenCode outputs newline-delimited JSON events. Each line is a JSON object with a `type` field. Extract the response text from events where `type === \"text\"` - the text is in `part.text` (NOT `part.content`). Concatenate all `part.text` values from `type: \"text\"` events. Event types: `step_start`, `tool_use`, `text`, `step_finish`. The `sessionID` is in every event's top-level `sessionID` field.\n\n**Session ID**: Available in every event as `event.sessionID` (e.g., `ses_xxxxx`). Use `--session SESSION_ID` to resume.\n**Continuable**: Yes (via `--continue` or `--session`). Sessions are stored in a SQLite database in the OpenCode data directory. Use `--session SESSION_ID` for a specific session, or `--continue` for the most recent.\n**ACP adapter**: `opencode acp` (see ACP Transport section)\n\n### Copilot\n\n```\nCommand: copilot -p \"QUESTION\"\n```\n\nModels: claude-sonnet-4-6 (default), claude-opus-4-6, claude-haiku-4-5, gpt-5\n\n| Effort | Notes |\n|--------|-------|\n| all | No effort control available. Model selectable via --model flag. |\n\n**Parse output**: Raw text from stdout\n**Continuable**: No\n**ACP adapter**: `copilot --acp --stdio` (see ACP Transport section)\n\n### Kiro\n\n```\nACP-only provider. No CLI mode for external consultation.\nCommand: node acp\u002Frun.js --provider=\"kiro\" --question-file=\"{AI_STATE_DIR}\u002Fconsult\u002Fquestion.tmp\" --timeout=120000\n```\n\nKiro is available only via ACP transport. It requires `kiro-cli` on PATH.\n\n**Parse output**: Via ACP runner (`JSON.parse(stdout)`)\n**Continuable**: No\n**ACP adapter**: `kiro-cli acp` (native ACP)\n\n## Input Validation\n\nBefore building commands, validate all user-provided arguments:\n\n- **--tool**: MUST be one of: gemini, codex, claude, opencode, copilot, kiro. Reject all other values.\n- **--effort**: MUST be one of: low, medium, high, max. Default to medium.\n- **--model**: Allow any string, but quote it in the command.\n- **--continue=SESSION_ID**: If provided, SESSION_ID MUST match `^(?!-)[A-Za-z0-9._:-]+$`. Reject values that contain spaces, leading dashes, or shell metacharacters.\n- **--context=file=PATH**: MUST resolve within the project directory. Reject absolute paths outside cwd. Additional checks:\n  1. **Block UNC paths** (Windows): Reject paths starting with `\\\\` or `\u002F\u002F` (network shares)\n  2. **Resolve canonical path**: Use the Read tool to read the file (do NOT use shell commands). Before reading, resolve the path: join `cwd + PATH`, then normalize (collapse `.`, `..`, resolve symlinks)\n  3. **Verify containment**: The resolved canonical path MUST start with the current working directory. If it escapes (via `..`, symlinks, or junction points), reject with: `[ERROR] Path escapes project directory: {PATH}`\n  4. **No shell access**: Read file content using the Read tool only. Never pass user-provided paths to shell commands (prevents injection via path values)\n\n## Command Building\n\nGiven the parsed arguments, build the complete CLI command. All user-provided values MUST be quoted in the shell command to prevent injection.\n\n### Step 1: Resolve Model\n\nIf `--model` is specified, use it directly. Otherwise, use the effort-based model from the provider table above.\n\n### Step 1b: Trust Gate for Codex `--skip-git-repo-check`\n\nBefore using any Codex template, resolve `{SKIP_GIT_FLAG}` with this gate:\n\n1. Verify the consultation is running from the current project working directory (the same workspace where `\u002Fconsult` was invoked), not an arbitrary external path.\n2. Verify the resolved active tool is Codex (flag, NLP, picker, or restored `--continue` session).\n3. Run `git rev-parse --is-inside-work-tree` in the current working directory:\n   - if true: set `{SKIP_GIT_FLAG}` to empty string\n   - if false and checks 1-2 passed: set `{SKIP_GIT_FLAG}` to `--skip-git-repo-check`\n4. If checks 1-2 fail, reject execution with `[ERROR] Refusing Codex --skip-git-repo-check outside trusted working directory`.\n\nCodex templates in this skill assume this trust gate has already passed.\n\n### Step 2: Build Command String\n\nUse the command template from the provider's configuration section. Substitute QUESTION, MODEL, TURNS, LEVEL, VARIANT, and SKIP_GIT_FLAG with resolved literal values.\n`{SKIP_GIT_FLAG}` MUST be set by Step 1b only. Do not read `SKIP_GIT_FLAG` from inherited shell environment.\n\nIf continuing a session:\n- **Claude or Gemini**: append `--resume \"SESSION_ID\"` to the command.\n- **Codex**: use `codex exec resume \"SESSION_ID\" \"QUESTION\" --json -m \"MODEL\" {SKIP_GIT_FLAG} -c model_reasoning_effort=\"LEVEL\"` instead of the standard command. Use `--last` instead of a session ID for the most recent session.\n- **OpenCode**: append `--session SESSION_ID` to the command. If no session_id is saved, use `--continue` instead (resumes most recent session).\nIf OpenCode at max effort: append `--thinking`.\n\n### Step 3: Context Packaging\n\nIf `--context=diff`: Run `git diff 2>\u002Fdev\u002Fnull` and prepend output to the question.\nIf `--context=file=PATH`: Read the file using the Read tool and prepend its content to the question.\n\n### Step 4: Safe Question Passing\n\nUser-provided question text MUST NOT be interpolated into shell command strings. Shell escaping is insufficient -- `$()`, backticks, and other expansion sequences can execute arbitrary commands even inside double quotes.\n\n**Required approach -- pass question via stdin or temp file:**\n\n1. **Write the question** to a temporary file using the Write tool (e.g., `{AI_STATE_DIR}\u002Fconsult\u002Fquestion.tmp`)\n\n   Platform state directory:\n   - Claude Code: `.claude\u002F`\n   - OpenCode: `.opencode\u002F`\n   - Codex CLI: `.codex\u002F`\n2. **Build the command** using the temp file as input instead of inline text:\n\n| Provider | Safe command pattern |\n|----------|---------------------|\n| Claude | `env -u CLAUDECODE claude -p - --output-format json --model \"MODEL\" --max-turns TURNS --allowedTools \"Read,Glob,Grep\" \u003C \"{AI_STATE_DIR}\u002Fconsult\u002Fquestion.tmp\"` |\n| Claude (resume) | `env -u CLAUDECODE claude -p - --output-format json --model \"MODEL\" --max-turns TURNS --allowedTools \"Read,Glob,Grep\" --resume \"SESSION_ID\" \u003C \"{AI_STATE_DIR}\u002Fconsult\u002Fquestion.tmp\"` |\n| Gemini | `gemini -p - --output-format json -m \"MODEL\" \u003C \"{AI_STATE_DIR}\u002Fconsult\u002Fquestion.tmp\"` |\n| Gemini (resume) | `gemini -p - --output-format json -m \"MODEL\" --resume \"SESSION_ID\" \u003C \"{AI_STATE_DIR}\u002Fconsult\u002Fquestion.tmp\"` |\n| Codex | `codex exec \"$(cat \"{AI_STATE_DIR}\u002Fconsult\u002Fquestion.tmp\")\" --json -m \"MODEL\" {SKIP_GIT_FLAG} -c model_reasoning_effort=\"LEVEL\"` (Codex exec lacks stdin mode -- cat reads from platform-controlled path, not user input) |\n| Codex (resume) | `codex exec resume \"SESSION_ID\" \"$(cat \"{AI_STATE_DIR}\u002Fconsult\u002Fquestion.tmp\")\" --json -m \"MODEL\" {SKIP_GIT_FLAG} -c model_reasoning_effort=\"LEVEL\"` |\n| Codex (resume latest) | `codex exec resume --last \"$(cat \"{AI_STATE_DIR}\u002Fconsult\u002Fquestion.tmp\")\" --json -m \"MODEL\" {SKIP_GIT_FLAG} -c model_reasoning_effort=\"LEVEL\"` |\n| OpenCode | `opencode run - --format json --model \"MODEL\" --variant \"VARIANT\" \u003C \"{AI_STATE_DIR}\u002Fconsult\u002Fquestion.tmp\"` |\n| OpenCode (resume by ID) | `opencode run - --format json --model \"MODEL\" --variant \"VARIANT\" --session \"SESSION_ID\" \u003C \"{AI_STATE_DIR}\u002Fconsult\u002Fquestion.tmp\"` |\n| OpenCode (resume latest) | `opencode run - --format json --model \"MODEL\" --variant \"VARIANT\" --continue \u003C \"{AI_STATE_DIR}\u002Fconsult\u002Fquestion.tmp\"` |\n| Copilot | `copilot -p - \u003C \"{AI_STATE_DIR}\u002Fconsult\u002Fquestion.tmp\"` |\n\n3. **Delete the temp file** after the command completes (success or failure). Always clean up to prevent accumulation.\n\n**Model and session ID values** are controlled strings (from pickers or saved state) and safe to quote directly in the command. Only the question contains arbitrary user text and requires the temp file approach. The temp file path (`{AI_STATE_DIR}\u002Fconsult\u002Fquestion.tmp`) uses a platform-controlled directory and fixed filename -- no user input in the path.\n\n## Provider Detection\n\nCross-platform tool detection:\n\n- **Windows**: `where.exe TOOL 2>nul` -- returns 0 if found\n- **Unix**: `which TOOL 2>\u002Fdev\u002Fnull` -- returns 0 if found\n\nCheck each tool (claude, gemini, codex, opencode, copilot, kiro) and return only the available ones.\n\n## ACP Transport\n\nACP (Agent Client Protocol) is an alternative transport to CLI subprocess invocation. When available, ACP provides structured JSON-RPC 2.0 communication, session persistence, and streaming responses via a universal protocol supported by all major AI coding tools.\n\n### ACP Provider Adapters\n\n| Provider | ACP Command | Type | Detection |\n|----------|-------------|------|-----------|\n| Claude | `npx -y @anthropic-ai\u002Fclaude-code-acp` | adapter | npx available |\n| Gemini | `gemini` (native ACP) | native | gemini available |\n| Codex | `npx -y @zed-industries\u002Fcodex-acp` | adapter | npx available |\n| Copilot | `copilot --acp --stdio` | native | copilot available |\n| Kiro | `kiro-cli acp` | native | kiro-cli available |\n| OpenCode | `opencode acp` | native | opencode available |\n\n### Transport Selection\n\n1. Check ACP availability for the target provider (see ACP Detection below)\n2. If ACP available: use ACP transport (preferred - standardized protocol, session persistence)\n3. If ACP unavailable: fall back to CLI transport (existing behavior above)\n\nThe output envelope is identical regardless of transport. Downstream consumers (session management, debate orchestrator, output parsing) are transport-agnostic.\n\n### ACP Command Template\n\nAll ACP providers use the same command pattern via the ACP runner script:\n\n```\nnode acp\u002Frun.js --provider=\"PROVIDER\" --question-file=\"{AI_STATE_DIR}\u002Fconsult\u002Fquestion.tmp\" --timeout=TIMEOUT_MS [--model=\"MODEL\"] [--session-id=\"SESSION_ID\"]\n```\n\n| Provider | ACP Safe Command Pattern |\n|----------|------------------------|\n| Claude | `node acp\u002Frun.js --provider=\"claude\" --question-file=\"{AI_STATE_DIR}\u002Fconsult\u002Fquestion.tmp\" --timeout=120000 --model=\"MODEL\"` |\n| Gemini | `node acp\u002Frun.js --provider=\"gemini\" --question-file=\"{AI_STATE_DIR}\u002Fconsult\u002Fquestion.tmp\" --timeout=120000 --model=\"MODEL\"` |\n| Codex | `node acp\u002Frun.js --provider=\"codex\" --question-file=\"{AI_STATE_DIR}\u002Fconsult\u002Fquestion.tmp\" --timeout=120000 --model=\"MODEL\"` |\n| OpenCode | `node acp\u002Frun.js --provider=\"opencode\" --question-file=\"{AI_STATE_DIR}\u002Fconsult\u002Fquestion.tmp\" --timeout=120000 --model=\"MODEL\"` |\n| Copilot | `node acp\u002Frun.js --provider=\"copilot\" --question-file=\"{AI_STATE_DIR}\u002Fconsult\u002Fquestion.tmp\" --timeout=120000` |\n| Kiro | `node acp\u002Frun.js --provider=\"kiro\" --question-file=\"{AI_STATE_DIR}\u002Fconsult\u002Fquestion.tmp\" --timeout=120000` |\n\n**Parse output**: Same as CLI transport - `JSON.parse(stdout)`. The ACP runner outputs the same envelope format.\n**Session ID**: From `JSON.parse(stdout).session_id` (ACP session ID)\n**Resume**: Pass `--session-id=\"SESSION_ID\"` flag on the ACP command\n**Continuable**: Claude, Gemini, Codex, OpenCode (yes). Copilot, Kiro (no).\n\n### ACP Detection\n\nRun ACP detection alongside CLI detection. For each provider:\n\n```bash\nnode acp\u002Frun.js --detect --provider=\"PROVIDER\"\n```\n\nReturns on success (exit 0):\n```json\n{\"provider\": \"claude\", \"acp_available\": true, \"name\": \"Claude\"}\n```\n\nReturns on failure (exit 1):\n```json\n{\"provider\": \"claude\", \"acp_available\": false, \"name\": \"Claude\", \"reason\": \"npx not found on PATH\"}\n```\n\n**Kiro note**: Kiro is ACP-only - it has no CLI mode for external consultation. It only appears as available when `kiro-cli` is on PATH and ACP detection succeeds.\n\n## Session Management\n\n### Save Session\n\nAfter successful consultation, save to `{AI_STATE_DIR}\u002Fconsult\u002Flast-session.json`:\n\n```json\n{\n  \"tool\": \"claude\",\n  \"model\": \"opus\",\n  \"effort\": \"high\",\n  \"session_id\": \"abc-123-def-456\",\n  \"timestamp\": \"2026-02-10T12:00:00Z\",\n  \"question\": \"original question text\",\n  \"continuable\": true,\n  \"transport\": \"acp\"\n}\n```\n\nThe `transport` field is `\"acp\"` or `\"cli\"`. When resuming a session with `--continue`, use the same transport that created it. If the field is absent, assume `\"cli\"` (backward compatible).\n\n`AI_STATE_DIR` uses the platform state directory:\n- Claude Code: `.claude\u002F`\n- OpenCode: `.opencode\u002F`\n- Codex CLI: `.codex\u002F`\n\n### Load Session\n\nFor `--continue`, read the session file and restore:\n- tool (from saved state)\n- session_id (for --resume flag)\n- model (reuse same model)\n\nBefore using restored values, re-validate them:\n- tool must still be in allow-list: gemini, codex, claude, opencode, copilot, kiro\n- session_id must match `^(?!-)[A-Za-z0-9._:-]+$`\n- model must match `^[A-Za-z0-9._:\u002F-]+$` (reject spaces and shell metacharacters)\n- if either check fails, reject with `[ERROR] Invalid restored session data` and do not build a command\n\nIf session file not found, warn and proceed as fresh consultation.\n\n## Output Sanitization\n\nBefore including any consulted tool's response in the output, scan the response text and redact matches for these patterns:\n\n| Pattern | Description | Replacement |\n|---------|-------------|-------------|\n| `sk-[a-zA-Z0-9_-]{20,}` | Anthropic API keys | `[REDACTED_API_KEY]` |\n| `sk-proj-[a-zA-Z0-9_-]{20,}` | OpenAI project keys | `[REDACTED_API_KEY]` |\n| `sk-ant-[a-zA-Z0-9_-]{20,}` | Anthropic API keys (ant prefix) | `[REDACTED_API_KEY]` |\n| `AIza[a-zA-Z0-9_-]{30,}` | Google API keys | `[REDACTED_API_KEY]` |\n| `ghp_[a-zA-Z0-9]{36,}` | GitHub personal access tokens | `[REDACTED_TOKEN]` |\n| `gho_[a-zA-Z0-9]{36,}` | GitHub OAuth tokens | `[REDACTED_TOKEN]` |\n| `github_pat_[a-zA-Z0-9_]{20,}` | GitHub fine-grained PATs | `[REDACTED_TOKEN]` |\n| `ANTHROPIC_API_KEY=[^\\s]+` | Key assignment in env output | `ANTHROPIC_API_KEY=[REDACTED]` |\n| `OPENAI_API_KEY=[^\\s]+` | Key assignment in env output | `OPENAI_API_KEY=[REDACTED]` |\n| `GOOGLE_API_KEY=[^\\s]+` | Key assignment in env output | `GOOGLE_API_KEY=[REDACTED]` |\n| `GEMINI_API_KEY=[^\\s]+` | Key assignment in env output | `GEMINI_API_KEY=[REDACTED]` |\n| `AKIA[A-Z0-9]{16}` | AWS access keys | `[REDACTED_AWS_KEY]` |\n| `ASIA[A-Z0-9]{16}` | AWS session tokens | `[REDACTED_AWS_KEY]` |\n| `Bearer [a-zA-Z0-9_-]{20,}` | Authorization headers | `Bearer [REDACTED]` |\n\nApply redaction to the full response text before inserting into the result JSON. If any redaction occurs, append a note: `[WARN] Sensitive tokens were redacted from the response.`\n\n## Output Format\n\nReturn a plain JSON object to stdout (no markers or wrappers):\n\n```json\n{\n  \"tool\": \"gemini\",\n  \"model\": \"gemini-3.1-pro-preview\",\n  \"effort\": \"high\",\n  \"duration_ms\": 12300,\n  \"response\": \"The AI's response text here...\",\n  \"session_id\": \"abc-123\",\n  \"continuable\": true\n}\n```\n\n## Install Instructions\n\nWhen a tool is not found, return these install commands:\n\n| Tool | Install |\n|------|---------|\n| Claude | `npm install -g @anthropic-ai\u002Fclaude-code` |\n| Gemini | See https:\u002F\u002Fgemini.google.com\u002Fcli for install instructions |\n| Codex | `npm install -g @openai\u002Fcodex` |\n| OpenCode | `npm install -g opencode-ai` or `brew install anomalyco\u002Ftap\u002Fopencode` |\n| Copilot | `gh extension install github\u002Fcopilot-cli` |\n\n## Error Handling\n\n| Error | Response |\n|-------|----------|\n| Tool not installed | Return install instructions from table above |\n| Tool execution timeout | Return `\"response\": \"Timeout after 120s\"` |\n| JSON parse error | Return raw text as response |\n| Empty output | Return `\"response\": \"No output received\"` |\n| Session file missing | Proceed without session resume |\n| API key missing | Return tool-specific env var instructions |\n\n## Integration\n\nThis skill is invoked by:\n- `consult-agent` for `\u002Fconsult` command\n- Direct invocation: `Skill('consult', '\"question\" --tool=gemini --effort=high')`\n\nExample: `Skill('consult', '\"Is this approach correct?\" --tool=gemini --effort=high --model=gemini-3.1-pro-preview')`\n","# consult\n\nCross-tool AI consultation: query another AI CLI tool and return the response.\n\n## When to Use\n\nInvoke this skill when:\n- User wants a second opinion from a different AI tool\n- User asks to consult, ask, or cross-check with gemini\u002Fcodex\u002Fclaude\u002Fopencode\u002Fcopilot\n- User needs to compare responses across AI tools\n- User wants to validate a decision with an external AI\n\n## Arguments\n\nParse from `$ARGUMENTS`:\n\n| Flag | Values | Default | Description |\n|------|--------|---------|-------------|\n| `--tool` | gemini, codex, claude, opencode, copilot | (picker) | Target tool |\n| `--effort` | low, medium, high, max | medium | Thinking effort level |\n| `--model` | any model name | (from effort) | Override model selection |\n| `--context` | diff, file=PATH, none | none | Auto-include context |\n| `--continue` | (flag) or SESSION_ID | false | Resume previous session |\n\nQuestion text is everything in `$ARGUMENTS` except the flags above.\n\n## Provider Configurations\n\n### Claude\n\n```\nCommand: env -u CLAUDECODE claude -p \"QUESTION\" --output-format json --model \"MODEL\" --max-turns TURNS --allowedTools \"Read,Glob,Grep\"\nSession resume: --resume \"SESSION_ID\"\n```\n\nModels: claude-haiku-4-5, claude-sonnet-4-6, claude-opus-4-6\n\n| Effort | Model | Max Turns |\n|--------|-------|-----------|\n| low | claude-haiku-4-5 | 1 |\n| medium | claude-sonnet-4-6 | 3 |\n| high | claude-opus-4-6 | 5 |\n| max | claude-opus-4-6 | 10 |\n\n**Parse output**: `JSON.parse(stdout).result`\n**Session ID**: `JSON.parse(stdout).session_id`\n**Continuable**: Yes\n**ACP adapter**: `npx -y @anthropic-ai\u002Fclaude-code-acp` (see ACP Transport section)\n\n### Gemini\n\n```\nCommand: gemini -p \"QUESTION\" --output-format json -m \"MODEL\"\nSession resume: --resume \"SESSION_ID\"\n```\n\nModels: gemini-2.5-flash, gemini-2.5-pro, gemini-3-flash-preview, gemini-3-pro-preview, gemini-3.1-pro-preview\n\n| Effort | Model |\n|--------|-------|\n| low | gemini-3-flash-preview |\n| medium | gemini-3-flash-preview |\n| high | gemini-3.1-pro-preview |\n| max | gemini-3.1-pro-preview |\n\n**Parse output**: `JSON.parse(stdout).response`\n**Session ID**: `JSON.parse(stdout).session_id`\n**Continuable**: Yes (via `--resume`)\n**ACP adapter**: `gemini` (native ACP - Gemini CLI is ACP-compatible)\n\n### Codex\n\n```\nCommand: codex exec \"QUESTION\" --json -m \"MODEL\" {SKIP_GIT_FLAG} -c model_reasoning_effort=\"LEVEL\"\nSession resume: codex exec resume \"SESSION_ID\" \"QUESTION\" --json -m \"MODEL\" {SKIP_GIT_FLAG} -c model_reasoning_effort=\"LEVEL\"\nSession resume (latest): codex exec resume --last \"QUESTION\" --json -m \"MODEL\" {SKIP_GIT_FLAG} -c model_reasoning_effort=\"LEVEL\"\n```\n\nNote: `codex exec` is the non-interactive\u002Fheadless mode. There is no `-q` flag. The TUI mode is `codex` (no subcommand).\n`{SKIP_GIT_FLAG}` is resolved by the trust gate in Command Building Step 1b:\n- inside trusted git repo: empty string\n- trusted non-repo execution: `--skip-git-repo-check`\n\nModels: gpt-5.3-codex\n\n| Effort | Model | Reasoning |\n|--------|-------|-----------|\n| low | gpt-5.3-codex | low |\n| medium | gpt-5.3-codex | medium |\n| high | gpt-5.3-codex | high |\n| max | gpt-5.3-codex | high |\n\n**Parse output**: `JSON.parse(stdout).message` or raw text\n**Session ID**: Codex prints a resume hint at session end (e.g., `codex resume SESSION_ID`). Extract the session ID from stdout or from `JSON.parse(stdout).session_id` if available.\n**Continuable**: Yes. Sessions are stored as JSONL rollout files at `~\u002F.codex\u002Fsessions\u002F`. Non-interactive resume uses `codex exec resume \"SESSION_ID\" \"follow-up prompt\" --json -m \"MODEL\" {SKIP_GIT_FLAG} -c model_reasoning_effort=\"LEVEL\"`. Use `--last` instead of a session ID to resume the most recent session.\n**ACP adapter**: `npx -y @zed-industries\u002Fcodex-acp` (see ACP Transport section)\n\n### OpenCode\n\n```\nCommand: opencode run \"QUESTION\" --format json --model \"MODEL\" --variant \"VARIANT\"\nSession resume: opencode run \"QUESTION\" --format json --model \"MODEL\" --variant \"VARIANT\" --continue (most recent) or --session \"SESSION_ID\"\nWith thinking: add --thinking flag\n```\n\nModels: 75+ via providers (format: `provider\u002Fmodel`). Key providers: `opencode\u002F` (free), `github-copilot\u002F`, `amazon-bedrock\u002F`, `google\u002F`. Examples: `github-copilot\u002Fgemini-3.1-pro-preview`, `opencode\u002Fbig-pickle`, `amazon-bedrock\u002Fanthropic.claude-opus-4-6-v1`. Run `opencode models` to list all.\n\nFree models: `opencode\u002Fbig-pickle`, `opencode\u002Fgpt-5-nano`, `opencode\u002Fminimax-m2.5-free`, `opencode\u002Ftrinity-large-preview-free`\n\n| Effort | Model | Variant |\n|--------|-------|---------|\n| low | (user-selected or default) | low |\n| medium | (user-selected or default) | medium |\n| high | (user-selected or default) | high |\n| max | (user-selected or default) | high + --thinking |\n\n**Parse output**: OpenCode outputs newline-delimited JSON events. Each line is a JSON object with a `type` field. Extract the response text from events where `type === \"text\"` - the text is in `part.text` (NOT `part.content`). Concatenate all `part.text` values from `type: \"text\"` events. Event types: `step_start`, `tool_use`, `text`, `step_finish`. The `sessionID` is in every event's top-level `sessionID` field.\n\n**Session ID**: Available in every event as `event.sessionID` (e.g., `ses_xxxxx`). Use `--session SESSION_ID` to resume.\n**Continuable**: Yes (via `--continue` or `--session`). Sessions are stored in a SQLite database in the OpenCode data directory. Use `--session SESSION_ID` for a specific session, or `--continue` for the most recent.\n**ACP adapter**: `opencode acp` (see ACP Transport section)\n\n### Copilot\n\n```\nCommand: copilot -p \"QUESTION\"\n```\n\nModels: claude-sonnet-4-6 (default), claude-opus-4-6, claude-haiku-4-5, gpt-5\n\n| Effort | Notes |\n|--------|-------|\n| all | No effort control available. Model selectable via --model flag. |\n\n**Parse output**: Raw text from stdout\n**Continuable**: No\n**ACP adapter**: `copilot --acp --stdio` (see ACP Transport section)\n\n### Kiro\n\n```\nACP-only provider. No CLI mode for external consultation.\nCommand: node acp\u002Frun.js --provider=\"kiro\" --question-file=\"{AI_STATE_DIR}\u002Fconsult\u002Fquestion.tmp\" --timeout=120000\n```\n\nKiro is available only via ACP transport. It requires `kiro-cli` on PATH.\n\n**Parse output**: Via ACP runner (`JSON.parse(stdout)`)\n**Continuable**: No\n**ACP adapter**: `kiro-cli acp` (native ACP)\n\n## Input Validation\n\nBefore building commands, validate all user-provided arguments:\n\n- **--tool**: MUST be one of: gemini, codex, claude, opencode, copilot, kiro. Reject all other values.\n- **--effort**: MUST be one of: low, medium, high, max. Default to medium.\n- **--model**: Allow any string, but quote it in the command.\n- **--continue=SESSION_ID**: If provided, SESSION_ID MUST match `^(?!-)[A-Za-z0-9._:-]+$`. Reject values that contain spaces, leading dashes, or shell metacharacters.\n- **--context=file=PATH**: MUST resolve within the project directory. Reject absolute paths outside cwd. Additional checks:\n  1. **Block UNC paths** (Windows): Reject paths starting with `\\\\` or `\u002F\u002F` (network shares)\n  2. **Resolve canonical path**: Use the Read tool to read the file (do NOT use shell commands). Before reading, resolve the path: join `cwd + PATH`, then normalize (collapse `.`, `..`, resolve symlinks)\n  3. **Verify containment**: The resolved canonical path MUST start with the current working directory. If it escapes (via `..`, symlinks, or junction points), reject with: `[ERROR] Path escapes project directory: {PATH}`\n  4. **No shell access**: Read file content using the Read tool only. Never pass user-provided paths to shell commands (prevents injection via path values)\n\n## Command Building\n\nGiven the parsed arguments, build the complete CLI command. All user-provided values MUST be quoted in the shell command to prevent injection.\n\n### Step 1: Resolve Model\n\nIf `--model` is specified, use it directly. Otherwise, use the effort-based model from the provider table above.\n\n### Step 1b: Trust Gate for Codex `--skip-git-repo-check`\n\nBefore using any Codex template, resolve `{SKIP_GIT_FLAG}` with this gate:\n\n1. Verify the consultation is running from the current project working directory (the same workspace where `\u002Fconsult` was invoked), not an arbitrary external path.\n2. Verify the resolved active tool is Codex (flag, NLP, picker, or restored `--continue` session).\n3. Run `git rev-parse --is-inside-work-tree` in the current working directory:\n   - if true: set `{SKIP_GIT_FLAG}` to empty string\n   - if false and checks 1-2 passed: set `{SKIP_GIT_FLAG}` to `--skip-git-repo-check`\n4. If checks 1-2 fail, reject execution with `[ERROR] Refusing Codex --skip-git-repo-check outside trusted working directory`.\n\nCodex templates in this skill assume this trust gate has already passed.\n\n### Step 2: Build Command String\n\nUse the command template from the provider's configuration section. Substitute QUESTION, MODEL, TURNS, LEVEL, VARIANT, and SKIP_GIT_FLAG with resolved literal values.\n`{SKIP_GIT_FLAG}` MUST be set by Step 1b only. Do not read `SKIP_GIT_FLAG` from inherited shell environment.\n\nIf continuing a session:\n- **Claude or Gemini**: append `--resume \"SESSION_ID\"` to the command.\n- **Codex**: use `codex exec resume \"SESSION_ID\" \"QUESTION\" --json -m \"MODEL\" {SKIP_GIT_FLAG} -c model_reasoning_effort=\"LEVEL\"` instead of the standard command. Use `--last` instead of a session ID for the most recent session.\n- **OpenCode**: append `--session SESSION_ID` to the command. If no session_id is saved, use `--continue` instead (resumes most recent session).\nIf OpenCode at max effort: append `--thinking`.\n\n### Step 3: Context Packaging\n\nIf `--context=diff`: Run `git diff 2>\u002Fdev\u002Fnull` and prepend output to the question.\nIf `--context=file=PATH`: Read the file using the Read tool and prepend its content to the question.\n\n### Step 4: Safe Question Passing\n\nUser-provided question text MUST NOT be interpolated into shell command strings. Shell escaping is insufficient -- `$()`, backticks, and other expansion sequences can execute arbitrary commands even inside double quotes.\n\n**Required approach -- pass question via stdin or temp file:**\n\n1. **Write the question** to a temporary file using the Write tool (e.g., `{AI_STATE_DIR}\u002Fconsult\u002Fquestion.tmp`)\n\n   Platform state directory:\n   - Claude Code: `.claude\u002F`\n   - OpenCode: `.opencode\u002F`\n   - Codex CLI: `.codex\u002F`\n2. **Build the command** using the temp file as input instead of inline text:\n\n| Provider | Safe command pattern |\n|----------|---------------------|\n| Claude | `env -u CLAUDECODE claude -p - --output-format json --model \"MODEL\" --max-turns TURNS --allowedTools \"Read,Glob,Grep\" \u003C \"{AI_STATE_DIR}\u002Fconsult\u002Fquestion.tmp\"` |\n| Claude (resume) | `env -u CLAUDECODE claude -p - --output-format json --model \"MODEL\" --max-turns TURNS --allowedTools \"Read,Glob,Grep\" --resume \"SESSION_ID\" \u003C \"{AI_STATE_DIR}\u002Fconsult\u002Fquestion.tmp\"` |\n| Gemini | `gemini -p - --output-format json -m \"MODEL\" \u003C \"{AI_STATE_DIR}\u002Fconsult\u002Fquestion.tmp\"` |\n| Gemini (resume) | `gemini -p - --output-format json -m \"MODEL\" --resume \"SESSION_ID\" \u003C \"{AI_STATE_DIR}\u002Fconsult\u002Fquestion.tmp\"` |\n| Codex | `codex exec \"$(cat \"{AI_STATE_DIR}\u002Fconsult\u002Fquestion.tmp\")\" --json -m \"MODEL\" {SKIP_GIT_FLAG} -c model_reasoning_effort=\"LEVEL\"` (Codex exec lacks stdin mode -- cat reads from platform-controlled path, not user input) |\n| Codex (resume) | `codex exec resume \"SESSION_ID\" \"$(cat \"{AI_STATE_DIR}\u002Fconsult\u002Fquestion.tmp\")\" --json -m \"MODEL\" {SKIP_GIT_FLAG} -c model_reasoning_effort=\"LEVEL\"` |\n| Codex (resume latest) | `codex exec resume --last \"$(cat \"{AI_STATE_DIR}\u002Fconsult\u002Fquestion.tmp\")\" --json -m \"MODEL\" {SKIP_GIT_FLAG} -c model_reasoning_effort=\"LEVEL\"` |\n| OpenCode | `opencode run - --format json --model \"MODEL\" --variant \"VARIANT\" \u003C \"{AI_STATE_DIR}\u002Fconsult\u002Fquestion.tmp\"` |\n| OpenCode (resume by ID) | `opencode run - --format json --model \"MODEL\" --variant \"VARIANT\" --session \"SESSION_ID\" \u003C \"{AI_STATE_DIR}\u002Fconsult\u002Fquestion.tmp\"` |\n| OpenCode (resume latest) | `opencode run - --format json --model \"MODEL\" --variant \"VARIANT\" --continue \u003C \"{AI_STATE_DIR}\u002Fconsult\u002Fquestion.tmp\"` |\n| Copilot | `copilot -p - \u003C \"{AI_STATE_DIR}\u002Fconsult\u002Fquestion.tmp\"` |\n\n3. **Delete the temp file** after the command completes (success or failure). Always clean up to prevent accumulation.\n\n**Model and session ID values** are controlled strings (from pickers or saved state) and safe to quote directly in the command. Only the question contains arbitrary user text and requires the temp file approach. The temp file path (`{AI_STATE_DIR}\u002Fconsult\u002Fquestion.tmp`) uses a platform-controlled directory and fixed filename -- no user input in the path.\n\n## Provider Detection\n\nCross-platform tool detection:\n\n- **Windows**: `where.exe TOOL 2>nul` -- returns 0 if found\n- **Unix**: `which TOOL 2>\u002Fdev\u002Fnull` -- returns 0 if found\n\nCheck each tool (claude, gemini, codex, opencode, copilot, kiro) and return only the available ones.\n\n## ACP Transport\n\nACP (Agent Client Protocol) is an alternative transport to CLI subprocess invocation. When available, ACP provides structured JSON-RPC 2.0 communication, session persistence, and streaming responses via a universal protocol supported by all major AI coding tools.\n\n### ACP Provider Adapters\n\n| Provider | ACP Command | Type | Detection |\n|----------|-------------|------|-----------|\n| Claude | `npx -y @anthropic-ai\u002Fclaude-code-acp` | adapter | npx available |\n| Gemini | `gemini` (native ACP) | native | gemini available |\n| Codex | `npx -y @zed-industries\u002Fcodex-acp` | adapter | npx available |\n| Copilot | `copilot --acp --stdio` | native | copilot available |\n| Kiro | `kiro-cli acp` | native | kiro-cli available |\n| OpenCode | `opencode acp` | native | opencode available |\n\n### Transport Selection\n\n1. Check ACP availability for the target provider (see ACP Detection below)\n2. If ACP available: use ACP transport (preferred - standardized protocol, session persistence)\n3. If ACP unavailable: fall back to CLI transport (existing behavior above)\n\nThe output envelope is identical regardless of transport. Downstream consumers (session management, debate orchestrator, output parsing) are transport-agnostic.\n\n### ACP Command Template\n\nAll ACP providers use the same command pattern via the ACP runner script:\n\n```\nnode acp\u002Frun.js --provider=\"PROVIDER\" --question-file=\"{AI_STATE_DIR}\u002Fconsult\u002Fquestion.tmp\" --timeout=TIMEOUT_MS [--model=\"MODEL\"] [--session-id=\"SESSION_ID\"]\n```\n\n| Provider | ACP Safe Command Pattern |\n|----------|------------------------|\n| Claude | `node acp\u002Frun.js --provider=\"claude\" --question-file=\"{AI_STATE_DIR}\u002Fconsult\u002Fquestion.tmp\" --timeout=120000 --model=\"MODEL\"` |\n| Gemini | `node acp\u002Frun.js --provider=\"gemini\" --question-file=\"{AI_STATE_DIR}\u002Fconsult\u002Fquestion.tmp\" --timeout=120000 --model=\"MODEL\"` |\n| Codex | `node acp\u002Frun.js --provider=\"codex\" --question-file=\"{AI_STATE_DIR}\u002Fconsult\u002Fquestion.tmp\" --timeout=120000 --model=\"MODEL\"` |\n| OpenCode | `node acp\u002Frun.js --provider=\"opencode\" --question-file=\"{AI_STATE_DIR}\u002Fconsult\u002Fquestion.tmp\" --timeout=120000 --model=\"MODEL\"` |\n| Copilot | `node acp\u002Frun.js --provider=\"copilot\" --question-file=\"{AI_STATE_DIR}\u002Fconsult\u002Fquestion.tmp\" --timeout=120000` |\n| Kiro | `node acp\u002Frun.js --provider=\"kiro\" --question-file=\"{AI_STATE_DIR}\u002Fconsult\u002Fquestion.tmp\" --timeout=120000` |\n\n**Parse output**: Same as CLI transport - `JSON.parse(stdout)`. The ACP runner outputs the same envelope format.\n**Session ID**: From `JSON.parse(stdout).session_id` (ACP session ID)\n**Resume**: Pass `--session-id=\"SESSION_ID\"` flag on the ACP command\n**Continuable**: Claude, Gemini, Codex, OpenCode (yes). Copilot, Kiro (no).\n\n### ACP Detection\n\nRun ACP detection alongside CLI detection. For each provider:\n\n```bash\nnode acp\u002Frun.js --detect --provider=\"PROVIDER\"\n```\n\nReturns on success (exit 0):\n```json\n{\"provider\": \"claude\", \"acp_available\": true, \"name\": \"Claude\"}\n```\n\nReturns on failure (exit 1):\n```json\n{\"provider\": \"claude\", \"acp_available\": false, \"name\": \"Claude\", \"reason\": \"npx not found on PATH\"}\n```\n\n**Kiro note**: Kiro is ACP-only - it has no CLI mode for external consultation. It only appears as available when `kiro-cli` is on PATH and ACP detection succeeds.\n\n## Session Management\n\n### Save Session\n\nAfter successful consultation, save to `{AI_STATE_DIR}\u002Fconsult\u002Flast-session.json`:\n\n```json\n{\n  \"tool\": \"claude\",\n  \"model\": \"opus\",\n  \"effort\": \"high\",\n  \"session_id\": \"abc-123-def-456\",\n  \"timestamp\": \"2026-02-10T12:00:00Z\",\n  \"question\": \"original question text\",\n  \"continuable\": true,\n  \"transport\": \"acp\"\n}\n```\n\nThe `transport` field is `\"acp\"` or `\"cli\"`. When resuming a session with `--continue`, use the same transport that created it. If the field is absent, assume `\"cli\"` (backward compatible).\n\n`AI_STATE_DIR` uses the platform state directory:\n- Claude Code: `.claude\u002F`\n- OpenCode: `.opencode\u002F`\n- Codex CLI: `.codex\u002F`\n\n### Load Session\n\nFor `--continue`, read the session file and restore:\n- tool (from saved state)\n- session_id (for --resume flag)\n- model (reuse same model)\n\nBefore using restored values, re-validate them:\n- tool must still be in allow-list: gemini, codex, claude, opencode, copilot, kiro\n- session_id must match `^(?!-)[A-Za-z0-9._:-]+$`\n- model must match `^[A-Za-z0-9._:\u002F-]+$` (reject spaces and shell metacharacters)\n- if either check fails, reject with `[ERROR] Invalid restored session data` and do not build a command\n\nIf session file not found, warn and proceed as fresh consultation.\n\n## Output Sanitization\n\nBefore including any consulted tool's response in the output, scan the response text and redact matches for these patterns:\n\n| Pattern | Description | Replacement |\n|---------|-------------|-------------|\n| `sk-[a-zA-Z0-9_-]{20,}` | Anthropic API keys | `[REDACTED_API_KEY]` |\n| `sk-proj-[a-zA-Z0-9_-]{20,}` | OpenAI project keys | `[REDACTED_API_KEY]` |\n| `sk-ant-[a-zA-Z0-9_-]{20,}` | Anthropic API keys (ant prefix) | `[REDACTED_API_KEY]` |\n| `AIza[a-zA-Z0-9_-]{30,}` | Google API keys | `[REDACTED_API_KEY]` |\n| `ghp_[a-zA-Z0-9]{36,}` | GitHub personal access tokens | `[REDACTED_TOKEN]` |\n| `gho_[a-zA-Z0-9]{36,}` | GitHub OAuth tokens | `[REDACTED_TOKEN]` |\n| `github_pat_[a-zA-Z0-9_]{20,}` | GitHub fine-grained PATs | `[REDACTED_TOKEN]` |\n| `ANTHROPIC_API_KEY=[^\\s]+` | Key assignment in env output | `ANTHROPIC_API_KEY=[REDACTED]` |\n| `OPENAI_API_KEY=[^\\s]+` | Key assignment in env output | `OPENAI_API_KEY=[REDACTED]` |\n| `GOOGLE_API_KEY=[^\\s]+` | Key assignment in env output | `GOOGLE_API_KEY=[REDACTED]` |\n| `GEMINI_API_KEY=[^\\s]+` | Key assignment in env output | `GEMINI_API_KEY=[REDACTED]` |\n| `AKIA[A-Z0-9]{16}` | AWS access keys | `[REDACTED_AWS_KEY]` |\n| `ASIA[A-Z0-9]{16}` | AWS session tokens | `[REDACTED_AWS_KEY]` |\n| `Bearer [a-zA-Z0-9_-]{20,}` | Authorization headers | `Bearer [REDACTED]` |\n\nApply redaction to the full response text before inserting into the result JSON. If any redaction occurs, append a note: `[WARN] Sensitive tokens were redacted from the response.`\n\n## Output Format\n\nReturn a plain JSON object to stdout (no markers or wrappers):\n\n```json\n{\n  \"tool\": \"gemini\",\n  \"model\": \"gemini-3.1-pro-preview\",\n  \"effort\": \"high\",\n  \"duration_ms\": 12300,\n  \"response\": \"The AI's response text here...\",\n  \"session_id\": \"abc-123\",\n  \"continuable\": true\n}\n```\n\n## Install Instructions\n\nWhen a tool is not found, return these install commands:\n\n| Tool | Install |\n|------|---------|\n| Claude | `npm install -g @anthropic-ai\u002Fclaude-code` |\n| Gemini | See https:\u002F\u002Fgemini.google.com\u002Fcli for install instructions |\n| Codex | `npm install -g @openai\u002Fcodex` |\n| OpenCode | `npm install -g opencode-ai` or `brew install anomalyco\u002Ftap\u002Fopencode` |\n| Copilot | `gh extension install github\u002Fcopilot-cli` |\n\n## Error Handling\n\n| Error | Response |\n|-------|----------|\n| Tool not installed | Return install instructions from table above |\n| Tool execution timeout | Return `\"response\": \"Timeout after 120s\"` |\n| JSON parse error | Return raw text as response |\n| Empty output | Return `\"response\": \"No output received\"` |\n| Session file missing | Proceed without session resume |\n| API key missing | Return tool-specific env var instructions |\n\n## Integration\n\nThis skill is invoked by:\n- `consult-agent` for `\u002Fconsult` command\n- Direct invocation: `Skill('consult', '\"question\" --tool=gemini --effort=high')`\n\nExample: `Skill('consult', '\"Is this approach correct?\" --tool=gemini --effort=high --model=gemini-3.1-pro-preview')`\n",{"name":5,"version":23,"description":7,"argument-hint":24},"5.1.0","[question] [--tool] [--effort] [--model] [--context] [--continue]","main","f37de8f681f0c0ca0e0ebab6e5fddf764ca7553d","skills\u002Fconsult",1,"https:\u002F\u002Fgithub.com\u002Fagisota\u002Fold-one","https:\u002F\u002Fagisota.github.io\u002Fold-one\u002F","https:\u002F\u002Fgithub.com\u002Fagisota","pzd.world","2026-07-04 22:32:06",{"source":8,"skillName":5,"commands":35,"prompt":45,"zipAvailable":46},[36,39,42],{"tool":37,"command":38},"npx","npx skills add agisota\u002Fold-one --skill consult",{"tool":40,"command":41},"bunx","bunx skills add agisota\u002Fold-one --skill consult",{"tool":43,"command":44},"pnpm","pnpm dlx skills add agisota\u002Fold-one --skill consult","安装技能，技能地址：https:\u002F\u002Fgithub.com\u002Fagisota\u002Fold-one\u002Fblob\u002Fmain\u002Fskills\u002Fconsult\u002FSKILL.md",true,[],[49,56,63,72,79,86],{"skillNo":50,"name":51,"nameZh":6,"description":52,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":9,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":53,"categories":54,"keywords":55,"publishedAt":18},"01M75KRGZWQWE9JDBS6RX42NWV","zoom-out","Tell the agent to zoom out and give broader context or a higher-level perspective. Use when you're unfamiliar with a section of code or need to understand how it fits into the bigger picture.","https:\u002F\u002Fgithub.com\u002Fagisota\u002Fold-one\u002Fblob\u002Fmain\u002Fskills\u002Fzoom-out\u002FSKILL.md",[],[],{"skillNo":57,"name":58,"nameZh":6,"description":59,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":9,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":60,"categories":61,"keywords":62,"publishedAt":18},"01M75KRCZHKE0ZYAQFFYHS0YNP","zeroize-audit","Detects missing zeroization of sensitive data in source code and identifies zeroization removed by compiler optimizations, with assembly-level analysis, and control-flow verification. Use for auditing C\u002FC++\u002FRust code handling secrets, keys, passwords, or other sensitive data.","https:\u002F\u002Fgithub.com\u002Fagisota\u002Fold-one\u002Fblob\u002Fmain\u002Fskills\u002Fzeroize-audit\u002FSKILL.md",[],[],{"skillNo":64,"name":65,"nameZh":6,"description":66,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":9,"repositoryNo":12,"starsCount":13,"licenseSpdxId":67,"licenseFileUrl":68,"sourceHtmlUrl":69,"categories":70,"keywords":71,"publishedAt":18},"01M75KR94KYQ30DTE1P9WNDAE0","yeet","Use only when the user explicitly asks to stage, commit, push, and open a GitHub pull request in one flow using the GitHub CLI (`gh`).","Apache-2.0","https:\u002F\u002Fgithub.com\u002Fagisota\u002Fold-one\u002Fblob\u002Fmain\u002Fskills\u002Fyeet\u002FLICENSE.txt","https:\u002F\u002Fgithub.com\u002Fagisota\u002Fold-one\u002Fblob\u002Fmain\u002Fskills\u002Fyeet\u002FSKILL.md",[],[],{"skillNo":73,"name":74,"nameZh":6,"description":75,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":9,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":76,"categories":77,"keywords":78,"publishedAt":18},"01M75KR3H13YJ9QHMD49818FA1","yara-rule-authoring","Guides authoring of high-quality YARA-X detection rules for malware identification. Use when writing, reviewing, or optimizing YARA rules. Covers naming conventions, string selection, performance optimization, migration from legacy YARA, and false positive reduction. Triggers on: YARA, YARA-X, malware detection, threat hunting, IOC, signature, crx module, dex module.","https:\u002F\u002Fgithub.com\u002Fagisota\u002Fold-one\u002Fblob\u002Fmain\u002Fskills\u002Fyara-rule-authoring\u002FSKILL.md",[],[],{"skillNo":80,"name":81,"nameZh":6,"description":82,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":9,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":83,"categories":84,"keywords":85,"publishedAt":18},"01M75KQMPY8A4Y8XTDD2DT0M9T","x-twitter-growth","X\u002FTwitter growth engine for building audience, crafting viral content, and analyzing engagement. Use when the user wants to grow on X\u002FTwitter, write tweets or threads, analyze their X profile, research competitors on X, plan a posting strategy, or optimize engagement. Complements social-content (generic multi-platform) with X-specific depth: algorithm mechanics, thread engineering, reply strategy, profile optimization, and competitive intelligence via web search.","https:\u002F\u002Fgithub.com\u002Fagisota\u002Fold-one\u002Fblob\u002Fmain\u002Fskills\u002Fx-twitter-growth\u002FSKILL.md",[],[],{"skillNo":87,"name":88,"nameZh":6,"description":89,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":9,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":90,"categories":91,"keywords":92,"publishedAt":18},"01M75KQHNZ0ANZNJGZY6M8MDAK","x-api","X\u002FTwitter API integration for posting tweets, threads, reading timelines, search, and analytics. Covers OAuth auth patterns, rate limits, and platform-native content posting. Use when the user wants to interact with X programmatically.","https:\u002F\u002Fgithub.com\u002Fagisota\u002Fold-one\u002Fblob\u002Fmain\u002Fskills\u002Fx-api\u002FSKILL.md",[],[]]