Skip to content

Commit

Permalink
Merge pull request #12424 from nextcloud/feat/describe-task-type-disa…
Browse files Browse the repository at this point in the history
…bling

feat: describe task type disabling
  • Loading branch information
janepie authored Dec 18, 2024
2 parents 1939bfb + d766ccb commit c743726
Show file tree
Hide file tree
Showing 2 changed files with 41 additions and 1 deletion.
37 changes: 37 additions & 0 deletions admin_manual/ai/app_assistant.rst
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,8 @@ Related apps

Artificial intelligence at Nextcloud is built in a modular way, allowing you to choose from a variety of solutions for your needs. In order to make use of the various features of the Assistant you will need additional apps that act as backends to provide the actual implementation of the AI functionality. In the Nextcloud administration settings under "Artificial intelligence" you can select which AI backend app to use for which tasks. Note that some of the backend apps are only community maintained, while others are available for Customer support upon request.

The AI admin settings will show all types of Assistant Tasks that are implemented by all your installed apps. Task types can be disabled in the AI admin settings so they are not available for the Assistant or other apps even if they are implemented. All implemented Task types are enabled by default.

**Note**: At Nextcloud we focus on creating on-premise AI apps that run fully self-hosted on your own servers in order to preserve your privacy and data sovereignty. However, you can also offload these resource-heavy tasks to an :ref:`"AI as a Service" provider<ai-ai_as_a_service>`.

**Note**: When using our on-premise AI apps, make sure you have a GPU with enough VRAM that fits all the features you need. For each app documented here you will find its hardware requirements.
Expand Down Expand Up @@ -137,6 +139,41 @@ To enable/disable the text-to-image smart picker for all the users.
To enable/disable the speech-to-text smart picker for all the users.

Task processing
~~~~~~~~~~~~~~~

1. List Tasks

.. code-block::
occ taskprocessing:task:list
lists all task processing tasks.

2. Get Task

.. code-block::
occ taskprocessing:task:get $TASK_ID
shows all information for a specific task.

3. Enable or disable a Task type

.. code-block::
occ taskprocessing:task-type:set-enabled $TASK_TYPE_ID 1
Set 1 to enable and 0 to disable an implemented task type.

4. Get Task statistics

.. code-block::
occ taskprocessing:task:stats
shows statistics for all task processing Tasks.

Image storage
~~~~~~~~~~~~~

Expand Down
5 changes: 4 additions & 1 deletion developer_manual/digging_deeper/task_processing.rst
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ Consuming the Task Processing API
To consume the Task Processing API, you will need to :ref:`inject<dependency-injection>` ``\OCP\TaskProcessing\IManager``. This manager offers the following methods:

* ``hasProviders()`` This method returns a boolean which indicates if any providers have been registered. If this is false you cannot use the TextProcessing feature.
* ``getAvailableTaskTypes()`` This method returns an array of task types indexed by their ID with their names and additional metadata.
* ``getAvailableTaskTypes(bool $showDisabled = false)`` This method returns an array of enabled task types indexed by their ID with their names and additional metadata. If you set ``$showdisabled`` to ``true`` (available since NC31), it will include disabled task types.
* ``scheduleTask(Task $task)`` This method provides the actual scheduling functionality. The task is defined using the Task class. This method runs the task asynchronously in a background job.
* ``getTask(int $id)`` This method fetches a task specified by its id.
* ``deleteTask(Task $task)`` This method deletes a task
Expand Down Expand Up @@ -111,6 +111,9 @@ The following built-in task types are available:
* Output shape:
* ``output``: ``Text``


Task types can be disabled in the AI admin settings so they are not available for the Assistant or other apps even if they are implemented. All implemented Task types are enabled by default.

LLM Prompts and multilingual I/O
################################

Expand Down

0 comments on commit c743726

Please sign in to comment.