Skip to content
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

Support multiple edges (output streams) in graph #95

Open
amitschang opened this issue Jul 8, 2024 · 0 comments
Open

Support multiple edges (output streams) in graph #95

amitschang opened this issue Jul 8, 2024 · 0 comments
Labels
enhancement New feature or request triage incoming issue needs tagging and a look over

Comments

@amitschang
Copy link
Member

In some cases it may be useful to send different data to different downstream tasks, for example to implement a filter and send filtered data one way and remaining data another (or to output). Right now this has to be implemented by forking a task and doing complementary filtering in two separate tasks, which has some overhead and is repetitive.

Could be implemented by having a task return like:

def task(df: DataFrame) -> DataFrame | list[DataFrame] | dict[DataFrame]

and the edge annotated something like:

(task1, task2, {"streams": [0]})
(task1, task3, {"streams": [1]})
@amitschang amitschang added enhancement New feature or request triage incoming issue needs tagging and a look over labels Jul 8, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request triage incoming issue needs tagging and a look over
Projects
None yet
Development

No branches or pull requests

1 participant