본문으로 건너뛰기
cccskills
무료GitHub에 공개

genimg-gemini-web

Image generation skill using Gemini Web. Generates images from text prompts via Google Gemini. Also supports text generation. Use as the image generation backend for other skills like cover-image, xhs-images, article-illustrator.

한국어 요약은 준비 중입니다. 원문 설명을 표시하고 있습니다.

연동 도구Gemini
설치 방법 보기

포함된 파일(12)

  • SKILL.md6.9 KB
  • scripts/chrome-auth.ts12.6 KB
  • scripts/client.ts21.2 KB
  • scripts/constants.ts3.2 KB
  • scripts/cookie-store.ts4.5 KB
  • scripts/executor.ts17.9 KB
  • scripts/get-cookie.ts779 B
  • scripts/index.ts127 B
  • scripts/main.ts18.3 KB
  • scripts/paths.ts1.7 KB
  • scripts/session-store.ts2.7 KB
  • scripts/types.ts796 B

SKILL.md(원문)

설치하기 전에 에이전트에게 전달되는 지시 내용을 확인할 수 있습니다.

Gemini Web Client

Supports:

  • Text generation
  • Image generation (download + save)
  • Reference image upload (attach images for vision tasks)
  • Multi-turn conversations within the same executor instance (keepSession)
  • Experimental video generation (generateVideo) — Gemini may return an async placeholder; download might require Gemini web UI

Quick start

npx -y bun scripts/main.ts "Hello, Gemini"
npx -y bun scripts/main.ts --prompt "Explain quantum computing"
npx -y bun scripts/main.ts --prompt "A cute cat" --image cat.png
npx -y bun scripts/main.ts --promptfiles system.md content.md --image out.png

# Multi-turn conversation (agent generates unique sessionId)
npx -y bun scripts/main.ts "Remember this: 42" --sessionId my-unique-id-123
npx -y bun scripts/main.ts "What number?" --sessionId my-unique-id-123

Executor options (programmatic)

This skill is typically consumed via createGeminiWebExecutor(geminiOptions) (see scripts/executor.ts).

Key options in GeminiWebOptions:

  • referenceImages?: string | string[] Upload local images as references (vision input).
  • keepSession?: boolean Reuse Gemini chatMetadata to continue the same conversation across calls (required if you want reference images to persist across multiple messages).
  • generateVideo?: string Generate a video and (best-effort) download to the given path. Gemini may return video_gen_chip (async); in that case you must open Gemini web UI to download the result.

Notes:

  • generateVideo cannot be combined with generateImage / editImage.
  • When keepSession=true and referenceImages is set, reference images are uploaded once per executor instance.

Commands

Text generation

# Simple prompt (positional)
npx -y bun scripts/main.ts "Your prompt here"

# Explicit prompt flag
npx -y bun scripts/main.ts --prompt "Your prompt here"
npx -y bun scripts/main.ts -p "Your prompt here"

# With model selection
npx -y bun scripts/main.ts -p "Hello" -m gemini-2.5-pro

# Pipe from stdin
echo "Summarize this" | npx -y bun scripts/main.ts

Image generation

# Generate image with default path (./generated.png)
npx -y bun scripts/main.ts --prompt "A sunset over mountains" --image

# Generate image with custom path
npx -y bun scripts/main.ts --prompt "A cute robot" --image robot.png

# Shorthand
npx -y bun scripts/main.ts "A dragon" --image=dragon.png

Output formats

# Plain text (default)
npx -y bun scripts/main.ts "Hello"

# JSON output
npx -y bun scripts/main.ts "Hello" --json

Options

OptionDescription
--prompt <text>, -pPrompt text
--promptfiles <files...>Read prompt from files (concatenated in order)
--model <id>, -mModel: gemini-3-pro (default), gemini-2.5-pro, gemini-2.5-flash
--image [path]Generate image, save to path (default: generated.png)
--sessionId <id>Session ID for multi-turn conversation (agent generates unique ID)
--list-sessionsList saved sessions (max 100, sorted by update time)
--jsonOutput as JSON
--loginSign in / refresh cookies, then exit (non-zero if still signed out)
--forceWith --login, always open the browser
--cookie-path <path>Custom cookie file path
--profile-dir <path>Chrome profile directory
--help, -hShow help

CLI note: scripts/main.ts supports text generation, image generation, and multi-turn conversations via --sessionId. Reference images and video generation are exposed via the executor API.

Models

  • gemini-3-pro - Default, latest model
  • gemini-2.5-pro - Previous generation pro
  • gemini-2.5-flash - Fast, lightweight

Authentication

First run opens Chrome to authenticate with Google. Cookies are cached for subsequent runs.

# Sign in / refresh cookies (exits non-zero if still signed out)
npx -y bun scripts/main.ts --login

# Always re-open the browser, even if cached cookies look valid
npx -y bun scripts/main.ts --login --force

Image generation requires a signed-in session. Google serves signed-out visitors a free Flash-tier model that refuses to create images — it answers with prose like "can't create it right now... it's possible you're signed out" instead of failing. The skill detects this and errors out with the fix, rather than reporting an empty result.

