Merge pull request #511 from FlowiseAI/feature/ConversationalRetrievalQAChain-Memory

Feature/conversational retrieval qa chain memory
This commit is contained in:
Henry Heng
2023-07-09 16:49:54 +01:00
committed by GitHub
11 changed files with 90 additions and 20 deletions
+4 -2
View File
@@ -168,8 +168,10 @@ export const isValidConnection = (connection, reactFlowInstance) => {
//sourceHandle: "llmChain_0-output-llmChain-BaseChain"
//targetHandle: "mrlkAgentLLM_0-input-model-BaseLanguageModel"
const sourceTypes = sourceHandle.split('-')[sourceHandle.split('-').length - 1].split('|')
const targetTypes = targetHandle.split('-')[targetHandle.split('-').length - 1].split('|')
let sourceTypes = sourceHandle.split('-')[sourceHandle.split('-').length - 1].split('|')
sourceTypes = sourceTypes.map((s) => s.trim())
let targetTypes = targetHandle.split('-')[targetHandle.split('-').length - 1].split('|')
targetTypes = targetTypes.map((t) => t.trim())
if (targetTypes.some((t) => sourceTypes.includes(t))) {
let targetNode = reactFlowInstance.getNode(target)