thumbs-eval.md
HTML wrapper for HTML-only fetchers; content is shown verbatim.
Raw file
# GGQ thumbnails: feasibility notes (Dragonfly `/system/images`)
Black/white:
- Verified: GGQ serves images via Dragonfly-style URLs and supports the `thumb` processor at arbitrary sizes (example sizes used in the demos: `480x320`, `960x640`).
- Quality depends on the original upload. If the stored original is small (e.g., ~300×200), a larger `thumb` will upscale and won’t become sharper.
- Name-based “find the real original” heuristics are only needed when multiple near-duplicate uploads exist; otherwise the Dragonfly `f` reference already points at the original.
## What we observed
- Production destination pages currently render many thumbnails at `360x240` (example: `image_fu ... "360x240"`).
- The URL shape is:
`/system/images/<b64(json)>/<filename>`
Where json looks like:
- Original:
- `[["f","<image_uid>"]]`
- Thumb:
- `[["f","<image_uid>"],["p","thumb","480x320"]]`
Changing the `thumb` geometry changes the rendered size without needing a new upload.
## What this enables (recommended)
- Keep the existing `360x240` as baseline (fast), but add `srcset` for retina/large displays:
- 1x: `360x240`
- 2x: `720x480` (or `960x640` for hero placements)
- For hero/featured placements, use a larger crop (e.g., `960x640`) and let CSS constrain the rendered size.
- For images used across multiple components, standardize a small set of thumb sizes to maximize cache hit-rate.
## Name-based mapping heuristics (when needed)
If GGQ has multiple images that represent the “same visual” at different resolutions, and the page is currently pointing at a low-res variant, use the DB + filenames to pick a better source:
- Normalize `image_name` for grouping:
- lowercase
- strip tokens like `-min`, `(copy)`, trailing counters
- strip embedded size hints like `300x200`, `360x240`
- Within a group, select the highest `image_width × image_height` (and/or highest `image_size`) as the preferred original.
- Regenerate thumbs from that preferred original.
## Evidence: media DB inventory (hi-res exists)
An internal media inventory run verified public `/system/images/*` URLs and found that many originals are high resolution:
- Total images: `9312`
- Max-dim ≥ 2000px: `1062`
- Max-dim ≥ 3000px: `449`