Skip to content

Commit c344da4

Browse files
authored
fix keepalive for non-interactive mode (ollama#4438)
1 parent 0e331c7 commit c344da4

File tree

1 file changed

+9
-8
lines changed

1 file changed

+9
-8
lines changed

cmd/cmd.go

+9-8
Original file line numberDiff line numberDiff line change
@@ -905,14 +905,15 @@ func generate(cmd *cobra.Command, opts runOptions) error {
905905
}
906906

907907
request := api.GenerateRequest{
908-
Model: opts.Model,
909-
Prompt: opts.Prompt,
910-
Context: generateContext,
911-
Images: opts.Images,
912-
Format: opts.Format,
913-
System: opts.System,
914-
Template: opts.Template,
915-
Options: opts.Options,
908+
Model: opts.Model,
909+
Prompt: opts.Prompt,
910+
Context: generateContext,
911+
Images: opts.Images,
912+
Format: opts.Format,
913+
System: opts.System,
914+
Template: opts.Template,
915+
Options: opts.Options,
916+
KeepAlive: opts.KeepAlive,
916917
}
917918

918919
if err := client.Generate(ctx, &request, fn); err != nil {

0 commit comments

Comments
 (0)