Format json

This commit is contained in:
ogabrielluiz 2024-05-24 09:16:09 -03:00
commit 3194ba7aee
6 changed files with 9405 additions and 8540 deletions

View file

@ -45,7 +45,9 @@
"name": "template", "name": "template",
"display_name": "Template", "display_name": "Template",
"advanced": false, "advanced": false,
"input_types": ["Text"], "input_types": [
"Text"
],
"dynamic": false, "dynamic": false,
"info": "", "info": "",
"load_from_db": false, "load_from_db": false,
@ -84,14 +86,22 @@
"is_input": null, "is_input": null,
"is_output": null, "is_output": null,
"is_composition": null, "is_composition": null,
"base_classes": ["object", "str", "Text"], "base_classes": [
"object",
"str",
"Text"
],
"name": "", "name": "",
"display_name": "Prompt", "display_name": "Prompt",
"documentation": "", "documentation": "",
"custom_fields": { "custom_fields": {
"template": ["user_input"] "template": [
"user_input"
]
}, },
"output_types": ["Text"], "output_types": [
"Text"
],
"full_path": null, "full_path": null,
"field_formatters": {}, "field_formatters": {},
"frozen": false, "frozen": false,
@ -140,7 +150,9 @@
"info": "", "info": "",
"load_from_db": false, "load_from_db": false,
"title_case": false, "title_case": false,
"input_types": ["Text"] "input_types": [
"Text"
]
}, },
"code": { "code": {
"type": "code", "type": "code",
@ -223,7 +235,9 @@
"info": "", "info": "",
"load_from_db": false, "load_from_db": false,
"title_case": false, "title_case": false,
"input_types": ["Text"] "input_types": [
"Text"
]
}, },
"openai_api_base": { "openai_api_base": {
"type": "str", "type": "str",
@ -242,7 +256,9 @@
"info": "The base URL of the OpenAI API. Defaults to https://api.openai.com/v1.\n\nYou can change this to use other APIs like JinaChat, LocalAI and Prem.", "info": "The base URL of the OpenAI API. Defaults to https://api.openai.com/v1.\n\nYou can change this to use other APIs like JinaChat, LocalAI and Prem.",
"load_from_db": false, "load_from_db": false,
"title_case": false, "title_case": false,
"input_types": ["Text"] "input_types": [
"Text"
]
}, },
"openai_api_key": { "openai_api_key": {
"type": "str", "type": "str",
@ -261,7 +277,9 @@
"info": "The OpenAI API Key to use for the OpenAI model.", "info": "The OpenAI API Key to use for the OpenAI model.",
"load_from_db": true, "load_from_db": true,
"title_case": false, "title_case": false,
"input_types": ["Text"], "input_types": [
"Text"
],
"value": "" "value": ""
}, },
"stream": { "stream": {
@ -300,7 +318,9 @@
"info": "System message to pass to the model.", "info": "System message to pass to the model.",
"load_from_db": false, "load_from_db": false,
"title_case": false, "title_case": false,
"input_types": ["Text"] "input_types": [
"Text"
]
}, },
"temperature": { "temperature": {
"type": "float", "type": "float",
@ -331,7 +351,11 @@
}, },
"description": "Generates text using OpenAI LLMs.", "description": "Generates text using OpenAI LLMs.",
"icon": "OpenAI", "icon": "OpenAI",
"base_classes": ["object", "Text", "str"], "base_classes": [
"object",
"Text",
"str"
],
"display_name": "OpenAI", "display_name": "OpenAI",
"documentation": "", "documentation": "",
"custom_fields": { "custom_fields": {
@ -345,7 +369,9 @@
"stream": null, "stream": null,
"system_message": null "system_message": null
}, },
"output_types": ["Text"], "output_types": [
"Text"
],
"field_formatters": {}, "field_formatters": {},
"frozen": false, "frozen": false,
"field_order": [ "field_order": [
@ -392,7 +418,7 @@
"list": false, "list": false,
"show": true, "show": true,
"multiline": true, "multiline": true,
"value": "from typing import Optional, Union\n\nfrom langflow.base.io.chat import ChatComponent\nfrom langflow.field_typing import Text\nfrom langflow.schema import Record\n\n\nclass ChatOutput(ChatComponent):\n display_name = \"Chat Output\"\n description = \"Display a chat message in the Playground.\"\n icon = \"ChatOutput\"\n\n def build(\n self,\n sender: Optional[str] = \"Machine\",\n sender_name: Optional[str] = \"AI\",\n input_value: Optional[str] = None,\n session_id: Optional[str] = None,\n return_record: Optional[bool] = False,\n record_template: Optional[str] = \"{text}\",\n ) -> Union[Text, Record]:\n return super().build_with_record(\n sender=sender,\n sender_name=sender_name,\n input_value=input_value,\n session_id=session_id,\n return_record=return_record,\n record_template=record_template or \"\",\n )\n", "value": "from typing import Optional, Union\n\nfrom langflow.base.io.chat import ChatComponent\nfrom langflow.field_typing import Text\nfrom langflow.schema import Record\n\n\nclass ChatOutput(ChatComponent):\n display_name = \"Chat Output\"\n description = \"Display a chat message in the Playground.\"\n icon = \"ChatOutput\"\n\n def build(\n self,\n sender: Optional[str] = \"Machine\",\n sender_name: Optional[str] = \"AI\",\n input_value: Optional[str] = None,\n session_id: Optional[str] = None,\n return_record: Optional[bool] = False,\n record_template: Optional[str] = \"{text}\",\n files: Optional[list[str]] = None,\n ) -> Union[Text, Record]:\n return super().build_with_record(\n sender=sender,\n sender_name=sender_name,\n input_value=input_value,\n session_id=session_id,\n return_record=return_record,\n record_template=record_template or \"\",\n files=files,\n )\n",
"fileTypes": [], "fileTypes": [],
"file_path": "", "file_path": "",
"password": false, "password": false,
@ -416,7 +442,9 @@
"name": "input_value", "name": "input_value",
"display_name": "Message", "display_name": "Message",
"advanced": false, "advanced": false,
"input_types": ["Text"], "input_types": [
"Text"
],
"dynamic": false, "dynamic": false,
"info": "", "info": "",
"load_from_db": false, "load_from_db": false,
@ -440,7 +468,9 @@
"info": "In case of Message being a Record, this template will be used to convert it to text.", "info": "In case of Message being a Record, this template will be used to convert it to text.",
"load_from_db": false, "load_from_db": false,
"title_case": false, "title_case": false,
"input_types": ["Text"] "input_types": [
"Text"
]
}, },
"return_record": { "return_record": {
"type": "bool", "type": "bool",
@ -472,7 +502,10 @@
"fileTypes": [], "fileTypes": [],
"file_path": "", "file_path": "",
"password": false, "password": false,
"options": ["Machine", "User"], "options": [
"Machine",
"User"
],
"name": "sender", "name": "sender",
"display_name": "Sender Type", "display_name": "Sender Type",
"advanced": true, "advanced": true,
@ -480,7 +513,9 @@
"info": "", "info": "",
"load_from_db": false, "load_from_db": false,
"title_case": false, "title_case": false,
"input_types": ["Text"] "input_types": [
"Text"
]
}, },
"sender_name": { "sender_name": {
"type": "str", "type": "str",
@ -500,7 +535,9 @@
"info": "", "info": "",
"load_from_db": false, "load_from_db": false,
"title_case": false, "title_case": false,
"input_types": ["Text"] "input_types": [
"Text"
]
}, },
"session_id": { "session_id": {
"type": "str", "type": "str",
@ -519,13 +556,20 @@
"info": "If provided, the message will be stored in the memory.", "info": "If provided, the message will be stored in the memory.",
"load_from_db": false, "load_from_db": false,
"title_case": false, "title_case": false,
"input_types": ["Text"] "input_types": [
"Text"
]
}, },
"_type": "CustomComponent" "_type": "CustomComponent"
}, },
"description": "Display a chat message in the Playground.", "description": "Display a chat message in the Playground.",
"icon": "ChatOutput", "icon": "ChatOutput",
"base_classes": ["Record", "Text", "str", "object"], "base_classes": [
"Record",
"Text",
"str",
"object"
],
"display_name": "Chat Output", "display_name": "Chat Output",
"documentation": "", "documentation": "",
"custom_fields": { "custom_fields": {
@ -536,7 +580,10 @@
"return_record": null, "return_record": null,
"record_template": null "record_template": null
}, },
"output_types": ["Text", "Record"], "output_types": [
"Text",
"Record"
],
"field_formatters": {}, "field_formatters": {},
"frozen": false, "frozen": false,
"field_order": [], "field_order": [],
@ -571,7 +618,7 @@
"list": false, "list": false,
"show": true, "show": true,
"multiline": true, "multiline": true,
"value": "from typing import Optional, Union\n\nfrom langflow.base.io.chat import ChatComponent\nfrom langflow.field_typing import Text\nfrom langflow.schema import Record\n\n\nclass ChatInput(ChatComponent):\n display_name = \"Chat Input\"\n description = \"Get chat inputs from the Playground.\"\n icon = \"ChatInput\"\n\n def build_config(self):\n build_config = super().build_config()\n build_config[\"input_value\"] = {\n \"input_types\": [],\n \"display_name\": \"Message\",\n \"multiline\": True,\n }\n\n return build_config\n\n def build(\n self,\n sender: Optional[str] = \"User\",\n sender_name: Optional[str] = \"User\",\n input_value: Optional[str] = None,\n session_id: Optional[str] = None,\n return_record: Optional[bool] = False,\n ) -> Union[Text, Record]:\n return super().build_no_record(\n sender=sender,\n sender_name=sender_name,\n input_value=input_value,\n session_id=session_id,\n return_record=return_record,\n )\n", "value": "from typing import Optional, Union\n\nfrom langflow.base.io.chat import ChatComponent\nfrom langflow.field_typing import Text\nfrom langflow.schema import Record\n\n\nclass ChatInput(ChatComponent):\n display_name = \"Chat Input\"\n description = \"Get chat inputs from the Playground.\"\n icon = \"ChatInput\"\n\n def build_config(self):\n build_config = super().build_config()\n build_config[\"input_value\"] = {\n \"input_types\": [],\n \"display_name\": \"Message\",\n \"multiline\": True,\n }\n\n return build_config\n\n def build(\n self,\n sender: Optional[str] = \"User\",\n sender_name: Optional[str] = \"User\",\n input_value: Optional[str] = None,\n files: Optional[list[str]] = None,\n session_id: Optional[str] = None,\n return_record: Optional[bool] = False,\n ) -> Union[Text, Record]:\n return super().build_no_record(\n sender=sender,\n sender_name=sender_name,\n input_value=input_value,\n files=files,\n session_id=session_id,\n return_record=return_record,\n )\n",
"fileTypes": [], "fileTypes": [],
"file_path": "", "file_path": "",
"password": false, "password": false,
@ -632,7 +679,10 @@
"fileTypes": [], "fileTypes": [],
"file_path": "", "file_path": "",
"password": false, "password": false,
"options": ["Machine", "User"], "options": [
"Machine",
"User"
],
"name": "sender", "name": "sender",
"display_name": "Sender Type", "display_name": "Sender Type",
"advanced": true, "advanced": true,
@ -640,7 +690,9 @@
"info": "", "info": "",
"load_from_db": false, "load_from_db": false,
"title_case": false, "title_case": false,
"input_types": ["Text"] "input_types": [
"Text"
]
}, },
"sender_name": { "sender_name": {
"type": "str", "type": "str",
@ -660,7 +712,9 @@
"info": "", "info": "",
"load_from_db": false, "load_from_db": false,
"title_case": false, "title_case": false,
"input_types": ["Text"] "input_types": [
"Text"
]
}, },
"session_id": { "session_id": {
"type": "str", "type": "str",
@ -679,13 +733,20 @@
"info": "If provided, the message will be stored in the memory.", "info": "If provided, the message will be stored in the memory.",
"load_from_db": false, "load_from_db": false,
"title_case": false, "title_case": false,
"input_types": ["Text"] "input_types": [
"Text"
]
}, },
"_type": "CustomComponent" "_type": "CustomComponent"
}, },
"description": "Get chat inputs from the Playground.", "description": "Get chat inputs from the Playground.",
"icon": "ChatInput", "icon": "ChatInput",
"base_classes": ["object", "Record", "str", "Text"], "base_classes": [
"object",
"Record",
"str",
"Text"
],
"display_name": "Chat Input", "display_name": "Chat Input",
"documentation": "", "documentation": "",
"custom_fields": { "custom_fields": {
@ -695,7 +756,10 @@
"session_id": null, "session_id": null,
"return_record": null "return_record": null
}, },
"output_types": ["Text", "Record"], "output_types": [
"Text",
"Record"
],
"field_formatters": {}, "field_formatters": {},
"frozen": false, "frozen": false,
"field_order": [], "field_order": [],
@ -716,18 +780,24 @@
"edges": [ "edges": [
{ {
"source": "OpenAIModel-k39HS", "source": "OpenAIModel-k39HS",
"sourceHandle": "{œbaseClassesœ:[œobjectœ,œTextœ,œstrœ],œdataTypeœ:œOpenAIModelœ,œidœ:œOpenAIModel-k39HSœ}", "sourceHandle": "{\u0153baseClasses\u0153:[\u0153object\u0153,\u0153Text\u0153,\u0153str\u0153],\u0153dataType\u0153:\u0153OpenAIModel\u0153,\u0153id\u0153:\u0153OpenAIModel-k39HS\u0153}",
"target": "ChatOutput-njtka", "target": "ChatOutput-njtka",
"targetHandle": "{œfieldNameœ:œinput_valueœ,œidœ:œChatOutput-njtkaœ,œinputTypesœ:[œTextœ],œtypeœ:œstrœ}", "targetHandle": "{\u0153fieldName\u0153:\u0153input_value\u0153,\u0153id\u0153:\u0153ChatOutput-njtka\u0153,\u0153inputTypes\u0153:[\u0153Text\u0153],\u0153type\u0153:\u0153str\u0153}",
"data": { "data": {
"targetHandle": { "targetHandle": {
"fieldName": "input_value", "fieldName": "input_value",
"id": "ChatOutput-njtka", "id": "ChatOutput-njtka",
"inputTypes": ["Text"], "inputTypes": [
"Text"
],
"type": "str" "type": "str"
}, },
"sourceHandle": { "sourceHandle": {
"baseClasses": ["object", "Text", "str"], "baseClasses": [
"object",
"Text",
"str"
],
"dataType": "OpenAIModel", "dataType": "OpenAIModel",
"id": "OpenAIModel-k39HS" "id": "OpenAIModel-k39HS"
} }
@ -736,22 +806,28 @@
"stroke": "#555" "stroke": "#555"
}, },
"className": "stroke-gray-900 stroke-connection", "className": "stroke-gray-900 stroke-connection",
"id": "reactflow__edge-OpenAIModel-k39HS{œbaseClassesœ:[œobjectœ,œTextœ,œstrœ],œdataTypeœ:œOpenAIModelœ,œidœ:œOpenAIModel-k39HSœ}-ChatOutput-njtka{œfieldNameœ:œinput_valueœ,œidœ:œChatOutput-njtkaœ,œinputTypesœ:[œTextœ],œtypeœ:œstrœ}" "id": "reactflow__edge-OpenAIModel-k39HS{\u0153baseClasses\u0153:[\u0153object\u0153,\u0153Text\u0153,\u0153str\u0153],\u0153dataType\u0153:\u0153OpenAIModel\u0153,\u0153id\u0153:\u0153OpenAIModel-k39HS\u0153}-ChatOutput-njtka{\u0153fieldName\u0153:\u0153input_value\u0153,\u0153id\u0153:\u0153ChatOutput-njtka\u0153,\u0153inputTypes\u0153:[\u0153Text\u0153],\u0153type\u0153:\u0153str\u0153}"
}, },
{ {
"source": "Prompt-uxBqP", "source": "Prompt-uxBqP",
"sourceHandle": "{œbaseClassesœ:[œobjectœ,œstrœ,œTextœ],œdataTypeœ:œPromptœ,œidœ:œPrompt-uxBqPœ}", "sourceHandle": "{\u0153baseClasses\u0153:[\u0153object\u0153,\u0153str\u0153,\u0153Text\u0153],\u0153dataType\u0153:\u0153Prompt\u0153,\u0153id\u0153:\u0153Prompt-uxBqP\u0153}",
"target": "OpenAIModel-k39HS", "target": "OpenAIModel-k39HS",
"targetHandle": "{œfieldNameœ:œinput_valueœ,œidœ:œOpenAIModel-k39HSœ,œinputTypesœ:[œTextœ],œtypeœ:œstrœ}", "targetHandle": "{\u0153fieldName\u0153:\u0153input_value\u0153,\u0153id\u0153:\u0153OpenAIModel-k39HS\u0153,\u0153inputTypes\u0153:[\u0153Text\u0153],\u0153type\u0153:\u0153str\u0153}",
"data": { "data": {
"targetHandle": { "targetHandle": {
"fieldName": "input_value", "fieldName": "input_value",
"id": "OpenAIModel-k39HS", "id": "OpenAIModel-k39HS",
"inputTypes": ["Text"], "inputTypes": [
"Text"
],
"type": "str" "type": "str"
}, },
"sourceHandle": { "sourceHandle": {
"baseClasses": ["object", "str", "Text"], "baseClasses": [
"object",
"str",
"Text"
],
"dataType": "Prompt", "dataType": "Prompt",
"id": "Prompt-uxBqP" "id": "Prompt-uxBqP"
} }
@ -760,22 +836,32 @@
"stroke": "#555" "stroke": "#555"
}, },
"className": "stroke-gray-900 stroke-connection", "className": "stroke-gray-900 stroke-connection",
"id": "reactflow__edge-Prompt-uxBqP{œbaseClassesœ:[œobjectœ,œstrœ,œTextœ],œdataTypeœ:œPromptœ,œidœ:œPrompt-uxBqPœ}-OpenAIModel-k39HS{œfieldNameœ:œinput_valueœ,œidœ:œOpenAIModel-k39HSœ,œinputTypesœ:[œTextœ],œtypeœ:œstrœ}" "id": "reactflow__edge-Prompt-uxBqP{\u0153baseClasses\u0153:[\u0153object\u0153,\u0153str\u0153,\u0153Text\u0153],\u0153dataType\u0153:\u0153Prompt\u0153,\u0153id\u0153:\u0153Prompt-uxBqP\u0153}-OpenAIModel-k39HS{\u0153fieldName\u0153:\u0153input_value\u0153,\u0153id\u0153:\u0153OpenAIModel-k39HS\u0153,\u0153inputTypes\u0153:[\u0153Text\u0153],\u0153type\u0153:\u0153str\u0153}"
}, },
{ {
"source": "ChatInput-P3fgL", "source": "ChatInput-P3fgL",
"sourceHandle": "{œbaseClassesœ:[œobjectœ,œRecordœ,œstrœ,œTextœ],œdataTypeœ:œChatInputœ,œidœ:œChatInput-P3fgLœ}", "sourceHandle": "{\u0153baseClasses\u0153:[\u0153object\u0153,\u0153Record\u0153,\u0153str\u0153,\u0153Text\u0153],\u0153dataType\u0153:\u0153ChatInput\u0153,\u0153id\u0153:\u0153ChatInput-P3fgL\u0153}",
"target": "Prompt-uxBqP", "target": "Prompt-uxBqP",
"targetHandle": "{œfieldNameœ:œuser_inputœ,œidœ:œPrompt-uxBqPœ,œinputTypesœ:[œDocumentœ,œBaseOutputParserœ,œRecordœ,œTextœ],œtypeœ:œstrœ}", "targetHandle": "{\u0153fieldName\u0153:\u0153user_input\u0153,\u0153id\u0153:\u0153Prompt-uxBqP\u0153,\u0153inputTypes\u0153:[\u0153Document\u0153,\u0153BaseOutputParser\u0153,\u0153Record\u0153,\u0153Text\u0153],\u0153type\u0153:\u0153str\u0153}",
"data": { "data": {
"targetHandle": { "targetHandle": {
"fieldName": "user_input", "fieldName": "user_input",
"id": "Prompt-uxBqP", "id": "Prompt-uxBqP",
"inputTypes": ["Document", "BaseOutputParser", "Record", "Text"], "inputTypes": [
"Document",
"BaseOutputParser",
"Record",
"Text"
],
"type": "str" "type": "str"
}, },
"sourceHandle": { "sourceHandle": {
"baseClasses": ["object", "Record", "str", "Text"], "baseClasses": [
"object",
"Record",
"str",
"Text"
],
"dataType": "ChatInput", "dataType": "ChatInput",
"id": "ChatInput-P3fgL" "id": "ChatInput-P3fgL"
} }
@ -784,7 +870,7 @@
"stroke": "#555" "stroke": "#555"
}, },
"className": "stroke-gray-900 stroke-connection", "className": "stroke-gray-900 stroke-connection",
"id": "reactflow__edge-ChatInput-P3fgL{œbaseClassesœ:[œobjectœ,œRecordœ,œstrœ,œTextœ],œdataTypeœ:œChatInputœ,œidœ:œChatInput-P3fgLœ}-Prompt-uxBqP{œfieldNameœ:œuser_inputœ,œidœ:œPrompt-uxBqPœ,œinputTypesœ:[œDocumentœ,œBaseOutputParserœ,œRecordœ,œTextœ],œtypeœ:œstrœ}" "id": "reactflow__edge-ChatInput-P3fgL{\u0153baseClasses\u0153:[\u0153object\u0153,\u0153Record\u0153,\u0153str\u0153,\u0153Text\u0153],\u0153dataType\u0153:\u0153ChatInput\u0153,\u0153id\u0153:\u0153ChatInput-P3fgL\u0153}-Prompt-uxBqP{\u0153fieldName\u0153:\u0153user_input\u0153,\u0153id\u0153:\u0153Prompt-uxBqP\u0153,\u0153inputTypes\u0153:[\u0153Document\u0153,\u0153BaseOutputParser\u0153,\u0153Record\u0153,\u0153Text\u0153],\u0153type\u0153:\u0153str\u0153}"
} }
], ],
"viewport": { "viewport": {

View file

@ -45,7 +45,9 @@
"name": "template", "name": "template",
"display_name": "Template", "display_name": "Template",
"advanced": false, "advanced": false,
"input_types": ["Text"], "input_types": [
"Text"
],
"dynamic": false, "dynamic": false,
"info": "", "info": "",
"load_from_db": false, "load_from_db": false,
@ -136,14 +138,24 @@
"is_input": null, "is_input": null,
"is_output": null, "is_output": null,
"is_composition": null, "is_composition": null,
"base_classes": ["object", "Text", "str"], "base_classes": [
"object",
"Text",
"str"
],
"name": "", "name": "",
"display_name": "Prompt", "display_name": "Prompt",
"documentation": "", "documentation": "",
"custom_fields": { "custom_fields": {
"template": ["reference_1", "reference_2", "instructions"] "template": [
"reference_1",
"reference_2",
"instructions"
]
}, },
"output_types": ["Text"], "output_types": [
"Text"
],
"full_path": null, "full_path": null,
"field_formatters": {}, "field_formatters": {},
"frozen": false, "frozen": false,
@ -210,7 +222,9 @@
"info": "", "info": "",
"load_from_db": false, "load_from_db": false,
"title_case": false, "title_case": false,
"input_types": ["Text"], "input_types": [
"Text"
],
"value": [ "value": [
"https://www.promptingguide.ai/techniques/prompt_chaining" "https://www.promptingguide.ai/techniques/prompt_chaining"
] ]
@ -219,13 +233,17 @@
}, },
"description": "Fetch content from one or more URLs.", "description": "Fetch content from one or more URLs.",
"icon": "layout-template", "icon": "layout-template",
"base_classes": ["Record"], "base_classes": [
"Record"
],
"display_name": "URL", "display_name": "URL",
"documentation": "", "documentation": "",
"custom_fields": { "custom_fields": {
"urls": null "urls": null
}, },
"output_types": ["Record"], "output_types": [
"Record"
],
"field_formatters": {}, "field_formatters": {},
"frozen": false, "frozen": false,
"field_order": [], "field_order": [],
@ -260,7 +278,7 @@
"list": false, "list": false,
"show": true, "show": true,
"multiline": true, "multiline": true,
"value": "from typing import Optional, Union\n\nfrom langflow.base.io.chat import ChatComponent\nfrom langflow.field_typing import Text\nfrom langflow.schema import Record\n\n\nclass ChatOutput(ChatComponent):\n display_name = \"Chat Output\"\n description = \"Display a chat message in the Playground.\"\n icon = \"ChatOutput\"\n\n def build(\n self,\n sender: Optional[str] = \"Machine\",\n sender_name: Optional[str] = \"AI\",\n input_value: Optional[str] = None,\n session_id: Optional[str] = None,\n return_record: Optional[bool] = False,\n record_template: Optional[str] = \"{text}\",\n ) -> Union[Text, Record]:\n return super().build_with_record(\n sender=sender,\n sender_name=sender_name,\n input_value=input_value,\n session_id=session_id,\n return_record=return_record,\n record_template=record_template or \"\",\n )\n", "value": "from typing import Optional, Union\n\nfrom langflow.base.io.chat import ChatComponent\nfrom langflow.field_typing import Text\nfrom langflow.schema import Record\n\n\nclass ChatOutput(ChatComponent):\n display_name = \"Chat Output\"\n description = \"Display a chat message in the Playground.\"\n icon = \"ChatOutput\"\n\n def build(\n self,\n sender: Optional[str] = \"Machine\",\n sender_name: Optional[str] = \"AI\",\n input_value: Optional[str] = None,\n session_id: Optional[str] = None,\n return_record: Optional[bool] = False,\n record_template: Optional[str] = \"{text}\",\n files: Optional[list[str]] = None,\n ) -> Union[Text, Record]:\n return super().build_with_record(\n sender=sender,\n sender_name=sender_name,\n input_value=input_value,\n session_id=session_id,\n return_record=return_record,\n record_template=record_template or \"\",\n files=files,\n )\n",
"fileTypes": [], "fileTypes": [],
"file_path": "", "file_path": "",
"password": false, "password": false,
@ -284,7 +302,9 @@
"name": "input_value", "name": "input_value",
"display_name": "Message", "display_name": "Message",
"advanced": false, "advanced": false,
"input_types": ["Text"], "input_types": [
"Text"
],
"dynamic": false, "dynamic": false,
"info": "", "info": "",
"load_from_db": false, "load_from_db": false,
@ -308,7 +328,9 @@
"info": "In case of Message being a Record, this template will be used to convert it to text.", "info": "In case of Message being a Record, this template will be used to convert it to text.",
"load_from_db": false, "load_from_db": false,
"title_case": false, "title_case": false,
"input_types": ["Text"] "input_types": [
"Text"
]
}, },
"return_record": { "return_record": {
"type": "bool", "type": "bool",
@ -340,7 +362,10 @@
"fileTypes": [], "fileTypes": [],
"file_path": "", "file_path": "",
"password": false, "password": false,
"options": ["Machine", "User"], "options": [
"Machine",
"User"
],
"name": "sender", "name": "sender",
"display_name": "Sender Type", "display_name": "Sender Type",
"advanced": true, "advanced": true,
@ -348,7 +373,9 @@
"info": "", "info": "",
"load_from_db": false, "load_from_db": false,
"title_case": false, "title_case": false,
"input_types": ["Text"] "input_types": [
"Text"
]
}, },
"sender_name": { "sender_name": {
"type": "str", "type": "str",
@ -368,7 +395,9 @@
"info": "", "info": "",
"load_from_db": false, "load_from_db": false,
"title_case": false, "title_case": false,
"input_types": ["Text"] "input_types": [
"Text"
]
}, },
"session_id": { "session_id": {
"type": "str", "type": "str",
@ -387,13 +416,20 @@
"info": "If provided, the message will be stored in the memory.", "info": "If provided, the message will be stored in the memory.",
"load_from_db": false, "load_from_db": false,
"title_case": false, "title_case": false,
"input_types": ["Text"] "input_types": [
"Text"
]
}, },
"_type": "CustomComponent" "_type": "CustomComponent"
}, },
"description": "Display a chat message in the Playground.", "description": "Display a chat message in the Playground.",
"icon": "ChatOutput", "icon": "ChatOutput",
"base_classes": ["Text", "Record", "object", "str"], "base_classes": [
"Text",
"Record",
"object",
"str"
],
"display_name": "Chat Output", "display_name": "Chat Output",
"documentation": "", "documentation": "",
"custom_fields": { "custom_fields": {
@ -404,7 +440,10 @@
"return_record": null, "return_record": null,
"record_template": null "record_template": null
}, },
"output_types": ["Text", "Record"], "output_types": [
"Text",
"Record"
],
"field_formatters": {}, "field_formatters": {},
"frozen": false, "frozen": false,
"field_order": [], "field_order": [],
@ -444,7 +483,9 @@
"info": "", "info": "",
"load_from_db": false, "load_from_db": false,
"title_case": false, "title_case": false,
"input_types": ["Text"] "input_types": [
"Text"
]
}, },
"code": { "code": {
"type": "code", "type": "code",
@ -527,7 +568,9 @@
"info": "", "info": "",
"load_from_db": false, "load_from_db": false,
"title_case": false, "title_case": false,
"input_types": ["Text"] "input_types": [
"Text"
]
}, },
"openai_api_base": { "openai_api_base": {
"type": "str", "type": "str",
@ -546,7 +589,9 @@
"info": "The base URL of the OpenAI API. Defaults to https://api.openai.com/v1.\n\nYou can change this to use other APIs like JinaChat, LocalAI and Prem.", "info": "The base URL of the OpenAI API. Defaults to https://api.openai.com/v1.\n\nYou can change this to use other APIs like JinaChat, LocalAI and Prem.",
"load_from_db": false, "load_from_db": false,
"title_case": false, "title_case": false,
"input_types": ["Text"] "input_types": [
"Text"
]
}, },
"openai_api_key": { "openai_api_key": {
"type": "str", "type": "str",
@ -565,7 +610,9 @@
"info": "The OpenAI API Key to use for the OpenAI model.", "info": "The OpenAI API Key to use for the OpenAI model.",
"load_from_db": false, "load_from_db": false,
"title_case": false, "title_case": false,
"input_types": ["Text"], "input_types": [
"Text"
],
"value": "" "value": ""
}, },
"stream": { "stream": {
@ -604,7 +651,9 @@
"info": "System message to pass to the model.", "info": "System message to pass to the model.",
"load_from_db": false, "load_from_db": false,
"title_case": false, "title_case": false,
"input_types": ["Text"] "input_types": [
"Text"
]
}, },
"temperature": { "temperature": {
"type": "float", "type": "float",
@ -635,7 +684,11 @@
}, },
"description": "Generates text using OpenAI LLMs.", "description": "Generates text using OpenAI LLMs.",
"icon": "OpenAI", "icon": "OpenAI",
"base_classes": ["str", "Text", "object"], "base_classes": [
"str",
"Text",
"object"
],
"display_name": "OpenAI", "display_name": "OpenAI",
"documentation": "", "documentation": "",
"custom_fields": { "custom_fields": {
@ -649,7 +702,9 @@
"stream": null, "stream": null,
"system_message": null "system_message": null
}, },
"output_types": ["Text"], "output_types": [
"Text"
],
"field_formatters": {}, "field_formatters": {},
"frozen": false, "frozen": false,
"field_order": [ "field_order": [
@ -722,20 +777,28 @@
"info": "", "info": "",
"load_from_db": false, "load_from_db": false,
"title_case": false, "title_case": false,
"input_types": ["Text"], "input_types": [
"value": ["https://www.promptingguide.ai/introduction/basics"] "Text"
],
"value": [
"https://www.promptingguide.ai/introduction/basics"
]
}, },
"_type": "CustomComponent" "_type": "CustomComponent"
}, },
"description": "Fetch content from one or more URLs.", "description": "Fetch content from one or more URLs.",
"icon": "layout-template", "icon": "layout-template",
"base_classes": ["Record"], "base_classes": [
"Record"
],
"display_name": "URL", "display_name": "URL",
"documentation": "", "documentation": "",
"custom_fields": { "custom_fields": {
"urls": null "urls": null
}, },
"output_types": ["Record"], "output_types": [
"Record"
],
"field_formatters": {}, "field_formatters": {},
"frozen": false, "frozen": false,
"field_order": [], "field_order": [],
@ -795,7 +858,10 @@
"name": "input_value", "name": "input_value",
"display_name": "Value", "display_name": "Value",
"advanced": false, "advanced": false,
"input_types": ["Record", "Text"], "input_types": [
"Record",
"Text"
],
"dynamic": false, "dynamic": false,
"info": "Text or Record to be passed as input.", "info": "Text or Record to be passed as input.",
"load_from_db": false, "load_from_db": false,
@ -819,20 +885,28 @@
"info": "Template to convert Record to Text. If left empty, it will be dynamically set to the Record's text key.", "info": "Template to convert Record to Text. If left empty, it will be dynamically set to the Record's text key.",
"load_from_db": false, "load_from_db": false,
"title_case": false, "title_case": false,
"input_types": ["Text"] "input_types": [
"Text"
]
}, },
"_type": "CustomComponent" "_type": "CustomComponent"
}, },
"description": "Get text inputs from the Playground.", "description": "Get text inputs from the Playground.",
"icon": "type", "icon": "type",
"base_classes": ["object", "Text", "str"], "base_classes": [
"object",
"Text",
"str"
],
"display_name": "Instructions", "display_name": "Instructions",
"documentation": "", "documentation": "",
"custom_fields": { "custom_fields": {
"input_value": null, "input_value": null,
"record_template": null "record_template": null
}, },
"output_types": ["Text"], "output_types": [
"Text"
],
"field_formatters": {}, "field_formatters": {},
"frozen": false, "frozen": false,
"field_order": [], "field_order": [],
@ -854,18 +928,25 @@
{ {
"source": "URL-HYPkR", "source": "URL-HYPkR",
"target": "Prompt-Rse03", "target": "Prompt-Rse03",
"sourceHandle": "{œbaseClassesœ:[œRecordœ],œdataTypeœ:œURLœ,œidœ:œURL-HYPkRœ}", "sourceHandle": "{\u0153baseClasses\u0153:[\u0153Record\u0153],\u0153dataType\u0153:\u0153URL\u0153,\u0153id\u0153:\u0153URL-HYPkR\u0153}",
"targetHandle": "{œfieldNameœ:œreference_2œ,œidœ:œPrompt-Rse03œ,œinputTypesœ:[œDocumentœ,œBaseOutputParserœ,œRecordœ,œTextœ],œtypeœ:œstrœ}", "targetHandle": "{\u0153fieldName\u0153:\u0153reference_2\u0153,\u0153id\u0153:\u0153Prompt-Rse03\u0153,\u0153inputTypes\u0153:[\u0153Document\u0153,\u0153BaseOutputParser\u0153,\u0153Record\u0153,\u0153Text\u0153],\u0153type\u0153:\u0153str\u0153}",
"id": "reactflow__edge-URL-HYPkR{œbaseClassesœ:[œRecordœ],œdataTypeœ:œURLœ,œidœ:œURL-HYPkRœ}-Prompt-Rse03{œfieldNameœ:œreference_2œ,œidœ:œPrompt-Rse03œ,œinputTypesœ:[œDocumentœ,œBaseOutputParserœ,œRecordœ,œTextœ],œtypeœ:œstrœ}", "id": "reactflow__edge-URL-HYPkR{\u0153baseClasses\u0153:[\u0153Record\u0153],\u0153dataType\u0153:\u0153URL\u0153,\u0153id\u0153:\u0153URL-HYPkR\u0153}-Prompt-Rse03{\u0153fieldName\u0153:\u0153reference_2\u0153,\u0153id\u0153:\u0153Prompt-Rse03\u0153,\u0153inputTypes\u0153:[\u0153Document\u0153,\u0153BaseOutputParser\u0153,\u0153Record\u0153,\u0153Text\u0153],\u0153type\u0153:\u0153str\u0153}",
"data": { "data": {
"targetHandle": { "targetHandle": {
"fieldName": "reference_2", "fieldName": "reference_2",
"id": "Prompt-Rse03", "id": "Prompt-Rse03",
"inputTypes": ["Document", "BaseOutputParser", "Record", "Text"], "inputTypes": [
"Document",
"BaseOutputParser",
"Record",
"Text"
],
"type": "str" "type": "str"
}, },
"sourceHandle": { "sourceHandle": {
"baseClasses": ["Record"], "baseClasses": [
"Record"
],
"dataType": "URL", "dataType": "URL",
"id": "URL-HYPkR" "id": "URL-HYPkR"
} }
@ -878,18 +959,24 @@
}, },
{ {
"source": "OpenAIModel-gi29P", "source": "OpenAIModel-gi29P",
"sourceHandle": "{œbaseClassesœ:[œstrœ,œTextœ,œobjectœ],œdataTypeœ:œOpenAIModelœ,œidœ:œOpenAIModel-gi29Pœ}", "sourceHandle": "{\u0153baseClasses\u0153:[\u0153str\u0153,\u0153Text\u0153,\u0153object\u0153],\u0153dataType\u0153:\u0153OpenAIModel\u0153,\u0153id\u0153:\u0153OpenAIModel-gi29P\u0153}",
"target": "ChatOutput-JPlxl", "target": "ChatOutput-JPlxl",
"targetHandle": "{œfieldNameœ:œinput_valueœ,œidœ:œChatOutput-JPlxlœ,œinputTypesœ:[œTextœ],œtypeœ:œstrœ}", "targetHandle": "{\u0153fieldName\u0153:\u0153input_value\u0153,\u0153id\u0153:\u0153ChatOutput-JPlxl\u0153,\u0153inputTypes\u0153:[\u0153Text\u0153],\u0153type\u0153:\u0153str\u0153}",
"data": { "data": {
"targetHandle": { "targetHandle": {
"fieldName": "input_value", "fieldName": "input_value",
"id": "ChatOutput-JPlxl", "id": "ChatOutput-JPlxl",
"inputTypes": ["Text"], "inputTypes": [
"Text"
],
"type": "str" "type": "str"
}, },
"sourceHandle": { "sourceHandle": {
"baseClasses": ["str", "Text", "object"], "baseClasses": [
"str",
"Text",
"object"
],
"dataType": "OpenAIModel", "dataType": "OpenAIModel",
"id": "OpenAIModel-gi29P" "id": "OpenAIModel-gi29P"
} }
@ -898,22 +985,29 @@
"stroke": "#555" "stroke": "#555"
}, },
"className": "stroke-gray-900 stroke-connection", "className": "stroke-gray-900 stroke-connection",
"id": "reactflow__edge-OpenAIModel-gi29P{œbaseClassesœ:[œstrœ,œTextœ,œobjectœ],œdataTypeœ:œOpenAIModelœ,œidœ:œOpenAIModel-gi29Pœ}-ChatOutput-JPlxl{œfieldNameœ:œinput_valueœ,œidœ:œChatOutput-JPlxlœ,œinputTypesœ:[œTextœ],œtypeœ:œstrœ}" "id": "reactflow__edge-OpenAIModel-gi29P{\u0153baseClasses\u0153:[\u0153str\u0153,\u0153Text\u0153,\u0153object\u0153],\u0153dataType\u0153:\u0153OpenAIModel\u0153,\u0153id\u0153:\u0153OpenAIModel-gi29P\u0153}-ChatOutput-JPlxl{\u0153fieldName\u0153:\u0153input_value\u0153,\u0153id\u0153:\u0153ChatOutput-JPlxl\u0153,\u0153inputTypes\u0153:[\u0153Text\u0153],\u0153type\u0153:\u0153str\u0153}"
}, },
{ {
"source": "URL-2cX90", "source": "URL-2cX90",
"sourceHandle": "{œbaseClassesœ:[œRecordœ],œdataTypeœ:œURLœ,œidœ:œURL-2cX90œ}", "sourceHandle": "{\u0153baseClasses\u0153:[\u0153Record\u0153],\u0153dataType\u0153:\u0153URL\u0153,\u0153id\u0153:\u0153URL-2cX90\u0153}",
"target": "Prompt-Rse03", "target": "Prompt-Rse03",
"targetHandle": "{œfieldNameœ:œreference_1œ,œidœ:œPrompt-Rse03œ,œinputTypesœ:[œDocumentœ,œBaseOutputParserœ,œRecordœ,œTextœ],œtypeœ:œstrœ}", "targetHandle": "{\u0153fieldName\u0153:\u0153reference_1\u0153,\u0153id\u0153:\u0153Prompt-Rse03\u0153,\u0153inputTypes\u0153:[\u0153Document\u0153,\u0153BaseOutputParser\u0153,\u0153Record\u0153,\u0153Text\u0153],\u0153type\u0153:\u0153str\u0153}",
"data": { "data": {
"targetHandle": { "targetHandle": {
"fieldName": "reference_1", "fieldName": "reference_1",
"id": "Prompt-Rse03", "id": "Prompt-Rse03",
"inputTypes": ["Document", "BaseOutputParser", "Record", "Text"], "inputTypes": [
"Document",
"BaseOutputParser",
"Record",
"Text"
],
"type": "str" "type": "str"
}, },
"sourceHandle": { "sourceHandle": {
"baseClasses": ["Record"], "baseClasses": [
"Record"
],
"dataType": "URL", "dataType": "URL",
"id": "URL-2cX90" "id": "URL-2cX90"
} }
@ -922,22 +1016,31 @@
"stroke": "#555" "stroke": "#555"
}, },
"className": "stroke-gray-900 stroke-connection", "className": "stroke-gray-900 stroke-connection",
"id": "reactflow__edge-URL-2cX90{œbaseClassesœ:[œRecordœ],œdataTypeœ:œURLœ,œidœ:œURL-2cX90œ}-Prompt-Rse03{œfieldNameœ:œreference_1œ,œidœ:œPrompt-Rse03œ,œinputTypesœ:[œDocumentœ,œBaseOutputParserœ,œRecordœ,œTextœ],œtypeœ:œstrœ}" "id": "reactflow__edge-URL-2cX90{\u0153baseClasses\u0153:[\u0153Record\u0153],\u0153dataType\u0153:\u0153URL\u0153,\u0153id\u0153:\u0153URL-2cX90\u0153}-Prompt-Rse03{\u0153fieldName\u0153:\u0153reference_1\u0153,\u0153id\u0153:\u0153Prompt-Rse03\u0153,\u0153inputTypes\u0153:[\u0153Document\u0153,\u0153BaseOutputParser\u0153,\u0153Record\u0153,\u0153Text\u0153],\u0153type\u0153:\u0153str\u0153}"
}, },
{ {
"source": "TextInput-og8Or", "source": "TextInput-og8Or",
"sourceHandle": "{œbaseClassesœ:[œobjectœ,œTextœ,œstrœ],œdataTypeœ:œTextInputœ,œidœ:œTextInput-og8Orœ}", "sourceHandle": "{\u0153baseClasses\u0153:[\u0153object\u0153,\u0153Text\u0153,\u0153str\u0153],\u0153dataType\u0153:\u0153TextInput\u0153,\u0153id\u0153:\u0153TextInput-og8Or\u0153}",
"target": "Prompt-Rse03", "target": "Prompt-Rse03",
"targetHandle": "{œfieldNameœ:œinstructionsœ,œidœ:œPrompt-Rse03œ,œinputTypesœ:[œDocumentœ,œBaseOutputParserœ,œRecordœ,œTextœ],œtypeœ:œstrœ}", "targetHandle": "{\u0153fieldName\u0153:\u0153instructions\u0153,\u0153id\u0153:\u0153Prompt-Rse03\u0153,\u0153inputTypes\u0153:[\u0153Document\u0153,\u0153BaseOutputParser\u0153,\u0153Record\u0153,\u0153Text\u0153],\u0153type\u0153:\u0153str\u0153}",
"data": { "data": {
"targetHandle": { "targetHandle": {
"fieldName": "instructions", "fieldName": "instructions",
"id": "Prompt-Rse03", "id": "Prompt-Rse03",
"inputTypes": ["Document", "BaseOutputParser", "Record", "Text"], "inputTypes": [
"Document",
"BaseOutputParser",
"Record",
"Text"
],
"type": "str" "type": "str"
}, },
"sourceHandle": { "sourceHandle": {
"baseClasses": ["object", "Text", "str"], "baseClasses": [
"object",
"Text",
"str"
],
"dataType": "TextInput", "dataType": "TextInput",
"id": "TextInput-og8Or" "id": "TextInput-og8Or"
} }
@ -946,22 +1049,28 @@
"stroke": "#555" "stroke": "#555"
}, },
"className": "stroke-gray-900 stroke-connection", "className": "stroke-gray-900 stroke-connection",
"id": "reactflow__edge-TextInput-og8Or{œbaseClassesœ:[œobjectœ,œTextœ,œstrœ],œdataTypeœ:œTextInputœ,œidœ:œTextInput-og8Orœ}-Prompt-Rse03{œfieldNameœ:œinstructionsœ,œidœ:œPrompt-Rse03œ,œinputTypesœ:[œDocumentœ,œBaseOutputParserœ,œRecordœ,œTextœ],œtypeœ:œstrœ}" "id": "reactflow__edge-TextInput-og8Or{\u0153baseClasses\u0153:[\u0153object\u0153,\u0153Text\u0153,\u0153str\u0153],\u0153dataType\u0153:\u0153TextInput\u0153,\u0153id\u0153:\u0153TextInput-og8Or\u0153}-Prompt-Rse03{\u0153fieldName\u0153:\u0153instructions\u0153,\u0153id\u0153:\u0153Prompt-Rse03\u0153,\u0153inputTypes\u0153:[\u0153Document\u0153,\u0153BaseOutputParser\u0153,\u0153Record\u0153,\u0153Text\u0153],\u0153type\u0153:\u0153str\u0153}"
}, },
{ {
"source": "Prompt-Rse03", "source": "Prompt-Rse03",
"sourceHandle": "{œbaseClassesœ:[œobjectœ,œTextœ,œstrœ],œdataTypeœ:œPromptœ,œidœ:œPrompt-Rse03œ}", "sourceHandle": "{\u0153baseClasses\u0153:[\u0153object\u0153,\u0153Text\u0153,\u0153str\u0153],\u0153dataType\u0153:\u0153Prompt\u0153,\u0153id\u0153:\u0153Prompt-Rse03\u0153}",
"target": "OpenAIModel-gi29P", "target": "OpenAIModel-gi29P",
"targetHandle": "{œfieldNameœ:œinput_valueœ,œidœ:œOpenAIModel-gi29Pœ,œinputTypesœ:[œTextœ],œtypeœ:œstrœ}", "targetHandle": "{\u0153fieldName\u0153:\u0153input_value\u0153,\u0153id\u0153:\u0153OpenAIModel-gi29P\u0153,\u0153inputTypes\u0153:[\u0153Text\u0153],\u0153type\u0153:\u0153str\u0153}",
"data": { "data": {
"targetHandle": { "targetHandle": {
"fieldName": "input_value", "fieldName": "input_value",
"id": "OpenAIModel-gi29P", "id": "OpenAIModel-gi29P",
"inputTypes": ["Text"], "inputTypes": [
"Text"
],
"type": "str" "type": "str"
}, },
"sourceHandle": { "sourceHandle": {
"baseClasses": ["object", "Text", "str"], "baseClasses": [
"object",
"Text",
"str"
],
"dataType": "Prompt", "dataType": "Prompt",
"id": "Prompt-Rse03" "id": "Prompt-Rse03"
} }
@ -970,7 +1079,7 @@
"stroke": "#555" "stroke": "#555"
}, },
"className": "stroke-gray-900 stroke-connection", "className": "stroke-gray-900 stroke-connection",
"id": "reactflow__edge-Prompt-Rse03{œbaseClassesœ:[œobjectœ,œTextœ,œstrœ],œdataTypeœ:œPromptœ,œidœ:œPrompt-Rse03œ}-OpenAIModel-gi29P{œfieldNameœ:œinput_valueœ,œidœ:œOpenAIModel-gi29Pœ,œinputTypesœ:[œTextœ],œtypeœ:œstrœ}", "id": "reactflow__edge-Prompt-Rse03{\u0153baseClasses\u0153:[\u0153object\u0153,\u0153Text\u0153,\u0153str\u0153],\u0153dataType\u0153:\u0153Prompt\u0153,\u0153id\u0153:\u0153Prompt-Rse03\u0153}-OpenAIModel-gi29P{\u0153fieldName\u0153:\u0153input_value\u0153,\u0153id\u0153:\u0153OpenAIModel-gi29P\u0153,\u0153inputTypes\u0153:[\u0153Text\u0153],\u0153type\u0153:\u0153str\u0153}",
"selected": false "selected": false
} }
], ],

