add REQUIRES command to Modelfile (#13361)

This commit is contained in:
Jeffrey Morgan
2025-12-18 13:21:29 -08:00
committed by GitHub
parent 7325791599
commit 8852220f59
10 changed files with 88 additions and 25 deletions

View File

@@ -554,6 +554,9 @@ type CreateRequest struct {
Renderer string `json:"renderer,omitempty"`
Parser string `json:"parser,omitempty"`
// Requires is the minimum version of Ollama required by the model.
Requires string `json:"requires,omitempty"`
// Info is a map of additional information for the model
Info map[string]any `json:"info,omitempty"`
@@ -604,6 +607,7 @@ type ShowResponse struct {
Tensors []Tensor `json:"tensors,omitempty"`
Capabilities []model.Capability `json:"capabilities,omitempty"`
ModifiedAt time.Time `json:"modified_at,omitempty"`
Requires string `json:"requires,omitempty"`
}
// CopyRequest is the request passed to [Client.Copy].