The Instill App component is an application component that allows users to manipulate Instill App related resources.. It can carry out the following tasks:
#Release Stage
Alpha
#Configuration
The component definition and tasks are defined in the definition.json and tasks.json files respectively.
#Supported Tasks
#Read Chat History
Retrieve the chat history from the conversation.
Input | ID | Type | Description |
---|---|---|---|
Task ID (required) | task | string | TASK_READ_CHAT_HISTORY |
Namespace (required) | namespace | string | Fill in your namespace, you can get namespace through the tab of switching namespace. |
App ID (required) | app-id | string | Fill in your app ID. |
Conversation ID (required) | conversation-id | string | Fill in your conversation ID. |
Role | role | string | The role of the user you want to specify to retrieve in the conversation. The default is all with the blank setting. Now, we support 'user' and 'assistant'. |
Message Type | message-type | string | The message type of the chat history you want to retrieve. The default is all with blank setting. Now, we only support 'MESSAGE_TYPE_TEXT'. |
Duration | duration | string | The duration between now and how long ago to retrieve the chat history from. i.e. 2h45m5s. Valid time units are "ns", "us" (or "ยตs"), "ms", "s", "m", "h". The default is all with blank setting. |
Max Message Count | max-message-count | integer | The maximum number of messages to retrieve. The default is all with blank setting. |
Output | ID | Type | Description |
---|---|---|---|
Chat Messages | messages | array[object] | List of chat messages |
Output Objects in Read Chat History
Chat Messages
Field | Field ID | Type | Note |
---|---|---|---|
Content | content | array | The message content. |
Name | name | string | An optional name for the participant. Provides the model information to differentiate between participants of the same role. |
Role | role | string | The message role, i.e. 'system', 'user' or 'assistant'. |
#Write Chat Message
Write the chat message into the conversation in catalog.
Input | ID | Type | Description |
---|---|---|---|
Task ID (required) | task | string | TASK_WRITE_CHAT_MESSAGE |
Namespace (required) | namespace | string | Fill in your namespace, you can get namespace through the tab of switching namespace. |
App ID (required) | app-id | string | Fill in your app ID. |
Conversation ID (required) | conversation-id | string | Fill in your conversation ID. |
Message (required) | message | object | A chat message to be written into the conversation. |
Input Objects in Write Chat Message
Message
A chat message to be written into the conversation.
Field | Field ID | Type | Note |
---|---|---|---|
Content | content | string | The contents of the message. |
Role | role | string | The role of the author of this message. Now, we support 'user' and 'assistant'. |
Output | ID | Type | Description |
---|---|---|---|
Message ID | message-uid | string | The unique identifier of the message. |
Create Time | create-time | string | The creation time of the message in ISO 8601 format |
Update Time | update-time | string | The update time of the message in ISO 8601 format |