Agent skill · Backend & API

image-extraction-debug

Debug Gemini/GPT vision API issues in puzzle image extraction

majiayu000github.com/majiayu000GitHub ↗
claude-codecan modify filesMIT
Install
npx skills add majiayu000/claude-skill-registry --skill image-extraction-debug --agent claude-code

Same command for any agent — swap --agent for codex, cursor, copilot.

Facts
Files in the skill folder: 2
SKILL.md size: 14 KB
Bundled scripts: none
Allowed tools: ReadEditGrepBash
Path: skills/ai-llm/image-extraction-debug/SKILL.md
Open the folder on GitHub →
Where it comes from
Stars: 534
Language: HTML

Weekly change comes from our own snapshots, not the repository page — it measures attention, not adoption.

From the SKILL.md

# Image Extraction Debug Debug and fix issues with AI-powered puzzle image extraction (GPT-5.2 via OpenRouter). ## When to Use - Grid extraction returns wrong dimensions (e.g., 5×5 instead of 7×9) - Domino count mismatches (extracted 12 dominoes, expected 15) - Region detection failures (missing regions, wrong constraints) - Pip counting errors (AI reads "5" as "6") - Constraint badge misinterpretation (reads "Σ10" as "equal") - API errors or timeouts ## Architecture Overview **File:** `src/lib/services/gemini.ts` The extraction uses a **dual-image approach**: 1. **User crops image into two parts** (DualImageCropper component): - **Domino image**: Just the domino tiles - **Grid image**: Just the grid with constraints 2. **Domino extraction** (line 117-211): - Model: `openai/gpt-5.2` - Counts pips on each domino half - Returns: `[(3,5), (0,0), (2,6), ...]` 3. **Grid extraction** (line 260-400): - Model: `openai/gpt-5.2` - Identifies regions, constraints, holes - Returns: JSON with grid structure ## Common Issues & Solutions ### Issue 1: Wrong Grid Dimensions **Symptom**: AI extracts 5×5 grid but puzzle is 7×9 **Cause**: AI guesses dimensions from visible cells only, ignoring holes *

What's inside
Steps it walks through
  1. When to Use
  2. Architecture Overview
  3. Common Issues & Solutions
  4. Issue 1: Wrong Grid Dimensions
  5. Issue 2: Domino Count Mismatch
  6. Issue 3: Wrong Pip Counts
  7. Issue 4: Constraint Badge Misinterpretation
  8. Issue 5: Region Contiguity Failures
  9. Issue 6: API Errors (401, 429, 500)
  10. Testing Extraction Changes
  11. Use Built-in Test Puzzles
  12. Add Debug Extraction Function
  13. Log Image Base64 Size
  14. Prompt Engineering Tips
Ships with 1 file
  • metadata.json
Commands it runs
Look for:
More from claude-skill-registry
All skills →
About this skill
What does the image-extraction-debug skill do?

Debug Gemini/GPT vision API issues in puzzle image extraction

How do I install it?

Run `npx skills add majiayu000/claude-skill-registry --skill image-extraction-debug --agent claude-code` — it drops the skill into your project so the agent can pick it up. Swap the --agent value for codex, cursor or copilot if you use one of those.

Where does this skill come from?

From majiayu000/claude-skill-registry, a repository with 534 stars. We read it straight from the repository tree rather than a submitted listing, so what you see here is what is actually published.

Is a popular skill a good skill?

Not necessarily. Stars measure attention, not adoption — a repository can trend for a week and be abandoned. That is why we show the weekly change from our own snapshots next to the total, instead of a single flattering number.

Keep going