mirror of
https://github.com/hwchase17/langchain.git
synced 2026-07-11 01:01:41 +00:00
fix(65ff729c): replace invalid Perplexity model 'openai/gpt-5.5' with 'openai/gpt-5'
The slug 'openai/gpt-5.5' was never a valid Perplexity Agent-API model and the API now rejects it with BadRequestError invalid_model, breaking the entire TestPerplexityResponsesStandard integration suite. Point the fixture, docstring, and unit-test instantiation at 'openai/gpt-5', a currently-listed tool-capable Agent-API model.
This commit is contained in:
@@ -1528,7 +1528,7 @@ class ChatPerplexity(BaseChatModel):
|
||||
|
||||
Client-side function tools require the Perplexity Responses (Agent) API:
|
||||
construct the model with `use_responses_api=True` and a tool-capable
|
||||
model such as `openai/gpt-5.5`. The `sonar` family does not support
|
||||
model such as `openai/gpt-5`. The `sonar` family does not support
|
||||
client-side function tools.
|
||||
|
||||
Args:
|
||||
|
||||
@@ -51,7 +51,7 @@ class TestPerplexityResponsesStandard(ChatModelIntegrationTests):
|
||||
|
||||
@property
|
||||
def chat_model_params(self) -> dict:
|
||||
return {"model": "openai/gpt-5.5", "use_responses_api": True}
|
||||
return {"model": "openai/gpt-5", "use_responses_api": True}
|
||||
|
||||
@property
|
||||
def has_tool_choice(self) -> bool:
|
||||
|
||||
@@ -532,7 +532,7 @@ def test_translate_responses_input_keeps_assistant_text_with_tool_calls() -> Non
|
||||
|
||||
def test_to_responses_payload_flattens_tools_and_translates_messages() -> None:
|
||||
"""End-to-end: `_to_responses_payload` flattens tools and translates tool turns."""
|
||||
llm = ChatPerplexity(model="openai/gpt-5.5", api_key="test", use_responses_api=True)
|
||||
llm = ChatPerplexity(model="openai/gpt-5", api_key="test", use_responses_api=True)
|
||||
message_dicts: list[dict[str, Any]] = [
|
||||
{"role": "user", "content": "weather in Paris?"},
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user