forked from Mirror/ollama4j
Refactor model response classes and update API methods
- Renamed `ModelProcessesResponse` to `ModelProcessesResult` and updated all related references in the codebase. - Introduced `OllamaEmbedResult` class to replace `OllamaEmbedResponse`, ensuring consistency across the API. - Updated method signatures in `OllamaAPI` to reflect the new class names and adjusted integration tests accordingly.
This commit is contained in:
@@ -12,14 +12,14 @@ This API corresponds to the [PS](https://github.com/ollama/ollama/blob/main/docs
|
||||
package io.github.ollama4j.localtests;
|
||||
|
||||
import io.github.ollama4j.OllamaAPI;
|
||||
import io.github.ollama4j.models.ps.ModelProcessesResponse;
|
||||
import io.github.ollama4j.models.ps.ModelProcessesResult;
|
||||
|
||||
public class Main {
|
||||
public static void main(String[] args) {
|
||||
|
||||
OllamaAPI ollamaAPI = new OllamaAPI("http://localhost:11434");
|
||||
|
||||
ModelProcessesResponse response = ollamaAPI.ps();
|
||||
ModelProcessesResult response = ollamaAPI.ps();
|
||||
|
||||
System.out.println(response);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user