Skip to content

Commit 6026e78

Browse files
committed
Text to SQL RFT example
1 parent c0c7c8e commit 6026e78

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

eval_protocol/models.py

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@
1414
from openai.types.chat.chat_completion_message_tool_call import (
1515
ChatCompletionMessageToolCall,
1616
)
17+
from openai.types.chat import ChatCompletionContentPartImageParam
1718
from pydantic import BaseModel, ConfigDict, Field
1819

1920
from eval_protocol.get_pep440_version import get_pep440_version
@@ -462,9 +463,9 @@ class Message(BaseModel):
462463
"""Chat message model with trajectory evaluation support."""
463464

464465
role: str # assistant, user, system, tool
465-
content: Optional[Union[str, List[ChatCompletionContentPartTextParam]]] = Field(
466-
default="", description="The content of the message."
467-
)
466+
content: Optional[
467+
Union[str, List[Union[ChatCompletionContentPartTextParam, ChatCompletionContentPartImageParam]]]
468+
] = Field(default="", description="The content of the message.")
468469
reasoning_content: Optional[str] = Field(
469470
default=None, description="Optional hidden chain-of-thought or reasoning content."
470471
)

0 commit comments

Comments
 (0)