gemini-cli

Delegate multi-step engineering and research tasks to Gemini CLI with explicit context handoff.

5|Updated Apr 23, 2026
One-click install
npx skills add https://github.com/amirkiarafiei/subagent-cli-skills --skill gemini-cli-amirkiarafiei
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: gemini-cli
Source: https://github.com/amirkiarafiei/subagent-cli-skills/tree/main/skills/gemini-cli
Command: npx skills add https://github.com/amirkiarafiei/subagent-cli-skills --skill gemini-cli-amirkiarafiei

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve?

Gemini CLI reduces context and cost by letting your main orchestrator delegate large, multi-step engineering or research work to an isolated Gemini run.

Core Features & Use Cases

  • Long-horizon repo work: Drive multi-file edits, broad refactors, and deep exploration without flooding the primary agent’s context window.
  • Specialist prompting support: Use @codebase_investigator, @generalist, and @gemini-cli-security to target architecture mapping, heavy implementation, or security audits.
  • Verification-first delegation: Require the delegated prompt to run explicit checks (tests/lint/typecheck) and then reconcile decisions and diffs back into the main thread.

Quick Start

Tell your agent to delegate by running Gemini CLI with a single handoff prompt that includes the original goal, prior decisions, repo scope, constraints, verification command, and the desired output format.

Frequently Asked Questions about gemini-cli

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I delegate large refactoring tasks to an isolated agent without losing context?

Delegating large refactoring tasks requires passing a single handoff prompt with the original goal, prior decisions, and repo scope to an isolated programmatic agent. This preserves alignment by reconciling the resulting file changes and decisions back into your main orchestrator thread.

What is the best way to run a security audit on a repository when local context is insufficient?

Running a security audit when local context is insufficient involves delegating the task to an isolated agent using specialist prompting. The delegated run executes with auto-approved tool use and post-run verification to ensure isolation-safe checks are reconciled back to the main thread.

Can I perform deep codebase investigation and web search grounding without flooding my primary context window?

Performing deep codebase investigation and web-grounded documentation searches without context flooding is possible by delegating the multi-step work to an isolated agent run. This non-interactive execution handles the heavy exploration and returns only the reconciled output to your main thread.

How do I verify file changes after delegating multi-file edits to an external agent?

Verifying file changes after delegating multi-file edits requires the delegated prompt to run explicit checks like tests, lint, or typecheck. The agent must execute these commands during the isolated run and reconcile the diffs and decisions back into the main orchestrator.

Does delegating deep work to an external agent require auto-approved tool use?

Delegating deep work to an external agent does require auto-approved tool use for non-interactive programmatic execution. This ensures the isolated run can autonomously perform strict model selection and apply isolation-safe prompts without manual intervention.

When should I not use an isolated agent run for broad repository refactoring?

You should not use an isolated agent run for broad repository refactoring when your primary orchestrator has sufficient local context to handle the task. Isolated delegation is specifically for heavy multi-file edits and long-horizon work that would otherwise flood the main context window.