Skip to content

Sorting Recipes

A sorting recipe tells RapiD Vision what to do with each product it inspects. As every product passes under the camera, the system checks it against the recipe's rules and decides which destination it should go to — for example "Grade A", "Grade B", or "Reject".

Recipes belong to a Vision Configuration. A configuration can have several recipes saved for it (for example one recipe per customer or product spec). More than one recipe can be active at the same time on a multi-lane machine — see Lanes below.

Destinations

Before you can build a recipe, your company needs a Destinations catalogue: the list of physical outputs a product can be sorted to (a chute, lane, or robot output), each with a name, a logo colour, and the physical output number it's wired to. Recipes pick from this list instead of every item defining its own output.

Open Sortings, then the Destinations tab, to manage the catalogue:

Field Description
Destination name The name shown everywhere a recipe references this destination, for example "Grade A" or "Reject".
Physical output The chute, lane, or relay this destination is wired to. Set once at commissioning and fixed afterwards — every recipe using the destination points at this number.
Color The colour the device's status logo lights up when a product is sent here.
Reject Marks this destination as a reject/ungraded output.
Selectable in recipes Turn this off to retire a destination without deleting it. Recipes already using it keep working; it just won't be offered on new items.

If your company doesn't have a catalogue yet, select Import from recipes to adopt the destinations your existing recipes already use. If the same physical output has been named differently across recipes, the most-used name is kept, and you're told how many needed reconciling so you can rename them afterwards.

A destination that's still used by a recipe can't be deleted — turn off Selectable in recipes to retire it instead.

How Sorting Recipes Work

A recipe is made up of one or more Sorting Items. Each Sorting Item points at a destination and defines the rules a product must meet to be sent there:

  • A Main Condition — the primary rule, based on the product itself (label, weight, size).
  • Optional Defect Conditions — extra rules based on defects/spots found on the product by the vision system.

When a product is inspected, RapiD Vision compares it against every Sorting Item in the active recipe and collects all the items it matches:

  • If it matches exactly one Sorting Item, that item's destination is used.
  • If it matches more than one, the item highest in the list wins — see Priority.
  • If it matches none, the product falls back to the first Sorting Item in the recipe. It's good practice to make your first item a catch-all (for example "Reject" or "Ungraded") so nothing is routed unexpectedly.

Sorting Items

Each Sorting Item card shows:

Field Description
Destination Picked from the company's Destinations catalogue. Each destination can only be used once per recipe — reusing one is flagged immediately and blocks saving.
Main Condition Shown side by side with the destination as a row of chips; select one to edit the item's limits.
Defect Conditions An expandable section at the foot of the card, with a count badge.
Priority The card's position in the list — drag to reorder.
Auto-increment output Optional. Spreads this item's products over a row of physical outputs — see Auto-Increment Output.

Recipes created before this catalogue existed

An item whose output doesn't match anything in the catalogue is shown with a Not in catalogue chip. It keeps working unchanged, with its own name, colour and number; pick a destination from the catalogue whenever you're ready to replace it.

Select Add item to add a new Sorting Item to the recipe.

Auto-Increment Output

Turn on Auto-increment output on a Sorting Item to spread its products over a row of physical outputs instead of sending them all to one. Each product the item catches goes to the next output, from the destination's own output up to the End output, then starts over — for example crates 3, 4, 5, 6, 3, 4, …

  • The End output must be higher than the item's own output. Ranges that overlap another item's output (or another range) are flagged like a duplicate destination and block saving, and Add item skips outputs a range already covers.
  • The recipe card, the charts and the Home page sorting bar show the range (for example "Crates (4)"), and every output in the range can be picked on a conveyor in Machine management.
  • The counter is shared across lanes and restarts at the first output when the device restarts or the item's end output changes.

Auto-increment is off by default.

Priority

Drag a card to change its priority — the card nearest the top wins when a product matches more than one destination. A card's position and its priority can never drift apart, since priority is reassigned from the list order automatically. The up/down buttons next to the drag handle move a card one slot at a time, and remain there for keyboard use and as a precise alternative to dragging.

Main Conditions

Select a condition chip, or Edit limits, on a Sorting Item to open its condition inspector — a panel docked to the right of the item list. It supports:

  • Label — the product class this rule applies to. Leave this at No Label to match any product.
  • Weight Range (g) — minimum and maximum weight.
  • Length Range (mm) and Width Range (mm) — minimum and maximum measured dimensions.
  • Area Range (mm²) — minimum and maximum measured surface area.
  • Min Score (%) — the minimum AI confidence required for a match.
  • Density (g/cm³) — used together with weight and area for products graded by density.

