Skip to content

Do not validate model requests and responses #2230

Closed as not planned
Closed as not planned
@jvstme

Description

@jvstme

Problem

Currently, dstack's OpenAI-compatible endpoint performs strict validation of all requests and responses against a hardcoded schema. However, some model launchers don't adhere to the official OpenAI schema, and the official schema can also evolve rapidly. As a result, some models or launchers can't be used with dstack because validation fails for them. Examples: #1777, #2228.

Solution

Do not perform strict validation for format: openai models. Only extract the fields that dstack needs, such as the model field, and pass the rest of the fields in requests and responses as is.

Note: strict validation may still be necessary for format: tgi models in order to perform format conversion.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions