Skip to content

BUG: fill_adversarial_placeholders drops converted values and metadata of passed through pieces #3301

Closed

Description

Description

_ModalityFeedbackRouter.fill_adversarial_placeholders documents that non-placeholder pieces are passed through unchanged, but the rebuild only carries original_value and original_value_data_type. The converted_value, converted_value_data_type, and prompt_metadata of a passed through piece are dropped, and the model validator backfills converted_value from the original.

A caller supplied follow-up message whose media piece was already converted (for example a resized or re-encoded file path from an earlier turn) therefore sends the unconverted file to the objective target, and any metadata on the piece is lost.

The sibling builder used by the same router forwards converted_value when it builds multimodal messages, so the pass-through branch is the outlier.

Expected behavior

Passed through pieces should keep their converted values, data types, and prompt metadata, as the docstring already promises.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions