Skip to content

[Feature]: Add seed support to Response #257

Description

@sepandhaghighi

Describe the feature you want to add

Add an optional seed field to the Response class to store the random seed used during LLM inference. This allows users to track and reproduce model generations when the underlying model and provider support deterministic seeding.

Describe your proposed solution

Introduce an optional seed: Optional[int] parameter with validation and a corresponding property and update method. Include seed in to_dict(), to_json(), and from_json(), and include it in response equality checks. The default value should be None to indicate that no seed was provided or reported by the LLM provider.

Describe alternatives you've considered, if relevant

No response

Additional context

No response

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

Metadata

Metadata

Assignees

Labels

enhancementNew feature or request

Projects

No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions