Replies: 1 comment 1 reply
-
Hey @wirtsi you're right, it shouldn't be the case that the whole looping has to stay outside the pipeline. With Haystack, you can also have connections of components in a pipeline that create a loop. In that case, the directed acyclic graph (DAG) actually becomes a directed cyclic graph. We have recently added an example showing it for a similar use case: conversational rag using experimental memory components: https://colab.research.google.com/github/deepset-ai/haystack-cookbook/blob/main/notebooks/conversational_rag_using_memory.ipynb |
Beta Was this translation helpful? Give feedback.
-
Hey ...
so for example, looking at the Function Calling Example, you notice that the whole looping (so feeding the RAG documents back into the ChatMessages list) is happening outside of the pipeline (the ChatGenerator is called over and over again).
This does not seem very close to how Pipelines are supposed to be used, I am under the impression that the idea is to build a directed graph (DAG) that haystack executes. So something like
So that the whole execution handling resides inside the pipeline. It would also be interesting to see how error handling would be done. I think it would be nice to have a final pipeline state which either gives me the response or an error message so that my code can work with this.
So generally some more advances examples how to conditionally execute pipelines and potentially also how to break down pipelines into sub-pipelines
Bests & Thanks
Beta Was this translation helpful? Give feedback.
All reactions