Troubleshooting

SymptomCauseFix
Gemini session is not signed inCached cookies expired (__Secure-1PSIDTS rotates often)--login
Image command returns text, no fileSigned-out session downgraded to Flash tier--login
Requested "..." but Gemini served "..."Google rotated the model id for that aliasUse -m gemini-3-pro
Unable to locate Gemini access tokenGemini moved host, or network/redirect issueSet GEMINI_WEB_BASE_URL

Known drift (verified Aug 2026): the gemini-3-pro alias maps correctly to the current Pro tier. The gemini-2.5-pro alias id is stale and silently resolves to a Flash model — the CLI warns when this happens. Prefer gemini-3-pro.

Environment variables

VariableDescription
GEMINI_WEB_DATA_DIRData directory
GEMINI_WEB_COOKIE_PATHCookie file path
GEMINI_WEB_CHROME_PROFILE_DIRChrome profile directory
GEMINI_WEB_CHROME_PATHChrome executable path
GEMINI_WEB_BASE_URLGemini origin override (default https://gemini.google.com)

Examples

Generate text response

npx -y bun scripts/main.ts "What is the capital of France?"

Generate image

npx -y bun scripts/main.ts "A photorealistic image of a golden retriever puppy" --image puppy.png

Get JSON output for parsing

npx -y bun scripts/main.ts "Hello" --json | jq '.text'

Generate image from prompt files

# Concatenate system.md + content.md as prompt
npx -y bun scripts/main.ts --promptfiles system.md content.md --image output.png

Multi-turn conversation

# Start a session with unique ID (agent generates this)
npx -y bun scripts/main.ts "You are a helpful math tutor." --sessionId task-abc123

# Continue the conversation (remembers context)
npx -y bun scripts/main.ts "What is 2+2?" --sessionId task-abc123
npx -y bun scripts/main.ts "Now multiply that by 10" --sessionId task-abc123

# List recent sessions (max 100, sorted by update time)
npx -y bun scripts/main.ts --list-sessions

Session files are stored in ~/Library/Application Support/genimg-skills/gemini-web/sessions/<id>.json and contain:

  • id: Session ID
  • metadata: Gemini chat metadata for continuation
  • messages: Array of {role, content, timestamp, error?}
  • createdAt, updatedAt: Timestamps

리뷰

아직 리뷰가 없습니다. 사용해 본 소감을 남겨 주세요.

댓글

로그인 없이 쓸 수 있습니다. 사용 후기, 질문, 작동하지 않은 환경 등을 편하게 남겨 주세요.

아직 댓글이 없습니다. 첫 댓글을 남겨 보세요.

보내면 바로 공개됩니다. 이메일 주소나 전화번호 같은 개인 정보는 쓰지 마세요. URL은 2개까지입니다.

0 / 1,000자

이 양식은 reCAPTCHA로 보호되며 Google 개인정보처리방침 및 서비스 약관이 적용됩니다.

같은 저장소의 스킬

Generate format-controlled research reports with evidence tracking, citations, and iterative review. This skill should be used when users request a research report, literature review, market or industry analysis, competitive landscape, policy or technical brief, or require a strict report template and section formatting that a single deepresearch pass cannot reliably enforce.

한국어 요약은 준비 중입니다. 원문 설명을 표시하고 있습니다.

proyecto26/sherlock-ai-plugin392026년 9월 1일 업데이트

Transform academic papers into in-depth technical articles with multiple writing style options. Use the MinerU Cloud API for high-precision PDF parsing, automatically extracting images, tables, and formulas. Optional formula explanations and GitHub code analysis, generating Markdown and HTML formats.

한국어 요약은 준비 중입니다. 원문 설명을 표시하고 있습니다.

proyecto26/sherlock-ai-plugin392026년 9월 1일 업데이트

Generate educational comics from academic papers, using visual storytelling to explain core ideas and innovations. Supports 4 art styles: classic (clean lines), tech (futuristic), warm (friendly), chalk (blackboard). Uses genimg-gemini-web to generate images.

한국어 요약은 준비 중입니다. 원문 설명을 표시하고 있습니다.

proyecto26/sherlock-ai-plugin392026년 9월 1일 업데이트

Analyzes research papers (PDF/arXiv URL) and converts them into executable code. Automatically activated upon requests for paper replication, algorithm implementation, or research reproduction. Responds to requests like "Implement this paper", "paper2code", "Convert paper to code".

한국어 요약은 준비 중입니다. 원문 설명을 표시하고 있습니다.

proyecto26/sherlock-ai-plugin392026년 9월 1일 업데이트

Transform research papers into professional visual schemas. Analyzes paper logic, selects optimal layout patterns, and generates detailed prompts for AI image generation.

한국어 요약은 준비 중입니다. 원문 설명을 표시하고 있습니다.

proyecto26/sherlock-ai-plugin392026년 9월 1일 업데이트

proyecto26의 스킬 모두 보기

이 스킬의 문제 신고