Skip to content

Commit 016b59b

Browse files
committed
checkpoint: 2025/09/02 15:27:48
1 parent 89df7b1 commit 016b59b

File tree

7 files changed

+24
-25
lines changed

7 files changed

+24
-25
lines changed

cmd/chat.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@ through natural language interaction.
4545
Examples:
4646
coda chat # Start a new chat session
4747
coda chat --continue # Continue the last session
48-
coda chat --model gpt-4 # Use a specific model`,
48+
coda chat --model o4-mini # Use a specific model`,
4949
RunE: runChat,
5050
}
5151

cmd/config.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -50,8 +50,8 @@ var setCmd = &cobra.Command{
5050
Long: `Set a configuration value.
5151
5252
Examples:
53-
coda config set ai.model gpt-4
54-
coda config set ai.temperature 0.7
53+
coda config set ai.model o4-mini
54+
coda config set ai.temperature 1
5555
coda config set logging.level debug`,
5656
Args: cobra.ExactArgs(2),
5757
RunE: runConfigSet,

internal/ai/azure_test.go

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ func TestNewAzureClient(t *testing.T) {
3131
},
3232
azureConfig: AzureConfig{
3333
Endpoint: "https://myaccount.openai.azure.com",
34-
DeploymentName: "gpt-4-deployment",
34+
DeploymentName: "o4-mini-deployment",
3535
APIVersion: "2024-02-01",
3636
},
3737
wantErr: false,
@@ -43,7 +43,7 @@ func TestNewAzureClient(t *testing.T) {
4343
},
4444
azureConfig: AzureConfig{
4545
Endpoint: "https://myaccount.openai.azure.com",
46-
DeploymentName: "gpt-4-deployment",
46+
DeploymentName: "o4-mini-deployment",
4747
},
4848
wantErr: true,
4949
errType: ErrTypeAuthentication,
@@ -56,7 +56,7 @@ func TestNewAzureClient(t *testing.T) {
5656
},
5757
azureConfig: AzureConfig{
5858
Endpoint: "",
59-
DeploymentName: "gpt-4-deployment",
59+
DeploymentName: "o4-mini-deployment",
6060
},
6161
wantErr: true,
6262
errType: ErrTypeInvalidRequest,
@@ -82,7 +82,7 @@ func TestNewAzureClient(t *testing.T) {
8282
},
8383
azureConfig: AzureConfig{
8484
Endpoint: "not-a-valid-url",
85-
DeploymentName: "gpt-4-deployment",
85+
DeploymentName: "o4-mini-deployment",
8686
},
8787
wantErr: true,
8888
errType: ErrTypeInvalidRequest,
@@ -95,7 +95,7 @@ func TestNewAzureClient(t *testing.T) {
9595
},
9696
azureConfig: AzureConfig{
9797
Endpoint: "myaccount.openai.azure.com",
98-
DeploymentName: "gpt-4-deployment",
98+
DeploymentName: "o4-mini-deployment",
9999
},
100100
wantErr: true,
101101
errType: ErrTypeInvalidRequest,
@@ -108,7 +108,7 @@ func TestNewAzureClient(t *testing.T) {
108108
},
109109
azureConfig: AzureConfig{
110110
Endpoint: "https://myaccount.openai.azure.com",
111-
DeploymentName: "gpt-4-deployment",
111+
DeploymentName: "o4-mini-deployment",
112112
APIVersion: "", // Should default to 2024-02-01
113113
},
114114
wantErr: false,
@@ -347,7 +347,7 @@ func TestAzureEndpointConstruction(t *testing.T) {
347347
func TestAzureListModels(t *testing.T) {
348348
config := AIConfig{
349349
APIKey: "test-key",
350-
Model: "gpt-4-turbo",
350+
Model: "o4-mini",
351351
}
352352
azureConfig := AzureConfig{
353353
Endpoint: "https://myaccount.openai.azure.com",
@@ -367,7 +367,7 @@ func TestAzureListModels(t *testing.T) {
367367
assert.Equal(t, "azure", models[0].OwnedBy)
368368

369369
// Should also return configured model if different
370-
assert.Equal(t, "gpt-4-turbo", models[1].ID)
370+
assert.Equal(t, "o4-mini", models[1].ID)
371371
assert.Equal(t, "azure", models[1].OwnedBy)
372372
}
373373

internal/config/config.example.yaml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -10,13 +10,13 @@ ai:
1010
# api_key: your-api-key-here
1111

1212
# Model to use
13-
model: gpt-4
13+
model: o3
1414

1515
# Temperature (0-2, default: 0.7)
16-
temperature: 0.7
16+
temperature: 1
1717

1818
# Maximum tokens for response
19-
max_tokens: 4096
19+
max_tokens: 0
2020

2121
# OpenAI specific settings
2222
openai:

internal/config/config.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,7 @@ type AIConfig struct {
5151
// Azure specific settings
5252
Azure AzureConfig `yaml:"azure" json:"azure"`
5353

54-
// Reasoning effort for GPT-5 models (optional)
54+
// Reasoning effort for oN, GPT-5 models (optional)
5555
// Valid values: "minimal", "low", "medium", "high"
5656
ReasoningEffort *string `yaml:"reasoning_effort,omitempty" json:"reasoning_effort,omitempty"`
5757

internal/config/config_test.go

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,7 @@ func TestNewDefaultConfig(t *testing.T) {
5151
t.Run("environment overrides", func(t *testing.T) {
5252
os.Setenv("CODA_AI_PROVIDER", "azure")
5353
os.Setenv("OPENAI_API_KEY", "test-key")
54-
os.Setenv("CODA_MODEL", "gpt-4-turbo")
54+
os.Setenv("CODA_MODEL", "o4-mini")
5555
os.Setenv("CODA_LOG_LEVEL", "debug")
5656
os.Setenv("AZURE_OPENAI_ENDPOINT", "https://test.openai.azure.com")
5757
os.Setenv("AZURE_OPENAI_DEPLOYMENT", "test-deployment")
@@ -60,13 +60,12 @@ func TestNewDefaultConfig(t *testing.T) {
6060

6161
assert.Equal(t, "azure", cfg.AI.Provider)
6262
assert.Equal(t, "test-key", cfg.AI.APIKey)
63-
assert.Equal(t, "gpt-4-turbo", cfg.AI.Model)
63+
assert.Equal(t, "o4-mini", cfg.AI.Model)
6464
assert.Equal(t, "debug", cfg.Logging.Level)
6565
assert.Equal(t, "https://test.openai.azure.com", cfg.AI.Azure.Endpoint)
6666
assert.Equal(t, "test-deployment", cfg.AI.Azure.DeploymentName)
6767
})
6868

69-
7069
t.Run("default denied paths", func(t *testing.T) {
7170
cfg := NewDefaultConfig()
7271

internal/config/loader_test.go

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -71,7 +71,7 @@ func TestLoaderLoad(t *testing.T) {
7171
configContent := `
7272
ai:
7373
provider: azure
74-
model: gpt-4-turbo
74+
model: o4-mini
7575
api_key: test-key
7676
azure:
7777
endpoint: https://test.openai.azure.com
@@ -91,8 +91,8 @@ ai:
9191
if cfg.AI.Provider != "azure" {
9292
t.Errorf("Expected provider azure, got %s", cfg.AI.Provider)
9393
}
94-
if cfg.AI.Model != "gpt-4-turbo" {
95-
t.Errorf("Expected model gpt-4-turbo, got %s", cfg.AI.Model)
94+
if cfg.AI.Model != "o4-mini" {
95+
t.Errorf("Expected model o4-mini, got %s", cfg.AI.Model)
9696
}
9797
if cfg.AI.Azure.Endpoint != "https://test.openai.azure.com" {
9898
t.Errorf("Expected endpoint https://test.openai.azure.com, got %s", cfg.AI.Azure.Endpoint)
@@ -130,7 +130,7 @@ func TestLoaderSave(t *testing.T) {
130130
loader := NewLoader()
131131
cfg := NewDefaultConfig()
132132
cfg.AI.Provider = "azure"
133-
cfg.AI.Model = "gpt-4-turbo"
133+
cfg.AI.Model = "o4-mini"
134134
cfg.AI.APIKey = "test-api-key"
135135

136136
savePath := filepath.Join(tempDir, "saved-config.yaml")
@@ -154,8 +154,8 @@ func TestLoaderSave(t *testing.T) {
154154
if loadedCfg.AI.Provider != "azure" {
155155
t.Errorf("Expected provider azure, got %s", loadedCfg.AI.Provider)
156156
}
157-
if loadedCfg.AI.Model != "gpt-4-turbo" {
158-
t.Errorf("Expected model gpt-4-turbo, got %s", loadedCfg.AI.Model)
157+
if loadedCfg.AI.Model != "o4-mini" {
158+
t.Errorf("Expected model o4-mini, got %s", loadedCfg.AI.Model)
159159
}
160160
})
161161

@@ -275,7 +275,7 @@ func TestApplyEnvironmentOverrides(t *testing.T) {
275275
t.Errorf("Expected API key coda-key, got %s", cfg.AI.APIKey)
276276
}
277277
if cfg.AI.Model != "o3" {
278-
t.Errorf("Expected model gpt-4, got %s", cfg.AI.Model)
278+
t.Errorf("Expected model o3, got %s", cfg.AI.Model)
279279
}
280280
})
281281

0 commit comments

Comments
 (0)