Skip to content
Try Free →

Guidance rules

Last updated: · 4 min read

What a guidance rule is

A guidance rule is a short, categorized instruction that only applies when its channel and audience conditions match. It layers on top of general guidance, the free-text block that applies to every conversation on every channel.

Both live in the same place: open AI Agents, and General guidance sits above Targeted rules. General guidance is best for instructions that always apply. Targeted rules are best for anything that should only apply on WhatsApp, only for a specific visitor plan, or only for a segment tagged with a custom attribute.

Categories

Every rule is tagged with one category, mostly to keep the rule list organized and to label the rule section when it is added to the prompt:

  • Tone. How the agent should sound.
  • Clarification. When and how the agent should ask a follow-up question before answering.
  • Content. What facts, policies, or offers the agent should or should not state.
  • Escalation. When the agent should hand the conversation to a human.
  • Other. Anything that does not fit the categories above.

Categories do not change enforcement. A rule in any category is matched, ordered, and capped the same way as any other rule.

Channel and audience targeting

Leave a rule channel list blank to apply it everywhere, or restrict it to specific channels: widget, WhatsApp, Telegram, Slack, Discord, SMS, voice, and API are selectable in the rule editor today. The API accepts up to 13 channel values per rule and does not validate them against a fixed list, so a mistyped or unsupported channel value is saved without error and simply never matches.

Audience targeting narrows a rule further by the plan assigned to the visitor (the tier set for that visitor, not the AskVault plan on the account) and by a single custom attribute passed in with identify() on the widget or live chat. Visitor plan can also be set through the public API; custom attributes currently cannot. This is the same custom-attribute data the Automation rules "Custom attribute" condition reads, not the separate contact-level tag conditions. A rule with no audience filter applies to every visitor who matches its channel condition. Every guidance rule belongs to exactly 1 workspace, visible only to you and the teammates you invite to that workspace, never to another customer.

The order rules apply in

Enabled rules that match the current channel and audience apply in the order set in the rule list. Use the up and down arrows next to each rule to reorder it; rules at an identical position fall back to creation order.

That order becomes the deciding factor once the combined guidance is close to the character limit below: a rule near the top of the list is applied before AskVault ever checks whether a rule further down would have fit.

The 6,000-character limit

General guidance is always included in full. AskVault then adds matching rules, in the saved order, until the combined guidance block reaches 6,000 characters.

The first rule that no longer fits is dropped, along with every rule listed after it in the saved order, even a short one further down the list that would have fit on its own. Rules are dropped whole, never truncated mid-rule, because half an instruction can flip its meaning: a refund policy cut off after "unless" is a different policy than the one that was written.

Anyone relying on a rule near the bottom of the list should keep general guidance and higher-priority rules concise, or move the rule that matters most closer to the top.

General guidance alone can crowd out rules more than it looks. At the 4,000-character general guidance maximum, under 1,800 characters remain in the 6,000-character budget for rules, less than one maximum-length (2,500-character) rule. Keep general guidance well short of its maximum on any workspace that also relies on targeted rules.

Preview: see what will actually apply

Open the AI Agents page, scroll to Targeted rules, and click Preview. Pick a channel, an optional visitor plan, and an optional custom attribute, then run the preview to see the exact guidance block an agent would receive for that combination, plus the list of rules that matched, before a real visitor does.

Not yet enabled: a future update will have Preview call out any matched rule that did not make it into the final block because of the character limit, so you can shorten or reorder it ahead of time instead of finding out from a support ticket.

Common pitfalls

A long general guidance block leaves less room for rules. General guidance is never dropped, so a near-maximum general guidance block can push most or all targeted rules out of the 6,000-character budget.

A bulky rule near the top pushes out everything below it. Because the cutoff is a strict prefix of the saved order, one long, high-priority rule can silently drop every rule after it, including short ones that would easily have fit.

Leading markdown headings are stripped from rule text. Any leading # heading typed into a rule is removed automatically before it reaches the model.

Limits

  • Categories. 5: tone, clarification, content, escalation, other.
  • Rule text. Up to 2,500 characters per rule.
  • General guidance. Up to 4,000 characters.
  • Channels per rule. Up to 13 channel values via the API. Channel names are not validated, so a mistyped value is saved without error and simply never matches.
  • Combined guidance block. AskVault keeps adding matching rules, in order, until the block would reach 6,000 characters, then stops; general guidance is never trimmed to make room.

FAQ

What happens when guidance rules exceed the character limit?

AskVault keeps adding matching rules, in saved order, until the next one would push the combined guidance block, general guidance plus every matching rule, past 6,000 characters, then stops. The first rule that no longer fits is dropped whole, along with every rule listed after it, even a shorter one further down that would have fit on its own.

Can I see which guidance rules are actually reaching my AI agent?

Yes, through the Preview panel on the AI Agents page. It runs the same rule composer used in live conversations for a chosen channel and visitor profile, and returns the exact guidance block plus the rules that matched. Not yet enabled: a future update will also call out any matched rule that was dropped for space.

Does general guidance text ever get dropped to make room for rules?

No. General guidance is always included in full. Only channel- or audience-targeted rules compete for the remaining space in the 6,000-character guidance budget.

Can a rule apply to more than one channel?

Yes. Select any combination of channels in the rule editor, or leave the field blank to apply the rule to every channel.

Was this page helpful?