Skip to content

Documentation for Workflows - Condition Branches #484

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 3 additions & 1 deletion site/guide/model-inventory/manage-model-inventory-fields.qmd
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,9 @@ Email
: Text value in valid email (`user@domain.com`) format.

User
: Select list pre-populated with users from your User Directory.[^4]
:
- Select list pre-populated with users from your User Directory.[^4]
- Toggle [allow linking to multiple records]{.smallcaps} on to allow multi-selection of users.

Calculation
: Define a `formula(params)` function that automatically calculates and returns a value based on the params dictionary, which includes selected custom field keys retrieved from your other inventory model fields.
Expand Down
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
77 changes: 63 additions & 14 deletions site/guide/model-workflows/set-up-model-workflows.qmd
Original file line number Diff line number Diff line change
Expand Up @@ -143,25 +143,67 @@ Example

::::

#### Condition Branch
- Allows diverging paths based on conditional requirements.
- A `default` branch will be automatically included as a catch-all `else` path to ensure that your conditional logic is complete.

::: {.callout-important}
Workflows cannot be saved until condition branches are connected to other steps.
:::

To configure a condition branch:

1. On the Configure Condition Branch module, click **+ Add Branch**.
2. Enter in the **[name]{.smallcaps}** and designate the **[conditions]{.smallcaps}**[^12] that apply to this path.
3. Continue with steps 1 and 2 until your conditional branch logic is complete.

To remove a path, click **{{< fa ellipsis-vertical >}}** and select **{{< fa trash-can >}} Remove Path**.
4. When you are finished setting up all your branch paths, click **Update Step** to save your step.

Proceed with linking the Condition Branch with your subsequent steps.[^13]

For example, if you wanted your models where the field `GenAI Model` is set to `true` to undergo a special legal approval process:

- First, you'd set up a Condition Branch path to look for instances where `GenAI Model` is set to `true`.
- Then, you would add an Approval step[^14] that requests a review of the model from the User group `Legal Team`.
- Finally, configure the `default` path to bypass this special approval.

:::: {.flex .flex-wrap .justify-around}

::: {.w-50-ns}
![CONDITION BRANCH step configuration with condition of GenAI Model = `true`](configure-condition-branch.png){fig-alt="A screenshot showing a CONDITION BRANCH step configuration with condition of GenAI Model = `true`" class="screenshot"}

:::

::: {.w-50-ns}
![Legal team Approval step configuration](legal-team-approval.png){fig-alt="Screenshot showing the Legal team Approval step configuration" class="screenshot" width=80%}

:::

::::

![Example Condition Branch where GenAI models require special approval from the User group Legal Team](example-condition-branch.png){fig-alt="A screenshot showing an example Condition Branch where GenAI models require special approval from the User group Legal Team" class="screenshot"}

### Add conditional requirements

Conditional requirements can be configured for all three available step types:
Conditional requirements can be configured for all four available step types:

| Step type | Conditional options |
|---:|---|
| Status Change | Under **When these conditions are met**, you are able to set both `AND` and `OR` conditions. |
| User Action | Under **Display action button when**, you are able to set both `AND` and `OR` conditions. |
| Approval | Under **Threshold**, you are able to set the minimum percentage of approvers required for the resource to be approved. |
| Status Change | Under **[when these conditions are met]{.smallcaps}**, you are able to set both `AND` and `OR` conditions. |
| User Action | Under **[display action button when]{.smallcaps}**, you are able to set both `AND` and `OR` conditions. |
| Approval | Under **[threshold]{.smallcaps}**, you are able to set the minimum percentage of approvers required for the resource to be approved. |
| Condition Branch | Under each branch's **[conditions]{.smallcaps}**, you're able to designate the conditions that apply to that path. |
: Step type conditional options {.hover tbl-colwidths="[20,80]"}

For Status Change[^12] and User Action[^13] conditions, you're able to add a single independent **Rule** or a linked condition **Group**. These rules and groups can be nested if desired:
For Status Change[^15], User Action[^16], and Condition Branch[^17] conditions, you're able to add a single independent **Rule** or a linked condition **Group**. These rules and groups can be nested if desired:

- Click **{{< fa plus >}} Rule** to add an independent rule.
- Click **{{< fa plus >}} Group** to add a linked group of rules that all must be true to qualify.

## Link workflow together

To initiate the beginning of your workflow:[^14]
To initiate the beginning of your workflow:[^18]

1. Locate the **Start** of your workflow.

Expand All @@ -182,9 +224,9 @@ To link subsequent steps together:
#### Link approval steps
Approval steps need to be subsequently linked to both a `Rejected` and an `Approved` Status Change step:

1. First, configure an **Approval** step.[^15]
1. First, configure an **Approval** step.[^19]

2. Then, drag two **Status Change** steps onto the canvas:[^16]
2. Then, drag two **Status Change** steps onto the canvas:[^20]

- Assign a `Rejected` status to one in the **Set Document Status** field.
- Assign an `Approved` status to the other in the **Set Document Status** field.
Expand Down Expand Up @@ -243,16 +285,23 @@ Approval steps need to be subsequently linked to both a `Rejected` and an `Appro

[^11]: [Add conditional requirements](#add-conditional-requirements)

[^12]: [Status Change](#status-change) steps
[^12]: [Add conditional requirements](#add-conditional-requirements)

[^13]: [Link steps together](#link-steps-together)

[^14]: [Approval](#approval) steps

[^13]: [User Action](#user-action) steps
[^15]: [Status Change](#status-change) steps

[^14]: After you’ve [configured your workflow steps](#configure-workflow-steps), you can then link your workflow together.
[^16]: [User Action](#user-action) steps

[^15]:
[^17]: [Condition Branch](#condition-branch) steps

[^18]: After you’ve [configured your workflow steps](#configure-workflow-steps), you can then link your workflow together.

[^19]:

- [Configure workflow steps](#configure-workflow-steps)
- [Approval](#approval) steps

[^16]: [Status Change](#status-change) steps

[^20]: [Status Change](#status-change) steps
Loading