mcpField
G
gemini-qa

gemini-qa

github.com/funnelenvyAgent workflows137 installsUpdated 41w ago
Repository

About gemini-qa

gemini-qa is a skill that routes codebase questions to Google's Gemini CLI and returns its response. It is for agents and developers seeking explanations, architecture details, or a second opinion on code.

Key features

  1. 01Ask codebase questions through Gemini CLI
  2. 02Run queries in headless mode
  3. 03Include files or directories with @ references
  4. 04Accept piped input
  5. 05Request JSON output

Use cases

  1. 01Explain a function or module
  2. 02Ask about database-layer structure
  3. 03Locate error-handling patterns
  4. 04Review a file for potential issues

Install

Copy the command and run it in a terminal.

$npx skills add https://github.com/funnelenvy/agents_webinar_demos --skill gemini-qa

After installing, type/gemini-qain Claude Code to confirm it loaded.

Details

From the project README

Gemini Q&A

Use Google's Gemini CLI to answer questions about the codebase.

Prerequisites

Gemini CLI must be installed:

npm install -g @anthropic-ai/gemini-cli
# or follow installation at https://github.com/google-gemini/gemini-cli

Authentication must be configured (Google API key or Application Default Credentials).

Usage

Spawn the gemini-qa subagent to handle the question:

Use the Task tool to spawn the gemini-qa agent with the user's question.

The subagent will:

  1. Formulate a clear prompt for Gemini
  2. Run gemini -p "question" in headless mode
  3. Return Gemini's response

Direct Usage (without subagent)

If you prefer to run Gemini directly:

gemini -p "your question here"
# or
gemini "your question here"
Command Options
  • Basic query: gemini -p "question"
  • Positional: gemini "question"
  • Pipe input: cat file.txt | gemini -p "summarize this"
  • JSON output: gemini -p "question" --output-format json
  • File reference: gemini -p "@src/file.ts explain this"
File References with @

Gemini supports @ syntax to include file context:

# Reference a specific file
gemini -p "@src/auth.ts Explain this module"

# Reference a directory
gemini -p "@src/ Summarize all code here"

Common Use Cases

  • Code explanation: "What does this function do?"
  • Architecture questions: "How is the database layer structured?"
  • Finding patterns: "Where is error handling implemented?"
  • Code review: "Review this file for potential issues"
  • Comparison: Get a second opinion on a code question

Notes

  • Use -p flag for headless (non-interactive) mode
  • Gemini is git-aware and respects .gitignore for directory references
  • For complex questions, use the subagent for better context isolation

Comments

Markdown supported