You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
What I would like to do is have a pydantic model where the AI model call should fill out all the fields but one or two.
The idea here is I'm looping through a list of elements that need to be processed by a particular agent. I have an ID or some sort of deterministic value that I want set on each result and I don't want the agent to touch that field. I could create two separate pydantic models to represent these two states, but I'd rather have a single pydantic model and somehow mark one of the fields as handled by me instead of handled by the agent.
Is this sort of thing possible?
Here's a quick example.
classLabelResult(BaseModel):
labels: list[str]
reasoning: strsummary: strmessage_id: str# I want the model to avoid filling this field in
The text was updated successfully, but these errors were encountered:
Think that would mean this field will be missing if the schema is reproduced for another reason - like the swagger docs of a fastapi deployment which uses this model.
What I would like to do is have a pydantic model where the AI model call should fill out all the fields but one or two.
The idea here is I'm looping through a list of elements that need to be processed by a particular agent. I have an ID or some sort of deterministic value that I want set on each result and I don't want the agent to touch that field. I could create two separate pydantic models to represent these two states, but I'd rather have a single pydantic model and somehow mark one of the fields as handled by me instead of handled by the agent.
Is this sort of thing possible?
Here's a quick example.
The text was updated successfully, but these errors were encountered: