diff options
| author | Paul Buetow <paul@buetow.org> | 2026-06-11 08:21:33 +0300 |
|---|---|---|
| committer | Paul Buetow <paul@buetow.org> | 2026-06-11 08:21:33 +0300 |
| commit | 73dadb573f92dca310036e8793932e94277abd62 (patch) | |
| tree | f2def55cf07533400dda21babb759d077e7f899b /internal/llm/openai.go | |
| parent | 8135a6b851b420597c22cfa5e58e6d69e894a00d (diff) | |
llm: add compile-time interface checks for all providers
Add the missing var _ Client / var _ Streamer compile-time satisfaction
check to anthropicClient, and clarify the existing assertion comments for
openAIClient, openRouterClient, ollamaClient (all Client+Streamer) and
youSearchClient (Client only; the You.com research API is non-streaming).
All providers use value receivers, so assertions use zero-value structs.
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Diffstat (limited to 'internal/llm/openai.go')
| -rw-r--r-- | internal/llm/openai.go | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/internal/llm/openai.go b/internal/llm/openai.go index 983723a..25696ce 100644 --- a/internal/llm/openai.go +++ b/internal/llm/openai.go @@ -25,7 +25,8 @@ type openAIClient struct { defaultTemperature *float64 } -// Ensure openAIClient implements Client and Streamer. +// Ensure openAIClient implements Client and Streamer. All of its methods use +// value receivers, so the assertions use a zero-value struct (not a pointer). var ( _ Client = openAIClient{} _ Streamer = openAIClient{} |
