Skip to content

Remote Images are not supported for Anthropic #143

@veshei

Description

@veshei

Seems like even though the documentation claims images are supported here: https://rubyllm.com/guides/chat#working-with-images

Images are not actually supported if you look at the source code: https://github.com/crmne/ruby_llm/blob/main/lib/ruby_llm/providers/anthropic/media.rb

Specifically:

        def format_image(part)
          # Handle image formatting for Anthropic
          # This is just a placeholder - implement based on Anthropic's requirements
          part
        end

Can we get an update to fix this? We would like to use Claude to process image files. It seems pretty similar to the format_pdf logic.

Right now if you try to include an image per the documentation it'll throw this error:
messages.0.content.1.image.source.type: Field required

Metadata

Metadata

Assignees

Labels

bugSomething isn't working

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions