Add CreateRecordComponent, update IDGeneratorComponent and input components' descriptions
This commit is contained in:
parent
21df24956f
commit
8e3ce9050e
4 changed files with 7 additions and 7 deletions
|
|
@ -2,16 +2,16 @@ from langflow.interface.custom.custom_component import CustomComponent
|
||||||
from langflow.schema import Record
|
from langflow.schema import Record
|
||||||
|
|
||||||
|
|
||||||
class TextToRecordComponent(CustomComponent):
|
class CreateRecordComponent(CustomComponent):
|
||||||
display_name = "Text to Record"
|
display_name = "Create Record"
|
||||||
description = "A component to create a record from Text."
|
description = "A component to create a record."
|
||||||
beta: bool = True
|
beta: bool = True
|
||||||
|
|
||||||
def build_config(self):
|
def build_config(self):
|
||||||
return {
|
return {
|
||||||
"data": {
|
"data": {
|
||||||
"display_name": "Data",
|
"display_name": "Data",
|
||||||
"info": "The data to convert to a record.",
|
"info": "Data to contruct the record.",
|
||||||
"input_types": ["Text"],
|
"input_types": ["Text"],
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
@ -6,7 +6,7 @@ from langflow.interface.custom.custom_component import CustomComponent
|
||||||
|
|
||||||
class UUIDGeneratorComponent(CustomComponent):
|
class UUIDGeneratorComponent(CustomComponent):
|
||||||
documentation: str = "http://docs.langflow.org/components/custom"
|
documentation: str = "http://docs.langflow.org/components/custom"
|
||||||
display_name = "Unique ID Generator"
|
display_name = "ID Generator"
|
||||||
description = "Generates a unique ID."
|
description = "Generates a unique ID."
|
||||||
|
|
||||||
def update_build_config(
|
def update_build_config(
|
||||||
|
|
|
||||||
|
|
@ -7,7 +7,7 @@ from langflow.schema import Record
|
||||||
|
|
||||||
class ChatInput(ChatComponent):
|
class ChatInput(ChatComponent):
|
||||||
display_name = "Chat Input"
|
display_name = "Chat Input"
|
||||||
description = "Used to capture and send user inputs from the chat."
|
description = "Capture user inputs from the chat interface."
|
||||||
icon = "ChatInput"
|
icon = "ChatInput"
|
||||||
|
|
||||||
def build(
|
def build(
|
||||||
|
|
|
||||||
|
|
@ -6,7 +6,7 @@ from langflow.field_typing import Text
|
||||||
|
|
||||||
class TextInput(TextComponent):
|
class TextInput(TextComponent):
|
||||||
display_name = "Text Input"
|
display_name = "Text Input"
|
||||||
description = "Used to capture and send text inputs."
|
description = "Capture and send text inputs."
|
||||||
|
|
||||||
def build(self, input_value: Optional[str] = "") -> Text:
|
def build(self, input_value: Optional[str] = "") -> Text:
|
||||||
return super().build(input_value=input_value)
|
return super().build(input_value=input_value)
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue