Back to list
WilliamKarolDiCioccio

invoke-gemini

by WilliamKarolDiCioccio

My second attempt building a cross-platform game-engine in C++.

2🍴 1📅 Jan 22, 2026

SKILL.md


name: invoke-gemini description: Delegate large file analysis and bulk code generation to Gemini CLI. Use when files exceed 1000 lines, structural file splitting needed, or repetitive boilerplate generation required. NOT for architecture, ECS, renderer, threading, or memory systems. allowed-tools: ["Bash", "Read", "Write", "Grep", "Glob"]

Invoke Gemini

Gemini CLI integration for large-context and bulk-generation tasks within Saturn.

Authority: Claude Code is sole decision-maker. Gemini is constrained executor.

Configuration

LARGE_FILE_LINE_THRESHOLD = 1000
DEFAULT_GEMINI_MODEL = gemini-2.5-flash

When to Use

MUST invoke when:

  • File exceeds 1000 lines
  • Structural understanding of very large file required
  • Repetitive, pattern-based, low-risk code generation

NEVER invoke for:

  • Renderer internals
  • ECS
  • Threading / async systems
  • Memory ownership
  • Vulkan / WebGPU logic
  • Engine architecture
  • Any architectural decisions

Pre-Flight Check (MANDATORY)

Before reading ANY file, check line count:

python scripts/check_line_count.py <file_path>

Output: DELEGATE (>1000 lines) or PROCEED (<=1000 lines)

If DELEGATE: Claude MUST NOT read file directly.

Action 1: Large File Analysis

When

File exceeds 1000 lines and Claude needs structural understanding.

Execute

python scripts/analyze_large_file.py <file_path>

Post-Execution

  • Claude reads only the output file
  • Claude bases decisions on Gemini's summary
  • Claude NEVER re-scans large file manually

Action 2: Structural File Splitting

When

Large file needs decomposition into logical components.

Execute

python scripts/split_file.py <file_path> --intent "high-level goal"

Post-Execution

  • Claude validates Gemini's split boundaries
  • Claude applies split (does not override boundaries)

Action 3: Bulk Code Generation

When

Repetitive, pattern-based, low-risk generation needed.

Encouraged Domains

  • Flutter UI code
  • Dart bindings
  • Generated adapters / glue code
  • Serialization / deserialization
  • Repetitive C++ declarations
  • Platform boilerplate

Forbidden Domains

  • Renderer internals
  • ECS
  • Threading / async
  • Memory ownership
  • Vulkan / WebGPU
  • Engine architecture

Execute

python scripts/generate_bulk.py --spec "specification here"

Workflow

  1. Claude defines WHAT is needed (spec, constraints, patterns)
  2. Claude invokes Gemini with spec
  3. Gemini generates bulk output
  4. Claude reviews, edits if necessary
  5. Claude integrates

Guardrails

Invalid outputs (reject immediately):

  • Claude analyzed >1000 line file directly
  • Gemini used for architecture/engine reasoning
  • Gemini output integrated without Claude review
  • CLAUDE.md rules bypassed

Context Rules

All Gemini prompts MUST include:

  • Reference to relevant CLAUDE.md files
  • Instruction to assume Saturn conventions
  • Explicit prohibition on new patterns

Reference

See references/GEMINI.md for full Gemini role definition and constraints.

Score

Total Score

65/100

Based on repository quality metrics

SKILL.md

SKILL.mdファイルが含まれている

+20
LICENSE

ライセンスが設定されている

+10
説明文

100文字以上の説明がある

0/10
人気

GitHub Stars 100以上

0/15
最近の活動

1ヶ月以内に更新

+10
フォーク

10回以上フォークされている

0/5
Issue管理

オープンIssueが50未満

+5
言語

プログラミング言語が設定されている

+5
タグ

1つ以上のタグが設定されている

+5

Reviews

💬

Reviews coming soon