mcpField
V
vision-bench

vision-bench

github.com/glebisテスト・品質401173 回インストール1 日前に更新
リポジトリ

vision-bench について

vision-benchは、1つ以上のビジョンLLM評価器で画像を採点・比較するコマンドラインツールです。画像生成や画像理解の評価向けで、プリセットまたは独自のYAML基準と複数の評価プロバイダーに対応します。

主な機能

  1. 01ビジョンLLM評価器で画像を採点
  2. 02複数画像の比較
  3. 03プリセット評価基準の利用
  4. 04独自のYAML基準の定義
  5. 05Markdown、JSON、表形式で出力

活用シーン

  1. 01AI画像生成の出力比較
  2. 02人物写真や商品写真の品質評価
  3. 03OCRやチャート理解の評価

インストール

コマンドをコピーしてターミナルで実行します。

$npx skills add https://github.com/glebis/claude-skills --skill vision-bench

インストール後、Claude Code で/vision-benchを入力して読み込まれたか確認します。

同梱ファイル

SKILL.md と一緒にインストールされる参考資料やスクリプト。

.gitignore
.sops.yaml
bench.py
judge.py
report.py
requirements.txt
vault.py
.claude-plugin/
plugin.json
criteria/
alt_text.yaml
artistic_style.yaml
chart_analysis.yaml
document_ocr.yaml
invoice.yaml
photorealism.yaml
portrait.yaml
product_photo.yaml
scientific.yaml
text_to_image.yaml
ui_screenshot.yaml

詳細

Vision Bench — LLM 画像評価

1 つ以上の視覚 LLM 評価者を使用し、構造化された評価基準に照らして画像をスコアリングして比較します。

クイックスタート

# Install dependencies
pip install pyyaml openai anthropic mistralai

# Score a single image
python bench.py image.png --criteria photorealism --judge gemini-2.5-flash

# Compare two AI-generated images
python bench.py img_a.png img_b.png \
  --criteria text_to_image \
  --prompt "a fox in a snowy forest" \
  --judge gpt-4o

# Multi-judge consensus
python bench.py img.png \
  --criteria portrait \
  --judges gpt-4o gemini-2.5-flash claude-opus-4-5-20251022

# OpenRouter models (any vision-capable model)
python bench.py img_a.png img_b.png \
  --criteria artistic_style \
  --judges "openrouter/meta-llama/llama-4-maverick" "openrouter/mistralai/pixtral-large-2411"

# List all presets
python bench.py --list-presets

# Save report to file
python bench.py img.png --criteria chart_analysis --save report.md

プリセット

プリセット使用例
text_to_imageAI 画像生成ツール(Midjourney、DALL-E、Flux)の比較
photorealism画像がどれほど説得力のある写真に見えるか
artistic_styleスタイルの一貫性、構図、色の調和
portraitAI 生成ポートレートの品質とリアリティ
product_photoE コマース商品画像の品質
document_ocr文書のテキスト抽出とレイアウト理解
chart_analysisグラフとデータ可視化の理解度
invoice財務文書のフィールド抽出精度
ui_screenshotアプリ/ウェブのスクリーンショット理解
scientific科学・医療画像の精度
alt_textアクセシビリティ向け画像説明の品質

カスタム評価基準:任意の .yaml ファイルを --criteria path/to/my.yaml として渡します。

評価プロバイダー

プレフィックスプロバイダー例
gpt-、o1、o3、o4OpenAIgpt-4o
claude-Anthropicclaude-sonnet-4-5-20251022
gemini-Google Geminigemini-2.5-flash
pixtral-、mistral-、ministral-Mistralpixtral-12b-2409
openrouter/OpenRouter(任意のモデル)openrouter/meta-llama/llama-4-maverick

API キー

キーは secrets.enc.yaml(SOPS + age で暗号化)から読み込まれ、見つからない場合は環境変数が使用されます。

対応するキー:OPENAI_API_KEY、ANTHROPIC_API_KEY、GEMINI_API_KEY、OPENROUTER_API_KEY

独自のキーを暗号化するには:

sops --config .sops.yaml --encrypt --input-type yaml --output-type yaml secrets.yaml > secrets.enc.yaml

出力形式

--output markdown(デフォルト) · --output json · --output table

ファイル

  • bench.py — CLI エントリーポイント
  • judge.py — マルチプロバイダー対応の LLM 評価ロジック
  • report.py — レポート生成
  • vault.py — SOPS シークレットの復号
  • criteria/ — 11 個の YAML プリセットファイル
  • .sops.yaml — 暗号化用 Age キー設定
  • secrets.enc.yaml — 暗号化された API キー

コメント