Added APIs to pass images and ask questions on it with LLaVA model

This commit is contained in:
Amith Koujalgi 2023-12-17 15:07:26 +05:30
parent 6e8a7f2593
commit ab89dfcefe

View File

@ -257,7 +257,7 @@ public class OllamaAPI {
* @param imageFiles the list of image files to use for the question * @param imageFiles the list of image files to use for the question
* @return OllamaResult - that includes response text and time taken for response * @return OllamaResult - that includes response text and time taken for response
*/ */
public OllamaResult askWithImages(String model, String promptText, List<File> imageFiles) public OllamaResult askWithImageFiles(String model, String promptText, List<File> imageFiles)
throws OllamaBaseException, IOException, InterruptedException { throws OllamaBaseException, IOException, InterruptedException {
List<String> images = new ArrayList<>(); List<String> images = new ArrayList<>();
for (File imageFile : imageFiles) { for (File imageFile : imageFiles) {