Chat and knowledge

How the AI agent works

How the AI answers from your knowledge, when it asks a question or hands off, how it handles abuse, and how to tune it.

The AI agent answers customers in the chat using only your knowledge. It searches, answers with what it found, asks one clarifying question when a detail is missing, and offers your team when it can't help. You shape its tone and boundaries under AI agent.

Answers come from your content

  • For each question, the agent searches your knowledge (it may search up to three times with different wording) and answers from the passages it found.
  • An answer must cite the passages it used. An answer that doesn't cite your content is thrown away before the customer sees it, and the customer is offered your team instead. The agent never invents features, prices, policies or links.
  • Pinned answers are your team's official wording and win over other passages when they disagree.
  • It replies in the customer's language.

Clarifying questions

When a needed detail is missing (which plan, which device, an order number), the agent asks one short question. It never asks two in a row: after one, it answers with what it has or offers your team.

Handing off to your team

The agent asks before handing off:

  1. When it can't answer, it says so and asks whether the customer wants the question passed to your team.
  2. If the customer says yes, the conversation goes to your inbox right away.
  3. If the next question can't be answered either, it hands off automatically. The customer is never stuck in a loop.

A customer who asks for a person ("talk to a human", "can I speak to someone", or the same in Spanish, French, German, Italian or Portuguese) is handed off immediately, as is anyone who clicks Talk to a person in the chat.

On hand-off, the AI writes a short summary for your team, the conversation is marked Needs reply, and your team gets an email. After a hand-off the AI keeps answering what it can until someone from your team replies. From then on it only answers a new question about your product that your knowledge covers, with its sources. Anything else (a follow-up on your teammate's reply, the customer's own account, payment or order, or a question your knowledge doesn't answer) waits for your team, and the customer gets a short "the team has your conversation" note at most every 10 minutes. It never replies to a "thanks" after your teammate's answer. Those turns don't count as AI answers. Outside business hours, the hand-off message tells the customer when your team is back.

Small talk

"Hi", "thanks" and "bye" get a friendly reply without an AI call, and don't count against your answer allowance.

Abuse and spam

  • Abusive messages get one calm reply asking to keep it respectful. Swearing about a problem ("this damn export") isn't treated as abuse.
  • Spam (3 or more links, the same message three times in a row, keyboard mashing) gets a short reply.
  • After 3 abusive or spam messages in a conversation, the AI stops replying, the conversation is closed and marked Abusive, and the visitor can't send messages for 24 hours.
  • Abuse never emails your team, and a chat closed for abuse doesn't ask for a rating.

Prompt injection

Customer messages and your content are treated as data, not instructions. Attempts to change the agent's instructions, make it reveal them, or make it act as something else are flagged and ignored, and it never reveals its instructions or your settings.

Tune it: guidelines, guardrails and scenarios

Under AI agent:

Setting What it's for Limits
Response guidelines Tone and style. Empty: warm and direct, two to four short sentences. 2,000 characters
Guardrails Things it must not do or talk about, one per line, for example "Don't compare us with competitors". 30 lines, 300 characters each
Scenarios Playbooks: a name, when it applies, and what to do, for example "Refund requests". 20 scenarios

Your settings never override the core rules: answer only from your content, cite it, stay safe, and hand off when asked.

How was this answered?

Every AI reply in the inbox has a How was this answered? link showing what the agent searched, which passages it found and cited, any lookups it ran, and why it decided what it did. Use it to find missing knowledge.

Usage and limits

Limit Default
AI answers per app per day 500. Change it under Settings → Security.
AI answers per month, across all your apps Starter 1,500, Pro 7,500

One customer question counts as one answer, however many searches it takes. Pinned answers, small talk, and the same first question answered again within 7 days (from the answer cache, until your knowledge changes) don't count. When the allowance runs out, new questions go straight to your inbox until the month resets.

Test it

Try the chat on your help center, or use the Ask it a question step in Setup. The Start over button there forgets the test conversation so you can try again as a new visitor.

With your coding agent

  • get_agent_settings and update_agent_settings (guidelines, guardrails, scenarios)
  • test_question runs the real agent on a question and returns its answer, sources and full trace, without creating a conversation:
    npx pandadesk test_question --question "Can I get a refund after two weeks?"
    
  • search_knowledge shows which passages the agent would find.

See also Lookups to let the agent fetch a signed-in customer's own data.

View as Markdown