# Model pipeline selection and configuration

{% hint style="info" %}
Nx Witness, Nx Go and Nx Meta will work in the same way for the configuration.
{% endhint %}

The device detail page is the central place to manage the model pipelines that the device should run. Pipelines are chains of one or more models that can run with the given video input from the device. Usually a device has a default pipeline configured after the plugin is enabled for the device.

### Add a new pipeline

When no pipelines are set, the only available option is to add a new pipeline:

<figure><img src="/files/EBmiNRBYWCxaupbaly1R" alt="" width="375"><figcaption><p>A device detail page without any pipelines</p></figcaption></figure>

Clicking the "Add a pipeline" button redirects you to the model catalogue.

### Selecting a model

In the model catalogue you can select a model to use in the new (or current) pipeline.

The top of the page will show a message that you are "Currently assigning...".

If you have uploaded custom models, they will also be available in the catalogue.

<figure><img src="/files/Bsuflmp8IK06zeFZuIos" alt="" width="375"><figcaption><p>The model catalogue with the assignment message <br>and the option to select a model for the current pipeline</p></figcaption></figure>

When a model is selected it will be assigned and downloaded to the server for the current device.

<figure><img src="/files/v0efb60LPcxarx3JJ8cb" alt="" width="375"><figcaption><p>Message that the model will be added to the server</p></figcaption></figure>

You will be redirected to the device details page again, with the newly assigned model.

<figure><img src="/files/cQKzTNrOVnL07HBatzA7" alt="" width="375"><figcaption><p>The device detail page with a single pipeline containing one model</p></figcaption></figure>

### Add a chained model

Chained models are models that use the input of a parent model instead of processing the video from the device directly.

You add a chained model by clicking the chain icon <img src="/files/w9OYnQ7DlAQOu0SSGHZi" alt="" data-size="line"> next to the parent model name. You will be redirected to the model catalogue to select a chained model.

<figure><img src="/files/gWqPljfloDp53kUwwrej" alt="" width="375"><figcaption><p>Model pipeline with settings and buttons to manage models in the pipeline</p></figcaption></figure>

The way a chained model will use the input can be chosen by setting a chaining method, currently there are three modes and not all of them may be available at the same time:

* Direct - the chained model gets the output from the parent model as input
* Conditional - the chained model will only run if a field with a given name outputs "`true`"
* Feature extraction - the chained model will get the contents of the bounding boxes that have a certain label

<figure><img src="/files/gSlzm5k27dlLTLjekgWi" alt="" width="375"><figcaption><p>A model pipeline with chaining options</p></figcaption></figure>

Choose the appropriate method, and when you have entered new data the pipeline form will change to indicate that settings need to be saved.

<figure><img src="/files/zk9BD0L1XIN2YiXx8CIQ" alt="" width="375"><figcaption><p>A model pipeline with changes that need to be saved</p></figcaption></figure>

The settings will be applied to the device when you click the "Save pipelines" button.

### Change a model in a pipeline

A parent model or a chained model can be replaced by clicking the left-right arrow button next to the  model title <img src="/files/vwpfoLShwQGgsOGLjE0Q" alt="" data-size="line">. This will redirect you to the normal model selection process where you can select a replacement model.&#x20;

The rest of the settings in the model pipeline are not affected, unless they are directly related to the model.

### Remove a chained model from a pipeline

Removing a chained model from a pipeline can be done by clicking the delete button next to a **chained** model <img src="/files/zw4SZDLScXjbypPZoDKF" alt="" data-size="line"> and the model will be removed directly.

Undoing is not possible, to undo this you will have to select the same model again and set the same chaining options and pre- and post-processing.

### Remove a pipeline

Removing a pipeline with all the models and settings can be done by clicking the delete button next to a **parent** model in a pipeline <img src="/files/NyZ74jNDvBnG9LgIz7SS" alt="" data-size="line"> and the full model pipeline with all associated settings and chained models will be removed.

Undoing is not possible, to restore the settings the same model pipeline must be rebuilt completely.


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://nx.docs.scailable.net/nx-ai-manager/configure-the-plugin/model-pipeline-configuration.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