View file

@ -45,7 +45,9 @@
"name": "template", "name": "template",
"display_name": "Template", "display_name": "Template",
"advanced": false, "advanced": false,
"input_types": ["Text"], "input_types": [
"Text"
],
"dynamic": false, "dynamic": false,
"info": "", "info": "",
"load_from_db": false, "load_from_db": false,
@ -110,14 +112,23 @@
"is_input": null, "is_input": null,
"is_output": null, "is_output": null,
"is_composition": null, "is_composition": null,
"base_classes": ["object", "str", "Text"], "base_classes": [
"object",
"str",
"Text"
],
"name": "", "name": "",
"display_name": "Prompt", "display_name": "Prompt",
"documentation": "", "documentation": "",
"custom_fields": { "custom_fields": {
"template": ["Document", "Question"] "template": [
"Document",
"Question"
]
}, },
"output_types": ["Text"], "output_types": [
"Text"
],
"full_path": null, "full_path": null,
"field_formatters": {}, "field_formatters": {},
"frozen": false, "frozen": false,
@ -220,14 +231,18 @@
"_type": "CustomComponent" "_type": "CustomComponent"
}, },
"description": "A generic file loader.", "description": "A generic file loader.",
"base_classes": ["Record"], "base_classes": [
"Record"
],
"display_name": "Files", "display_name": "Files",
"documentation": "", "documentation": "",
"custom_fields": { "custom_fields": {
"path": null, "path": null,
"silent_errors": null "silent_errors": null
}, },
"output_types": ["Record"], "output_types": [
"Record"
],
"field_formatters": {}, "field_formatters": {},
"frozen": false, "frozen": false,
"field_order": [], "field_order": [],
@ -262,7 +277,7 @@
"list": false, "list": false,
"show": true, "show": true,
"multiline": true, "multiline": true,
"value": "from typing import Optional, Union\n\nfrom langflow.base.io.chat import ChatComponent\nfrom langflow.field_typing import Text\nfrom langflow.schema import Record\n\n\nclass ChatInput(ChatComponent):\n display_name = \"Chat Input\"\n description = \"Get chat inputs from the Playground.\"\n icon = \"ChatInput\"\n\n def build_config(self):\n build_config = super().build_config()\n build_config[\"input_value\"] = {\n \"input_types\": [],\n \"display_name\": \"Message\",\n \"multiline\": True,\n }\n\n return build_config\n\n def build(\n self,\n sender: Optional[str] = \"User\",\n sender_name: Optional[str] = \"User\",\n input_value: Optional[str] = None,\n session_id: Optional[str] = None,\n return_record: Optional[bool] = False,\n ) -> Union[Text, Record]:\n return super().build_no_record(\n sender=sender,\n sender_name=sender_name,\n input_value=input_value,\n session_id=session_id,\n return_record=return_record,\n )\n", "value": "from typing import Optional, Union\n\nfrom langflow.base.io.chat import ChatComponent\nfrom langflow.field_typing import Text\nfrom langflow.schema import Record\n\n\nclass ChatInput(ChatComponent):\n display_name = \"Chat Input\"\n description = \"Get chat inputs from the Playground.\"\n icon = \"ChatInput\"\n\n def build_config(self):\n build_config = super().build_config()\n build_config[\"input_value\"] = {\n \"input_types\": [],\n \"display_name\": \"Message\",\n \"multiline\": True,\n }\n\n return build_config\n\n def build(\n self,\n sender: Optional[str] = \"User\",\n sender_name: Optional[str] = \"User\",\n input_value: Optional[str] = None,\n files: Optional[list[str]] = None,\n session_id: Optional[str] = None,\n return_record: Optional[bool] = False,\n ) -> Union[Text, Record]:\n return super().build_no_record(\n sender=sender,\n sender_name=sender_name,\n input_value=input_value,\n files=files,\n session_id=session_id,\n return_record=return_record,\n )\n",
"fileTypes": [], "fileTypes": [],
"file_path": "", "file_path": "",
"password": false, "password": false,
@ -323,7 +338,10 @@
"fileTypes": [], "fileTypes": [],
"file_path": "", "file_path": "",
"password": false, "password": false,
"options": ["Machine", "User"], "options": [
"Machine",
"User"
],
"name": "sender", "name": "sender",
"display_name": "Sender Type", "display_name": "Sender Type",
"advanced": true, "advanced": true,
@ -331,7 +349,9 @@
"info": "", "info": "",
"load_from_db": false, "load_from_db": false,
"title_case": false, "title_case": false,
"input_types": ["Text"] "input_types": [
"Text"
]
}, },
"sender_name": { "sender_name": {
"type": "str", "type": "str",
@ -351,7 +371,9 @@
"info": "", "info": "",
"load_from_db": false, "load_from_db": false,
"title_case": false, "title_case": false,
"input_types": ["Text"] "input_types": [
"Text"
]
}, },
"session_id": { "session_id": {
"type": "str", "type": "str",
@ -370,13 +392,20 @@
"info": "If provided, the message will be stored in the memory.", "info": "If provided, the message will be stored in the memory.",
"load_from_db": false, "load_from_db": false,
"title_case": false, "title_case": false,
"input_types": ["Text"] "input_types": [
"Text"
]
}, },
"_type": "CustomComponent" "_type": "CustomComponent"
}, },
"description": "Get chat inputs from the Playground.", "description": "Get chat inputs from the Playground.",
"icon": "ChatInput", "icon": "ChatInput",
"base_classes": ["str", "Record", "Text", "object"], "base_classes": [
"str",
"Record",
"Text",
"object"
],
"display_name": "Chat Input", "display_name": "Chat Input",
"documentation": "", "documentation": "",
"custom_fields": { "custom_fields": {
@ -386,7 +415,10 @@
"session_id": null, "session_id": null,
"return_record": null "return_record": null
}, },
"output_types": ["Text", "Record"], "output_types": [
"Text",
"Record"
],
"field_formatters": {}, "field_formatters": {},
"frozen": false, "frozen": false,
"field_order": [], "field_order": [],
@ -421,7 +453,7 @@
"list": false, "list": false,
"show": true, "show": true,
"multiline": true, "multiline": true,
"value": "from typing import Optional, Union\n\nfrom langflow.base.io.chat import ChatComponent\nfrom langflow.field_typing import Text\nfrom langflow.schema import Record\n\n\nclass ChatOutput(ChatComponent):\n display_name = \"Chat Output\"\n description = \"Display a chat message in the Playground.\"\n icon = \"ChatOutput\"\n\n def build(\n self,\n sender: Optional[str] = \"Machine\",\n sender_name: Optional[str] = \"AI\",\n input_value: Optional[str] = None,\n session_id: Optional[str] = None,\n return_record: Optional[bool] = False,\n record_template: Optional[str] = \"{text}\",\n ) -> Union[Text, Record]:\n return super().build_with_record(\n sender=sender,\n sender_name=sender_name,\n input_value=input_value,\n session_id=session_id,\n return_record=return_record,\n record_template=record_template or \"\",\n )\n", "value": "from typing import Optional, Union\n\nfrom langflow.base.io.chat import ChatComponent\nfrom langflow.field_typing import Text\nfrom langflow.schema import Record\n\n\nclass ChatOutput(ChatComponent):\n display_name = \"Chat Output\"\n description = \"Display a chat message in the Playground.\"\n icon = \"ChatOutput\"\n\n def build(\n self,\n sender: Optional[str] = \"Machine\",\n sender_name: Optional[str] = \"AI\",\n input_value: Optional[str] = None,\n session_id: Optional[str] = None,\n return_record: Optional[bool] = False,\n record_template: Optional[str] = \"{text}\",\n files: Optional[list[str]] = None,\n ) -> Union[Text, Record]:\n return super().build_with_record(\n sender=sender,\n sender_name=sender_name,\n input_value=input_value,\n session_id=session_id,\n return_record=return_record,\n record_template=record_template or \"\",\n files=files,\n )\n",
"fileTypes": [], "fileTypes": [],
"file_path": "", "file_path": "",
"password": false, "password": false,
@ -445,7 +477,9 @@
"name": "input_value", "name": "input_value",
"display_name": "Message", "display_name": "Message",
"advanced": false, "advanced": false,
"input_types": ["Text"], "input_types": [
"Text"
],
"dynamic": false, "dynamic": false,
"info": "", "info": "",
"load_from_db": false, "load_from_db": false,
@ -481,7 +515,10 @@
"fileTypes": [], "fileTypes": [],
"file_path": "", "file_path": "",
"password": false, "password": false,
"options": ["Machine", "User"], "options": [
"Machine",
"User"
],
"name": "sender", "name": "sender",
"display_name": "Sender Type", "display_name": "Sender Type",
"advanced": true, "advanced": true,
@ -489,7 +526,9 @@
"info": "", "info": "",
"load_from_db": false, "load_from_db": false,
"title_case": false, "title_case": false,
"input_types": ["Text"] "input_types": [
"Text"
]
}, },
"sender_name": { "sender_name": {
"type": "str", "type": "str",
@ -509,7 +548,9 @@
"info": "", "info": "",
"load_from_db": false, "load_from_db": false,
"title_case": false, "title_case": false,
"input_types": ["Text"] "input_types": [
"Text"
]
}, },
"session_id": { "session_id": {
"type": "str", "type": "str",
@ -528,13 +569,20 @@
"info": "If provided, the message will be stored in the memory.", "info": "If provided, the message will be stored in the memory.",
"load_from_db": false, "load_from_db": false,
"title_case": false, "title_case": false,
"input_types": ["Text"] "input_types": [
"Text"
]
}, },
"_type": "CustomComponent" "_type": "CustomComponent"
}, },
"description": "Display a chat message in the Playground.", "description": "Display a chat message in the Playground.",
"icon": "ChatOutput", "icon": "ChatOutput",
"base_classes": ["str", "Record", "Text", "object"], "base_classes": [
"str",
"Record",
"Text",
"object"
],
"display_name": "Chat Output", "display_name": "Chat Output",
"documentation": "", "documentation": "",
"custom_fields": { "custom_fields": {
@ -544,7 +592,10 @@
"session_id": null, "session_id": null,
"return_record": null "return_record": null
}, },
"output_types": ["Text", "Record"], "output_types": [
"Text",
"Record"
],
"field_formatters": {}, "field_formatters": {},
"frozen": false, "frozen": false,
"field_order": [], "field_order": [],
@ -589,7 +640,9 @@
"info": "", "info": "",
"load_from_db": false, "load_from_db": false,
"title_case": false, "title_case": false,
"input_types": ["Text"] "input_types": [
"Text"
]
}, },
"code": { "code": {
"type": "code", "type": "code",
@ -672,7 +725,9 @@
"info": "", "info": "",
"load_from_db": false, "load_from_db": false,
"title_case": false, "title_case": false,
"input_types": ["Text"] "input_types": [
"Text"
]
}, },
"openai_api_base": { "openai_api_base": {
"type": "str", "type": "str",
@ -691,7 +746,9 @@
"info": "The base URL of the OpenAI API. Defaults to https://api.openai.com/v1.\n\nYou can change this to use other APIs like JinaChat, LocalAI and Prem.", "info": "The base URL of the OpenAI API. Defaults to https://api.openai.com/v1.\n\nYou can change this to use other APIs like JinaChat, LocalAI and Prem.",
"load_from_db": false, "load_from_db": false,
"title_case": false, "title_case": false,
"input_types": ["Text"] "input_types": [
"Text"
]
}, },
"openai_api_key": { "openai_api_key": {
"type": "str", "type": "str",
@ -710,7 +767,9 @@
"info": "The OpenAI API Key to use for the OpenAI model.", "info": "The OpenAI API Key to use for the OpenAI model.",
"load_from_db": false, "load_from_db": false,
"title_case": false, "title_case": false,
"input_types": ["Text"], "input_types": [
"Text"
],
"value": "" "value": ""
}, },
"stream": { "stream": {
@ -749,7 +808,9 @@
"info": "System message to pass to the model.", "info": "System message to pass to the model.",
"load_from_db": false, "load_from_db": false,
"title_case": false, "title_case": false,
"input_types": ["Text"] "input_types": [
"Text"
]
}, },
"temperature": { "temperature": {
"type": "float", "type": "float",
@ -780,7 +841,11 @@
}, },
"description": "Generates text using OpenAI LLMs.", "description": "Generates text using OpenAI LLMs.",
"icon": "OpenAI", "icon": "OpenAI",
"base_classes": ["object", "str", "Text"], "base_classes": [
"object",
"str",
"Text"
],
"display_name": "OpenAI", "display_name": "OpenAI",
"documentation": "", "documentation": "",
"custom_fields": { "custom_fields": {
@ -794,7 +859,9 @@
"stream": null, "stream": null,
"system_message": null "system_message": null
}, },
"output_types": ["Text"], "output_types": [
"Text"
],
"field_formatters": {}, "field_formatters": {},
"frozen": false, "frozen": false,
"field_order": [ "field_order": [
@ -825,18 +892,28 @@
"edges": [ "edges": [
{ {
"source": "ChatInput-MsSJ9", "source": "ChatInput-MsSJ9",
"sourceHandle": "{œbaseClassesœ:[œstrœ,œRecordœ,œTextœ,œobjectœ],œdataTypeœ:œChatInputœ,œidœ:œChatInput-MsSJ9œ}", "sourceHandle": "{\u0153baseClasses\u0153:[\u0153str\u0153,\u0153Record\u0153,\u0153Text\u0153,\u0153object\u0153],\u0153dataType\u0153:\u0153ChatInput\u0153,\u0153id\u0153:\u0153ChatInput-MsSJ9\u0153}",
"target": "Prompt-tHwPf", "target": "Prompt-tHwPf",
"targetHandle": "{œfieldNameœ:œQuestionœ,œidœ:œPrompt-tHwPfœ,œinputTypesœ:[œDocumentœ,œBaseOutputParserœ,œRecordœ,œTextœ],œtypeœ:œstrœ}", "targetHandle": "{\u0153fieldName\u0153:\u0153Question\u0153,\u0153id\u0153:\u0153Prompt-tHwPf\u0153,\u0153inputTypes\u0153:[\u0153Document\u0153,\u0153BaseOutputParser\u0153,\u0153Record\u0153,\u0153Text\u0153],\u0153type\u0153:\u0153str\u0153}",
"data": { "data": {
"targetHandle": { "targetHandle": {
"fieldName": "Question", "fieldName": "Question",
"id": "Prompt-tHwPf", "id": "Prompt-tHwPf",
"inputTypes": ["Document", "BaseOutputParser", "Record", "Text"], "inputTypes": [
"Document",
"BaseOutputParser",
"Record",
"Text"
],
"type": "str" "type": "str"
}, },
"sourceHandle": { "sourceHandle": {
"baseClasses": ["str", "Record", "Text", "object"], "baseClasses": [
"str",
"Record",
"Text",
"object"
],
"dataType": "ChatInput", "dataType": "ChatInput",
"id": "ChatInput-MsSJ9" "id": "ChatInput-MsSJ9"
} }
@ -845,22 +922,29 @@
"stroke": "#555" "stroke": "#555"
}, },
"className": "stroke-gray-900 stroke-connection", "className": "stroke-gray-900 stroke-connection",
"id": "reactflow__edge-ChatInput-MsSJ9{œbaseClassesœ:[œstrœ,œRecordœ,œTextœ,œobjectœ],œdataTypeœ:œChatInputœ,œidœ:œChatInput-MsSJ9œ}-Prompt-tHwPf{œfieldNameœ:œQuestionœ,œidœ:œPrompt-tHwPfœ,œinputTypesœ:[œDocumentœ,œBaseOutputParserœ,œRecordœ,œTextœ],œtypeœ:œstrœ}" "id": "reactflow__edge-ChatInput-MsSJ9{\u0153baseClasses\u0153:[\u0153str\u0153,\u0153Record\u0153,\u0153Text\u0153,\u0153object\u0153],\u0153dataType\u0153:\u0153ChatInput\u0153,\u0153id\u0153:\u0153ChatInput-MsSJ9\u0153}-Prompt-tHwPf{\u0153fieldName\u0153:\u0153Question\u0153,\u0153id\u0153:\u0153Prompt-tHwPf\u0153,\u0153inputTypes\u0153:[\u0153Document\u0153,\u0153BaseOutputParser\u0153,\u0153Record\u0153,\u0153Text\u0153],\u0153type\u0153:\u0153str\u0153}"
}, },
{ {
"source": "File-6TEsD", "source": "File-6TEsD",
"sourceHandle": "{œbaseClassesœ:[œRecordœ],œdataTypeœ:œFileœ,œidœ:œFile-6TEsDœ}", "sourceHandle": "{\u0153baseClasses\u0153:[\u0153Record\u0153],\u0153dataType\u0153:\u0153File\u0153,\u0153id\u0153:\u0153File-6TEsD\u0153}",
"target": "Prompt-tHwPf", "target": "Prompt-tHwPf",
"targetHandle": "{œfieldNameœ:œDocumentœ,œidœ:œPrompt-tHwPfœ,œinputTypesœ:[œDocumentœ,œBaseOutputParserœ,œRecordœ,œTextœ],œtypeœ:œstrœ}", "targetHandle": "{\u0153fieldName\u0153:\u0153Document\u0153,\u0153id\u0153:\u0153Prompt-tHwPf\u0153,\u0153inputTypes\u0153:[\u0153Document\u0153,\u0153BaseOutputParser\u0153,\u0153Record\u0153,\u0153Text\u0153],\u0153type\u0153:\u0153str\u0153}",
"data": { "data": {
"targetHandle": { "targetHandle": {
"fieldName": "Document", "fieldName": "Document",
"id": "Prompt-tHwPf", "id": "Prompt-tHwPf",
"inputTypes": ["Document", "BaseOutputParser", "Record", "Text"], "inputTypes": [
"Document",
"BaseOutputParser",
"Record",
"Text"
],
"type": "str" "type": "str"
}, },
"sourceHandle": { "sourceHandle": {
"baseClasses": ["Record"], "baseClasses": [
"Record"
],
"dataType": "File", "dataType": "File",
"id": "File-6TEsD" "id": "File-6TEsD"
} }
@ -869,22 +953,28 @@
"stroke": "#555" "stroke": "#555"
}, },
"className": "stroke-gray-900 stroke-connection", "className": "stroke-gray-900 stroke-connection",
"id": "reactflow__edge-File-6TEsD{œbaseClassesœ:[œRecordœ],œdataTypeœ:œFileœ,œidœ:œFile-6TEsDœ}-Prompt-tHwPf{œfieldNameœ:œDocumentœ,œidœ:œPrompt-tHwPfœ,œinputTypesœ:[œDocumentœ,œBaseOutputParserœ,œRecordœ,œTextœ],œtypeœ:œstrœ}" "id": "reactflow__edge-File-6TEsD{\u0153baseClasses\u0153:[\u0153Record\u0153],\u0153dataType\u0153:\u0153File\u0153,\u0153id\u0153:\u0153File-6TEsD\u0153}-Prompt-tHwPf{\u0153fieldName\u0153:\u0153Document\u0153,\u0153id\u0153:\u0153Prompt-tHwPf\u0153,\u0153inputTypes\u0153:[\u0153Document\u0153,\u0153BaseOutputParser\u0153,\u0153Record\u0153,\u0153Text\u0153],\u0153type\u0153:\u0153str\u0153}"
}, },
{ {
"source": "Prompt-tHwPf", "source": "Prompt-tHwPf",
"sourceHandle": "{œbaseClassesœ:[œobjectœ,œstrœ,œTextœ],œdataTypeœ:œPromptœ,œidœ:œPrompt-tHwPfœ}", "sourceHandle": "{\u0153baseClasses\u0153:[\u0153object\u0153,\u0153str\u0153,\u0153Text\u0153],\u0153dataType\u0153:\u0153Prompt\u0153,\u0153id\u0153:\u0153Prompt-tHwPf\u0153}",
"target": "OpenAIModel-Bt067", "target": "OpenAIModel-Bt067",
"targetHandle": "{œfieldNameœ:œinput_valueœ,œidœ:œOpenAIModel-Bt067œ,œinputTypesœ:[œTextœ],œtypeœ:œstrœ}", "targetHandle": "{\u0153fieldName\u0153:\u0153input_value\u0153,\u0153id\u0153:\u0153OpenAIModel-Bt067\u0153,\u0153inputTypes\u0153:[\u0153Text\u0153],\u0153type\u0153:\u0153str\u0153}",
"data": { "data": {
"targetHandle": { "targetHandle": {
"fieldName": "input_value", "fieldName": "input_value",
"id": "OpenAIModel-Bt067", "id": "OpenAIModel-Bt067",
"inputTypes": ["Text"], "inputTypes": [
"Text"
],
"type": "str" "type": "str"
}, },
"sourceHandle": { "sourceHandle": {
"baseClasses": ["object", "str", "Text"], "baseClasses": [
"object",
"str",
"Text"
],
"dataType": "Prompt", "dataType": "Prompt",
"id": "Prompt-tHwPf" "id": "Prompt-tHwPf"
} }
@ -893,22 +983,28 @@
"stroke": "#555" "stroke": "#555"
}, },
"className": "stroke-gray-900 stroke-connection", "className": "stroke-gray-900 stroke-connection",
"id": "reactflow__edge-Prompt-tHwPf{œbaseClassesœ:[œobjectœ,œstrœ,œTextœ],œdataTypeœ:œPromptœ,œidœ:œPrompt-tHwPfœ}-OpenAIModel-Bt067{œfieldNameœ:œinput_valueœ,œidœ:œOpenAIModel-Bt067œ,œinputTypesœ:[œTextœ],œtypeœ:œstrœ}" "id": "reactflow__edge-Prompt-tHwPf{\u0153baseClasses\u0153:[\u0153object\u0153,\u0153str\u0153,\u0153Text\u0153],\u0153dataType\u0153:\u0153Prompt\u0153,\u0153id\u0153:\u0153Prompt-tHwPf\u0153}-OpenAIModel-Bt067{\u0153fieldName\u0153:\u0153input_value\u0153,\u0153id\u0153:\u0153OpenAIModel-Bt067\u0153,\u0153inputTypes\u0153:[\u0153Text\u0153],\u0153type\u0153:\u0153str\u0153}"
}, },
{ {
"source": "OpenAIModel-Bt067", "source": "OpenAIModel-Bt067",
"sourceHandle": "{œbaseClassesœ:[œobjectœ,œstrœ,œTextœ],œdataTypeœ:œOpenAIModelœ,œidœ:œOpenAIModel-Bt067œ}", "sourceHandle": "{\u0153baseClasses\u0153:[\u0153object\u0153,\u0153str\u0153,\u0153Text\u0153],\u0153dataType\u0153:\u0153OpenAIModel\u0153,\u0153id\u0153:\u0153OpenAIModel-Bt067\u0153}",
"target": "ChatOutput-F5Awj", "target": "ChatOutput-F5Awj",
"targetHandle": "{œfieldNameœ:œinput_valueœ,œidœ:œChatOutput-F5Awjœ,œinputTypesœ:[œTextœ],œtypeœ:œstrœ}", "targetHandle": "{\u0153fieldName\u0153:\u0153input_value\u0153,\u0153id\u0153:\u0153ChatOutput-F5Awj\u0153,\u0153inputTypes\u0153:[\u0153Text\u0153],\u0153type\u0153:\u0153str\u0153}",
"data": { "data": {
"targetHandle": { "targetHandle": {
"fieldName": "input_value", "fieldName": "input_value",
"id": "ChatOutput-F5Awj", "id": "ChatOutput-F5Awj",
"inputTypes": ["Text"], "inputTypes": [
"Text"
],
"type": "str" "type": "str"
}, },
"sourceHandle": { "sourceHandle": {
"baseClasses": ["object", "str", "Text"], "baseClasses": [
"object",
"str",
"Text"
],
"dataType": "OpenAIModel", "dataType": "OpenAIModel",
"id": "OpenAIModel-Bt067" "id": "OpenAIModel-Bt067"
} }
@ -917,7 +1013,7 @@
"stroke": "#555" "stroke": "#555"
}, },
"className": "stroke-gray-900 stroke-connection", "className": "stroke-gray-900 stroke-connection",
"id": "reactflow__edge-OpenAIModel-Bt067{œbaseClassesœ:[œobjectœ,œstrœ,œTextœ],œdataTypeœ:œOpenAIModelœ,œidœ:œOpenAIModel-Bt067œ}-ChatOutput-F5Awj{œfieldNameœ:œinput_valueœ,œidœ:œChatOutput-F5Awjœ,œinputTypesœ:[œTextœ],œtypeœ:œstrœ}" "id": "reactflow__edge-OpenAIModel-Bt067{\u0153baseClasses\u0153:[\u0153object\u0153,\u0153str\u0153,\u0153Text\u0153],\u0153dataType\u0153:\u0153OpenAIModel\u0153,\u0153id\u0153:\u0153OpenAIModel-Bt067\u0153}-ChatOutput-F5Awj{\u0153fieldName\u0153:\u0153input_value\u0153,\u0153id\u0153:\u0153ChatOutput-F5Awj\u0153,\u0153inputTypes\u0153:[\u0153Text\u0153],\u0153type\u0153:\u0153str\u0153}"
} }
], ],
"viewport": { "viewport": {

View file

@ -1,6 +1,6 @@
{ {
"id": "08d5cccf-d098-4367-b14b-1078429c9ed9", "id": "08d5cccf-d098-4367-b14b-1078429c9ed9",
"icon": "🤖", "icon": "\ud83e\udd16",
"icon_bg_color": "#FFD700", "icon_bg_color": "#FFD700",
"data": { "data": {
"nodes": [ "nodes": [
@ -22,7 +22,7 @@
"list": false, "list": false,
"show": true, "show": true,
"multiline": true, "multiline": true,
"value": "from typing import Optional, Union\n\nfrom langflow.base.io.chat import ChatComponent\nfrom langflow.field_typing import Text\nfrom langflow.schema import Record\n\n\nclass ChatInput(ChatComponent):\n display_name = \"Chat Input\"\n description = \"Get chat inputs from the Playground.\"\n icon = \"ChatInput\"\n\n def build_config(self):\n build_config = super().build_config()\n build_config[\"input_value\"] = {\n \"input_types\": [],\n \"display_name\": \"Message\",\n \"multiline\": True,\n }\n\n return build_config\n\n def build(\n self,\n sender: Optional[str] = \"User\",\n sender_name: Optional[str] = \"User\",\n input_value: Optional[str] = None,\n session_id: Optional[str] = None,\n return_record: Optional[bool] = False,\n ) -> Union[Text, Record]:\n return super().build_no_record(\n sender=sender,\n sender_name=sender_name,\n input_value=input_value,\n session_id=session_id,\n return_record=return_record,\n )\n", "value": "from typing import Optional, Union\n\nfrom langflow.base.io.chat import ChatComponent\nfrom langflow.field_typing import Text\nfrom langflow.schema import Record\n\n\nclass ChatInput(ChatComponent):\n display_name = \"Chat Input\"\n description = \"Get chat inputs from the Playground.\"\n icon = \"ChatInput\"\n\n def build_config(self):\n build_config = super().build_config()\n build_config[\"input_value\"] = {\n \"input_types\": [],\n \"display_name\": \"Message\",\n \"multiline\": True,\n }\n\n return build_config\n\n def build(\n self,\n sender: Optional[str] = \"User\",\n sender_name: Optional[str] = \"User\",\n input_value: Optional[str] = None,\n files: Optional[list[str]] = None,\n session_id: Optional[str] = None,\n return_record: Optional[bool] = False,\n ) -> Union[Text, Record]:\n return super().build_no_record(\n sender=sender,\n sender_name=sender_name,\n input_value=input_value,\n files=files,\n session_id=session_id,\n return_record=return_record,\n )\n",
"fileTypes": [], "fileTypes": [],
"file_path": "", "file_path": "",
"password": false, "password": false,
@ -83,7 +83,10 @@
"fileTypes": [], "fileTypes": [],
"file_path": "", "file_path": "",
"password": false, "password": false,
"options": ["Machine", "User"], "options": [
"Machine",
"User"
],
"name": "sender", "name": "sender",
"display_name": "Sender Type", "display_name": "Sender Type",
"advanced": true, "advanced": true,
@ -91,7 +94,9 @@
"info": "", "info": "",
"load_from_db": false, "load_from_db": false,
"title_case": false, "title_case": false,
"input_types": ["Text"] "input_types": [
"Text"
]
}, },
"sender_name": { "sender_name": {
"type": "str", "type": "str",
@ -111,7 +116,9 @@
"info": "", "info": "",
"load_from_db": false, "load_from_db": false,
"title_case": false, "title_case": false,
"input_types": ["Text"] "input_types": [
"Text"
]
}, },
"session_id": { "session_id": {
"type": "str", "type": "str",
@ -130,14 +137,21 @@
"info": "If provided, the message will be stored in the memory.", "info": "If provided, the message will be stored in the memory.",
"load_from_db": false, "load_from_db": false,
"title_case": false, "title_case": false,
"input_types": ["Text"], "input_types": [
"Text"
],
"value": "MySessionID" "value": "MySessionID"
}, },
"_type": "CustomComponent" "_type": "CustomComponent"
}, },
"description": "Get chat inputs from the Playground.", "description": "Get chat inputs from the Playground.",
"icon": "ChatInput", "icon": "ChatInput",
"base_classes": ["Text", "object", "Record", "str"], "base_classes": [
"Text",
"object",
"Record",
"str"
],
"display_name": "Chat Input", "display_name": "Chat Input",
"documentation": "", "documentation": "",
"custom_fields": { "custom_fields": {
@ -147,7 +161,10 @@
"session_id": null, "session_id": null,
"return_record": null "return_record": null
}, },
"output_types": ["Text", "Record"], "output_types": [
"Text",
"Record"
],
"field_formatters": {}, "field_formatters": {},
"frozen": false, "frozen": false,
"field_order": [], "field_order": [],
@ -182,7 +199,7 @@
"list": false, "list": false,
"show": true, "show": true,
"multiline": true, "multiline": true,
"value": "from typing import Optional, Union\n\nfrom langflow.base.io.chat import ChatComponent\nfrom langflow.field_typing import Text\nfrom langflow.schema import Record\n\n\nclass ChatOutput(ChatComponent):\n display_name = \"Chat Output\"\n description = \"Display a chat message in the Playground.\"\n icon = \"ChatOutput\"\n\n def build(\n self,\n sender: Optional[str] = \"Machine\",\n sender_name: Optional[str] = \"AI\",\n input_value: Optional[str] = None,\n session_id: Optional[str] = None,\n return_record: Optional[bool] = False,\n record_template: Optional[str] = \"{text}\",\n ) -> Union[Text, Record]:\n return super().build_with_record(\n sender=sender,\n sender_name=sender_name,\n input_value=input_value,\n session_id=session_id,\n return_record=return_record,\n record_template=record_template or \"\",\n )\n", "value": "from typing import Optional, Union\n\nfrom langflow.base.io.chat import ChatComponent\nfrom langflow.field_typing import Text\nfrom langflow.schema import Record\n\n\nclass ChatOutput(ChatComponent):\n display_name = \"Chat Output\"\n description = \"Display a chat message in the Playground.\"\n icon = \"ChatOutput\"\n\n def build(\n self,\n sender: Optional[str] = \"Machine\",\n sender_name: Optional[str] = \"AI\",\n input_value: Optional[str] = None,\n session_id: Optional[str] = None,\n return_record: Optional[bool] = False,\n record_template: Optional[str] = \"{text}\",\n files: Optional[list[str]] = None,\n ) -> Union[Text, Record]:\n return super().build_with_record(\n sender=sender,\n sender_name=sender_name,\n input_value=input_value,\n session_id=session_id,\n return_record=return_record,\n record_template=record_template or \"\",\n files=files,\n )\n",
"fileTypes": [], "fileTypes": [],
"file_path": "", "file_path": "",
"password": false, "password": false,
@ -206,7 +223,9 @@
"name": "input_value", "name": "input_value",
"display_name": "Message", "display_name": "Message",
"advanced": false, "advanced": false,
"input_types": ["Text"], "input_types": [
"Text"
],
"dynamic": false, "dynamic": false,
"info": "", "info": "",
"load_from_db": false, "load_from_db": false,
@ -242,7 +261,10 @@
"fileTypes": [], "fileTypes": [],
"file_path": "", "file_path": "",
"password": false, "password": false,
"options": ["Machine", "User"], "options": [
"Machine",
"User"
],
"name": "sender", "name": "sender",
"display_name": "Sender Type", "display_name": "Sender Type",
"advanced": true, "advanced": true,
@ -250,7 +272,9 @@
"info": "", "info": "",
"load_from_db": false, "load_from_db": false,
"title_case": false, "title_case": false,
"input_types": ["Text"] "input_types": [
"Text"
]
}, },
"sender_name": { "sender_name": {
"type": "str", "type": "str",
@ -270,7 +294,9 @@
"info": "", "info": "",
"load_from_db": false, "load_from_db": false,
"title_case": false, "title_case": false,
"input_types": ["Text"] "input_types": [
"Text"
]
}, },
"session_id": { "session_id": {
"type": "str", "type": "str",
@ -289,14 +315,21 @@
"info": "If provided, the message will be stored in the memory.", "info": "If provided, the message will be stored in the memory.",
"load_from_db": false, "load_from_db": false,
"title_case": false, "title_case": false,
"input_types": ["Text"], "input_types": [
"Text"
],
"value": "MySessionID" "value": "MySessionID"
}, },
"_type": "CustomComponent" "_type": "CustomComponent"
}, },
"description": "Display a chat message in the Playground.", "description": "Display a chat message in the Playground.",
"icon": "ChatOutput", "icon": "ChatOutput",
"base_classes": ["Text", "object", "Record", "str"], "base_classes": [
"Text",
"object",
"Record",
"str"
],
"display_name": "Chat Output", "display_name": "Chat Output",
"documentation": "", "documentation": "",
"custom_fields": { "custom_fields": {
@ -306,7 +339,10 @@
"session_id": null, "session_id": null,
"return_record": null "return_record": null
}, },
"output_types": ["Text", "Record"], "output_types": [
"Text",
"Record"
],
"field_formatters": {}, "field_formatters": {},
"frozen": false, "frozen": false,
"field_order": [], "field_order": [],
@ -382,7 +418,10 @@
"fileTypes": [], "fileTypes": [],
"file_path": "", "file_path": "",
"password": false, "password": false,
"options": ["Ascending", "Descending"], "options": [
"Ascending",
"Descending"
],
"name": "order", "name": "order",
"display_name": "Order", "display_name": "Order",
"advanced": true, "advanced": true,
@ -390,7 +429,9 @@
"info": "Order of the messages.", "info": "Order of the messages.",
"load_from_db": false, "load_from_db": false,
"title_case": false, "title_case": false,
"input_types": ["Text"] "input_types": [
"Text"
]
}, },
"record_template": { "record_template": {
"type": "str", "type": "str",
@ -410,7 +451,9 @@
"info": "Template to convert Record to Text. If left empty, it will be dynamically set to the Record's text key.", "info": "Template to convert Record to Text. If left empty, it will be dynamically set to the Record's text key.",
"load_from_db": false, "load_from_db": false,
"title_case": false, "title_case": false,
"input_types": ["Text"] "input_types": [
"Text"
]
}, },
"sender": { "sender": {
"type": "str", "type": "str",
@ -423,7 +466,11 @@
"fileTypes": [], "fileTypes": [],
"file_path": "", "file_path": "",
"password": false, "password": false,
"options": ["Machine", "User", "Machine and User"], "options": [
"Machine",
"User",
"Machine and User"
],
"name": "sender", "name": "sender",
"display_name": "Sender Type", "display_name": "Sender Type",
"advanced": false, "advanced": false,
@ -431,7 +478,9 @@
"info": "", "info": "",
"load_from_db": false, "load_from_db": false,
"title_case": false, "title_case": false,
"input_types": ["Text"] "input_types": [
"Text"
]
}, },
"sender_name": { "sender_name": {
"type": "str", "type": "str",
@ -450,7 +499,9 @@
"info": "", "info": "",
"load_from_db": false, "load_from_db": false,
"title_case": false, "title_case": false,
"input_types": ["Text"] "input_types": [
"Text"
]
}, },
"session_id": { "session_id": {
"type": "str", "type": "str",
@ -465,7 +516,9 @@
"name": "session_id", "name": "session_id",
"display_name": "Session ID", "display_name": "Session ID",
"advanced": false, "advanced": false,
"input_types": ["Text"], "input_types": [
"Text"
],
"dynamic": false, "dynamic": false,
"info": "Session ID of the chat history.", "info": "Session ID of the chat history.",
"load_from_db": false, "load_from_db": false,
@ -476,7 +529,11 @@
}, },
"description": "Retrieves stored chat messages given a specific Session ID.", "description": "Retrieves stored chat messages given a specific Session ID.",
"icon": "history", "icon": "history",
"base_classes": ["str", "Text", "object"], "base_classes": [
"str",
"Text",
"object"
],
"display_name": "Chat Memory", "display_name": "Chat Memory",
"documentation": "", "documentation": "",
"custom_fields": { "custom_fields": {
@ -487,7 +544,9 @@
"order": null, "order": null,
"record_template": null "record_template": null
}, },
"output_types": ["Text"], "output_types": [
"Text"
],
"field_formatters": {}, "field_formatters": {},
"frozen": false, "frozen": false,
"field_order": [], "field_order": [],
@ -549,7 +608,9 @@
"name": "template", "name": "template",
"display_name": "Template", "display_name": "Template",
"advanced": false, "advanced": false,
"input_types": ["Text"], "input_types": [
"Text"
],
"dynamic": false, "dynamic": false,
"info": "", "info": "",
"load_from_db": false, "load_from_db": false,
@ -614,14 +675,23 @@
"is_input": null, "is_input": null,
"is_output": null, "is_output": null,
"is_composition": null, "is_composition": null,
"base_classes": ["Text", "str", "object"], "base_classes": [
"Text",
"str",
"object"
],
"name": "", "name": "",
"display_name": "Prompt", "display_name": "Prompt",
"documentation": "", "documentation": "",
"custom_fields": { "custom_fields": {
"template": ["context", "user_message"] "template": [
"context",
"user_message"
]
}, },
"output_types": ["Text"], "output_types": [
"Text"
],
"full_path": null, "full_path": null,
"field_formatters": {}, "field_formatters": {},
"frozen": false, "frozen": false,
@ -670,7 +740,9 @@
"info": "", "info": "",
"load_from_db": false, "load_from_db": false,
"title_case": false, "title_case": false,
"input_types": ["Text"] "input_types": [
"Text"
]
}, },
"code": { "code": {
"type": "code", "type": "code",
@ -753,7 +825,9 @@
"info": "", "info": "",
"load_from_db": false, "load_from_db": false,
"title_case": false, "title_case": false,
"input_types": ["Text"] "input_types": [
"Text"
]
}, },
"openai_api_base": { "openai_api_base": {
"type": "str", "type": "str",
@ -772,7 +846,9 @@
"info": "The base URL of the OpenAI API. Defaults to https://api.openai.com/v1.\n\nYou can change this to use other APIs like JinaChat, LocalAI and Prem.", "info": "The base URL of the OpenAI API. Defaults to https://api.openai.com/v1.\n\nYou can change this to use other APIs like JinaChat, LocalAI and Prem.",
"load_from_db": false, "load_from_db": false,
"title_case": false, "title_case": false,
"input_types": ["Text"] "input_types": [
"Text"
]
}, },
"openai_api_key": { "openai_api_key": {
"type": "str", "type": "str",
@ -791,7 +867,9 @@
"info": "The OpenAI API Key to use for the OpenAI model.", "info": "The OpenAI API Key to use for the OpenAI model.",
"load_from_db": false, "load_from_db": false,
"title_case": false, "title_case": false,
"input_types": ["Text"], "input_types": [
"Text"
],
"value": "" "value": ""
}, },
"stream": { "stream": {
@ -830,7 +908,9 @@
"info": "System message to pass to the model.", "info": "System message to pass to the model.",
"load_from_db": false, "load_from_db": false,
"title_case": false, "title_case": false,
"input_types": ["Text"] "input_types": [
"Text"
]
}, },
"temperature": { "temperature": {
"type": "float", "type": "float",
@ -861,7 +941,11 @@
}, },
"description": "Generates text using OpenAI LLMs.", "description": "Generates text using OpenAI LLMs.",
"icon": "OpenAI", "icon": "OpenAI",
"base_classes": ["str", "object", "Text"], "base_classes": [
"str",
"object",
"Text"
],
"display_name": "OpenAI", "display_name": "OpenAI",
"documentation": "", "documentation": "",
"custom_fields": { "custom_fields": {
@ -875,7 +959,9 @@
"stream": null, "stream": null,
"system_message": null "system_message": null
}, },
"output_types": ["Text"], "output_types": [
"Text"
],
"field_formatters": {}, "field_formatters": {},
"frozen": false, "frozen": false,
"field_order": [ "field_order": [
@ -927,7 +1013,10 @@
"name": "input_value", "name": "input_value",
"display_name": "Value", "display_name": "Value",
"advanced": false, "advanced": false,
"input_types": ["Record", "Text"], "input_types": [
"Record",
"Text"
],
"dynamic": false, "dynamic": false,
"info": "Text or Record to be passed as output.", "info": "Text or Record to be passed as output.",
"load_from_db": false, "load_from_db": false,
@ -969,20 +1058,28 @@
"info": "Template to convert Record to Text. If left empty, it will be dynamically set to the Record's text key.", "info": "Template to convert Record to Text. If left empty, it will be dynamically set to the Record's text key.",
"load_from_db": false, "load_from_db": false,
"title_case": false, "title_case": false,
"input_types": ["Text"] "input_types": [
"Text"
]
}, },
"_type": "CustomComponent" "_type": "CustomComponent"
}, },
"description": "Display a text output in the Playground.", "description": "Display a text output in the Playground.",
"icon": "type", "icon": "type",
"base_classes": ["str", "object", "Text"], "base_classes": [
"str",
"object",
"Text"
],
"display_name": "Inspect Memory", "display_name": "Inspect Memory",
"documentation": "", "documentation": "",
"custom_fields": { "custom_fields": {
"input_value": null, "input_value": null,
"record_template": null "record_template": null
}, },
"output_types": ["Text"], "output_types": [
"Text"
],
"field_formatters": {}, "field_formatters": {},
"frozen": false, "frozen": false,
"field_order": [], "field_order": [],
@ -1003,18 +1100,27 @@
"edges": [ "edges": [
{ {
"source": "MemoryComponent-cdA1J", "source": "MemoryComponent-cdA1J",
"sourceHandle": "{œbaseClassesœ:[œstrœ,œTextœ,œobjectœ],œdataTypeœ:œMemoryComponentœ,œidœ:œMemoryComponent-cdA1Jœ}", "sourceHandle": "{\u0153baseClasses\u0153:[\u0153str\u0153,\u0153Text\u0153,\u0153object\u0153],\u0153dataType\u0153:\u0153MemoryComponent\u0153,\u0153id\u0153:\u0153MemoryComponent-cdA1J\u0153}",
"target": "Prompt-ODkUx", "target": "Prompt-ODkUx",
"targetHandle": "{œfieldNameœ:œcontextœ,œidœ:œPrompt-ODkUxœ,œinputTypesœ:[œDocumentœ,œBaseOutputParserœ,œRecordœ,œTextœ],œtypeœ:œstrœ}", "targetHandle": "{\u0153fieldName\u0153:\u0153context\u0153,\u0153id\u0153:\u0153Prompt-ODkUx\u0153,\u0153inputTypes\u0153:[\u0153Document\u0153,\u0153BaseOutputParser\u0153,\u0153Record\u0153,\u0153Text\u0153],\u0153type\u0153:\u0153str\u0153}",
"data": { "data": {
"targetHandle": { "targetHandle": {
"fieldName": "context", "fieldName": "context",
"type": "str", "type": "str",
"id": "Prompt-ODkUx", "id": "Prompt-ODkUx",
"inputTypes": ["Document", "BaseOutputParser", "Record", "Text"] "inputTypes": [
"Document",
"BaseOutputParser",
"Record",
"Text"
]
}, },
"sourceHandle": { "sourceHandle": {
"baseClasses": ["str", "Text", "object"], "baseClasses": [
"str",
"Text",
"object"
],
"dataType": "MemoryComponent", "dataType": "MemoryComponent",
"id": "MemoryComponent-cdA1J" "id": "MemoryComponent-cdA1J"
} }
@ -1023,23 +1129,33 @@
"stroke": "#555" "stroke": "#555"
}, },
"className": "stroke-gray-900 stroke-connection", "className": "stroke-gray-900 stroke-connection",
"id": "reactflow__edge-MemoryComponent-cdA1J{œbaseClassesœ:[œstrœ,œTextœ,œobjectœ],œdataTypeœ:œMemoryComponentœ,œidœ:œMemoryComponent-cdA1Jœ}-Prompt-ODkUx{œfieldNameœ:œcontextœ,œidœ:œPrompt-ODkUxœ,œinputTypesœ:[œDocumentœ,œBaseOutputParserœ,œRecordœ,œTextœ],œtypeœ:œstrœ}", "id": "reactflow__edge-MemoryComponent-cdA1J{\u0153baseClasses\u0153:[\u0153str\u0153,\u0153Text\u0153,\u0153object\u0153],\u0153dataType\u0153:\u0153MemoryComponent\u0153,\u0153id\u0153:\u0153MemoryComponent-cdA1J\u0153}-Prompt-ODkUx{\u0153fieldName\u0153:\u0153context\u0153,\u0153id\u0153:\u0153Prompt-ODkUx\u0153,\u0153inputTypes\u0153:[\u0153Document\u0153,\u0153BaseOutputParser\u0153,\u0153Record\u0153,\u0153Text\u0153],\u0153type\u0153:\u0153str\u0153}",
"selected": false "selected": false
}, },
{ {
"source": "ChatInput-t7F8v", "source": "ChatInput-t7F8v",
"sourceHandle": "{œbaseClassesœ:[œTextœ,œobjectœ,œRecordœ,œstrœ],œdataTypeœ:œChatInputœ,œidœ:œChatInput-t7F8vœ}", "sourceHandle": "{\u0153baseClasses\u0153:[\u0153Text\u0153,\u0153object\u0153,\u0153Record\u0153,\u0153str\u0153],\u0153dataType\u0153:\u0153ChatInput\u0153,\u0153id\u0153:\u0153ChatInput-t7F8v\u0153}",
"target": "Prompt-ODkUx", "target": "Prompt-ODkUx",
"targetHandle": "{œfieldNameœ:œuser_messageœ,œidœ:œPrompt-ODkUxœ,œinputTypesœ:[œDocumentœ,œBaseOutputParserœ,œRecordœ,œTextœ],œtypeœ:œstrœ}", "targetHandle": "{\u0153fieldName\u0153:\u0153user_message\u0153,\u0153id\u0153:\u0153Prompt-ODkUx\u0153,\u0153inputTypes\u0153:[\u0153Document\u0153,\u0153BaseOutputParser\u0153,\u0153Record\u0153,\u0153Text\u0153],\u0153type\u0153:\u0153str\u0153}",
"data": { "data": {
"targetHandle": { "targetHandle": {
"fieldName": "user_message", "fieldName": "user_message",
"type": "str", "type": "str",
"id": "Prompt-ODkUx", "id": "Prompt-ODkUx",
"inputTypes": ["Document", "BaseOutputParser", "Record", "Text"] "inputTypes": [
"Document",
"BaseOutputParser",
"Record",
"Text"
]
}, },
"sourceHandle": { "sourceHandle": {
"baseClasses": ["Text", "object", "Record", "str"], "baseClasses": [
"Text",
"object",
"Record",
"str"
],
"dataType": "ChatInput", "dataType": "ChatInput",
"id": "ChatInput-t7F8v" "id": "ChatInput-t7F8v"
} }
@ -1048,23 +1164,29 @@
"stroke": "#555" "stroke": "#555"
}, },
"className": "stroke-gray-900 stroke-connection", "className": "stroke-gray-900 stroke-connection",
"id": "reactflow__edge-ChatInput-t7F8v{œbaseClassesœ:[œTextœ,œobjectœ,œRecordœ,œstrœ],œdataTypeœ:œChatInputœ,œidœ:œChatInput-t7F8vœ}-Prompt-ODkUx{œfieldNameœ:œuser_messageœ,œidœ:œPrompt-ODkUxœ,œinputTypesœ:[œDocumentœ,œBaseOutputParserœ,œRecordœ,œTextœ],œtypeœ:œstrœ}", "id": "reactflow__edge-ChatInput-t7F8v{\u0153baseClasses\u0153:[\u0153Text\u0153,\u0153object\u0153,\u0153Record\u0153,\u0153str\u0153],\u0153dataType\u0153:\u0153ChatInput\u0153,\u0153id\u0153:\u0153ChatInput-t7F8v\u0153}-Prompt-ODkUx{\u0153fieldName\u0153:\u0153user_message\u0153,\u0153id\u0153:\u0153Prompt-ODkUx\u0153,\u0153inputTypes\u0153:[\u0153Document\u0153,\u0153BaseOutputParser\u0153,\u0153Record\u0153,\u0153Text\u0153],\u0153type\u0153:\u0153str\u0153}",
"selected": false "selected": false
}, },
{ {
"source": "Prompt-ODkUx", "source": "Prompt-ODkUx",
"sourceHandle": "{œbaseClassesœ:[œTextœ,œstrœ,œobjectœ],œdataTypeœ:œPromptœ,œidœ:œPrompt-ODkUxœ}", "sourceHandle": "{\u0153baseClasses\u0153:[\u0153Text\u0153,\u0153str\u0153,\u0153object\u0153],\u0153dataType\u0153:\u0153Prompt\u0153,\u0153id\u0153:\u0153Prompt-ODkUx\u0153}",
"target": "OpenAIModel-9RykF", "target": "OpenAIModel-9RykF",
"targetHandle": "{œfieldNameœ:œinput_valueœ,œidœ:œOpenAIModel-9RykFœ,œinputTypesœ:[œTextœ],œtypeœ:œstrœ}", "targetHandle": "{\u0153fieldName\u0153:\u0153input_value\u0153,\u0153id\u0153:\u0153OpenAIModel-9RykF\u0153,\u0153inputTypes\u0153:[\u0153Text\u0153],\u0153type\u0153:\u0153str\u0153}",
"data": { "data": {
"targetHandle": { "targetHandle": {
"fieldName": "input_value", "fieldName": "input_value",
"id": "OpenAIModel-9RykF", "id": "OpenAIModel-9RykF",
"inputTypes": ["Text"], "inputTypes": [
"Text"
],
"type": "str" "type": "str"
}, },
"sourceHandle": { "sourceHandle": {
"baseClasses": ["Text", "str", "object"], "baseClasses": [
"Text",
"str",
"object"
],
"dataType": "Prompt", "dataType": "Prompt",
"id": "Prompt-ODkUx" "id": "Prompt-ODkUx"
} }
@ -1073,22 +1195,28 @@
"stroke": "#555" "stroke": "#555"
}, },
"className": "stroke-gray-900 stroke-connection", "className": "stroke-gray-900 stroke-connection",
"id": "reactflow__edge-Prompt-ODkUx{œbaseClassesœ:[œTextœ,œstrœ,œobjectœ],œdataTypeœ:œPromptœ,œidœ:œPrompt-ODkUxœ}-OpenAIModel-9RykF{œfieldNameœ:œinput_valueœ,œidœ:œOpenAIModel-9RykFœ,œinputTypesœ:[œTextœ],œtypeœ:œstrœ}" "id": "reactflow__edge-Prompt-ODkUx{\u0153baseClasses\u0153:[\u0153Text\u0153,\u0153str\u0153,\u0153object\u0153],\u0153dataType\u0153:\u0153Prompt\u0153,\u0153id\u0153:\u0153Prompt-ODkUx\u0153}-OpenAIModel-9RykF{\u0153fieldName\u0153:\u0153input_value\u0153,\u0153id\u0153:\u0153OpenAIModel-9RykF\u0153,\u0153inputTypes\u0153:[\u0153Text\u0153],\u0153type\u0153:\u0153str\u0153}"
}, },
{ {
"source": "OpenAIModel-9RykF", "source": "OpenAIModel-9RykF",
"sourceHandle": "{œbaseClassesœ:[œstrœ,œobjectœ,œTextœ],œdataTypeœ:œOpenAIModelœ,œidœ:œOpenAIModel-9RykFœ}", "sourceHandle": "{\u0153baseClasses\u0153:[\u0153str\u0153,\u0153object\u0153,\u0153Text\u0153],\u0153dataType\u0153:\u0153OpenAIModel\u0153,\u0153id\u0153:\u0153OpenAIModel-9RykF\u0153}",
"target": "ChatOutput-P1jEe", "target": "ChatOutput-P1jEe",
"targetHandle": "{œfieldNameœ:œinput_valueœ,œidœ:œChatOutput-P1jEeœ,œinputTypesœ:[œTextœ],œtypeœ:œstrœ}", "targetHandle": "{\u0153fieldName\u0153:\u0153input_value\u0153,\u0153id\u0153:\u0153ChatOutput-P1jEe\u0153,\u0153inputTypes\u0153:[\u0153Text\u0153],\u0153type\u0153:\u0153str\u0153}",
"data": { "data": {
"targetHandle": { "targetHandle": {
"fieldName": "input_value", "fieldName": "input_value",
"id": "ChatOutput-P1jEe", "id": "ChatOutput-P1jEe",
"inputTypes": ["Text"], "inputTypes": [
"Text"
],
"type": "str" "type": "str"
}, },
"sourceHandle": { "sourceHandle": {
"baseClasses": ["str", "object", "Text"], "baseClasses": [
"str",
"object",
"Text"
],
"dataType": "OpenAIModel", "dataType": "OpenAIModel",
"id": "OpenAIModel-9RykF" "id": "OpenAIModel-9RykF"
} }
@ -1097,22 +1225,29 @@
"stroke": "#555" "stroke": "#555"
}, },
"className": "stroke-gray-900 stroke-connection", "className": "stroke-gray-900 stroke-connection",
"id": "reactflow__edge-OpenAIModel-9RykF{œbaseClassesœ:[œstrœ,œobjectœ,œTextœ],œdataTypeœ:œOpenAIModelœ,œidœ:œOpenAIModel-9RykFœ}-ChatOutput-P1jEe{œfieldNameœ:œinput_valueœ,œidœ:œChatOutput-P1jEeœ,œinputTypesœ:[œTextœ],œtypeœ:œstrœ}" "id": "reactflow__edge-OpenAIModel-9RykF{\u0153baseClasses\u0153:[\u0153str\u0153,\u0153object\u0153,\u0153Text\u0153],\u0153dataType\u0153:\u0153OpenAIModel\u0153,\u0153id\u0153:\u0153OpenAIModel-9RykF\u0153}-ChatOutput-P1jEe{\u0153fieldName\u0153:\u0153input_value\u0153,\u0153id\u0153:\u0153ChatOutput-P1jEe\u0153,\u0153inputTypes\u0153:[\u0153Text\u0153],\u0153type\u0153:\u0153str\u0153}"
}, },
{ {
"source": "MemoryComponent-cdA1J", "source": "MemoryComponent-cdA1J",
"sourceHandle": "{œbaseClassesœ:[œstrœ,œTextœ,œobjectœ],œdataTypeœ:œMemoryComponentœ,œidœ:œMemoryComponent-cdA1Jœ}", "sourceHandle": "{\u0153baseClasses\u0153:[\u0153str\u0153,\u0153Text\u0153,\u0153object\u0153],\u0153dataType\u0153:\u0153MemoryComponent\u0153,\u0153id\u0153:\u0153MemoryComponent-cdA1J\u0153}",
"target": "TextOutput-vrs6T", "target": "TextOutput-vrs6T",
"targetHandle": "{œfieldNameœ:œinput_valueœ,œidœ:œTextOutput-vrs6Tœ,œinputTypesœ:[œRecordœ,œTextœ],œtypeœ:œstrœ}", "targetHandle": "{\u0153fieldName\u0153:\u0153input_value\u0153,\u0153id\u0153:\u0153TextOutput-vrs6T\u0153,\u0153inputTypes\u0153:[\u0153Record\u0153,\u0153Text\u0153],\u0153type\u0153:\u0153str\u0153}",
"data": { "data": {
"targetHandle": { "targetHandle": {
"fieldName": "input_value", "fieldName": "input_value",
"id": "TextOutput-vrs6T", "id": "TextOutput-vrs6T",
"inputTypes": ["Record", "Text"], "inputTypes": [
"Record",
"Text"
],
"type": "str" "type": "str"
}, },
"sourceHandle": { "sourceHandle": {
"baseClasses": ["str", "Text", "object"], "baseClasses": [
"str",
"Text",
"object"
],
"dataType": "MemoryComponent", "dataType": "MemoryComponent",
"id": "MemoryComponent-cdA1J" "id": "MemoryComponent-cdA1J"
} }
@ -1121,7 +1256,7 @@
"stroke": "#555" "stroke": "#555"
}, },
"className": "stroke-foreground stroke-connection", "className": "stroke-foreground stroke-connection",
"id": "reactflow__edge-MemoryComponent-cdA1J{œbaseClassesœ:[œstrœ,œTextœ,œobjectœ],œdataTypeœ:œMemoryComponentœ,œidœ:œMemoryComponent-cdA1Jœ}-TextOutput-vrs6T{œfieldNameœ:œinput_valueœ,œidœ:œTextOutput-vrs6Tœ,œinputTypesœ:[œRecordœ,œTextœ],œtypeœ:œstrœ}" "id": "reactflow__edge-MemoryComponent-cdA1J{\u0153baseClasses\u0153:[\u0153str\u0153,\u0153Text\u0153,\u0153object\u0153],\u0153dataType\u0153:\u0153MemoryComponent\u0153,\u0153id\u0153:\u0153MemoryComponent-cdA1J\u0153}-TextOutput-vrs6T{\u0153fieldName\u0153:\u0153input_value\u0153,\u0153id\u0153:\u0153TextOutput-vrs6T\u0153,\u0153inputTypes\u0153:[\u0153Record\u0153,\u0153Text\u0153],\u0153type\u0153:\u0153str\u0153}"
} }
], ],
"viewport": { "viewport": {

View file

@ -45,7 +45,9 @@
"name": "template", "name": "template",
"display_name": "Template", "display_name": "Template",
"advanced": false, "advanced": false,
"input_types": ["Text"], "input_types": [
"Text"
],
"dynamic": false, "dynamic": false,
"info": "", "info": "",
"load_from_db": false, "load_from_db": false,
@ -84,14 +86,22 @@
"is_input": null, "is_input": null,
"is_output": null, "is_output": null,
"is_composition": null, "is_composition": null,
"base_classes": ["object", "str", "Text"], "base_classes": [
"object",
"str",
"Text"
],
"name": "", "name": "",
"display_name": "Prompt", "display_name": "Prompt",
"documentation": "", "documentation": "",
"custom_fields": { "custom_fields": {
"template": ["document"] "template": [
"document"
]
}, },
"output_types": ["Text"], "output_types": [
"Text"
],
"full_path": null, "full_path": null,
"field_formatters": {}, "field_formatters": {},
"frozen": false, "frozen": false,
@ -155,7 +165,9 @@
"name": "template", "name": "template",
"display_name": "Template", "display_name": "Template",
"advanced": false, "advanced": false,
"input_types": ["Text"], "input_types": [
"Text"
],
"dynamic": false, "dynamic": false,
"info": "", "info": "",
"load_from_db": false, "load_from_db": false,
@ -194,14 +206,22 @@
"is_input": null, "is_input": null,
"is_output": null, "is_output": null,
"is_composition": null, "is_composition": null,
"base_classes": ["object", "str", "Text"], "base_classes": [
"object",
"str",
"Text"
],
"name": "", "name": "",
"display_name": "Prompt", "display_name": "Prompt",
"documentation": "", "documentation": "",
"custom_fields": { "custom_fields": {
"template": ["summary"] "template": [
"summary"
]
}, },
"output_types": ["Text"], "output_types": [
"Text"
],
"full_path": null, "full_path": null,
"field_formatters": {}, "field_formatters": {},
"frozen": false, "frozen": false,
@ -236,7 +256,7 @@
"list": false, "list": false,
"show": true, "show": true,
"multiline": true, "multiline": true,
"value": "from typing import Optional, Union\n\nfrom langflow.base.io.chat import ChatComponent\nfrom langflow.field_typing import Text\nfrom langflow.schema import Record\n\n\nclass ChatOutput(ChatComponent):\n display_name = \"Chat Output\"\n description = \"Display a chat message in the Playground.\"\n icon = \"ChatOutput\"\n\n def build(\n self,\n sender: Optional[str] = \"Machine\",\n sender_name: Optional[str] = \"AI\",\n input_value: Optional[str] = None,\n session_id: Optional[str] = None,\n return_record: Optional[bool] = False,\n record_template: Optional[str] = \"{text}\",\n ) -> Union[Text, Record]:\n return super().build_with_record(\n sender=sender,\n sender_name=sender_name,\n input_value=input_value,\n session_id=session_id,\n return_record=return_record,\n record_template=record_template or \"\",\n )\n", "value": "from typing import Optional, Union\n\nfrom langflow.base.io.chat import ChatComponent\nfrom langflow.field_typing import Text\nfrom langflow.schema import Record\n\n\nclass ChatOutput(ChatComponent):\n display_name = \"Chat Output\"\n description = \"Display a chat message in the Playground.\"\n icon = \"ChatOutput\"\n\n def build(\n self,\n sender: Optional[str] = \"Machine\",\n sender_name: Optional[str] = \"AI\",\n input_value: Optional[str] = None,\n session_id: Optional[str] = None,\n return_record: Optional[bool] = False,\n record_template: Optional[str] = \"{text}\",\n files: Optional[list[str]] = None,\n ) -> Union[Text, Record]:\n return super().build_with_record(\n sender=sender,\n sender_name=sender_name,\n input_value=input_value,\n session_id=session_id,\n return_record=return_record,\n record_template=record_template or \"\",\n files=files,\n )\n",
"fileTypes": [], "fileTypes": [],
"file_path": "", "file_path": "",
"password": false, "password": false,
@ -260,7 +280,9 @@
"name": "input_value", "name": "input_value",
"display_name": "Message", "display_name": "Message",
"advanced": false, "advanced": false,
"input_types": ["Text"], "input_types": [
"Text"
],
"dynamic": false, "dynamic": false,
"info": "", "info": "",
"load_from_db": false, "load_from_db": false,
@ -284,7 +306,9 @@
"info": "In case of Message being a Record, this template will be used to convert it to text.", "info": "In case of Message being a Record, this template will be used to convert it to text.",
"load_from_db": false, "load_from_db": false,
"title_case": false, "title_case": false,
"input_types": ["Text"] "input_types": [
"Text"
]
}, },
"return_record": { "return_record": {
"type": "bool", "type": "bool",
@ -316,7 +340,10 @@
"fileTypes": [], "fileTypes": [],
"file_path": "", "file_path": "",
"password": false, "password": false,
"options": ["Machine", "User"], "options": [
"Machine",
"User"
],
"name": "sender", "name": "sender",
"display_name": "Sender Type", "display_name": "Sender Type",
"advanced": true, "advanced": true,
@ -324,7 +351,9 @@
"info": "", "info": "",
"load_from_db": false, "load_from_db": false,
"title_case": false, "title_case": false,
"input_types": ["Text"] "input_types": [
"Text"
]
}, },
"sender_name": { "sender_name": {
"type": "str", "type": "str",
@ -344,7 +373,9 @@
"info": "", "info": "",
"load_from_db": false, "load_from_db": false,
"title_case": false, "title_case": false,
"input_types": ["Text"] "input_types": [
"Text"
]
}, },
"session_id": { "session_id": {
"type": "str", "type": "str",
@ -363,13 +394,20 @@
"info": "If provided, the message will be stored in the memory.", "info": "If provided, the message will be stored in the memory.",
"load_from_db": false, "load_from_db": false,
"title_case": false, "title_case": false,
"input_types": ["Text"] "input_types": [
"Text"
]
}, },
"_type": "CustomComponent" "_type": "CustomComponent"
}, },
"description": "Display a chat message in the Playground.", "description": "Display a chat message in the Playground.",
"icon": "ChatOutput", "icon": "ChatOutput",
"base_classes": ["object", "Record", "Text", "str"], "base_classes": [
"object",
"Record",
"Text",
"str"
],
"display_name": "Chat Output", "display_name": "Chat Output",
"documentation": "", "documentation": "",
"custom_fields": { "custom_fields": {
@ -380,7 +418,10 @@
"return_record": null, "return_record": null,
"record_template": null "record_template": null
}, },
"output_types": ["Text", "Record"], "output_types": [
"Text",
"Record"
],
"field_formatters": {}, "field_formatters": {},
"frozen": false, "frozen": false,
"field_order": [], "field_order": [],
@ -411,7 +452,7 @@
"list": false, "list": false,
"show": true, "show": true,
"multiline": true, "multiline": true,
"value": "from typing import Optional, Union\n\nfrom langflow.base.io.chat import ChatComponent\nfrom langflow.field_typing import Text\nfrom langflow.schema import Record\n\n\nclass ChatOutput(ChatComponent):\n display_name = \"Chat Output\"\n description = \"Display a chat message in the Playground.\"\n icon = \"ChatOutput\"\n\n def build(\n self,\n sender: Optional[str] = \"Machine\",\n sender_name: Optional[str] = \"AI\",\n input_value: Optional[str] = None,\n session_id: Optional[str] = None,\n return_record: Optional[bool] = False,\n record_template: Optional[str] = \"{text}\",\n ) -> Union[Text, Record]:\n return super().build_with_record(\n sender=sender,\n sender_name=sender_name,\n input_value=input_value,\n session_id=session_id,\n return_record=return_record,\n record_template=record_template or \"\",\n )\n", "value": "from typing import Optional, Union\n\nfrom langflow.base.io.chat import ChatComponent\nfrom langflow.field_typing import Text\nfrom langflow.schema import Record\n\n\nclass ChatOutput(ChatComponent):\n display_name = \"Chat Output\"\n description = \"Display a chat message in the Playground.\"\n icon = \"ChatOutput\"\n\n def build(\n self,\n sender: Optional[str] = \"Machine\",\n sender_name: Optional[str] = \"AI\",\n input_value: Optional[str] = None,\n session_id: Optional[str] = None,\n return_record: Optional[bool] = False,\n record_template: Optional[str] = \"{text}\",\n files: Optional[list[str]] = None,\n ) -> Union[Text, Record]:\n return super().build_with_record(\n sender=sender,\n sender_name=sender_name,\n input_value=input_value,\n session_id=session_id,\n return_record=return_record,\n record_template=record_template or \"\",\n files=files,\n )\n",
"fileTypes": [], "fileTypes": [],
"file_path": "", "file_path": "",
"password": false, "password": false,
@ -435,7 +476,9 @@
"name": "input_value", "name": "input_value",
"display_name": "Message", "display_name": "Message",
"advanced": false, "advanced": false,
"input_types": ["Text"], "input_types": [
"Text"
],
"dynamic": false, "dynamic": false,
"info": "", "info": "",
"load_from_db": false, "load_from_db": false,
@ -459,7 +502,9 @@
"info": "In case of Message being a Record, this template will be used to convert it to text.", "info": "In case of Message being a Record, this template will be used to convert it to text.",
"load_from_db": false, "load_from_db": false,
"title_case": false, "title_case": false,
"input_types": ["Text"] "input_types": [
"Text"
]
}, },
"return_record": { "return_record": {
"type": "bool", "type": "bool",
@ -491,7 +536,10 @@
"fileTypes": [], "fileTypes": [],
"file_path": "", "file_path": "",
"password": false, "password": false,
"options": ["Machine", "User"], "options": [
"Machine",
"User"
],
"name": "sender", "name": "sender",
"display_name": "Sender Type", "display_name": "Sender Type",
"advanced": true, "advanced": true,
@ -499,7 +547,9 @@
"info": "", "info": "",
"load_from_db": false, "load_from_db": false,
"title_case": false, "title_case": false,
"input_types": ["Text"] "input_types": [
"Text"
]
}, },
"sender_name": { "sender_name": {
"type": "str", "type": "str",
@ -519,7 +569,9 @@
"info": "", "info": "",
"load_from_db": false, "load_from_db": false,
"title_case": false, "title_case": false,
"input_types": ["Text"] "input_types": [
"Text"
]
}, },
"session_id": { "session_id": {
"type": "str", "type": "str",
@ -538,13 +590,20 @@
"info": "If provided, the message will be stored in the memory.", "info": "If provided, the message will be stored in the memory.",
"load_from_db": false, "load_from_db": false,
"title_case": false, "title_case": false,
"input_types": ["Text"] "input_types": [
"Text"
]
}, },
"_type": "CustomComponent" "_type": "CustomComponent"
}, },
"description": "Display a chat message in the Playground.", "description": "Display a chat message in the Playground.",
"icon": "ChatOutput", "icon": "ChatOutput",
"base_classes": ["object", "Record", "Text", "str"], "base_classes": [
"object",
"Record",
"Text",
"str"
],
"display_name": "Chat Output", "display_name": "Chat Output",
"documentation": "", "documentation": "",
"custom_fields": { "custom_fields": {
@ -555,7 +614,10 @@
"return_record": null, "return_record": null,
"record_template": null "record_template": null
}, },
"output_types": ["Text", "Record"], "output_types": [
"Text",
"Record"
],
"field_formatters": {}, "field_formatters": {},
"frozen": false, "frozen": false,
"field_order": [], "field_order": [],
@ -610,7 +672,10 @@
"name": "input_value", "name": "input_value",
"display_name": "Value", "display_name": "Value",
"advanced": false, "advanced": false,
"input_types": ["Record", "Text"], "input_types": [
"Record",
"Text"
],
"dynamic": false, "dynamic": false,
"info": "Text or Record to be passed as input.", "info": "Text or Record to be passed as input.",
"load_from_db": false, "load_from_db": false,
@ -634,20 +699,28 @@
"info": "Template to convert Record to Text. If left empty, it will be dynamically set to the Record's text key.", "info": "Template to convert Record to Text. If left empty, it will be dynamically set to the Record's text key.",
"load_from_db": false, "load_from_db": false,
"title_case": false, "title_case": false,
"input_types": ["Text"] "input_types": [
"Text"
]
}, },
"_type": "CustomComponent" "_type": "CustomComponent"
}, },
"description": "Get text inputs from the Playground.", "description": "Get text inputs from the Playground.",
"icon": "type", "icon": "type",
"base_classes": ["str", "Text", "object"], "base_classes": [
"str",
"Text",
"object"
],
"display_name": "Text Input", "display_name": "Text Input",
"documentation": "", "documentation": "",
"custom_fields": { "custom_fields": {
"input_value": null, "input_value": null,
"record_template": null "record_template": null
}, },
"output_types": ["Text"], "output_types": [
"Text"
],
"field_formatters": {}, "field_formatters": {},
"frozen": false, "frozen": false,
"field_order": [], "field_order": [],
@ -689,7 +762,10 @@
"name": "input_value", "name": "input_value",
"display_name": "Value", "display_name": "Value",
"advanced": false, "advanced": false,
"input_types": ["Record", "Text"], "input_types": [
"Record",
"Text"
],
"dynamic": false, "dynamic": false,
"info": "Text or Record to be passed as output.", "info": "Text or Record to be passed as output.",
"load_from_db": false, "load_from_db": false,
@ -731,20 +807,28 @@
"info": "Template to convert Record to Text. If left empty, it will be dynamically set to the Record's text key.", "info": "Template to convert Record to Text. If left empty, it will be dynamically set to the Record's text key.",
"load_from_db": false, "load_from_db": false,
"title_case": false, "title_case": false,
"input_types": ["Text"] "input_types": [
"Text"
]
}, },
"_type": "CustomComponent" "_type": "CustomComponent"
}, },
"description": "Display a text output in the Playground.", "description": "Display a text output in the Playground.",
"icon": "type", "icon": "type",
"base_classes": ["str", "Text", "object"], "base_classes": [
"str",
"Text",
"object"
],
"display_name": "First Prompt", "display_name": "First Prompt",
"documentation": "", "documentation": "",
"custom_fields": { "custom_fields": {
"input_value": null, "input_value": null,
"record_template": null "record_template": null
}, },
"output_types": ["Text"], "output_types": [
"Text"
],
"field_formatters": {}, "field_formatters": {},
"frozen": false, "frozen": false,
"field_order": [], "field_order": [],
@ -789,7 +873,9 @@
"info": "", "info": "",
"load_from_db": false, "load_from_db": false,
"title_case": false, "title_case": false,
"input_types": ["Text"] "input_types": [
"Text"
]
}, },
"code": { "code": {
"type": "code", "type": "code",
@ -872,7 +958,9 @@
"info": "", "info": "",
"load_from_db": false, "load_from_db": false,
"title_case": false, "title_case": false,
"input_types": ["Text"] "input_types": [
"Text"
]
}, },
"openai_api_base": { "openai_api_base": {
"type": "str", "type": "str",
@ -891,7 +979,9 @@
"info": "The base URL of the OpenAI API. Defaults to https://api.openai.com/v1.\n\nYou can change this to use other APIs like JinaChat, LocalAI and Prem.", "info": "The base URL of the OpenAI API. Defaults to https://api.openai.com/v1.\n\nYou can change this to use other APIs like JinaChat, LocalAI and Prem.",
"load_from_db": false, "load_from_db": false,
"title_case": false, "title_case": false,
"input_types": ["Text"] "input_types": [
"Text"
]
}, },
"openai_api_key": { "openai_api_key": {
"type": "str", "type": "str",
@ -910,7 +1000,9 @@
"info": "The OpenAI API Key to use for the OpenAI model.", "info": "The OpenAI API Key to use for the OpenAI model.",
"load_from_db": false, "load_from_db": false,
"title_case": false, "title_case": false,
"input_types": ["Text"], "input_types": [
"Text"
],
"value": "" "value": ""
}, },
"stream": { "stream": {
@ -949,7 +1041,9 @@
"info": "System message to pass to the model.", "info": "System message to pass to the model.",
"load_from_db": false, "load_from_db": false,
"title_case": false, "title_case": false,
"input_types": ["Text"] "input_types": [
"Text"
]
}, },
"temperature": { "temperature": {
"type": "float", "type": "float",
@ -980,7 +1074,11 @@
}, },
"description": "Generates text using OpenAI LLMs.", "description": "Generates text using OpenAI LLMs.",
"icon": "OpenAI", "icon": "OpenAI",
"base_classes": ["str", "Text", "object"], "base_classes": [
"str",
"Text",
"object"
],
"display_name": "OpenAI", "display_name": "OpenAI",
"documentation": "", "documentation": "",
"custom_fields": { "custom_fields": {
@ -994,7 +1092,9 @@
"stream": null, "stream": null,
"system_message": null "system_message": null
}, },
"output_types": ["Text"], "output_types": [
"Text"
],
"field_formatters": {}, "field_formatters": {},
"frozen": false, "frozen": false,
"field_order": [ "field_order": [
@ -1046,7 +1146,10 @@
"name": "input_value", "name": "input_value",
"display_name": "Value", "display_name": "Value",
"advanced": false, "advanced": false,
"input_types": ["Record", "Text"], "input_types": [
"Record",
"Text"
],
"dynamic": false, "dynamic": false,
"info": "Text or Record to be passed as output.", "info": "Text or Record to be passed as output.",
"load_from_db": false, "load_from_db": false,
@ -1088,20 +1191,28 @@
"info": "Template to convert Record to Text. If left empty, it will be dynamically set to the Record's text key.", "info": "Template to convert Record to Text. If left empty, it will be dynamically set to the Record's text key.",
"load_from_db": false, "load_from_db": false,
"title_case": false, "title_case": false,
"input_types": ["Text"] "input_types": [
"Text"
]
}, },
"_type": "CustomComponent" "_type": "CustomComponent"
}, },
"description": "Display a text output in the Playground.", "description": "Display a text output in the Playground.",
"icon": "type", "icon": "type",
"base_classes": ["str", "Text", "object"], "base_classes": [
"str",
"Text",
"object"
],
"display_name": "Second Prompt", "display_name": "Second Prompt",
"documentation": "", "documentation": "",
"custom_fields": { "custom_fields": {
"input_value": null, "input_value": null,
"record_template": null "record_template": null
}, },
"output_types": ["Text"], "output_types": [
"Text"
],
"field_formatters": {}, "field_formatters": {},
"frozen": false, "frozen": false,
"field_order": [], "field_order": [],
@ -1146,7 +1257,9 @@
"info": "", "info": "",
"load_from_db": false, "load_from_db": false,
"title_case": false, "title_case": false,
"input_types": ["Text"] "input_types": [
"Text"
]
}, },
"code": { "code": {
"type": "code", "type": "code",
@ -1229,7 +1342,9 @@
"info": "", "info": "",
"load_from_db": false, "load_from_db": false,
"title_case": false, "title_case": false,
"input_types": ["Text"] "input_types": [
"Text"
]
}, },
"openai_api_base": { "openai_api_base": {
"type": "str", "type": "str",
@ -1248,7 +1363,9 @@
"info": "The base URL of the OpenAI API. Defaults to https://api.openai.com/v1.\n\nYou can change this to use other APIs like JinaChat, LocalAI and Prem.", "info": "The base URL of the OpenAI API. Defaults to https://api.openai.com/v1.\n\nYou can change this to use other APIs like JinaChat, LocalAI and Prem.",
"load_from_db": false, "load_from_db": false,
"title_case": false, "title_case": false,
"input_types": ["Text"] "input_types": [
"Text"
]
}, },
"openai_api_key": { "openai_api_key": {
"type": "str", "type": "str",
@ -1267,7 +1384,9 @@
"info": "The OpenAI API Key to use for the OpenAI model.", "info": "The OpenAI API Key to use for the OpenAI model.",
"load_from_db": false, "load_from_db": false,
"title_case": false, "title_case": false,
"input_types": ["Text"], "input_types": [
"Text"
],
"value": "" "value": ""
}, },
"stream": { "stream": {
@ -1306,7 +1425,9 @@
"info": "System message to pass to the model.", "info": "System message to pass to the model.",
"load_from_db": false, "load_from_db": false,
"title_case": false, "title_case": false,
"input_types": ["Text"] "input_types": [
"Text"
]
}, },
"temperature": { "temperature": {
"type": "float", "type": "float",
@ -1337,7 +1458,11 @@
}, },
"description": "Generates text using OpenAI LLMs.", "description": "Generates text using OpenAI LLMs.",
"icon": "OpenAI", "icon": "OpenAI",
"base_classes": ["str", "Text", "object"], "base_classes": [
"str",
"Text",
"object"
],
"display_name": "OpenAI", "display_name": "OpenAI",
"documentation": "", "documentation": "",
"custom_fields": { "custom_fields": {
@ -1351,7 +1476,9 @@
"stream": null, "stream": null,
"system_message": null "system_message": null
}, },
"output_types": ["Text"], "output_types": [
"Text"
],
"field_formatters": {}, "field_formatters": {},
"frozen": false, "frozen": false,
"field_order": [ "field_order": [
@ -1382,18 +1509,27 @@
"edges": [ "edges": [
{ {
"source": "TextInput-sptaH", "source": "TextInput-sptaH",
"sourceHandle": "{œbaseClassesœ:[œstrœ,œTextœ,œobjectœ],œdataTypeœ:œTextInputœ,œidœ:œTextInput-sptaHœ}", "sourceHandle": "{\u0153baseClasses\u0153:[\u0153str\u0153,\u0153Text\u0153,\u0153object\u0153],\u0153dataType\u0153:\u0153TextInput\u0153,\u0153id\u0153:\u0153TextInput-sptaH\u0153}",
"target": "Prompt-amqBu", "target": "Prompt-amqBu",
"targetHandle": "{œfieldNameœ:œdocumentœ,œidœ:œPrompt-amqBuœ,œinputTypesœ:[œDocumentœ,œBaseOutputParserœ,œRecordœ,œTextœ],œtypeœ:œstrœ}", "targetHandle": "{\u0153fieldName\u0153:\u0153document\u0153,\u0153id\u0153:\u0153Prompt-amqBu\u0153,\u0153inputTypes\u0153:[\u0153Document\u0153,\u0153BaseOutputParser\u0153,\u0153Record\u0153,\u0153Text\u0153],\u0153type\u0153:\u0153str\u0153}",
"data": { "data": {
"targetHandle": { "targetHandle": {
"fieldName": "document", "fieldName": "document",
"id": "Prompt-amqBu", "id": "Prompt-amqBu",
"inputTypes": ["Document", "BaseOutputParser", "Record", "Text"], "inputTypes": [
"Document",
"BaseOutputParser",
"Record",
"Text"
],
"type": "str" "type": "str"
}, },
"sourceHandle": { "sourceHandle": {
"baseClasses": ["str", "Text", "object"], "baseClasses": [
"str",
"Text",
"object"
],
"dataType": "TextInput", "dataType": "TextInput",
"id": "TextInput-sptaH" "id": "TextInput-sptaH"
} }
@ -1402,22 +1538,29 @@
"stroke": "#555" "stroke": "#555"
}, },
"className": "stroke-gray-900 stroke-connection", "className": "stroke-gray-900 stroke-connection",
"id": "reactflow__edge-TextInput-sptaH{œbaseClassesœ:[œstrœ,œTextœ,œobjectœ],œdataTypeœ:œTextInputœ,œidœ:œTextInput-sptaHœ}-Prompt-amqBu{œfieldNameœ:œdocumentœ,œidœ:œPrompt-amqBuœ,œinputTypesœ:[œDocumentœ,œBaseOutputParserœ,œRecordœ,œTextœ],œtypeœ:œstrœ}" "id": "reactflow__edge-TextInput-sptaH{\u0153baseClasses\u0153:[\u0153str\u0153,\u0153Text\u0153,\u0153object\u0153],\u0153dataType\u0153:\u0153TextInput\u0153,\u0153id\u0153:\u0153TextInput-sptaH\u0153}-Prompt-amqBu{\u0153fieldName\u0153:\u0153document\u0153,\u0153id\u0153:\u0153Prompt-amqBu\u0153,\u0153inputTypes\u0153:[\u0153Document\u0153,\u0153BaseOutputParser\u0153,\u0153Record\u0153,\u0153Text\u0153],\u0153type\u0153:\u0153str\u0153}"
}, },
{ {
"source": "Prompt-amqBu", "source": "Prompt-amqBu",
"sourceHandle": "{œbaseClassesœ:[œobjectœ,œstrœ,œTextœ],œdataTypeœ:œPromptœ,œidœ:œPrompt-amqBuœ}", "sourceHandle": "{\u0153baseClasses\u0153:[\u0153object\u0153,\u0153str\u0153,\u0153Text\u0153],\u0153dataType\u0153:\u0153Prompt\u0153,\u0153id\u0153:\u0153Prompt-amqBu\u0153}",
"target": "TextOutput-2MS4a", "target": "TextOutput-2MS4a",
"targetHandle": "{œfieldNameœ:œinput_valueœ,œidœ:œTextOutput-2MS4aœ,œinputTypesœ:[œRecordœ,œTextœ],œtypeœ:œstrœ}", "targetHandle": "{\u0153fieldName\u0153:\u0153input_value\u0153,\u0153id\u0153:\u0153TextOutput-2MS4a\u0153,\u0153inputTypes\u0153:[\u0153Record\u0153,\u0153Text\u0153],\u0153type\u0153:\u0153str\u0153}",
"data": { "data": {
"targetHandle": { "targetHandle": {
"fieldName": "input_value", "fieldName": "input_value",
"id": "TextOutput-2MS4a", "id": "TextOutput-2MS4a",
"inputTypes": ["Record", "Text"], "inputTypes": [
"Record",
"Text"
],
"type": "str" "type": "str"
}, },
"sourceHandle": { "sourceHandle": {
"baseClasses": ["object", "str", "Text"], "baseClasses": [
"object",
"str",
"Text"
],
"dataType": "Prompt", "dataType": "Prompt",
"id": "Prompt-amqBu" "id": "Prompt-amqBu"
} }
@ -1426,22 +1569,28 @@
"stroke": "#555" "stroke": "#555"
}, },
"className": "stroke-gray-900 stroke-connection", "className": "stroke-gray-900 stroke-connection",
"id": "reactflow__edge-Prompt-amqBu{œbaseClassesœ:[œobjectœ,œstrœ,œTextœ],œdataTypeœ:œPromptœ,œidœ:œPrompt-amqBuœ}-TextOutput-2MS4a{œfieldNameœ:œinput_valueœ,œidœ:œTextOutput-2MS4aœ,œinputTypesœ:[œRecordœ,œTextœ],œtypeœ:œstrœ}" "id": "reactflow__edge-Prompt-amqBu{\u0153baseClasses\u0153:[\u0153object\u0153,\u0153str\u0153,\u0153Text\u0153],\u0153dataType\u0153:\u0153Prompt\u0153,\u0153id\u0153:\u0153Prompt-amqBu\u0153}-TextOutput-2MS4a{\u0153fieldName\u0153:\u0153input_value\u0153,\u0153id\u0153:\u0153TextOutput-2MS4a\u0153,\u0153inputTypes\u0153:[\u0153Record\u0153,\u0153Text\u0153],\u0153type\u0153:\u0153str\u0153}"
}, },
{ {
"source": "Prompt-amqBu", "source": "Prompt-amqBu",
"sourceHandle": "{œbaseClassesœ:[œobjectœ,œstrœ,œTextœ],œdataTypeœ:œPromptœ,œidœ:œPrompt-amqBuœ}", "sourceHandle": "{\u0153baseClasses\u0153:[\u0153object\u0153,\u0153str\u0153,\u0153Text\u0153],\u0153dataType\u0153:\u0153Prompt\u0153,\u0153id\u0153:\u0153Prompt-amqBu\u0153}",
"target": "OpenAIModel-uYXZJ", "target": "OpenAIModel-uYXZJ",
"targetHandle": "{œfieldNameœ:œinput_valueœ,œidœ:œOpenAIModel-uYXZJœ,œinputTypesœ:[œTextœ],œtypeœ:œstrœ}", "targetHandle": "{\u0153fieldName\u0153:\u0153input_value\u0153,\u0153id\u0153:\u0153OpenAIModel-uYXZJ\u0153,\u0153inputTypes\u0153:[\u0153Text\u0153],\u0153type\u0153:\u0153str\u0153}",
"data": { "data": {
"targetHandle": { "targetHandle": {
"fieldName": "input_value", "fieldName": "input_value",
"id": "OpenAIModel-uYXZJ", "id": "OpenAIModel-uYXZJ",
"inputTypes": ["Text"], "inputTypes": [
"Text"
],
"type": "str" "type": "str"
}, },
"sourceHandle": { "sourceHandle": {
"baseClasses": ["object", "str", "Text"], "baseClasses": [
"object",
"str",
"Text"
],
"dataType": "Prompt", "dataType": "Prompt",
"id": "Prompt-amqBu" "id": "Prompt-amqBu"
} }
@ -1450,22 +1599,31 @@
"stroke": "#555" "stroke": "#555"
}, },
"className": "stroke-gray-900 stroke-connection", "className": "stroke-gray-900 stroke-connection",
"id": "reactflow__edge-Prompt-amqBu{œbaseClassesœ:[œobjectœ,œstrœ,œTextœ],œdataTypeœ:œPromptœ,œidœ:œPrompt-amqBuœ}-OpenAIModel-uYXZJ{œfieldNameœ:œinput_valueœ,œidœ:œOpenAIModel-uYXZJœ,œinputTypesœ:[œTextœ],œtypeœ:œstrœ}" "id": "reactflow__edge-Prompt-amqBu{\u0153baseClasses\u0153:[\u0153object\u0153,\u0153str\u0153,\u0153Text\u0153],\u0153dataType\u0153:\u0153Prompt\u0153,\u0153id\u0153:\u0153Prompt-amqBu\u0153}-OpenAIModel-uYXZJ{\u0153fieldName\u0153:\u0153input_value\u0153,\u0153id\u0153:\u0153OpenAIModel-uYXZJ\u0153,\u0153inputTypes\u0153:[\u0153Text\u0153],\u0153type\u0153:\u0153str\u0153}"
}, },
{ {
"source": "OpenAIModel-uYXZJ", "source": "OpenAIModel-uYXZJ",
"sourceHandle": "{œbaseClassesœ:[œstrœ,œTextœ,œobjectœ],œdataTypeœ:œOpenAIModelœ,œidœ:œOpenAIModel-uYXZJœ}", "sourceHandle": "{\u0153baseClasses\u0153:[\u0153str\u0153,\u0153Text\u0153,\u0153object\u0153],\u0153dataType\u0153:\u0153OpenAIModel\u0153,\u0153id\u0153:\u0153OpenAIModel-uYXZJ\u0153}",
"target": "Prompt-gTNiz", "target": "Prompt-gTNiz",
"targetHandle": "{œfieldNameœ:œsummaryœ,œidœ:œPrompt-gTNizœ,œinputTypesœ:[œDocumentœ,œBaseOutputParserœ,œRecordœ,œTextœ],œtypeœ:œstrœ}", "targetHandle": "{\u0153fieldName\u0153:\u0153summary\u0153,\u0153id\u0153:\u0153Prompt-gTNiz\u0153,\u0153inputTypes\u0153:[\u0153Document\u0153,\u0153BaseOutputParser\u0153,\u0153Record\u0153,\u0153Text\u0153],\u0153type\u0153:\u0153str\u0153}",
"data": { "data": {
"targetHandle": { "targetHandle": {
"fieldName": "summary", "fieldName": "summary",
"id": "Prompt-gTNiz", "id": "Prompt-gTNiz",
"inputTypes": ["Document", "BaseOutputParser", "Record", "Text"], "inputTypes": [
"Document",
"BaseOutputParser",
"Record",
"Text"
],
"type": "str" "type": "str"
}, },
"sourceHandle": { "sourceHandle": {
"baseClasses": ["str", "Text", "object"], "baseClasses": [
"str",
"Text",
"object"
],
"dataType": "OpenAIModel", "dataType": "OpenAIModel",
"id": "OpenAIModel-uYXZJ" "id": "OpenAIModel-uYXZJ"
} }
@ -1474,22 +1632,28 @@
"stroke": "#555" "stroke": "#555"
}, },
"className": "stroke-gray-900 stroke-connection", "className": "stroke-gray-900 stroke-connection",
"id": "reactflow__edge-OpenAIModel-uYXZJ{œbaseClassesœ:[œstrœ,œTextœ,œobjectœ],œdataTypeœ:œOpenAIModelœ,œidœ:œOpenAIModel-uYXZJœ}-Prompt-gTNiz{œfieldNameœ:œsummaryœ,œidœ:œPrompt-gTNizœ,œinputTypesœ:[œDocumentœ,œBaseOutputParserœ,œRecordœ,œTextœ],œtypeœ:œstrœ}" "id": "reactflow__edge-OpenAIModel-uYXZJ{\u0153baseClasses\u0153:[\u0153str\u0153,\u0153Text\u0153,\u0153object\u0153],\u0153dataType\u0153:\u0153OpenAIModel\u0153,\u0153id\u0153:\u0153OpenAIModel-uYXZJ\u0153}-Prompt-gTNiz{\u0153fieldName\u0153:\u0153summary\u0153,\u0153id\u0153:\u0153Prompt-gTNiz\u0153,\u0153inputTypes\u0153:[\u0153Document\u0153,\u0153BaseOutputParser\u0153,\u0153Record\u0153,\u0153Text\u0153],\u0153type\u0153:\u0153str\u0153}"
}, },
{ {
"source": "OpenAIModel-uYXZJ", "source": "OpenAIModel-uYXZJ",
"sourceHandle": "{œbaseClassesœ:[œstrœ,œTextœ,œobjectœ],œdataTypeœ:œOpenAIModelœ,œidœ:œOpenAIModel-uYXZJœ}", "sourceHandle": "{\u0153baseClasses\u0153:[\u0153str\u0153,\u0153Text\u0153,\u0153object\u0153],\u0153dataType\u0153:\u0153OpenAIModel\u0153,\u0153id\u0153:\u0153OpenAIModel-uYXZJ\u0153}",
"target": "ChatOutput-EJkG3", "target": "ChatOutput-EJkG3",
"targetHandle": "{œfieldNameœ:œinput_valueœ,œidœ:œChatOutput-EJkG3œ,œinputTypesœ:[œTextœ],œtypeœ:œstrœ}", "targetHandle": "{\u0153fieldName\u0153:\u0153input_value\u0153,\u0153id\u0153:\u0153ChatOutput-EJkG3\u0153,\u0153inputTypes\u0153:[\u0153Text\u0153],\u0153type\u0153:\u0153str\u0153}",
"data": { "data": {
"targetHandle": { "targetHandle": {
"fieldName": "input_value", "fieldName": "input_value",
"id": "ChatOutput-EJkG3", "id": "ChatOutput-EJkG3",
"inputTypes": ["Text"], "inputTypes": [
"Text"
],
"type": "str" "type": "str"
}, },
"sourceHandle": { "sourceHandle": {
"baseClasses": ["str", "Text", "object"], "baseClasses": [
"str",
"Text",
"object"
],
"dataType": "OpenAIModel", "dataType": "OpenAIModel",
"id": "OpenAIModel-uYXZJ" "id": "OpenAIModel-uYXZJ"
} }
@ -1498,22 +1662,29 @@
"stroke": "#555" "stroke": "#555"
}, },
"className": "stroke-gray-900 stroke-connection", "className": "stroke-gray-900 stroke-connection",
"id": "reactflow__edge-OpenAIModel-uYXZJ{œbaseClassesœ:[œstrœ,œTextœ,œobjectœ],œdataTypeœ:œOpenAIModelœ,œidœ:œOpenAIModel-uYXZJœ}-ChatOutput-EJkG3{œfieldNameœ:œinput_valueœ,œidœ:œChatOutput-EJkG3œ,œinputTypesœ:[œTextœ],œtypeœ:œstrœ}" "id": "reactflow__edge-OpenAIModel-uYXZJ{\u0153baseClasses\u0153:[\u0153str\u0153,\u0153Text\u0153,\u0153object\u0153],\u0153dataType\u0153:\u0153OpenAIModel\u0153,\u0153id\u0153:\u0153OpenAIModel-uYXZJ\u0153}-ChatOutput-EJkG3{\u0153fieldName\u0153:\u0153input_value\u0153,\u0153id\u0153:\u0153ChatOutput-EJkG3\u0153,\u0153inputTypes\u0153:[\u0153Text\u0153],\u0153type\u0153:\u0153str\u0153}"
}, },
{ {
"source": "Prompt-gTNiz", "source": "Prompt-gTNiz",
"sourceHandle": "{œbaseClassesœ:[œobjectœ,œstrœ,œTextœ],œdataTypeœ:œPromptœ,œidœ:œPrompt-gTNizœ}", "sourceHandle": "{\u0153baseClasses\u0153:[\u0153object\u0153,\u0153str\u0153,\u0153Text\u0153],\u0153dataType\u0153:\u0153Prompt\u0153,\u0153id\u0153:\u0153Prompt-gTNiz\u0153}",
"target": "TextOutput-MUDOR", "target": "TextOutput-MUDOR",
"targetHandle": "{œfieldNameœ:œinput_valueœ,œidœ:œTextOutput-MUDORœ,œinputTypesœ:[œRecordœ,œTextœ],œtypeœ:œstrœ}", "targetHandle": "{\u0153fieldName\u0153:\u0153input_value\u0153,\u0153id\u0153:\u0153TextOutput-MUDOR\u0153,\u0153inputTypes\u0153:[\u0153Record\u0153,\u0153Text\u0153],\u0153type\u0153:\u0153str\u0153}",
"data": { "data": {
"targetHandle": { "targetHandle": {
"fieldName": "input_value", "fieldName": "input_value",
"id": "TextOutput-MUDOR", "id": "TextOutput-MUDOR",
"inputTypes": ["Record", "Text"], "inputTypes": [
"Record",
"Text"
],
"type": "str" "type": "str"
}, },
"sourceHandle": { "sourceHandle": {
"baseClasses": ["object", "str", "Text"], "baseClasses": [
"object",
"str",
"Text"
],
"dataType": "Prompt", "dataType": "Prompt",
"id": "Prompt-gTNiz" "id": "Prompt-gTNiz"
} }
@ -1522,22 +1693,28 @@
"stroke": "#555" "stroke": "#555"
}, },
"className": "stroke-gray-900 stroke-connection", "className": "stroke-gray-900 stroke-connection",
"id": "reactflow__edge-Prompt-gTNiz{œbaseClassesœ:[œobjectœ,œstrœ,œTextœ],œdataTypeœ:œPromptœ,œidœ:œPrompt-gTNizœ}-TextOutput-MUDOR{œfieldNameœ:œinput_valueœ,œidœ:œTextOutput-MUDORœ,œinputTypesœ:[œRecordœ,œTextœ],œtypeœ:œstrœ}" "id": "reactflow__edge-Prompt-gTNiz{\u0153baseClasses\u0153:[\u0153object\u0153,\u0153str\u0153,\u0153Text\u0153],\u0153dataType\u0153:\u0153Prompt\u0153,\u0153id\u0153:\u0153Prompt-gTNiz\u0153}-TextOutput-MUDOR{\u0153fieldName\u0153:\u0153input_value\u0153,\u0153id\u0153:\u0153TextOutput-MUDOR\u0153,\u0153inputTypes\u0153:[\u0153Record\u0153,\u0153Text\u0153],\u0153type\u0153:\u0153str\u0153}"
}, },
{ {
"source": "Prompt-gTNiz", "source": "Prompt-gTNiz",
"sourceHandle": "{œbaseClassesœ:[œobjectœ,œstrœ,œTextœ],œdataTypeœ:œPromptœ,œidœ:œPrompt-gTNizœ}", "sourceHandle": "{\u0153baseClasses\u0153:[\u0153object\u0153,\u0153str\u0153,\u0153Text\u0153],\u0153dataType\u0153:\u0153Prompt\u0153,\u0153id\u0153:\u0153Prompt-gTNiz\u0153}",
"target": "OpenAIModel-XawYB", "target": "OpenAIModel-XawYB",
"targetHandle": "{œfieldNameœ:œinput_valueœ,œidœ:œOpenAIModel-XawYBœ,œinputTypesœ:[œTextœ],œtypeœ:œstrœ}", "targetHandle": "{\u0153fieldName\u0153:\u0153input_value\u0153,\u0153id\u0153:\u0153OpenAIModel-XawYB\u0153,\u0153inputTypes\u0153:[\u0153Text\u0153],\u0153type\u0153:\u0153str\u0153}",
"data": { "data": {
"targetHandle": { "targetHandle": {
"fieldName": "input_value", "fieldName": "input_value",
"id": "OpenAIModel-XawYB", "id": "OpenAIModel-XawYB",
"inputTypes": ["Text"], "inputTypes": [
"Text"
],
"type": "str" "type": "str"
}, },
"sourceHandle": { "sourceHandle": {
"baseClasses": ["object", "str", "Text"], "baseClasses": [
"object",
"str",
"Text"
],
"dataType": "Prompt", "dataType": "Prompt",
"id": "Prompt-gTNiz" "id": "Prompt-gTNiz"
} }
@ -1546,22 +1723,28 @@
"stroke": "#555" "stroke": "#555"
}, },
"className": "stroke-gray-900 stroke-connection", "className": "stroke-gray-900 stroke-connection",
"id": "reactflow__edge-Prompt-gTNiz{œbaseClassesœ:[œobjectœ,œstrœ,œTextœ],œdataTypeœ:œPromptœ,œidœ:œPrompt-gTNizœ}-OpenAIModel-XawYB{œfieldNameœ:œinput_valueœ,œidœ:œOpenAIModel-XawYBœ,œinputTypesœ:[œTextœ],œtypeœ:œstrœ}" "id": "reactflow__edge-Prompt-gTNiz{\u0153baseClasses\u0153:[\u0153object\u0153,\u0153str\u0153,\u0153Text\u0153],\u0153dataType\u0153:\u0153Prompt\u0153,\u0153id\u0153:\u0153Prompt-gTNiz\u0153}-OpenAIModel-XawYB{\u0153fieldName\u0153:\u0153input_value\u0153,\u0153id\u0153:\u0153OpenAIModel-XawYB\u0153,\u0153inputTypes\u0153:[\u0153Text\u0153],\u0153type\u0153:\u0153str\u0153}"
}, },
{ {
"source": "OpenAIModel-XawYB", "source": "OpenAIModel-XawYB",
"sourceHandle": "{œbaseClassesœ:[œstrœ,œTextœ,œobjectœ],œdataTypeœ:œOpenAIModelœ,œidœ:œOpenAIModel-XawYBœ}", "sourceHandle": "{\u0153baseClasses\u0153:[\u0153str\u0153,\u0153Text\u0153,\u0153object\u0153],\u0153dataType\u0153:\u0153OpenAIModel\u0153,\u0153id\u0153:\u0153OpenAIModel-XawYB\u0153}",
"target": "ChatOutput-DNmvg", "target": "ChatOutput-DNmvg",
"targetHandle": "{œfieldNameœ:œinput_valueœ,œidœ:œChatOutput-DNmvgœ,œinputTypesœ:[œTextœ],œtypeœ:œstrœ}", "targetHandle": "{\u0153fieldName\u0153:\u0153input_value\u0153,\u0153id\u0153:\u0153ChatOutput-DNmvg\u0153,\u0153inputTypes\u0153:[\u0153Text\u0153],\u0153type\u0153:\u0153str\u0153}",
"data": { "data": {
"targetHandle": { "targetHandle": {
"fieldName": "input_value", "fieldName": "input_value",
"id": "ChatOutput-DNmvg", "id": "ChatOutput-DNmvg",
"inputTypes": ["Text"], "inputTypes": [
"Text"
],
"type": "str" "type": "str"
}, },
"sourceHandle": { "sourceHandle": {
"baseClasses": ["str", "Text", "object"], "baseClasses": [
"str",
"Text",
"object"
],
"dataType": "OpenAIModel", "dataType": "OpenAIModel",
"id": "OpenAIModel-XawYB" "id": "OpenAIModel-XawYB"
} }
@ -1570,7 +1753,7 @@
"stroke": "#555" "stroke": "#555"
}, },
"className": "stroke-gray-900 stroke-connection", "className": "stroke-gray-900 stroke-connection",
"id": "reactflow__edge-OpenAIModel-XawYB{œbaseClassesœ:[œstrœ,œTextœ,œobjectœ],œdataTypeœ:œOpenAIModelœ,œidœ:œOpenAIModel-XawYBœ}-ChatOutput-DNmvg{œfieldNameœ:œinput_valueœ,œidœ:œChatOutput-DNmvgœ,œinputTypesœ:[œTextœ],œtypeœ:œstrœ}" "id": "reactflow__edge-OpenAIModel-XawYB{\u0153baseClasses\u0153:[\u0153str\u0153,\u0153Text\u0153,\u0153object\u0153],\u0153dataType\u0153:\u0153OpenAIModel\u0153,\u0153id\u0153:\u0153OpenAIModel-XawYB\u0153}-ChatOutput-DNmvg{\u0153fieldName\u0153:\u0153input_value\u0153,\u0153id\u0153:\u0153ChatOutput-DNmvg\u0153,\u0153inputTypes\u0153:[\u0153Text\u0153],\u0153type\u0153:\u0153str\u0153}"
} }
], ],
"viewport": { "viewport": {

File diff suppressed because one or more lines are too long