diff --git a/changelog/4000.fixed.md b/changelog/4000.fixed.md new file mode 100644 index 000000000..871d71135 --- /dev/null +++ b/changelog/4000.fixed.md @@ -0,0 +1 @@ +- Fixed an issue where the default model for `OpenAILLMService` and `AzureLLMService` was mistakenly reverted to `gpt-4o`. The defaults are now restored to `gpt-4.1`. diff --git a/examples/foundational/04a-transports-daily.py b/examples/foundational/04a-transports-daily.py index ab986c22f..b73b7bdfe 100644 --- a/examples/foundational/04a-transports-daily.py +++ b/examples/foundational/04a-transports-daily.py @@ -58,7 +58,6 @@ async def main(): llm = OpenAILLMService( api_key=os.getenv("OPENAI_API_KEY"), settings=OpenAILLMService.Settings( - model="gpt-4o", system_instruction="You are a helpful LLM in a WebRTC call. Your goal is to demonstrate your capabilities in a succinct way. Your output will be spoken aloud, so avoid special characters that can't easily be spoken, such as emojis or bullet points. Respond to what the user said in a creative and helpful way.", ), ) diff --git a/examples/foundational/14v-function-calling-openai.py b/examples/foundational/14v-function-calling-openai.py index 639d9bd23..db759b186 100644 --- a/examples/foundational/14v-function-calling-openai.py +++ b/examples/foundational/14v-function-calling-openai.py @@ -79,7 +79,6 @@ async def run_bot(transport: BaseTransport, runner_args: RunnerArguments): instructions="Please speak clearly and at a moderate pace.", ) - # model choices: gpt-4o, gpt-4.1, etc. llm = OpenAILLMService( api_key=os.getenv("OPENAI_API_KEY"), settings=OpenAILLMService.Settings( diff --git a/examples/foundational/27-simli-layer.py b/examples/foundational/27-simli-layer.py index c8a9ad663..b2cbb6837 100644 --- a/examples/foundational/27-simli-layer.py +++ b/examples/foundational/27-simli-layer.py @@ -73,7 +73,6 @@ async def run_bot(transport: BaseTransport, runner_args: RunnerArguments): llm = OpenAILLMService( api_key=os.getenv("OPENAI_API_KEY"), settings=OpenAILLMService.Settings( - model="gpt-4o-mini", system_instruction="You are a helpful LLM in a WebRTC call. Your goal is to demonstrate your capabilities in a succinct way. Your output will be spoken aloud, so avoid special characters that can't easily be spoken, such as emojis or bullet points. Respond to what the user said in a creative and helpful way.", ), ) diff --git a/examples/foundational/35-pattern-pair-voice-switching.py b/examples/foundational/35-pattern-pair-voice-switching.py index ed9bb3973..c246ce599 100644 --- a/examples/foundational/35-pattern-pair-voice-switching.py +++ b/examples/foundational/35-pattern-pair-voice-switching.py @@ -24,7 +24,7 @@ The PatternPairAggregator: - Returns processed text at sentence boundaries Requirements: - - OpenAI API key (for GPT-4o) + - OpenAI API key - Cartesia API key (for text-to-speech) - Daily API key (for video/audio transport) diff --git a/examples/foundational/37-mem0.py b/examples/foundational/37-mem0.py index 06883a43e..e572d2dbe 100644 --- a/examples/foundational/37-mem0.py +++ b/examples/foundational/37-mem0.py @@ -24,7 +24,7 @@ Example usage (run from pipecat root directory): $ python examples/foundational/37-mem0.py Requirements: - - OpenAI API key (for GPT-4o-mini) + - OpenAI API key - ElevenLabs API key (for text-to-speech) - Daily API key (for video/audio transport) - Mem0 API key (for cloud-based memory storage) @@ -226,7 +226,6 @@ async def run_bot(transport: BaseTransport, runner_args: RunnerArguments): llm = OpenAILLMService( api_key=os.getenv("OPENAI_API_KEY"), settings=OpenAILLMService.Settings( - model="gpt-4o-mini", system_instruction="""You are a personal assistant. You can remember things about the person you are talking to. Some Guidelines: - Make sure your responses are friendly yet short and concise. diff --git a/src/pipecat/services/azure/llm.py b/src/pipecat/services/azure/llm.py index ea705eec6..8b5050e5b 100644 --- a/src/pipecat/services/azure/llm.py +++ b/src/pipecat/services/azure/llm.py @@ -47,7 +47,7 @@ class AzureLLMService(OpenAILLMService): Args: api_key: The API key for accessing Azure OpenAI. endpoint: The Azure endpoint URL. - model: The model identifier to use. Defaults to "gpt-4o". + model: The model identifier to use. Defaults to "gpt-4.1". .. deprecated:: 0.0.105 Use ``settings=AzureLLMService.Settings(model=...)`` instead. @@ -58,7 +58,7 @@ class AzureLLMService(OpenAILLMService): **kwargs: Additional keyword arguments passed to OpenAILLMService. """ # 1. Initialize default_settings with hardcoded defaults - default_settings = self.Settings(model="gpt-4o") + default_settings = self.Settings(model="gpt-4.1") # 2. Apply direct init arg overrides (deprecated) if model is not None: diff --git a/src/pipecat/services/openai/base_llm.py b/src/pipecat/services/openai/base_llm.py index d1d695ef6..41b26bd20 100644 --- a/src/pipecat/services/openai/base_llm.py +++ b/src/pipecat/services/openai/base_llm.py @@ -151,7 +151,7 @@ class BaseOpenAILLMService(LLMService): """ # 1. Initialize default_settings with hardcoded defaults default_settings = self.Settings( - model="gpt-4o", + model="gpt-4.1", system_instruction=None, frequency_penalty=NOT_GIVEN, presence_penalty=NOT_GIVEN,