一键导入
polym-eval-score-image-gemini
Score generated images with Gemini via Vertex AI or AIDP. Use for pointwise image grading and pairwise A/B/tie image comparisons.
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
菜单
Score generated images with Gemini via Vertex AI or AIDP. Use for pointwise image grading and pairwise A/B/tie image comparisons.
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
基于 SOC 职业分类
Research BytePlus products, APIs, SDKs, setup, quotas, regions, pricing, and troubleshooting using the bundled official documentation index, then verify claims on live docs. Use for requests for BytePlus documentation or official links.
Batch-generate Seedance 2.0 Mini videos via the BytePlus console BFF (Mini has no public API). Covers T2V, image/video reference (I2V/R2V), first/last frame, and human portraits. Triggers: "seedance mini", "dreamina mini", "用 mini 出视频".
Generate textured 3D models (GLB + PBR) from an image and/or text prompt via Volcengine Ark Seed3D (doubao-seed3d). Submits the async task, polls to completion, and downloads the .glb. Domestic Volcengine Ark only, not BytePlus overseas.
Generate videos with BytePlus Seedance. Use for Seedance text-to-video, image-to-video, camera control, and draft video workflows.
Generate images with BytePlus Seedream 4.x/4.5. Use for Seedream text-to-image, AI art, product images, and batch image generation.
Creates polished explainer videos from docs, URLs, PDFs, screenshots, or text. Use for product demos, announcement reels, repo videos, and requests like "make an explainer video" or "turn this repo into a video".
| name | polym-eval-score-image-gemini |
| description | Score generated images with Gemini via Vertex AI or AIDP. Use for pointwise image grading and pairwise A/B/tie image comparisons. |
Evaluate AI-generated image quality using Google Gemini models.
Two backends:
google-genai SDKgemini-3.1-p)Two evaluation modes:
Vertex AI backend — verify in .env:
GOOGLE_CLOUD_PROJECT (Required — GCP project ID)GOOGLE_CLOUD_LOCATION (Required — e.g. us-central1)GOOGLE_CLOUD_MODEL (optional, default: gemini-2.5-flash-preview-05-20)Ensure Google Cloud authentication is configured (ADC or service account).
AIDP backend — verify in .env:
AIDP_API_KEY (Required — ByteDance AIDP API key)AIDP_ENDPOINT (optional, default: https://aidp.bytedance.net/api/modelhub/online/v2/crawl)AIDP_MODEL (optional, default: gemini-3.1-p)Also install: pip install openai
# Pointwise via Vertex AI (default)
python skills/polym-eval-score-image-gemini/scripts/evaluate.py \
--mode pointwise \
--prompt "A golden retriever sitting in a garden" \
--image generated.png
# Pointwise via AIDP (gemini-3.1-p)
python skills/polym-eval-score-image-gemini/scripts/evaluate.py \
--mode pointwise \
--prompt "A golden retriever sitting in a garden" \
--image generated.png \
--backend aidp
# Pointwise with reference images
python skills/polym-eval-score-image-gemini/scripts/evaluate.py \
--mode pointwise \
--prompt "Product photo of a red sneaker" \
--image generated.png \
--ref-images ref1.jpg ref2.jpg
# Pairwise via AIDP: compare two images
python skills/polym-eval-score-image-gemini/scripts/evaluate.py \
--mode pairwise \
--prompt "A futuristic city skyline at sunset" \
--image-a modelA_output.png \
--image-b modelB_output.png \
--backend aidp
# Pairwise with reference images
python skills/polym-eval-score-image-gemini/scripts/evaluate.py \
--mode pairwise \
--prompt "Edit: change the dress color to blue" \
--image-a editA.png \
--image-b editB.png \
--ref-images original.jpg
| Parameter | CLI Flag | Type | Description | Default |
|---|---|---|---|---|
mode | --mode | string | pointwise or pairwise | Required |
prompt | --prompt, -p | string | The text prompt used to generate the image | Required |
backend | --backend | string | vertexai or aidp | vertexai |
image | --image | string | Image path (pointwise mode) | Required for pointwise |
image_a | --image-a | string | Image A path (pairwise mode) | Required for pairwise |
image_b | --image-b | string | Image B path (pairwise mode) | Required for pairwise |
ref_images | --ref-images | string[] | Reference image paths (optional) | None |
model | --model, -m | string | Gemini model ID | env GOOGLE_CLOUD_MODEL / AIDP_MODEL |
temperature | --temperature | float | Sampling temperature | 0.2 |
max_image_size | --max-image-size | int | Max image dimension (auto-resize) | 2048 |
| Dimension | Description |
|---|---|
instruction_follow | Faithfulness to prompt instructions (subject, count, action, scene, constraints) |
structure_accuracy | Anatomical/structural correctness (proportions, perspective, physics) |
content_correctness | Semantic correctness (attributes, quantities, text content, factual accuracy) |
aesthetics | Composition, color harmony, lighting, overall visual appeal |
edit_consistency | For editing tasks: preserving unmodified regions while applying edits |
reference_consistency | Alignment with reference images (identity, brand, style preservation) |
reason | 1-3 sentence summary of key scoring rationale |
| Dimension | Description |
|---|---|
prompt_fidelity | Which image better follows the text prompt |
structure | Structural accuracy and physical plausibility |
texture | Detail and material quality |
lighting | Lighting and material realism |
artifacts | Fewer AI-generated defects |
usefulness | Practical usability for real-world applications |
factual_consistency | Alignment with real-world knowledge |
text_rendering | Quality of rendered text in image |
edit_consistency | Correctness of editing operations |
# Vertex AI backend
google-genai
Pillow
requests
python-dotenv
# AIDP backend (additional)
openai
Set GOOGLE_CLOUD_PROJECT and GOOGLE_CLOUD_LOCATION in .env.
Set AIDP_API_KEY in .env.
Run gcloud auth application-default login or configure a service account.
The script automatically retries with smaller image sizes. If it persists, try --max-image-size 1024.
The script uses exponential backoff. If persistent, reduce request frequency or increase quota.