You need to follow these steps :
- Create the Conversation LLM Node:
- Add a node for the conversation LLM.
- Configure the node to maintain chat history where you can pass the conversation history as part of the input to the LLM.
- Set up the node to handle user inputs and generate responses until a specific termination phrase (for example "goodbye") is detected.
- Detect Termination Phrase: Implement logic to detect the termination phrase ("goodbye") in the user's input, you can use a conditional check within the conversation node or by adding a separate node to handle this logic.
- Trigger the Analysis LLM Node: Once the termination phrase is detected, trigger the next node which contains the analysis LLM and pass the entire conversation history to the analysis LLM node.