mirror of
https://github.com/farcasclaudiu/Flowise.git
synced 2026-06-25 21:01:09 +03:00
Fix merge conflicts
This commit is contained in:
@@ -15,7 +15,7 @@
|
||||
"data": {
|
||||
"id": "openApiChain_1",
|
||||
"label": "OpenAPI Chain",
|
||||
"version": 1,
|
||||
"version": 2,
|
||||
"name": "openApiChain",
|
||||
"type": "OpenAPIChain",
|
||||
"baseClasses": ["OpenAPIChain", "BaseChain"],
|
||||
@@ -53,9 +53,19 @@
|
||||
"name": "model",
|
||||
"type": "ChatOpenAI",
|
||||
"id": "openApiChain_1-input-model-ChatOpenAI"
|
||||
},
|
||||
{
|
||||
"label": "Input Moderation",
|
||||
"description": "Detect text that could generate harmful output and prevent it from being sent to the language model",
|
||||
"name": "inputModeration",
|
||||
"type": "Moderation",
|
||||
"optional": true,
|
||||
"list": true,
|
||||
"id": "openApiChain_1-input-inputModeration-Moderation"
|
||||
}
|
||||
],
|
||||
"inputs": {
|
||||
"inputModeration": "",
|
||||
"model": "{{chatOpenAI_1.data.instance}}",
|
||||
"yamlLink": "https://gist.githubusercontent.com/roaldnefs/053e505b2b7a807290908fe9aa3e1f00/raw/0a212622ebfef501163f91e23803552411ed00e4/openapi.yaml",
|
||||
"headers": ""
|
||||
@@ -399,7 +409,7 @@
|
||||
"id": "openAIFunctionAgent_0",
|
||||
"label": "OpenAI Function Agent",
|
||||
"name": "openAIFunctionAgent",
|
||||
"version": 3,
|
||||
"version": 4,
|
||||
"type": "AgentExecutor",
|
||||
"baseClasses": ["AgentExecutor", "BaseChain"],
|
||||
"category": "Agents",
|
||||
@@ -434,9 +444,19 @@
|
||||
"name": "model",
|
||||
"type": "BaseChatModel",
|
||||
"id": "openAIFunctionAgent_0-input-model-BaseChatModel"
|
||||
},
|
||||
{
|
||||
"label": "Input Moderation",
|
||||
"description": "Detect text that could generate harmful output and prevent it from being sent to the language model",
|
||||
"name": "inputModeration",
|
||||
"type": "Moderation",
|
||||
"optional": true,
|
||||
"list": true,
|
||||
"id": "openAIFunctionAgent_0-input-inputModeration-Moderation"
|
||||
}
|
||||
],
|
||||
"inputs": {
|
||||
"inputModeration": "",
|
||||
"tools": ["{{chainTool_0.data.instance}}"],
|
||||
"memory": "{{bufferMemory_0.data.instance}}",
|
||||
"model": "{{chatOpenAI_2.data.instance}}",
|
||||
|
||||
@@ -1100,7 +1100,7 @@
|
||||
"data": {
|
||||
"id": "conversationalAgent_0",
|
||||
"label": "Conversational Agent",
|
||||
"version": 2,
|
||||
"version": 3,
|
||||
"name": "conversationalAgent",
|
||||
"type": "AgentExecutor",
|
||||
"baseClasses": ["AgentExecutor", "BaseChain", "Runnable"],
|
||||
@@ -1137,9 +1137,19 @@
|
||||
"name": "memory",
|
||||
"type": "BaseChatMemory",
|
||||
"id": "conversationalAgent_0-input-memory-BaseChatMemory"
|
||||
},
|
||||
{
|
||||
"label": "Input Moderation",
|
||||
"description": "Detect text that could generate harmful output and prevent it from being sent to the language model",
|
||||
"name": "inputModeration",
|
||||
"type": "Moderation",
|
||||
"optional": true,
|
||||
"list": true,
|
||||
"id": "conversationalAgent_0-input-inputModeration-Moderation"
|
||||
}
|
||||
],
|
||||
"inputs": {
|
||||
"inputModeration": "",
|
||||
"tools": ["{{chainTool_0.data.instance}}", "{{chainTool_1.data.instance}}"],
|
||||
"model": "{{chatOpenAI_3.data.instance}}",
|
||||
"memory": "{{bufferMemory_0.data.instance}}",
|
||||
|
||||
@@ -15,7 +15,7 @@
|
||||
"data": {
|
||||
"id": "autoGPT_0",
|
||||
"label": "AutoGPT",
|
||||
"version": 1,
|
||||
"version": 2,
|
||||
"name": "autoGPT",
|
||||
"type": "AutoGPT",
|
||||
"baseClasses": ["AutoGPT"],
|
||||
@@ -66,9 +66,19 @@
|
||||
"name": "vectorStoreRetriever",
|
||||
"type": "BaseRetriever",
|
||||
"id": "autoGPT_0-input-vectorStoreRetriever-BaseRetriever"
|
||||
},
|
||||
{
|
||||
"label": "Input Moderation",
|
||||
"description": "Detect text that could generate harmful output and prevent it from being sent to the language model",
|
||||
"name": "inputModeration",
|
||||
"type": "Moderation",
|
||||
"optional": true,
|
||||
"list": true,
|
||||
"id": "autoGPT_0-input-inputModeration-Moderation"
|
||||
}
|
||||
],
|
||||
"inputs": {
|
||||
"inputModeration": "",
|
||||
"tools": ["{{readFile_0.data.instance}}", "{{writeFile_1.data.instance}}", "{{serpAPI_0.data.instance}}"],
|
||||
"model": "{{chatOpenAI_0.data.instance}}",
|
||||
"vectorStoreRetriever": "{{pinecone_0.data.instance}}",
|
||||
|
||||
@@ -15,7 +15,7 @@
|
||||
"data": {
|
||||
"id": "babyAGI_1",
|
||||
"label": "BabyAGI",
|
||||
"version": 1,
|
||||
"version": 2,
|
||||
"name": "babyAGI",
|
||||
"type": "BabyAGI",
|
||||
"baseClasses": ["BabyAGI"],
|
||||
@@ -42,9 +42,19 @@
|
||||
"name": "vectorStore",
|
||||
"type": "VectorStore",
|
||||
"id": "babyAGI_1-input-vectorStore-VectorStore"
|
||||
},
|
||||
{
|
||||
"label": "Input Moderation",
|
||||
"description": "Detect text that could generate harmful output and prevent it from being sent to the language model",
|
||||
"name": "inputModeration",
|
||||
"type": "Moderation",
|
||||
"optional": true,
|
||||
"list": true,
|
||||
"id": "babyAGI_1-input-inputModeration-Moderation"
|
||||
}
|
||||
],
|
||||
"inputs": {
|
||||
"inputModeration": "",
|
||||
"model": "{{chatOpenAI_0.data.instance}}",
|
||||
"vectorStore": "{{pinecone_0.data.instance}}",
|
||||
"taskLoop": 3
|
||||
|
||||
@@ -16,7 +16,7 @@
|
||||
"id": "csvAgent_0",
|
||||
"label": "CSV Agent",
|
||||
"name": "csvAgent",
|
||||
"version": 1,
|
||||
"version": 2,
|
||||
"type": "AgentExecutor",
|
||||
"baseClasses": ["AgentExecutor", "BaseChain"],
|
||||
"category": "Agents",
|
||||
@@ -36,9 +36,19 @@
|
||||
"name": "model",
|
||||
"type": "BaseLanguageModel",
|
||||
"id": "csvAgent_0-input-model-BaseLanguageModel"
|
||||
},
|
||||
{
|
||||
"label": "Input Moderation",
|
||||
"description": "Detect text that could generate harmful output and prevent it from being sent to the language model",
|
||||
"name": "inputModeration",
|
||||
"type": "Moderation",
|
||||
"optional": true,
|
||||
"list": true,
|
||||
"id": "csvAgent_0-input-inputModeration-Moderation"
|
||||
}
|
||||
],
|
||||
"inputs": {
|
||||
"inputModeration": "",
|
||||
"model": "{{chatOpenAI_0.data.instance}}"
|
||||
},
|
||||
"outputAnchors": [
|
||||
|
||||
@@ -15,7 +15,7 @@
|
||||
"data": {
|
||||
"id": "conversationalRetrievalQAChain_0",
|
||||
"label": "Conversational Retrieval QA Chain",
|
||||
"version": 2,
|
||||
"version": 3,
|
||||
"name": "conversationalRetrievalQAChain",
|
||||
"type": "ConversationalRetrievalQAChain",
|
||||
"baseClasses": ["ConversationalRetrievalQAChain", "BaseChain", "Runnable"],
|
||||
@@ -74,9 +74,19 @@
|
||||
"optional": true,
|
||||
"description": "If left empty, a default BufferMemory will be used",
|
||||
"id": "conversationalRetrievalQAChain_0-input-memory-BaseMemory"
|
||||
},
|
||||
{
|
||||
"label": "Input Moderation",
|
||||
"description": "Detect text that could generate harmful output and prevent it from being sent to the language model",
|
||||
"name": "inputModeration",
|
||||
"type": "Moderation",
|
||||
"optional": true,
|
||||
"list": true,
|
||||
"id": "conversationalRetrievalQAChain_0-input-inputModeration-Moderation"
|
||||
}
|
||||
],
|
||||
"inputs": {
|
||||
"inputModeration": "",
|
||||
"model": "{{chatOpenAI_0.data.instance}}",
|
||||
"vectorStoreRetriever": "{{memoryVectorStore_0.data.instance}}",
|
||||
"memory": "",
|
||||
|
||||
@@ -451,7 +451,7 @@
|
||||
"id": "mrklAgentChat_0",
|
||||
"label": "MRKL Agent for Chat Models",
|
||||
"name": "mrklAgentChat",
|
||||
"version": 1,
|
||||
"version": 2,
|
||||
"type": "AgentExecutor",
|
||||
"baseClasses": ["AgentExecutor", "BaseChain"],
|
||||
"category": "Agents",
|
||||
@@ -470,9 +470,19 @@
|
||||
"name": "model",
|
||||
"type": "BaseLanguageModel",
|
||||
"id": "mrklAgentChat_0-input-model-BaseLanguageModel"
|
||||
},
|
||||
{
|
||||
"label": "Input Moderation",
|
||||
"description": "Detect text that could generate harmful output and prevent it from being sent to the language model",
|
||||
"name": "inputModeration",
|
||||
"type": "Moderation",
|
||||
"optional": true,
|
||||
"list": true,
|
||||
"id": "mrklAgentChat_0-input-inputModeration-Moderation"
|
||||
}
|
||||
],
|
||||
"inputs": {
|
||||
"inputModeration": "",
|
||||
"tools": ["{{requestsGet_0.data.instance}}", "{{requestsPost_0.data.instance}}", "{{aiPlugin_0.data.instance}}"],
|
||||
"model": "{{chatOpenAI_0.data.instance}}"
|
||||
},
|
||||
|
||||
@@ -160,7 +160,7 @@
|
||||
"data": {
|
||||
"id": "chatAnthropic_0",
|
||||
"label": "ChatAnthropic",
|
||||
"version": 3,
|
||||
"version": 4,
|
||||
"name": "chatAnthropic",
|
||||
"type": "ChatAnthropic",
|
||||
"baseClasses": ["ChatAnthropic", "BaseChatModel", "BaseLanguageModel", "Runnable"],
|
||||
@@ -179,6 +179,16 @@
|
||||
"name": "modelName",
|
||||
"type": "options",
|
||||
"options": [
|
||||
{
|
||||
"label": "claude-3-opus",
|
||||
"name": "claude-3-opus-20240229",
|
||||
"description": "Most powerful model for highly complex tasks"
|
||||
},
|
||||
{
|
||||
"label": "claude-3-sonnet",
|
||||
"name": "claude-3-sonnet-20240229",
|
||||
"description": "Ideal balance of intelligence and speed for enterprise workloads"
|
||||
},
|
||||
{
|
||||
"label": "claude-2",
|
||||
"name": "claude-2",
|
||||
@@ -278,6 +288,15 @@
|
||||
"optional": true,
|
||||
"additionalParams": true,
|
||||
"id": "chatAnthropic_0-input-topK-number"
|
||||
},
|
||||
{
|
||||
"label": "Allow Image Uploads",
|
||||
"name": "allowImageUploads",
|
||||
"type": "boolean",
|
||||
"description": "Automatically uses claude-3-* models when image is being uploaded from chat. Only works with LLMChain, Conversation Chain, ReAct Agent, and Conversational Agent",
|
||||
"default": false,
|
||||
"optional": true,
|
||||
"id": "chatAnthropic_0-input-allowImageUploads-boolean"
|
||||
}
|
||||
],
|
||||
"inputAnchors": [
|
||||
@@ -295,7 +314,8 @@
|
||||
"temperature": 0.9,
|
||||
"maxTokensToSample": "",
|
||||
"topP": "",
|
||||
"topK": ""
|
||||
"topK": "",
|
||||
"allowImageUploads": true
|
||||
},
|
||||
"outputAnchors": [
|
||||
{
|
||||
|
||||
@@ -392,7 +392,7 @@
|
||||
"data": {
|
||||
"id": "conversationalAgent_0",
|
||||
"label": "Conversational Agent",
|
||||
"version": 2,
|
||||
"version": 3,
|
||||
"name": "conversationalAgent",
|
||||
"type": "AgentExecutor",
|
||||
"baseClasses": ["AgentExecutor", "BaseChain", "Runnable"],
|
||||
@@ -429,9 +429,19 @@
|
||||
"name": "memory",
|
||||
"type": "BaseChatMemory",
|
||||
"id": "conversationalAgent_0-input-memory-BaseChatMemory"
|
||||
},
|
||||
{
|
||||
"label": "Input Moderation",
|
||||
"description": "Detect text that could generate harmful output and prevent it from being sent to the language model",
|
||||
"name": "inputModeration",
|
||||
"type": "Moderation",
|
||||
"optional": true,
|
||||
"list": true,
|
||||
"id": "conversationalAgent_0-input-inputModeration-Moderation"
|
||||
}
|
||||
],
|
||||
"inputs": {
|
||||
"inputModeration": "",
|
||||
"tools": ["{{calculator_1.data.instance}}", "{{serpAPI_0.data.instance}}"],
|
||||
"model": "{{chatOpenAI_0.data.instance}}",
|
||||
"memory": "{{bufferMemory_1.data.instance}}",
|
||||
|
||||
@@ -123,7 +123,7 @@
|
||||
"data": {
|
||||
"id": "conversationalRetrievalAgent_0",
|
||||
"label": "Conversational Retrieval Agent",
|
||||
"version": 3,
|
||||
"version": 4,
|
||||
"name": "conversationalRetrievalAgent",
|
||||
"type": "AgentExecutor",
|
||||
"baseClasses": ["AgentExecutor", "BaseChain", "Runnable"],
|
||||
@@ -159,9 +159,19 @@
|
||||
"name": "model",
|
||||
"type": "BaseChatModel",
|
||||
"id": "conversationalRetrievalAgent_0-input-model-BaseChatModel"
|
||||
},
|
||||
{
|
||||
"label": "Input Moderation",
|
||||
"description": "Detect text that could generate harmful output and prevent it from being sent to the language model",
|
||||
"name": "inputModeration",
|
||||
"type": "Moderation",
|
||||
"optional": true,
|
||||
"list": true,
|
||||
"id": "conversationalRetrievalAgent_0-input-inputModeration-Moderation"
|
||||
}
|
||||
],
|
||||
"inputs": {
|
||||
"inputModeration": "",
|
||||
"tools": ["{{retrieverTool_0.data.instance}}"],
|
||||
"memory": "{{bufferMemory_0.data.instance}}",
|
||||
"model": "{{chatOpenAI_0.data.instance}}",
|
||||
|
||||
@@ -274,7 +274,7 @@
|
||||
"data": {
|
||||
"id": "conversationalRetrievalQAChain_0",
|
||||
"label": "Conversational Retrieval QA Chain",
|
||||
"version": 2,
|
||||
"version": 3,
|
||||
"name": "conversationalRetrievalQAChain",
|
||||
"type": "ConversationalRetrievalQAChain",
|
||||
"baseClasses": ["ConversationalRetrievalQAChain", "BaseChain", "Runnable"],
|
||||
@@ -333,9 +333,19 @@
|
||||
"optional": true,
|
||||
"description": "If left empty, a default BufferMemory will be used",
|
||||
"id": "conversationalRetrievalQAChain_0-input-memory-BaseMemory"
|
||||
},
|
||||
{
|
||||
"label": "Input Moderation",
|
||||
"description": "Detect text that could generate harmful output and prevent it from being sent to the language model",
|
||||
"name": "inputModeration",
|
||||
"type": "Moderation",
|
||||
"optional": true,
|
||||
"list": true,
|
||||
"id": "conversationalRetrievalQAChain_0-input-inputModeration-Moderation"
|
||||
}
|
||||
],
|
||||
"inputs": {
|
||||
"inputModeration": "",
|
||||
"model": "{{chatOpenAI_0.data.instance}}",
|
||||
"vectorStoreRetriever": "{{pinecone_0.data.instance}}",
|
||||
"memory": "",
|
||||
|
||||
@@ -158,7 +158,7 @@
|
||||
"id": "conversationalRetrievalQAChain_0",
|
||||
"label": "Conversational Retrieval QA Chain",
|
||||
"name": "conversationalRetrievalQAChain",
|
||||
"version": 2,
|
||||
"version": 3,
|
||||
"type": "ConversationalRetrievalQAChain",
|
||||
"baseClasses": ["ConversationalRetrievalQAChain", "BaseChain", "Runnable"],
|
||||
"category": "Chains",
|
||||
@@ -216,9 +216,19 @@
|
||||
"optional": true,
|
||||
"description": "If left empty, a default BufferMemory will be used",
|
||||
"id": "conversationalRetrievalQAChain_0-input-memory-BaseMemory"
|
||||
},
|
||||
{
|
||||
"label": "Input Moderation",
|
||||
"description": "Detect text that could generate harmful output and prevent it from being sent to the language model",
|
||||
"name": "inputModeration",
|
||||
"type": "Moderation",
|
||||
"optional": true,
|
||||
"list": true,
|
||||
"id": "conversationalRetrievalQAChain_0-input-inputModeration-Moderation"
|
||||
}
|
||||
],
|
||||
"inputs": {
|
||||
"inputModeration": "",
|
||||
"model": "{{chatOpenAI_0.data.instance}}",
|
||||
"vectorStoreRetriever": "{{memoryVectorStore_0.data.instance}}",
|
||||
"memory": "",
|
||||
|
||||
@@ -85,7 +85,7 @@
|
||||
"data": {
|
||||
"id": "conversationalRetrievalQAChain_0",
|
||||
"label": "Conversational Retrieval QA Chain",
|
||||
"version": 2,
|
||||
"version": 3,
|
||||
"name": "conversationalRetrievalQAChain",
|
||||
"type": "ConversationalRetrievalQAChain",
|
||||
"baseClasses": ["ConversationalRetrievalQAChain", "BaseChain", "Runnable"],
|
||||
@@ -144,9 +144,19 @@
|
||||
"optional": true,
|
||||
"description": "If left empty, a default BufferMemory will be used",
|
||||
"id": "conversationalRetrievalQAChain_0-input-memory-BaseMemory"
|
||||
},
|
||||
{
|
||||
"label": "Input Moderation",
|
||||
"description": "Detect text that could generate harmful output and prevent it from being sent to the language model",
|
||||
"name": "inputModeration",
|
||||
"type": "Moderation",
|
||||
"optional": true,
|
||||
"list": true,
|
||||
"id": "conversationalRetrievalQAChain_0-input-inputModeration-Moderation"
|
||||
}
|
||||
],
|
||||
"inputs": {
|
||||
"inputModeration": "",
|
||||
"model": "{{chatOllama_0.data.instance}}",
|
||||
"vectorStoreRetriever": "{{faiss_0.data.instance}}",
|
||||
"memory": "",
|
||||
|
||||
@@ -15,7 +15,7 @@
|
||||
"data": {
|
||||
"id": "conversationalRetrievalQAChain_0",
|
||||
"label": "Conversational Retrieval QA Chain",
|
||||
"version": 2,
|
||||
"version": 3,
|
||||
"name": "conversationalRetrievalQAChain",
|
||||
"type": "ConversationalRetrievalQAChain",
|
||||
"baseClasses": ["ConversationalRetrievalQAChain", "BaseChain", "Runnable"],
|
||||
@@ -74,9 +74,19 @@
|
||||
"optional": true,
|
||||
"description": "If left empty, a default BufferMemory will be used",
|
||||
"id": "conversationalRetrievalQAChain_0-input-memory-BaseMemory"
|
||||
},
|
||||
{
|
||||
"label": "Input Moderation",
|
||||
"description": "Detect text that could generate harmful output and prevent it from being sent to the language model",
|
||||
"name": "inputModeration",
|
||||
"type": "Moderation",
|
||||
"optional": true,
|
||||
"list": true,
|
||||
"id": "conversationalRetrievalQAChain_0-input-inputModeration-Moderation"
|
||||
}
|
||||
],
|
||||
"inputs": {
|
||||
"inputModeration": "",
|
||||
"model": "{{chatOpenAI_0.data.instance}}",
|
||||
"vectorStoreRetriever": "{{qdrant_0.data.instance}}",
|
||||
"memory": "{{ZepMemory_0.data.instance}}",
|
||||
|
||||
@@ -251,7 +251,7 @@
|
||||
"data": {
|
||||
"id": "conversationalRetrievalQAChain_0",
|
||||
"label": "Conversational Retrieval QA Chain",
|
||||
"version": 2,
|
||||
"version": 3,
|
||||
"name": "conversationalRetrievalQAChain",
|
||||
"type": "ConversationalRetrievalQAChain",
|
||||
"baseClasses": ["ConversationalRetrievalQAChain", "BaseChain", "Runnable"],
|
||||
@@ -310,9 +310,19 @@
|
||||
"optional": true,
|
||||
"description": "If left empty, a default BufferMemory will be used",
|
||||
"id": "conversationalRetrievalQAChain_0-input-memory-BaseMemory"
|
||||
},
|
||||
{
|
||||
"label": "Input Moderation",
|
||||
"description": "Detect text that could generate harmful output and prevent it from being sent to the language model",
|
||||
"name": "inputModeration",
|
||||
"type": "Moderation",
|
||||
"optional": true,
|
||||
"list": true,
|
||||
"id": "conversationalRetrievalQAChain_0-input-inputModeration-Moderation"
|
||||
}
|
||||
],
|
||||
"inputs": {
|
||||
"inputModeration": "",
|
||||
"model": "{{chatOpenAI_0.data.instance}}",
|
||||
"vectorStoreRetriever": "{{pinecone_0.data.instance}}",
|
||||
"rephrasePrompt": "Given the following conversation and a follow up question, rephrase the follow up question to be a standalone question.\n\nChat History:\n{chat_history}\nFollow Up Input: {question}\nStandalone Question:",
|
||||
|
||||
@@ -84,7 +84,7 @@
|
||||
"id": "multiPromptChain_0",
|
||||
"label": "Multi Prompt Chain",
|
||||
"name": "multiPromptChain",
|
||||
"version": 1,
|
||||
"version": 2,
|
||||
"type": "MultiPromptChain",
|
||||
"baseClasses": ["MultiPromptChain", "MultiRouteChain", "BaseChain", "BaseLangChain"],
|
||||
"category": "Chains",
|
||||
@@ -103,9 +103,19 @@
|
||||
"type": "PromptRetriever",
|
||||
"list": true,
|
||||
"id": "multiPromptChain_0-input-promptRetriever-PromptRetriever"
|
||||
},
|
||||
{
|
||||
"label": "Input Moderation",
|
||||
"description": "Detect text that could generate harmful output and prevent it from being sent to the language model",
|
||||
"name": "inputModeration",
|
||||
"type": "Moderation",
|
||||
"optional": true,
|
||||
"list": true,
|
||||
"id": "multiPromptChain_0-input-inputModeration-Moderation"
|
||||
}
|
||||
],
|
||||
"inputs": {
|
||||
"inputModeration": "",
|
||||
"model": "{{chatOpenAI_0.data.instance}}",
|
||||
"promptRetriever": [
|
||||
"{{promptRetriever_0.data.instance}}",
|
||||
|
||||
@@ -82,7 +82,7 @@
|
||||
"data": {
|
||||
"id": "multiRetrievalQAChain_0",
|
||||
"label": "Multi Retrieval QA Chain",
|
||||
"version": 1,
|
||||
"version": 2,
|
||||
"name": "multiRetrievalQAChain",
|
||||
"type": "MultiRetrievalQAChain",
|
||||
"baseClasses": ["MultiRetrievalQAChain", "MultiRouteChain", "BaseChain", "BaseLangChain"],
|
||||
@@ -109,9 +109,19 @@
|
||||
"type": "VectorStoreRetriever",
|
||||
"list": true,
|
||||
"id": "multiRetrievalQAChain_0-input-vectorStoreRetriever-VectorStoreRetriever"
|
||||
},
|
||||
{
|
||||
"label": "Input Moderation",
|
||||
"description": "Detect text that could generate harmful output and prevent it from being sent to the language model",
|
||||
"name": "inputModeration",
|
||||
"type": "Moderation",
|
||||
"optional": true,
|
||||
"list": true,
|
||||
"id": "multiRetrievalQAChain_0-input-inputModeration-Moderation"
|
||||
}
|
||||
],
|
||||
"inputs": {
|
||||
"inputModeration": "",
|
||||
"model": "{{chatOpenAI_0.data.instance}}",
|
||||
"vectorStoreRetriever": [
|
||||
"{{vectorStoreRetriever_0.data.instance}}",
|
||||
|
||||
@@ -163,7 +163,7 @@
|
||||
"data": {
|
||||
"id": "retrievalQAChain_0",
|
||||
"label": "Retrieval QA Chain",
|
||||
"version": 1,
|
||||
"version": 2,
|
||||
"name": "retrievalQAChain",
|
||||
"type": "RetrievalQAChain",
|
||||
"baseClasses": ["RetrievalQAChain", "BaseChain", "BaseLangChain"],
|
||||
@@ -182,9 +182,19 @@
|
||||
"name": "vectorStoreRetriever",
|
||||
"type": "BaseRetriever",
|
||||
"id": "retrievalQAChain_0-input-vectorStoreRetriever-BaseRetriever"
|
||||
},
|
||||
{
|
||||
"label": "Input Moderation",
|
||||
"description": "Detect text that could generate harmful output and prevent it from being sent to the language model",
|
||||
"name": "inputModeration",
|
||||
"type": "Moderation",
|
||||
"optional": true,
|
||||
"list": true,
|
||||
"id": "retrievalQAChain_0-input-inputModeration-Moderation"
|
||||
}
|
||||
],
|
||||
"inputs": {
|
||||
"inputModeration": "",
|
||||
"model": "{{chatOpenAI_0.data.instance}}",
|
||||
"vectorStoreRetriever": "{{redis_0.data.instance}}"
|
||||
},
|
||||
@@ -218,7 +228,7 @@
|
||||
"data": {
|
||||
"id": "retrievalQAChain_1",
|
||||
"label": "Retrieval QA Chain",
|
||||
"version": 1,
|
||||
"version": 2,
|
||||
"name": "retrievalQAChain",
|
||||
"type": "RetrievalQAChain",
|
||||
"baseClasses": ["RetrievalQAChain", "BaseChain", "BaseLangChain"],
|
||||
@@ -237,9 +247,19 @@
|
||||
"name": "vectorStoreRetriever",
|
||||
"type": "BaseRetriever",
|
||||
"id": "retrievalQAChain_1-input-vectorStoreRetriever-BaseRetriever"
|
||||
},
|
||||
{
|
||||
"label": "Input Moderation",
|
||||
"description": "Detect text that could generate harmful output and prevent it from being sent to the language model",
|
||||
"name": "inputModeration",
|
||||
"type": "Moderation",
|
||||
"optional": true,
|
||||
"list": true,
|
||||
"id": "retrievalQAChain_1-input-inputModeration-Moderation"
|
||||
}
|
||||
],
|
||||
"inputs": {
|
||||
"inputModeration": "",
|
||||
"model": "{{chatOpenAI_1.data.instance}}",
|
||||
"vectorStoreRetriever": "{{faiss_0.data.instance}}"
|
||||
},
|
||||
@@ -1741,7 +1761,7 @@
|
||||
"data": {
|
||||
"id": "conversationalAgent_0",
|
||||
"label": "Conversational Agent",
|
||||
"version": 2,
|
||||
"version": 3,
|
||||
"name": "conversationalAgent",
|
||||
"type": "AgentExecutor",
|
||||
"baseClasses": ["AgentExecutor", "BaseChain", "Runnable"],
|
||||
@@ -1778,9 +1798,19 @@
|
||||
"name": "memory",
|
||||
"type": "BaseChatMemory",
|
||||
"id": "conversationalAgent_0-input-memory-BaseChatMemory"
|
||||
},
|
||||
{
|
||||
"label": "Input Moderation",
|
||||
"description": "Detect text that could generate harmful output and prevent it from being sent to the language model",
|
||||
"name": "inputModeration",
|
||||
"type": "Moderation",
|
||||
"optional": true,
|
||||
"list": true,
|
||||
"id": "conversationalAgent_0-input-inputModeration-Moderation"
|
||||
}
|
||||
],
|
||||
"inputs": {
|
||||
"inputModeration": "",
|
||||
"tools": ["{{chainTool_2.data.instance}}", "{{chainTool_3.data.instance}}"],
|
||||
"model": "{{chatOpenAI_2.data.instance}}",
|
||||
"memory": "{{bufferMemory_0.data.instance}}",
|
||||
|
||||
@@ -208,7 +208,7 @@
|
||||
"id": "openAIFunctionAgent_0",
|
||||
"label": "OpenAI Function Agent",
|
||||
"name": "openAIFunctionAgent",
|
||||
"version": 3,
|
||||
"version": 4,
|
||||
"type": "AgentExecutor",
|
||||
"baseClasses": ["AgentExecutor", "BaseChain"],
|
||||
"category": "Agents",
|
||||
@@ -243,9 +243,19 @@
|
||||
"name": "model",
|
||||
"type": "BaseChatModel",
|
||||
"id": "openAIFunctionAgent_0-input-model-BaseChatModel"
|
||||
},
|
||||
{
|
||||
"label": "Input Moderation",
|
||||
"description": "Detect text that could generate harmful output and prevent it from being sent to the language model",
|
||||
"name": "inputModeration",
|
||||
"type": "Moderation",
|
||||
"optional": true,
|
||||
"list": true,
|
||||
"id": "openAIFunctionAgent_0-input-inputModeration-Moderation"
|
||||
}
|
||||
],
|
||||
"inputs": {
|
||||
"inputModeration": "",
|
||||
"tools": ["{{calculator_0.data.instance}}", "{{serper_0.data.instance}}", "{{customTool_0.data.instance}}"],
|
||||
"memory": "{{bufferMemory_0.data.instance}}",
|
||||
"model": "{{chatOpenAI_0.data.instance}}",
|
||||
|
||||
@@ -382,6 +382,16 @@
|
||||
"name": "modelName",
|
||||
"type": "options",
|
||||
"options": [
|
||||
{
|
||||
"label": "claude-3-opus",
|
||||
"name": "claude-3-opus-20240229",
|
||||
"description": "Most powerful model for highly complex tasks"
|
||||
},
|
||||
{
|
||||
"label": "claude-3-sonnet",
|
||||
"name": "claude-3-sonnet-20240229",
|
||||
"description": "Ideal balance of intelligence and speed for enterprise workloads"
|
||||
},
|
||||
{
|
||||
"label": "claude-2",
|
||||
"name": "claude-2",
|
||||
|
||||
@@ -52,7 +52,7 @@
|
||||
"data": {
|
||||
"id": "mrklAgentChat_0",
|
||||
"label": "ReAct Agent for Chat Models",
|
||||
"version": 3,
|
||||
"version": 4,
|
||||
"name": "mrklAgentChat",
|
||||
"type": "AgentExecutor",
|
||||
"baseClasses": ["AgentExecutor", "BaseChain", "Runnable"],
|
||||
@@ -78,9 +78,19 @@
|
||||
"name": "memory",
|
||||
"type": "BaseChatMemory",
|
||||
"id": "mrklAgentChat_0-input-memory-BaseChatMemory"
|
||||
},
|
||||
{
|
||||
"label": "Input Moderation",
|
||||
"description": "Detect text that could generate harmful output and prevent it from being sent to the language model",
|
||||
"name": "inputModeration",
|
||||
"type": "Moderation",
|
||||
"optional": true,
|
||||
"list": true,
|
||||
"id": "mrklAgentChat_0-input-inputModeration-Moderation"
|
||||
}
|
||||
],
|
||||
"inputs": {
|
||||
"inputModeration": "",
|
||||
"tools": ["{{calculator_1.data.instance}}", "{{serper_0.data.instance}}"],
|
||||
"model": "{{chatOpenAI_0.data.instance}}",
|
||||
"memory": "{{RedisBackedChatMemory_0.data.instance}}"
|
||||
|
||||
@@ -249,7 +249,7 @@
|
||||
"data": {
|
||||
"id": "sqlDatabaseChain_0",
|
||||
"label": "Sql Database Chain",
|
||||
"version": 4,
|
||||
"version": 5,
|
||||
"name": "sqlDatabaseChain",
|
||||
"type": "SqlDatabaseChain",
|
||||
"baseClasses": ["SqlDatabaseChain", "BaseChain", "Runnable"],
|
||||
@@ -347,9 +347,19 @@
|
||||
"name": "model",
|
||||
"type": "BaseLanguageModel",
|
||||
"id": "sqlDatabaseChain_0-input-model-BaseLanguageModel"
|
||||
},
|
||||
{
|
||||
"label": "Input Moderation",
|
||||
"description": "Detect text that could generate harmful output and prevent it from being sent to the language model",
|
||||
"name": "inputModeration",
|
||||
"type": "Moderation",
|
||||
"optional": true,
|
||||
"list": true,
|
||||
"id": "sqlDatabaseChain_0-input-inputModeration-Moderation"
|
||||
}
|
||||
],
|
||||
"inputs": {
|
||||
"inputModeration": "",
|
||||
"model": "{{chatOpenAI_0.data.instance}}",
|
||||
"database": "sqlite",
|
||||
"url": "",
|
||||
|
||||
@@ -15,7 +15,7 @@
|
||||
"data": {
|
||||
"id": "vectaraQAChain_0",
|
||||
"label": "Vectara QA Chain",
|
||||
"version": 1,
|
||||
"version": 2,
|
||||
"name": "vectaraQAChain",
|
||||
"type": "VectaraQAChain",
|
||||
"baseClasses": ["VectaraQAChain", "BaseChain", "Runnable"],
|
||||
@@ -189,9 +189,19 @@
|
||||
"name": "vectaraStore",
|
||||
"type": "VectorStore",
|
||||
"id": "vectaraQAChain_0-input-vectaraStore-VectorStore"
|
||||
},
|
||||
{
|
||||
"label": "Input Moderation",
|
||||
"description": "Detect text that could generate harmful output and prevent it from being sent to the language model",
|
||||
"name": "inputModeration",
|
||||
"type": "Moderation",
|
||||
"optional": true,
|
||||
"list": true,
|
||||
"id": "vectaraQAChain_0-input-inputModeration-Moderation"
|
||||
}
|
||||
],
|
||||
"inputs": {
|
||||
"inputModeration": "",
|
||||
"vectaraStore": "{{vectara_1.data.instance}}",
|
||||
"summarizerPromptName": "vectara-experimental-summary-ext-2023-10-23-small",
|
||||
"responseLang": "eng",
|
||||
|
||||
@@ -702,7 +702,7 @@
|
||||
"data": {
|
||||
"id": "conversationalAgent_0",
|
||||
"label": "Conversational Agent",
|
||||
"version": 2,
|
||||
"version": 3,
|
||||
"name": "conversationalAgent",
|
||||
"type": "AgentExecutor",
|
||||
"baseClasses": ["AgentExecutor", "BaseChain", "Runnable"],
|
||||
@@ -739,9 +739,19 @@
|
||||
"name": "memory",
|
||||
"type": "BaseChatMemory",
|
||||
"id": "conversationalAgent_0-input-memory-BaseChatMemory"
|
||||
},
|
||||
{
|
||||
"label": "Input Moderation",
|
||||
"description": "Detect text that could generate harmful output and prevent it from being sent to the language model",
|
||||
"name": "inputModeration",
|
||||
"type": "Moderation",
|
||||
"optional": true,
|
||||
"list": true,
|
||||
"id": "conversationalAgent_0-input-inputModeration-Moderation"
|
||||
}
|
||||
],
|
||||
"inputs": {
|
||||
"inputModeration": "",
|
||||
"tools": ["{{webBrowser_0.data.instance}}"],
|
||||
"model": "{{chatOpenAI_1.data.instance}}",
|
||||
"memory": "{{bufferMemory_0.data.instance}}",
|
||||
|
||||
@@ -187,7 +187,7 @@
|
||||
"data": {
|
||||
"id": "conversationalRetrievalQAChain_0",
|
||||
"label": "Conversational Retrieval QA Chain",
|
||||
"version": 2,
|
||||
"version": 3,
|
||||
"name": "conversationalRetrievalQAChain",
|
||||
"type": "ConversationalRetrievalQAChain",
|
||||
"baseClasses": ["ConversationalRetrievalQAChain", "BaseChain", "Runnable"],
|
||||
@@ -246,9 +246,19 @@
|
||||
"optional": true,
|
||||
"description": "If left empty, a default BufferMemory will be used",
|
||||
"id": "conversationalRetrievalQAChain_0-input-memory-BaseMemory"
|
||||
},
|
||||
{
|
||||
"label": "Input Moderation",
|
||||
"description": "Detect text that could generate harmful output and prevent it from being sent to the language model",
|
||||
"name": "inputModeration",
|
||||
"type": "Moderation",
|
||||
"optional": true,
|
||||
"list": true,
|
||||
"id": "conversationalRetrievalQAChain_0-input-inputModeration-Moderation"
|
||||
}
|
||||
],
|
||||
"inputs": {
|
||||
"inputModeration": "",
|
||||
"model": "{{chatOpenAI_0.data.instance}}",
|
||||
"vectorStoreRetriever": "{{pinecone_0.data.instance}}",
|
||||
"memory": "{{RedisBackedChatMemory_0.data.instance}}",
|
||||
|
||||
@@ -1400,11 +1400,19 @@ export class App {
|
||||
if (chatflow.chatbotConfig) {
|
||||
const parsedConfig = JSON.parse(chatflow.chatbotConfig)
|
||||
// check whether the first one is not empty. if it is empty that means the user set a value and then removed it.
|
||||
const isValidAllowedOrigins = parsedConfig.allowedOrigins[0] !== ''
|
||||
if (parsedConfig.allowedOrigins && parsedConfig.allowedOrigins.length > 0 && isValidAllowedOrigins) {
|
||||
const isValidAllowedOrigins = parsedConfig.allowedOrigins?.length && parsedConfig.allowedOrigins[0] !== ''
|
||||
if (isValidAllowedOrigins) {
|
||||
const originHeader = req.headers.origin as string
|
||||
const origin = new URL(originHeader).host
|
||||
isDomainAllowed = parsedConfig.allowedOrigins.includes(origin)
|
||||
isDomainAllowed =
|
||||
parsedConfig.allowedOrigins.filter((domain: string) => {
|
||||
try {
|
||||
const allowedOrigin = new URL(domain).host
|
||||
return origin === allowedOrigin
|
||||
} catch (e) {
|
||||
return false
|
||||
}
|
||||
}).length > 0
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1464,13 +1472,12 @@ export class App {
|
||||
}
|
||||
templates.push(template)
|
||||
})
|
||||
const FlowiseDocsQnA = templates.find((tmp) => tmp.name === 'Flowise Docs QnA')
|
||||
const FlowiseDocsQnAIndex = templates.findIndex((tmp) => tmp.name === 'Flowise Docs QnA')
|
||||
if (FlowiseDocsQnA && FlowiseDocsQnAIndex > 0) {
|
||||
templates.splice(FlowiseDocsQnAIndex, 1)
|
||||
templates.unshift(FlowiseDocsQnA)
|
||||
const sortedTemplates = templates.sort((a, b) => a.templateName.localeCompare(b.templateName))
|
||||
const FlowiseDocsQnAIndex = sortedTemplates.findIndex((tmp) => tmp.templateName === 'Flowise Docs QnA')
|
||||
if (FlowiseDocsQnAIndex > 0) {
|
||||
sortedTemplates.unshift(sortedTemplates.splice(FlowiseDocsQnAIndex, 1)[0])
|
||||
}
|
||||
return res.json(templates.sort((a, b) => a.templateName.localeCompare(b.templateName)))
|
||||
return res.json(sortedTemplates)
|
||||
})
|
||||
|
||||
// ----------------------------------------
|
||||
@@ -1627,7 +1634,7 @@ export class App {
|
||||
if (!chatflow) return `Chatflow ${chatflowid} not found`
|
||||
|
||||
const uploadAllowedNodes = ['llmChain', 'conversationChain', 'mrklAgentChat', 'conversationalAgent']
|
||||
const uploadProcessingNodes = ['chatOpenAI']
|
||||
const uploadProcessingNodes = ['chatOpenAI', 'chatAnthropic']
|
||||
|
||||
const flowObj = JSON.parse(chatflow.flowData)
|
||||
const imgUploadSizeAndTypes: IUploadFileSizeAndTypes[] = []
|
||||
@@ -1782,6 +1789,8 @@ export class App {
|
||||
const newChatMessage = new ChatMessage()
|
||||
Object.assign(newChatMessage, chatMessage)
|
||||
|
||||
if (!newChatMessage.createdDate) newChatMessage.createdDate = new Date()
|
||||
|
||||
const chatmessage = this.AppDataSource.getRepository(ChatMessage).create(newChatMessage)
|
||||
return await this.AppDataSource.getRepository(ChatMessage).save(chatmessage)
|
||||
}
|
||||
|
||||
@@ -493,13 +493,14 @@ export const clearSessionMemory = async (
|
||||
* @returns {string}
|
||||
*/
|
||||
export const getVariableValue = (
|
||||
paramValue: string,
|
||||
paramValue: string | object,
|
||||
reactFlowNodes: IReactFlowNode[],
|
||||
question: string,
|
||||
chatHistory: IMessage[],
|
||||
isAcceptVariable = false
|
||||
) => {
|
||||
let returnVal = paramValue
|
||||
const isObject = typeof paramValue === 'object'
|
||||
let returnVal = isObject ? JSON.stringify(paramValue) : paramValue
|
||||
const variableStack = []
|
||||
const variableDict = {} as IVariableDict
|
||||
let startIdx = 0
|
||||
@@ -596,7 +597,7 @@ export const getVariableValue = (
|
||||
})
|
||||
return returnVal
|
||||
}
|
||||
return returnVal
|
||||
return isObject ? JSON.parse(returnVal) : returnVal
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
Reference in New Issue
Block a user