Skip to content

ChatCompletionMessageToolCallParam can't not be converted with openai>=1.99.0Β #1401

@DeoLeung

Description

@DeoLeung
lib/python3.12/site-packages/agents/models/chatcmpl_converter.py", line 443, in items_to_messages
    new_tool_call = ChatCompletionMessageToolCallParam(
                    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

TypeError: Cannot instantiate typing.Union

openai 1.99.3 will fail with chat completions, seems the ChatCompletionMessageToolCallParam is a union now

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions