Route an Agent with an AI decision

Give an Agent criteria for choosing among named branches and review the reason it selected a branch.

Use an AI condition when the Agent needs to interpret text. For example, trigger an Agent when a Gmail message arrives and route the support email based on whether it asks about an invoice or account access. Give each branch a distinct purpose and explain how the Agent should handle an ambiguous request.

Describe how to choose a branch

  1. Open your draft Agent in Agents → Mine → Build. Add a Condition at the point where the paths should diverge, then set Decision type to AI.
  2. Under Branches, change the Branch label for each path. Use Add branch if you need another category. For the support example, name the two branches Billing and Access. Use Add step on each branch to define what happens after the decision.
  3. In Decision prompt, name the branches and describe the evidence for each. For example, enter “Choose Billing for a question about an invoice or payment. Choose Access for a sign-in or account permissions problem. If both apply or the email is unclear, explain the ambiguity and leave the decision unresolved.”

Check the decision in a test

After saving the design, choose Test when available. Open Runs, expand the test with Show details, and review the selected branch and its reason on the condition step when shown. Compare them with the input used for the run. The run can stop for review if there’s too little evidence to choose a branch. In that case, check whether the Agent received the relevant text and make the branch criteria clearer before testing again.

When the decision comes from a known field value, see Route an Agent with a rule condition.

Ask Mainbase AI

Ask about any feature in Mainbase. Find a setting, get step-by-step guidance, or troubleshoot a problem.

Open the AI assistant

Copy a question to get started

  • How do I create a Kanban view?
  • How do I invite a teammate?
  • Why is a record missing from this view?