# Omega Gemini CLI

> Use when the user wants to use Google Gemini for analysis, large files or codebases, sandbox execution, or brainstorming. Runs headless Gemini CLI via a Node script (no MCP). Triggers on "use Gemini", "ask Gemini", "analyze with Gemini", "large file", "sandbox", "brainstorm with Gemini".

- Skill: `oimiragieo/omega-gemini-cli-4` (Agent Skill)
- Install (CLI): `npx skillmds@latest add oimiragieo/omega-gemini-cli-4`
- Raw SKILL.md: https://api.skillmd.com/api/skills/oimiragieo/omega-gemini-cli-4/raw
- Safety review: pending (external: skill-scanner PASS, skillspector PASS)
- Works with: Claude Code, Claude.ai, OpenAI Codex
- Category: AI & ML
- Author: oimiragieo (https://skillmd.com/u/oimiragieo)
- Updated: 2026-09-22
- Page: https://skillmd.com/skills/oimiragieo/omega-gemini-cli-4

---


# Omega Gemini CLI (headless)

This skill runs the **Gemini CLI in headless mode** so Antigravity can call Gemini from the project—no MCP server or MCP configuration required.

## Response times

Gemini CLI runs as a subprocess and includes model startup time. Typical wall-clock times observed on this setup:

- Simple Q&A / news query: ~2 minutes
- Codebase or large-file review: ~5–10 minutes

Set expectations with the user before running long tasks.

## Overview

From the **project root** (the directory that contains `.claude` and `.agent`), run the headless script. It invokes `gemini -p "..."` with optional model, sandbox, and JSON flags and returns the response. Requires **Node.js** and **Google Gemini CLI** to be installed.

## How to run Gemini

From the project root, run:

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

Optional flags (append to the command):

- `--model MODEL` / `-m MODEL` — e.g. `gemini-3.7-flash`, `gemini-3.1-flash-lite`. Reduce quota issues by using Flash-lite.
- `--sandbox` / `-s` — sandbox mode for running code.
- `--json` — output a JSON object `{"response":"..."}` (consistent envelope on success and error).

Gemini CLI also supports `--output-format stream-json`, `--approval-mode`, `--resume`, and more. Full reference: `.claude/skills/omega-gemini-cli/references/headless.md`.

Examples:

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

When the user says "ask Gemini", "use Gemini", or similar, build the prompt from their request and any @ file refs, run this command from the project root, and return the script output.

## When to use this skill

- **Large files or codebases** — Use Gemini's context for analysis.
- **Second opinion / feedback** — User wants Gemini's take on code or docs.
- **Sandbox** — Run or test code via Gemini (add `--sandbox` when supported).
- **Brainstorming** — Build a prompt that includes the challenge and optional method (e.g. SCAMPER) and run the script.

## If Gemini CLI is not set up

If the script fails (e.g. "gemini not found"), direct the user to install Node.js and Gemini CLI and complete one-time auth. Setup can be verified by running from project root:

```bash
node .claude/skills/omega-gemini-cli/scripts/verify-setup.mjs
```

Full installation and auth details: `.claude/skills/omega-gemini-cli/references/installation.md` and `references/auth.md` (same repo).

## Models (2026)

Gemini CLI model IDs: **gemini-3.7-flash** (latest, GA), **gemini-3.6-flash**, **gemini-3.5-flash**, **gemini-3.5-flash-lite**, **gemini-3.1-pro-preview**, **gemini-3.1-flash-lite**, **gemini-3-flash-preview**, **gemini-2.5-pro**, **gemini-2.5-flash**, **gemini-2.5-flash-lite**. Use `--model gemini-3.7-flash` (or `gemini-3.1-flash-lite`) for most tasks. **Note:** `gemini-3-pro-preview` shut down March 9, 2026 — use `gemini-3.1-pro-preview` instead. See `.claude/skills/omega-gemini-cli/references/models-2026.md`.

## Shared scripts

Scripts are shared with the Claude and Codex skills: `.claude/skills/omega-gemini-cli/scripts/`. No duplicate copies are required for Antigravity.

