一键导入
ask-gemini
Get a second opinion from Gemini on thorny problems. Calls the Gemini 3.5 Flash API with conversation history for multi-turn consults.
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
菜单
Get a second opinion from Gemini on thorny problems. Calls the Gemini 3.5 Flash API with conversation history for multi-turn consults.
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
基于 SOC 职业分类
| name | ask-gemini |
| description | Get a second opinion from Gemini on thorny problems. Calls the Gemini 3.5 Flash API with conversation history for multi-turn consults. |
Prereqs: the ask-gemini binary is on PATH and either GEMINI_API_KEY or ASK_GEMINI_KEY_COMMAND is set in your environment. See the project README for installation and credential setup.
Get a second opinion from Google's Gemini 3.5 Flash on a tricky problem. Useful for:
The tool is ask-gemini. It maintains conversation history across calls so you can have a multi-turn consult.
ask-gemini [flags] <prompt>
echo 'prompt' | ask-gemini [flags]
echo 'payload' | ask-gemini [flags] <prompt>
When both a positional prompt and piped stdin are given, stdin is appended to the arg prompt (separated by a blank line) — handy for putting a framing question in the arg and a long payload on stdin.
Flags:
--session <name> — name the conversation; stored at $TMPDIR/ask-gemini-<name>.json (falls back to /tmp if unset). Always pass this from the skill so concurrent Claude sessions don't trample each other.--reset — start a fresh conversation (use on first call per consult topic)--photo <path> — attach an image (repeatable). Uploaded via Gemini's File API and referenced by URI.--video <path> — attach a video (repeatable). Uploaded via the File API; the CLI waits for processing to complete (ACTIVE state) before sending.--audio <path> — attach an audio file (repeatable). Uploaded via the File API; the CLI waits for ACTIVE state before sending.--no-search — disable Google Search grounding (enabled by default)--no-url-context — disable URL context fetching (enabled by default)--model <id> — override model (default: gemini-3.5-flash)--system <prompt> — custom system prompt (only used on first turn)--history — show the current conversation and exit--version — print the binary version and exitNotes on attachments:
--session consult can keep referencing them across turns without re-uploading.When the user invokes /ask-gemini, follow this process:
Always pass --session <name>. Choose a short, slug-style name tied to the consult topic (e.g. --session auth-rewrite, --session pyspark-perf). Reuse the same name for follow-ups in the same consult so Gemini retains context. Use a fresh name (or --reset) when starting a new topic.
Gather context for a good consult. Include:
Write this up as a single clear prompt. Think of it as briefing a smart colleague who just sat down.
In your next message:
Take advantage of the fact that Gemini is a different model with a different thought process. It is a collaborator that you can benefit from, and will make your work stronger.
Use --reset on the first call for a new topic. It deletes any existing session file with that name, then sends your prompt against a fresh conversation:
ask-gemini --session <topic> --reset "Your well-formulated question here"
For follow-up questions in the same consult (Gemini remembers the conversation), drop --reset:
ask-gemini --session <topic> "Follow-up question here"
Attaching media:
ask-gemini --session ui-bug --reset \
--photo ./screenshot1.png --photo ./screenshot2.png \
"What's wrong with the alignment in the second screenshot vs the first?"
ask-gemini --session demo-review --reset \
--video ./recording.mov \
"Review this UX flow — where does the user appear confused?"
You can also pipe longer prompts via stdin if the question is too long for a shell argument.
The user has not seen the prompt you sent to Gemini — only your synthesis. Treat Gemini's response as raw input that needs to be re-framed for someone with no prior context:
Then add your own analysis on top:
Do NOT just parrot back the response — add value by synthesizing both perspectives.
If the user wants to dig deeper, send follow-up questions on the same --session (without --reset) to continue the conversation with Gemini.
ask-gemini checks GitHub for a newer release at most once a day (cached in the
system temp dir) and prints a one-line notice to stderr when one exists, e.g.:
ask-gemini: update available v0.2.0 → v0.3.0. Run this skill's update.sh to upgrade (suppress with ASK_GEMINI_NO_UPDATE_CHECK=1).
When you see that notice, tell the user a newer version is available and offer to upgrade — don't upgrade silently. The updater lives next to this file:
"$(dirname SKILL.md)/update.sh" # preview: prints current → latest, then stops
"$(dirname SKILL.md)/update.sh" --yes # apply after the user agrees
update.sh installs the new binary and skill to wherever this skill is
installed (so a project-level .claude install upgrades in place), cloning into
the system temp dir and cleaning up after itself. It needs git, curl, and the
Go toolchain. The check makes an unauthenticated GitHub API call, which reveals
the user's IP to GitHub; set ASK_GEMINI_NO_UPDATE_CHECK=1 to disable it.
If ask-gemini misbehaves (silent failures, confusing errors, missing flags, wrong-looking output) or the skill instructions are unclear, open a GitHub issue at:
https://github.com/akostibas/ask-gemini-skill/issues
Do not leave a bug_report*.txt file in the user's working directory — it will sit unnoticed. File the issue directly so it lands in the project tracker.
Before filing, use gh issue list -R akostibas/ask-gemini-skill --search "<keyword>" to check for a duplicate. A good bug report includes:
GEMINI_API_KEY set? ASK_GEMINI_KEY_COMMAND set?).ask-gemini --version (or ls -la $(which ask-gemini) for the build mtime).File via:
gh issue create -R akostibas/ask-gemini-skill --title "<short title>" --body-file <path-to-writeup>