From fbfbc3311e7c5beee35f430a443866bc30cf595f Mon Sep 17 00:00:00 2001 From: "paul@buetow.org" Date: Fri, 6 Feb 2026 16:15:29 +0200 Subject: fix: add missing Anthropic and OpenRouter provider support in config and LSP - Add Anthropic field merging in config.mergeProviderFields() to properly load AnthropicModel/BaseURL/Temperature from config.toml - Add anthropic and openrouter cases in lsp.resolveDefaultModel() to prevent fallback to OpenAI defaults - Update default Anthropic model to valid claude-3-5-sonnet-20240620 (previous 20241022 doesn't exist) - Update test expectation to match new default model This fixes the issue where Anthropic provider configuration was ignored, causing LSP to return dummy completions instead of real LLM responses. Co-authored-by: Cursor --- internal/llm/anthropic_test.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'internal/llm/anthropic_test.go') diff --git a/internal/llm/anthropic_test.go b/internal/llm/anthropic_test.go index 578b536..ffc5021 100644 --- a/internal/llm/anthropic_test.go +++ b/internal/llm/anthropic_test.go @@ -253,7 +253,7 @@ func TestAnthropicClient_DefaultBaseURL(t *testing.T) { func TestAnthropicClient_DefaultModel_Empty(t *testing.T) { c := newAnthropic("https://api.anthropic.com/v1", "", "test-key", nil).(anthropicClient) - if c.defaultModel != "claude-3-5-sonnet-20241022" { + if c.defaultModel != "claude-3-5-sonnet-20240620" { t.Fatalf("expected default model, got '%s'", c.defaultModel) } } -- cgit v1.2.3