@@ -200,22 +200,16 @@ func setDefaults(debug bool) {
200200// 1. Anthropic
201201// 2. OpenAI
202202// 3. Google Gemini
203- // 4. AWS Bedrock
203+ // 4. Groq
204+ // 5. AWS Bedrock
204205func setProviderDefaults () {
205- // Groq configuration
206- if apiKey := os .Getenv ("GROQ_API_KEY" ); apiKey != "" {
207- viper .SetDefault ("providers.groq.apiKey" , apiKey )
208- viper .SetDefault ("agents.coder.model" , models .QWENQwq )
209- viper .SetDefault ("agents.task.model" , models .QWENQwq )
210- viper .SetDefault ("agents.title.model" , models .QWENQwq )
211- }
212-
213- // Google Gemini configuration
214- if apiKey := os .Getenv ("GEMINI_API_KEY" ); apiKey != "" {
215- viper .SetDefault ("providers.gemini.apiKey" , apiKey )
216- viper .SetDefault ("agents.coder.model" , models .Gemini25 )
217- viper .SetDefault ("agents.task.model" , models .Gemini25Flash )
218- viper .SetDefault ("agents.title.model" , models .Gemini25Flash )
206+ // Anthropic configuration
207+ if apiKey := os .Getenv ("ANTHROPIC_API_KEY" ); apiKey != "" {
208+ viper .SetDefault ("providers.anthropic.apiKey" , apiKey )
209+ viper .SetDefault ("agents.coder.model" , models .Claude37Sonnet )
210+ viper .SetDefault ("agents.task.model" , models .Claude37Sonnet )
211+ viper .SetDefault ("agents.title.model" , models .Claude37Sonnet )
212+ return
219213 }
220214
221215 // OpenAI configuration
@@ -224,21 +218,33 @@ func setProviderDefaults() {
224218 viper .SetDefault ("agents.coder.model" , models .GPT41 )
225219 viper .SetDefault ("agents.task.model" , models .GPT41Mini )
226220 viper .SetDefault ("agents.title.model" , models .GPT41Mini )
221+ return
222+ }
227223
224+ // Google Gemini configuration
225+ if apiKey := os .Getenv ("GEMINI_API_KEY" ); apiKey != "" {
226+ viper .SetDefault ("providers.gemini.apiKey" , apiKey )
227+ viper .SetDefault ("agents.coder.model" , models .Gemini25 )
228+ viper .SetDefault ("agents.task.model" , models .Gemini25Flash )
229+ viper .SetDefault ("agents.title.model" , models .Gemini25Flash )
230+ return
228231 }
229232
230- // Anthropic configuration
231- if apiKey := os .Getenv ("ANTHROPIC_API_KEY" ); apiKey != "" {
232- viper .SetDefault ("providers.anthropic.apiKey" , apiKey )
233- viper .SetDefault ("agents.coder.model" , models .Claude37Sonnet )
234- viper .SetDefault ("agents.task.model" , models .Claude37Sonnet )
235- viper .SetDefault ("agents.title.model" , models .Claude37Sonnet )
233+ // Groq configuration
234+ if apiKey := os .Getenv ("GROQ_API_KEY" ); apiKey != "" {
235+ viper .SetDefault ("providers.groq.apiKey" , apiKey )
236+ viper .SetDefault ("agents.coder.model" , models .QWENQwq )
237+ viper .SetDefault ("agents.task.model" , models .QWENQwq )
238+ viper .SetDefault ("agents.title.model" , models .QWENQwq )
239+ return
236240 }
237241
242+ // AWS Bedrock configuration
238243 if hasAWSCredentials () {
239244 viper .SetDefault ("agents.coder.model" , models .BedrockClaude37Sonnet )
240245 viper .SetDefault ("agents.task.model" , models .BedrockClaude37Sonnet )
241246 viper .SetDefault ("agents.title.model" , models .BedrockClaude37Sonnet )
247+ return
242248 }
243249}
244250
0 commit comments