Skip to content

Add support for predicted outputs in OpenAIModelSettings #2098

Closed
@webholics

Description

@webholics

Description

I would be nice to add support for prediction in OpenAIModelSettings.

Also when it comes to predictions it would also be helpful to be able to define model_settings of an agent depending on the provided RunContext.
Something like:

@my_agent.model_settings
def define_model_settings(
    ctx: RunContext[MyAgentDeps],
) -> ModelSettings:
    return OpenAIModelSettings(prediction=ctx.example_state)

References

https://platform.openai.com/docs/guides/predicted-outputs

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions