Files
oh-my-pi/packages
Wolfgang Schoenberger 2f2011f5ee fix(ai): degrade Copilot Responses image detail "original" to auto
The Responses-API "original" image detail is an oh-my-pi extension that
preserves native resolution (snapcompact renders terminal-glyph frames
that do not survive the "auto" downscale). GitHub Copilot's Responses
endpoint rejects detail: "original" with an HTTP 400, so any request
carrying such an image failed outright.

- Add a supportsImageDetailOriginal compat flag in the catalog, resolved
  to false whenever the model resolves to the Copilot host (by provider id
  or base-URL marker, via modelMatchesHost, mirroring the Anthropic compat
  builder) and true for every other host, alongside the existing
  strictResponsesPairing Responses-only flag (same three type touch-points:
  optional on OpenAICompat, omitted from the chat-completions resolved type,
  required on the Responses resolved type).
- Clamp the image detail hint to "auto" when the host does not support
  "original" at both Responses image-emission sites (user content and
  tool-result content). Every other host preserves native-resolution
  frames, so snapcompact is unaffected.

Host-aware detection (rather than a bare provider-string check) keeps the
clamp in force when a model is pointed at the Copilot Responses host under
a different provider id, which would otherwise reintroduce the 400; a
regression test covers that path.

Closes #2822

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-17 22:38:30 -07:00
..
2026-06-18 05:12:25 +02:00
2026-06-17 15:11:23 +02:00
2026-06-18 03:20:08 +02:00
2026-06-18 04:55:19 +02:00
2026-06-18 03:20:08 +02:00
2026-06-18 03:20:08 +02:00
2026-06-18 03:20:08 +02:00
2026-06-18 03:20:08 +02:00
2026-06-18 03:20:08 +02:00
2026-06-18 03:20:08 +02:00