Skip to content

Commit 1e78cad

Browse files
authored
Merge pull request #15354 from nextcloud/more-task-types
docs(taskprocessing): Document improve, and multimodal task types
2 parents c58b66f + 941e8fe commit 1e78cad

1 file changed

Lines changed: 31 additions & 0 deletions

File tree

developer_manual/digging_deeper/task_processing.rst

Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -49,6 +49,18 @@ The following built-in task types are available:
4949
* Output shape:
5050
* ``output``: ``Text``
5151
* ``tool_calls``: ``Text`` A string containing a JSON array with ``{"name": string, "type": "tool_call", "id": string, "args": object}``
52+
* ``'core:text2text:multimodal-chatwithtools'``: This task allows chatting with the language model with tools calling support and file attachments. It is implemented by ``\OCP\TaskProcessing\TaskTypes\MultimodalChatWithTools``
53+
* Input shape:
54+
* ``system_prompt``: ``Text``
55+
* ``input``: ``Text``
56+
* ``input_attachments``: ``ListOfFiles`` Files to send along with the chat message
57+
* ``tool_message``: ``Text`` A string containing a JSON array of ``{"name": string, "content": string, "tool_call_id": string}``
58+
* ``history``: ``ListOfTexts`` Each list item is a JSON string with ``{"role": "human", "content": string}`` or ``{"role": "assistant", "content": string, (optional: "tool_calls": array<{"name": string, "type": "tool_call", "id": string, "args": object}>)}`` or ``{"role": "tool", "content": string, "name": string, "tool_call_id": string}``
59+
* ``tools``: ``Text`` The tools parameter should be a JSON array formatted according to the OpenAI API specifications: https://platform.openai.com/docs/api-reference/chat/create#chat-create-tools
60+
* Output shape:
61+
* ``output``: ``Text``
62+
* ``output_attachments``: ``ListOfFiles`` Files generated by the model
63+
* ``tool_calls``: ``Text`` A string containing a JSON array with ``{"name": string, "type": "tool_call", "id": string, "args": object}``
5264
* ``'core:contextagent:interaction'``: This task allows chatting with an agent. It is implemented by ``\OCP\TaskProcessing\TaskTypes\ContextAgentInteraction``
5365
* Input shape:
5466
* ``input``: ``Text``
@@ -58,6 +70,19 @@ The following built-in task types are available:
5870
* ``output``: ``Text``
5971
* ``conversation_token``: ``Text``
6072
* ``actions``: ``Text``
73+
* ``'core:contextagent:multimodal-interaction'``: This task allows chatting with an agent using file attachments. It is implemented by ``\OCP\TaskProcessing\TaskTypes\MultimodalContextAgentInteraction``
74+
* Input shape:
75+
* ``input``: ``Text``
76+
* ``input_attachments``: ``ListOfFiles`` Files to send along with the chat message
77+
* ``confirmation``: ``Number`` Boolean integer indicating whether to confirm previously requested actions: 0 to reject or 1 to confirm.
78+
* ``conversation_token``: ``Text`` Token representing the conversation
79+
* ``memories``: ``ListOfTexts`` Memories to send to the agent
80+
* Output shape:
81+
* ``output``: ``Text``
82+
* ``output_attachments``: ``ListOfFiles`` Files generated by the agent
83+
* ``conversation_token``: ``Text``
84+
* ``actions``: ``Text``
85+
* ``sources``: ``ListOfTexts`` Sources of the generated response
6186
* ``'core:text2text:formalization'``: This task will reformulate the passed input text to be more formal in tone. It is implemented by ``\OCP\TaskProcessing\TaskTypes\TextToTextFormalization``
6287
* Input shape:
6388
* ``input``: ``Text``
@@ -68,6 +93,12 @@ The following built-in task types are available:
6893
* ``input``: ``Text``
6994
* Output shape:
7095
* ``output``: ``Text``
96+
* ``'core:text2text:improve'``: This task will improve the passed input text based on instructions. It is implemented by ``\OCP\TaskProcessing\TaskTypes\TextToTextImprove``
97+
* Input shape:
98+
* ``input``: ``Text``
99+
* ``instructions``: ``Text``
100+
* Output shape:
101+
* ``output``: ``Text``
71102
* ``'core:text2text:reformulation'``: This task will reformulate the passed input text arbitrarily. It is implemented by ``\OCP\TaskProcessing\TaskTypes\TextToTextReformulation``
72103
* Input shape:
73104
* ``input``: ``Text``

0 commit comments

Comments
 (0)