-
Notifications
You must be signed in to change notification settings - Fork 783
Open
Labels
gen-aiRelated to generative AIRelated to generative AI
Description
Line 270 in ae4972c
class Base64JsonEncoder(json.JSONEncoder): |
In particular for tool call responses which can have arbitrary types inside of them, the uploader's JSON encoder needs to be more robust. For example, datetime may be returned from an tool.
- Handle common datatypes like datetime.
- Have a fallback with
repr()
so that the JSON doesn't get dropped on the floor - Log when the fallback is hit so we know to add support for more types.
It might make sense to consider pydantic for some of these edge cases (maybe as an optional dep), since many agent frameworks return a Pydantic model already that knows how to encode itself.
Metadata
Metadata
Assignees
Labels
gen-aiRelated to generative AIRelated to generative AI
Type
Projects
Status
New issues