Redis

The Redis component is a data component that allows users to manage data in NoSQL Redis databases. It can carry out the following tasks:

#Release Stage

Alpha

#Configuration

The component definition and tasks are defined in the definition.yaml and tasks.yaml files respectively.

#Setup

In order to communicate with Redis Labs, the following connection details need to be provided. You may specify them directly in a pipeline recipe as key-value pairs within the component's setup block, or you can create a Connection from the Integration Settings page and reference the whole setup as setup: ${connection.<my-connection-id>}.

FieldField IDTypeNote
Host (required)hoststringRedis host to connect to.
Port (required)portintegerPort of Redis.
UsernameusernamestringUsername associated with Redis.
PasswordpasswordstringPassword associated with Redis.
SSL ConnectionsslbooleanIndicates whether SSL encryption protocol will be used to connect to Redis. It is recommended to use SSL connection if possible.

#Supported Tasks

#Retrieve Chat History

Retrieve chat history from Redis.

InputField IDTypeDescription
Task ID (required)taskstringTASK_RETRIEVE_CHAT_HISTORY
Session ID (required)session-idstringA unique identifier for the chat session.
Latest Klatest-kintegerThe number of latest conversation turns to retrieve. A conversation turn typically includes one participant speaking or sending a message, and the other participant(s) responding to it.
Include System Message if Existsinclude-system-messagebooleanInclude system message in the retrieved conversation turns if exists.
OutputField IDTypeDescription
Chat MessagemessagesanyMessages.

#Write Chat Message

Write chat message into Redis.

InputField IDTypeDescription
Task ID (required)taskstringTASK_WRITE_CHAT_MESSAGE
Session ID (required)session-idstringA unique identifier for the chat session.
Role (required)rolestringThe message role, i.e. 'system', 'user' or 'assistant'.
Content (required)contentstringThe message content.
MetadatametadataobjectThe message metadata.
OutputField IDTypeDescription
StatusstatusbooleanThe status of the write operation.

#Write Multi Modal Chat Message

Write multi-modal chat message into Redis.

InputField IDTypeDescription
Task ID (required)taskstringTASK_WRITE_MULTI_MODAL_CHAT_MESSAGE
Session ID (required)session-idstringA unique identifier for the chat session.
Role (required)rolestringThe message role, i.e. 'system', 'user' or 'assistant'.
Content (required)contentstringThe multi-modal message content.
MetadatametadataobjectThe message metadata.
OutputField IDTypeDescription
StatusstatusbooleanThe status of the write operation.