Every range starts collapsed as Any, and only opens once you set a limit, so a condition shows at a glance what it actually constrains. Edits apply immediately — there's no separate Apply step; everything is saved together when you save the recipe.

Defect Conditions

Expand Defect conditions on a Sorting Item to route products based on blemishes or defects the vision system detects, in addition to (or instead of) the Main Condition. Select Add condition to add one; each supports:

  • Label — the type of defect it applies to.
  • Area Range (mm²) — the size range of the defect spot.
  • Min Score (%) — the minimum AI confidence required for the defect to count.
  • Combine area of same defects — when enabled, all spots of this defect type on a single product are added together (and their scores averaged) before checking against the area and score range, instead of checking each spot separately. Use this when many small defects of the same type together should be treated as one larger problem.

A product only needs to trigger one Defect Condition on a Sorting Item to be routed to that item's destination.

The Defect Conditions section only appears on a Sorting Item when the vision configuration's detector has a defect model configured — otherwise there's nothing to build a defect condition against.

Lanes

On a machine with more than one physical lane, a recipe can be scoped to run on specific lanes instead of the whole machine — so different lanes can be graded against different recipes at the same time. On the recipe's General page, turn off Run on every lane and pick which lanes it should run on.

A lane with nothing assigned to it falls back to whichever recipe is set to Run on every lane, if one is active. Activating a lane-scoped recipe tells you exactly what it will replace, per device and lane (for example "This will replace 'B-grade' on lane 2"), and Deactivate stops a recipe on its lanes without having to edit its lane scope first.

The lane numbers shown here come from the camera's own regions of interest, configured per device on the Options → Lanes tab — not the conveyor's mechanical row numbering. The picker only appears when a connected device actually has more than one lane.

Supplier Triggers

A recipe can be bound to the suppliers it's meant for, so batches from those suppliers point at the right recipe. This only applies when the recipe's Vision Configuration has Automatic recipe switching turned on (see Vision Configurations); otherwise the Triggers page is greyed out.

On the recipe's Triggers page:

  • Tick the Suppliers whose batches should use this recipe. Select all and Deselect all help with long lists.
  • Turn on Default recipe for this configuration to make this the fallback for a batch that doesn't match any supplier. Each configuration should have one default.

Note

For now, a batch that matches a supplier bound to a different recipe raises an in-app notification suggesting the switch. The recipe isn't switched automatically yet.

Creating a Sorting Recipe

  1. Make sure your Destinations catalogue is set up (see Destinations) — this only needs doing once per company.
  2. Open Sortings from the navigation menu and select Add.
  3. On the General page, enter a Recipe Name and pick the Vision Configuration it belongs to.
  4. On a multi-lane machine, keep Run on every lane on, or turn it off and pick specific lanes.
  5. Go to the Sorting Items page and select Add item for each destination you need (for example "Reject", "Grade A", "Grade B"). For each item, pick a Destination, then select Edit limits to set its Main Condition.
  6. If your configuration includes defect detection, expand Defect conditions on any item and select Add condition to add one or more defect rules for it.
  7. Drag the cards into the order you want — see Priority.
  8. If the configuration uses automatic recipe switching, pick this recipe's suppliers on the Triggers page — see Supplier Triggers.
  9. Review the live preview on the right of the dialog, then select Save.

Editing a Sorting Recipe

  1. Open Sortings.
  2. Select the recipe card, then select Edit (or Duplicate to start from a copy instead).
  3. Make your changes across the General, Sorting Items, and Triggers pages.
  4. Select Save.

If you edit the recipe that is currently active, the changes take effect on the device immediately — no restart required.

Activating a Sorting Recipe

  1. Open Sortings.
  2. Select the recipe you want to use.
  3. Select Activate and confirm. If more than one device is connected, pick which of them to activate it on.

Activating a recipe scoped to specific lanes tells you what it will replace on each lane; activating one set to Run on every lane replaces the whole machine's fallback recipe. The device remembers the last active recipe(s) for each Vision Configuration, so switching back to a configuration later automatically reselects the recipes you were using.

Deactivating a Sorting Recipe

Select Deactivate on a recipe card to stop it running without touching its lane scope. Its lanes fall back to whichever recipe is set to Run on every lane, if any.

Deleting a Sorting Recipe

  1. Open Sortings.
  2. Select the recipe card you want to remove.
  3. Select Delete and confirm.

Recipe Log Warnings

Sometimes a defect spot is detected but is too small, or scores too low, to match any Defect Condition in the active recipe. RapiD Vision still logs these as recipe log warnings so you can review near-misses and decide whether your recipe's thresholds need adjusting. You can review these from Machine management.