shipfeedAI news, curated daily

01:20:54 CET
26 JUL01:20:54shipfeed
pull to refreshlast sync
Just in — 30 new
§ tools · storyline

Fixes media-type sniffing from O(N) to O(1) on ID3-prefixed input

@ai-sdk/gateway fixes media-type sniffing from O(N) to O(1) on ID3-prefixed input.

Jul 22 · · primary fetch1 sourceupdated Jul 22 ·

Patch Changes 1efdef8: fix(ai): bound media-type sniffing decode for ID3-prefixed input Media-type detection stripped ID3 tags before the ~18-byte prefix cap, decoding the entire base64 attachment (plus a full-size copy) whenever the data began with `ID3`/`SUQz`. This turned the intended O(1) sniff into an O(N) decode of the whole attachment.

Detection now decodes at most a bounded prefix and skips the ID3 tag within that bound, keeping cost O(1) in input size on all paths (image, audio, and combined). 49414cf: Return response piping promises so callers can catch stream read and write errors. Updated dependencies [e7d064f] @ai-sdk/gateway@3.0.156

read full article on github.com
§ sources2 publications · timeline below
  1. github.comVercel AI SDK — ai v6.0.234primary
  2. github.comVercel AI SDK — ai v5.0.219

§ how this story moved

  1. primaryVercel AI SDK — Releases publishes the launch post.
  2. Vercel AI SDK — Releases picks up coverage.