GitHub user gidhubuser255 edited a comment on the discussion: APIs for updating underlying function of a node (2 part question)
### (1) The override modules method worked thanks! Still would be nice to manage with function overrides directly on the driver, but I see there is some relevant work being discussed here (https://github.com/apache/hamilton/issues/1268) already that might get that closer to reality. (Also looks like I can get some pseudo-functionality of this using types.ModuleType to create custom module objects that I can make updates on.) Would it be acceptable to re-request this (if not already implemented) when the work on first class function instantiation is more mature? ### (2) To expand on part 2 take a look at these 2 graphs <img width="579" height="290" alt="image" src="https://github.com/user-attachments/assets/fd00c884-debb-4725-a711-3c4b87ceb6ea" /> The left graph is the original DAG structure as defined by the functions. What I want to do is update X -> X' but only when considering the path that passes through B. Doing so will result in the right graph. You'll notice in the right graph the D in the 2 branches are identical even though they are on different branches. So essentially the idea is that I'm looking for some mechanism that can unconverge paths into separate paths, without having to manually define each separate path since this can explode exponentially depending on how many converging points you have and which in_paths you want to update in. Subdag and pipe look promising I'll take a deeper look at those, thanks! However, one downside off the bat I can think of is that the model will need to be pre-constructed/structure hardcoded for pre-determined unraveled branches, as opposed to having a mechanism that can dynamically unravel branches for these any path-specific updates, like the one proposed. GitHub link: https://github.com/apache/hamilton/discussions/1397#discussioncomment-14569798 ---- This is an automatically sent email for [email protected]. To unsubscribe, please send an email to: [email protected]
