-
Notifications
You must be signed in to change notification settings - Fork 684
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Core feature] Support Pydantic Models for input/output task/workflow types #2686
Comments
We have an implementation for this at Freenome and can potentially help build this into Flytekit! Our solution involved:
|
Thanks @ggydush! We may want to implement this slightly differently but would love to discuss @eapolinario @wild-endeavor |
Notes from the pydantic brainstorm: https://docs.google.com/document/d/1W6usjjm8d9NEwE0NLxF1Dt9rkTzLuJxw5kGiVHaPCdg/edit# @eapolinario ^^ if you're interested in reviewing |
Hey @fg91 just a friendly ping on this issue: I think a good milestone for this would be a work-in-progress PR attached to this issue (whatever you may have so far). |
Hello 👋, this issue has been inactive for over 9 months. To help maintain a clean and focused backlog, we'll be marking this issue as stale and will engage on it to decide if it is still applicable. |
Motivation: Why do you think this is important?
pydantic is a widely-used python data validation library. Similar to data classes, it offers a flexible way for users to create custom types that map field names to a variety of value types.
As a pydantic user, I can use my Model definitions in my Flyte workflows so that I don't have to re-implement my custom-defined types in a format that Flyte understands, like data classes.
Goal: What should the final outcome look like, ideally?
I should be able to use
pydantic.BaseModel
subclasses in my flyte tasks and workflowsDescribe alternatives you've considered
Create some sort of utility function that converts BaseModels to dataclasses.
Propose: Link/Inline OR Additional context
No response
Are you sure this issue hasn't been raised already?
Have you read the Code of Conduct?
The text was updated successfully, but these errors were encountered: