feat: Added web page for configuring model information

This commit is contained in:
wizardchen
2025-08-10 17:04:39 +08:00
committed by lyingbug
parent 4498442fcc
commit bdabed6bfa
43 changed files with 5689 additions and 338 deletions
+3 -1
View File
@@ -63,7 +63,9 @@ func (c *OllamaChat) buildChatRequest(messages []Message, opts *ChatOptions, isS
chatReq.Options["num_predict"] = opts.MaxTokens
}
if opts.Thinking != nil {
chatReq.Options["think"] = *opts.Thinking
chatReq.Think = &ollamaapi.ThinkValue{
Value: *opts.Thinking,
}
}
}
+5
View File
@@ -309,3 +309,8 @@ func (s *OllamaService) Generate(ctx context.Context, req *api.GenerateRequest,
// Use official client Generate method
return s.client.Generate(ctx, req, fn)
}
// GetClient returns the underlying ollama client for advanced operations
func (s *OllamaService) GetClient() *api.Client {
return s.client
}