The Logic Stage
Add a Logic Stage to your workflow to create dynamic paths for your data based on the annotations that your files contain.
Logic stages let you create custom if/else statements or Rules to automatically manage the flow of your data. Rules can have and logic which requires all conditions to be met for a file to move down a specific path, or Or logicwhich requires only one condition to be met.
Use Logic stages to automatically archive blurry images, assign files to specialists based on their content, or trigger webhook-based automations when specific classes are added to a file. Check out the guide below for inspiration on how you can inject logic into your datasets.
To set up a Logic stage:
- Drag and drop the Logic stage into your workflow template.
- Plug the stage into the previous workflow stage (where the files will be flowing from) and the next workflow stages in sequence (where the files will be flowing to). Logic stages are a conditional stage - if files meet the criteria for a rule, they will be sent to the next specified workflow stage. Any files that do not meet the criteria of the stage rules will be sent to the stage connected to Else.
- Configure the stage by adding one or more rules, adding an operator and value for each rule.
- If required, add multiple classes to a rule using and logic or or logic to determine your files' workflow. Let's say we want to train on an invoices dataset and we only want to include invoices that contain Vendor Name and Vendor Address in our final export. Clicking + next to our rule will add an And condition ensuring that files containing both classes are sent to the stage connected to the rule branch.
In another example, let's say we want to send all files that are tagged with the Blurry or Corrupt tag straight to archive, we can add both classes within the same condition so files move to the Archive stage when either condition is are met.
- Add additional rules if needed by clicking Add rule. Multiple rules in a logic stage will use or logic and will be applied to a file in the order in which they appear. For example, if a file meets multiple any of the conditions in a logic stage that contains multiple rules, it will be sent down the first path in descending order where the rules are met.
Self-Assignment
As an automated stage, the Logic Stage requires files to be assigned to it in order to be triggered.
As a result, if a Logic Stage is the first stage after the Dataset Stage in a workflow, it will be necessary for a User, Admin, or Workforce Manager to assign files to the stage manually to kick off the workflow. Workers will not be able to self-assign files until they have passed through the Logic Stage.
Updated 10 months ago