Skip to content

content_index missing in streamed response #44

@nivibilla

Description

@nivibilla

Bug Title

content_index missing in streamed response

Description

hi,

Im using this as a /responses api provider inside the openai agents sdk along with ChatKit sdk for rendering UI

Im getting this error

                     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
pydantic_core._pydantic_core.ValidationError: 1 validation error for AssistantMessageContentPartTextDelta
content_index
  Input should be a valid integer [type=int_type, input_value=None, input_type=NoneType]
    For further information visit https://errors.pydantic.dev/2.12/v/int_type

The AssistantMessageContentPartTextDelta is expected a content_index param to be not None.

I think this traces back to the openai text delta event but not sure how to fix it.

Steps to Reproduce

Need to setup Chatkit, OpenAI Agents

Expected Behavior

setup works fine with using raw vllm server

Actual Behavior

                     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
pydantic_core._pydantic_core.ValidationError: 1 validation error for AssistantMessageContentPartTextDelta
content_index
  Input should be a valid integer [type=int_type, input_value=None, input_type=NoneType]
    For further information visit https://errors.pydantic.dev/2.12/v/int_type

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions