mirror of
https://github.com/amithkoujalgi/ollama4j.git
synced 2025-05-15 03:47:13 +02:00
31 lines
784 B
Java
31 lines
784 B
Java
package io.github.ollama4j.models;
|
|
|
|
import com.fasterxml.jackson.annotation.JsonIgnoreProperties;
|
|
import com.fasterxml.jackson.annotation.JsonProperty;
|
|
import com.fasterxml.jackson.core.JsonProcessingException;
|
|
import io.github.ollama4j.utils.Utils;
|
|
import lombok.Data;
|
|
|
|
@Data
|
|
@JsonIgnoreProperties(ignoreUnknown = true)
|
|
public class ModelDetail {
|
|
private String license;
|
|
|
|
@JsonProperty("modelfile")
|
|
private String modelFile;
|
|
|
|
private String parameters;
|
|
private String template;
|
|
private String system;
|
|
private ModelMeta details;
|
|
|
|
@Override
|
|
public String toString() {
|
|
try {
|
|
return Utils.getObjectMapper().writerWithDefaultPrettyPrinter().writeValueAsString(this);
|
|
} catch (JsonProcessingException e) {
|
|
throw new RuntimeException(e);
|
|
}
|
|
}
|
|
}
|