summaryrefslogtreecommitdiff
path: root/internal/llm/openai.go
diff options
context:
space:
mode:
authorPaul Buetow <paul@buetow.org>2025-08-16 17:19:46 +0300
committerPaul Buetow <paul@buetow.org>2025-08-16 17:19:46 +0300
commite62c851109892ed60a60926904b03bb4d2378fe4 (patch)
tree7325477c1f7223de76545d47731a85c5c47a3f5c /internal/llm/openai.go
parent778a3591bd27ce49acb6f8596f3c714351c412dc (diff)
feat(llm): add Ollama provider + provider selection and CLI override; update README and logsv0.0.1
Diffstat (limited to 'internal/llm/openai.go')
-rw-r--r--internal/llm/openai.go12
1 files changed, 8 insertions, 4 deletions
diff --git a/internal/llm/openai.go b/internal/llm/openai.go
index 279eca4..dbcee4d 100644
--- a/internal/llm/openai.go
+++ b/internal/llm/openai.go
@@ -15,10 +15,10 @@ import (
// openAIClient implements Client against OpenAI's Chat Completions API.
type openAIClient struct {
- httpClient *http.Client
- apiKey string
- baseURL string
- defaultModel string
+ httpClient *http.Client
+ apiKey string
+ baseURL string
+ defaultModel string
}
// Colors and base styling are provided by logging.go
@@ -159,3 +159,7 @@ func trimPreview(s string, n int) string {
}
return s[:n] + "…"
}
+
+// Provider metadata
+func (c *openAIClient) Name() string { return "openai" }
+func (c *openAIClient) DefaultModel() string { return c.defaultModel }