Every support queue has the same first five minutes per ticket: read it, decide what kind of problem it is and how urgent, send it to the right person, and start a reply. That is the part an agent can take on well, as long as a person still owns what goes out to the customer. This example builds that agent in Insight AI Assist for a made-up software company.
Brightloom's shared support inbox
Brightloom (fictional) sells scheduling software to clinics and salons. Its six-person support team works one shared inbox: billing questions, technical problems and general enquiries all arrive together. Omar, the support lead, wants every ticket classified and routed before anyone opens it, with a draft reply waiting.
Eight nodes. A PROMPT step classifies each ticket into billing, technical or general with a priority and a reason, returned as JSON. A ROUTING step sends it to one of three handler prompts, each drafting a reply in the right voice. The final step bundles the draft with the category and priority for the agent who sends it.
The design

The classification step
The classify_ticket node is a PROMPT step. Its system prompt lists the three categories with a line on what belongs
in each, and asks for raw JSON with three keys: category, priority (low, medium or high) and
reason. The human prompt passes the ticket in with a placeholder, {{ ticket_description }}. Temperature
is set low (0.1) because this is a decision, not a piece of writing.

Routing and the handlers
The route_ticket step reads the classifier's output and applies two rules: category == 'BILLING' goes
to the billing handler, category == 'TECH_SUPPORT' to the technical handler, and anything else to the general handler.
Each handler is its own PROMPT step with its own system prompt (a billing specialist, a support engineer, a general agent) and gets
the ticket and the priority. The last step bundles the draft with the category and priority.
properties.yaml. Changing who handles what does not mean rewriting a prompt.Three tickets, three routes
Three made-up tickets arrive in Brightloom's inbox on a Tuesday morning. The classifier's JSON and the route each one takes:
| Ticket (shortened) | category | priority | Route |
|---|---|---|---|
| “We were charged twice for October, please refund one” | BILLING | high | Billing handler |
| “The calendar won't load since the update, on every browser” | TECH_SUPPORT | high | Technical handler |
| “Do you have a guide for setting up a second location?” | GENERAL | low | General handler |
Each row also carries a one-line reason, which is what the support agent reads first when they disagree with a
category. The routing rules only look at category; priority travels with the ticket into the handler's prompt so
the draft can acknowledge urgency.
PROMPT or TEXT_CLASSIFIER?
The palette also has a TEXT_CLASSIFIER node, which takes the text and a fixed list of categories directly, with a low default temperature. It is the simpler choice when all you need is a label. Brightloom uses a PROMPT step because it wants the priority and the reason in the same answer.
Keeping a person in charge of the reply
Brightloom starts with drafts only: the agent's output is a suggested reply that a person reads, edits and sends. Two additions are worth making as confidence grows:
- A human step for high priority. Route high-priority tickets to a human input step that asks the on-call lead to confirm the category before anything else happens.
- A fallback for unclear tickets. If the classifier's reason is empty or the JSON is malformed, route to the general handler and mark the ticket for a person, rather than trusting a guess.
What Omar checks each week
- A sample of runs from Agent history: was the category right, and was the draft usable?
- Tickets a person re-categorised: are they the same kind each time? If so, the system prompt needs a clearer line for that category.
- Drafts sent with no edits, as a rough sign of which handler prompts are ready for more trust.
Writing the categories
The classifier is only as good as the definitions in its system prompt. Write each category as a short rule with an example or two (“BILLING: payments, invoices, refunds, plan changes”), say what to do with tickets that fit two categories, and ask for JSON only, with no explanation around it, so the routing step can read it every time. When the team keeps re-categorising the same kind of ticket, the fix is usually one more line in the definitions, reviewed like any other change.
Getting tickets in and drafts out
The agent starts from a ticket handed to it. The EMAIL_TRIGGER and WEBHOOK nodes accept an email or a webhook event passed in by the system that calls the agent; they do not watch a mailbox themselves. In practice the help-desk tool, or a small job that reads the inbox, calls the agent's execute endpoint once per ticket. On the way out, an HTTP_REQUEST step can post the draft back to the help desk as an internal note, so the support agent finds it on the ticket. Sending to the customer stays with the person.
Questions support leads ask
What happens when the JSON is malformed?
The routing step cannot read a category, so the ticket goes down the default route to the general handler. Add a check that marks such tickets for a person, as above, and look for them in history.
Can we add a fourth category?
Yes: one more line in the classifier's system prompt, one more rule in the routing step and one more handler. Review the change
in properties.yaml before it goes live.
Does the agent learn from corrections?
No. It does what its prompts and rules say. Corrections show up in history, and a person turns them into a clearer definition.
Adapting the pattern
Classify-then-route fits far more than support: inbound sales enquiries by product line, HR requests by policy area, invoices by cost centre, documents by type before extraction. Keep the classifier's output small and structured, keep the routing rules out of the prompt, and give each branch its own focused step.


