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
If you want to double check that a property like "pdf_id" that the AI spits out in structured output exists in the database would you just run a while loop checker with max iterations, dynamic model creation of enums or literals, or use AfterValidator? Not sure what is the best practice for this agentic SDK.
The text was updated successfully, but these errors were encountered:
I think the most straightforward thing would be to take the final output, so the validation, and it the validation failed - re-run the agent with the previous input list plus a new message saying that the output was invalid. Something like "pdf didn't exist, please fix"
If you want to double check that a property like "pdf_id" that the AI spits out in structured output exists in the database would you just run a while loop checker with max iterations, dynamic model creation of enums or literals, or use AfterValidator? Not sure what is the best practice for this agentic SDK.
The text was updated successfully, but these errors were encountered: