language_models: Add images support for Ollama vision models (#31883)

Ollama supports vision to process input images. This PR adds support for
same. I have tested this with gemma3:4b and have attached the screenshot
of it working.

<img width="435" alt="image"
src="https://github.com/user-attachments/assets/5f17d742-0a37-4e6c-b4d8-05b750a0a158"
/>


Release Notes:

- Add image support for [Ollama vision models](https://ollama.com/search?c=vision)
This commit is contained in:
Umesh Yadav 2025-06-03 14:42:59 +05:30 committed by GitHub
parent a60bea8a3d
commit 59686f1f44
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
3 changed files with 136 additions and 26 deletions

View file

@ -372,6 +372,7 @@ impl AgentSettingsContent {
None,
None,
Some(language_model.supports_tools()),
Some(language_model.supports_images()),
None,
)),
api_url,