gemini
できること
このスキルは、Gemini のコマンドラインツールを実行して、コード、計画、大量のファイルをレビューします。作業を別のモデルにレビューさせたい開発者や、通常のチャットには大きすぎる入力を分析したい人向けです。
使う場面
- ✓Gemini を使って、多くのファイルにわたるコードレビューが求められたとき。
- ✓アーキテクチャの計画や仕様に、2つ目のレビューが必要なとき。
- ✓ドキュメント全体のような、20万トークンを超えるコンテキストを扱う作業の場合。
スキルのリンク
https://github.com/davila7/claude-code-templates/blob/main/cli-tool/components/skills/ai-research/gemini/SKILL.mdコピーしてAI(Claude、ChatGPT、Cursor)に貼り付け、指示に従うよう頼んでください。
使い方
いちばん簡単な方法:メッセージをコピーしてAIに貼り付けるだけ。AIがスキルを読んで指示に従います。
貼り付け用メッセージ
Claude Code、Codex、Cursorの場合:プロジェクトのフォルダで実行するとスキルがインストールされます。
SKILL.mdをダウンロードして、エージェントのスキル用フォルダに入れてください。
AIへの頼み方の例
“Gemini を使って、これらのファイルの変更を確認し、危険なロジックがあれば指摘してください。”
毎週5つの新しいスキル。1分で読めます。
仕組み
このスキルは、どの Gemini モデルを使うかを尋ね、選んだファイルやプロンプトに対してコマンドラインツールを実行します。対話的な承認の確認がバックグラウンドの実行を止めることがあるため、自動実行には非対話の設定かタイムアウトが必要だと警告しています。
技術的な内容(元のSKILL.md)
作者による元のテキスト(英語)をGitHubからそのまま表示しています。
Gemini Skill Guide
When to Use Gemini
- WHEN ASKED TO BE ACTIVATED
- Code Review: Comprehensive code reviews across multiple files
- Plan Review: Analyzing architectural plans, technical specifications, or project roadmaps
- Big Context Processing: Tasks requiring >200k tokens of context (entire codebases, documentation sets)
- Multi-file Analysis: Understanding relationships and patterns across many files
⚠️ Critical: Background/Non-Interactive Mode Warning
NEVER use --approval-mode default in background or non-interactive shells (like Claude Code tool calls). It will hang indefinitely waiting for approval prompts that cannot be provided.
For automated/background reviews:
- ✅ Use
--approval-mode yolofor fully automated execution - ✅ OR wrap with timeout:
timeout 300 gemini ... - ❌ NEVER use
--approval-mode defaultwithout interactive terminal
Symptoms of hung Gemini:
- Process running 20+ minutes with 0% CPU usage
- No network activity
- Process state shows 'S' (sleeping)
Fix hung process:
# Check if hung
ps aux | grep gemini | grep -v grep
# Kill if necessary
pkill -9 -f "gemini.*gemini-3-pro-preview"
Running a Task
Ask the user (via
AskUserQuestion) which model to use in a single prompt. Available models:gemini-3-pro-preview⭐ (flagship model, best for coding & complex reasoning, 35% better at software engineering than 2.5 Pro)gemini-3-flash(sub-second latency, distilled from 3 Pro, best for speed-critical tasks)gemini-2.5-pro(legacy option, strong all-around performance)gemini-2.5-flash(legacy option, cost-efficient with thinking capabilities)gemini-2.5-flash-lite(legacy option, fastest processing)
Select the approval mode based on the task:
default: Prompt for approval (⚠️ ONLY for interactive terminal sessions)auto_edit: Auto-approve edit tools only (for code reviews with suggestions)yolo: Auto-approve all tools (✅ REQUIRED for background/automated tasks)
Assemble the command with appropriate options:
-m, --model <MODEL>- Model selection--approval-mode <default|auto_edit|yolo>- Control tool approval-y, --yolo- Alternative to--approval-mode yolo-i, --prompt-interactive "prompt"- Execute prompt and continue interactively--include-directories <DIR>- Additional directories to include in workspace-s, --sandbox- Run in sandbox mode for isolation
For background/automated tasks, ALWAYS use
--approval-mode yoloor add timeout wrapper. NEVER usedefaultin non-interactive shells.Run the command and capture the output. For background/automated mode:
# Recommended: Use yolo for background tasks gemini -m gemini-3-pro-preview --approval-mode yolo "Review this codebase for security issues" # Or with timeout (5 min limit) timeout 300 gemini -m gemini-3-pro-preview --approval-mode yolo "Review this codebase"For interactive sessions with an initial prompt:
gemini -m gemini-3-pro-preview -i "Review the authentication system" --approval-mode auto_editAfter Gemini completes, inform the user: "The Gemini analysis is complete. You can start a new Gemini session for follow-up analysis or continue exploring the findings."
Quick Reference
| Use case | Approval mode | Key flags |
|---|---|---|
| Background code review | yolo ✅ |
-m gemini-3-pro-preview --approval-mode yolo |
| Background analysis | yolo ✅ |
-m gemini-3-pro-preview --approval-mode yolo |
| Background with timeout | yolo ✅ |
timeout 300 gemini -m gemini-3-pro-preview --approval-mode yolo |
| Interactive code review | default |
-m gemini-3-pro-preview --approval-mode default (interactive terminal only) |
| Code review with auto-edits | auto_edit |
-m gemini-3-pro-preview --approval-mode auto_edit |
| Automated refactoring | yolo |
-m gemini-3-pro-preview --approval-mode yolo |
| Speed-critical background | yolo ✅ |
-m gemini-3-flash --approval-mode yolo |
| Cost-optimized background | yolo ✅ |
-m gemini-2.5-flash --approval-mode yolo |
| Multi-directory analysis | yolo (if background) |
--include-directories <DIR1> --include-directories <DIR2> |
| Interactive with prompt | auto_edit or default |
-i "prompt" --approval-mode <mode> |
Model Selection Guide
| Model | Best for | Context window | Key features | | --- | --- | ---
よくある質問
実行が止まるのはなぜですか?
既定の承認モードは入力を待つため、タイムアウトや自動承認の設定がないと、バックグラウンドの実行が止まることがあると警告しています。
大きなコンテキストは何に使いますか?
コードベース全体や多くのドキュメントなど、非常に大きな入力の分析に使います。
Gemini CLI のインストールは必要ですか?
はい。このスキルは Gemini のコマンドラインツールを実行するため、先に設定しておく必要があります。
詳細
作者による元の説明
Use when the user asks to run Gemini CLI for code review, plan review, or big context (>200k) processing. Ideal for comprehensive analysis requiring large context windows. Uses Gemini 3 Pro by default for state-of-the-art reasoning and coding.
人気
- GitHubのスター
- 33k
- ランキング
- #8561
- ライセンス
- MIT
- 更新日
- 2026/11/2
コメント
- …
このリポジトリの他のスキル
owasp-security
33kエージェントがWebアプリ、API、モバイル、コンテナ、AIエージェント向けの OWASP のセキュリティ指針を理解し、よくある弱点を見つけて修正案を出せるよう支援します。
agent-management
33kエージェントが、AI Maestro のコマンドラインを使って AI エージェントを作成、一覧表示、休止、再開、名前変更、削除できるよう支援します。各エージェントのライフサイクルを管理します。
agent-messaging
33kエージェントが、主に自分のマシン上で Agent Messaging Protocol を使い、AIエージェント同士の署名付きメッセージを送信、受信、返信できるよう支援します。
docs-search
33kエージェントが、自動生成されたコードのドキュメントから関数の署名、クラスの定義、コメントを検索できるよう支援します。コードを変更する前に、実際のAPIを確認できます。
似ているスキル
diffs
394k編集内容の実際の共有可能な差分を、手書きの要約ではなく、ビューアーのリンクや画像ファイルとして作成するようエージェントを支援します。
coding-agent
394kCodex、Claude Code、OpenCodeに大きめのコーディング作業をバックグラウンドのワーカーとして渡し、その進捗を確認するようエージェントを支援します。
gh-issues
394kGitHubのイシューを探し、取り組むものを選び、修正を含むプルリクエストを開くようエージェントを支援します。レビューコメントへの対応も含みます。