Module multimodal
Structs§
- Local
Image Cache - Per-path cache for resolved local image data URIs. Keyed by absolute
path; stores
(len, mtime)for freshness checks ((0, 0)sentinel = immutable upload). LRU evicts by both entry count and total bytes. - Prepared
Messages
Enums§
Functions§
- contains_
image_ markers - count_
image_ markers - count_
latest_ user_ image_ markers - count_
user_ image_ markers - extract_
ollama_ image_ payload - parse_
image_ markers - prepare_
messages_ for_ provider - prepare_
messages_ for_ provider_ cached - Like
prepare_messages_for_providerbut reuses aLocalImageCacheacross calls so each unique local image file is read from disk at most once per session (or once per modification for mutable files). - sanitize_
audio_ markers - Strip loadable audio markers (see
strip_unplayable_audio_markers) across every message inmessages, logging one degradation warning when any are removed. Returns the input borrowed when no candidate marker is present (the common, allocation-free path) or an owned rebuilt vector otherwise. - strip_
media_ markers