Skip to content

Commit 884d961

Browse files
authored
Merge pull request #925 from PrefectHQ/gpt-4o
Use gpt-4o by default
2 parents aedfb95 + a7070ea commit 884d961

File tree

7 files changed

+10
-10
lines changed

7 files changed

+10
-10
lines changed

cookbook/_archive/docs_writer.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
from marvin.beta.applications import Application
88

99
# marvin.settings.log_level = "DEBUG"
10-
marvin.settings.openai.chat.completions.model = "gpt-4-1106-preview"
10+
marvin.settings.openai.chat.completions.model = "gpt-4o"
1111

1212

1313
ROOT_DIR = Path(marvin.__file__).parents[2]

cookbook/_archive/test_writing_application.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99
from pydantic import BaseModel, Field
1010

1111
marvin.settings.log_level = "DEBUG"
12-
marvin.settings.llm_model = "gpt-4"
12+
marvin.settings.llm_model = "gpt-4o"
1313

1414

1515
class TestWriterState(BaseModel):

cookbook/flows/github_digest/repo_activity.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -164,7 +164,7 @@ async def daily_github_digest(
164164
contributors_activity=await data_future.result(),
165165
)
166166

167-
marvin.settings.openai.chat.completions.model = "gpt-4"
167+
marvin.settings.openai.chat.completions.model = "gpt-4o"
168168

169169
epic_story = write_a_tasteful_epic(markdown_digest)
170170

docs/docs/configuration/settings.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ Please set Marvin specific settings in `~/.marvin/.env`. One exception being `OP
1111
For example, in your `~/.marvin/.env` file you could have:
1212
```shell
1313
MARVIN_LOG_LEVEL=INFO
14-
MARVIN_CHAT_COMPLETIONS_MODEL=gpt-4
14+
MARVIN_CHAT_COMPLETIONS_MODEL=gpt-4o
1515
MARVIN_OPENAI_API_KEY='sk-my-api-key'
1616
```
1717
Settings these values will let you avoid setting an API key every time.
@@ -24,7 +24,7 @@ A runtime settings object is accessible via `marvin.settings` and can be used to
2424
```python
2525
import marvin
2626

27-
marvin.settings.openai.chat.completions.model = 'gpt-4'
27+
marvin.settings.openai.chat.completions.model = 'gpt-4o'
2828
```
2929

3030
## Settings for using Azure OpenAI models

src/marvin/settings.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ class ChatCompletionSettings(MarvinSettings):
3636
model_config = SettingsConfigDict(
3737
env_prefix="marvin_chat_completions_", extra="ignore"
3838
)
39-
model: str = Field(description="The default chat model to use.", default="gpt-4")
39+
model: str = Field(description="The default chat model to use.", default="gpt-4o")
4040

4141
temperature: float = Field(description="The default temperature to use.", default=1)
4242

@@ -117,13 +117,13 @@ class AssistantSettings(MarvinSettings):
117117
"""Settings for the assistant API.
118118
119119
Attributes:
120-
model: The default assistant model to use, defaults to `gpt-4-1106-preview`.
120+
model: The default assistant model to use
121121
"""
122122

123123
model_config = SettingsConfigDict(env_prefix="marvin_assistant_")
124124

125125
model: str = Field(
126-
default="gpt-4-1106-preview",
126+
default="gpt-4o",
127127
description="The default assistant model to use.",
128128
)
129129

src/marvin/utilities/testing.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -57,7 +57,7 @@ def assert_equal(
5757
assert result.is_equal, assert_msg
5858

5959

60-
@marvin.fn(model_kwargs=dict(model="gpt-4-1106-preview"))
60+
@marvin.fn(model_kwargs=dict(model="gpt-4o"))
6161
def _assert_equal(
6262
llm_output: Any, expected: Any, instructions: str = None
6363
) -> Assertion:

tests/test_settings.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@ def test_speech_settings_default(self):
4444
class TestAssistantSettings:
4545
def test_assistant_settings_default(self):
4646
settings = AssistantSettings()
47-
assert settings.model == "gpt-4-1106-preview"
47+
assert settings.model == "gpt-4o"
4848

4949

5050
class TestTemporarySettings:

0 commit comments

Comments
 (0)