AgentSkillsCN

omega-claude-cli

当用户希望借助Claude(Claude Code CLI)从其他代理处获取分析、代码库梳理,或进行头脑风暴时,此技能将自动运行。它同样采用无头Claude Code CLI脚本(无需MCP),并在“使用Claude”、“用Claude分析”、“向Claude提问”、“用Claude头脑风暴”等指令触发时,自动执行相应任务。

SKILL.md
--- frontmatter
name: omega-claude-cli
description: Use when the user wants to use Claude (Claude Code CLI) for analysis, codebases, or brainstorming from another agent. Uses headless Claude Code CLI scripts (no MCP). Triggers on "use Claude", "analyze with Claude", "ask Claude", "brainstorm with Claude".
allowed-tools: Read, Grep, Bash

Omega Claude CLI (headless)

This skill uses the Claude Code CLI in headless mode so other agents (Codex, Cursor, Copilot, etc.) can run Claude from scripts—no MCP server or MCP configuration required.

Overview

Run Claude via the headless script: scripts/ask-claude.mjs (from the skill root) or .claude/skills/omega-claude-cli/scripts/ask-claude.mjs (from the project root). It invokes claude -p "..." --dangerously-skip-permissions (and optional --model, --json, --sandbox, --timeout-ms) and returns the response. Requires Node.js and the Claude Code CLI to be installed. For one-time setup after copying this folder, run /omega-claude-setup. For install and auth, see references/installation.md and references/auth.md.

First-time setup

If the user has not set up Claude Code CLI yet, direct them to run /omega-claude-setup. That runs the verification script (node .claude/skills/omega-claude-cli/scripts/verify-setup.mjs) and guides them to install Node, install Claude Code CLI, and complete one-time auth. No MCP config is needed.

How to run Claude (headless)

From the project root (where .claude lives), run:

bash
node .claude/skills/omega-claude-cli/scripts/ask-claude.mjs "USER_PROMPT"

Options (append to the command):

  • --model MODEL — optional. CLI has three models: Default (Opus 4.6), Sonnet 4.5, Haiku 4.5. Use e.g. --model sonnet or --model haiku.
  • --json — output JSON; the script prints the .response field if present.
  • --sandbox — run or test code in Claude's sandbox mode.
  • --timeout-ms N — optional timeout for automation.

Examples:

  • Analysis: node .claude/skills/omega-claude-cli/scripts/ask-claude.mjs "Review @src/main.js for bugs"
  • With model: node .claude/skills/omega-claude-cli/scripts/ask-claude.mjs "Summarize this" --model sonnet
  • Stdin: echo "Explain recursion" | node .claude/skills/omega-claude-cli/scripts/ask-claude.mjs

When the user says "ask Claude for feedback" (or similar), build the prompt from their request and any @ file refs, then run the script and return the script output to the user.

When to use this skill

  • Analysis — Use Claude's context for code or doc review from another agent.
  • Second opinion / feedback — User wants Claude's take on code or docs from Codex, Cursor, Copilot, etc.
  • Brainstorming — Build a prompt that includes the challenge and optional methodology and run the script.

For full headless options and examples, see references/headless.md. For copying this skill into another project, see references/copy-and-run.md. Other surfaces: Cursor, Codex CLI, GitHub Copilot CLI, Antigravity IDE, VS Code.

Slash commands

  • /analyze — Run the headless script with the user's prompt (and any @ refs). Example: /analyze summarize @README.md.
  • /omega-claude — Use the headless script for analysis or brainstorm as appropriate.
  • /omega-claude-setup — Verify Node and Claude Code CLI; guide the user to install and auth. No MCP.

Natural language: "use Claude to explain index.html", "ask Claude for feedback on this function", "brainstorm with Claude using design thinking".

Auth

One-time sign-in and auth issues: references/auth.md.

Copy and run in another project

Copy the entire .claude folder (so you have .claude/skills/omega-claude-cli/ and .claude/commands/) into the target project. Open that project in your agent and run from its root. Run /omega-claude-setup once, then "ask Claude" works. Details: references/copy-and-run.md.