Guide
A plain-English walkthrough of every section, how the pieces fit together, and the workflows you'll use day to day.
A user sends a DM on Instagram. ManyChat forwards it to our webhook. The intelligence layer:
- Classifies the message (intent + routing).
- If it's small talk (hello, thanks, bye…) → answers with AI.
- If it's a question → searches the Knowledge Base. A strong match (≥ 0.75 similarity) becomes an AI reply.
- Otherwise → returns a handoff message and
needs_human: trueso ManyChat can route it to a human.
Every message and every KB lookup is logged so you can audit and tune.
Live stats: total messages, KB articles, and a feed of the latest incoming DMs.
Use this as your daily heartbeat. If message volume drops to zero, the ManyChat External Request is probably misconfigured — check the Webhook page.
Every article the AI is allowed to quote. If it isn't in here, the AI won't answer it — it routes to a human.
Three ways to add knowledge
- New article — write a title and rich content manually. Best for FAQs and policies.
- From URL — paste a page (or enable crawl) and we fetch + clean the HTML. Each page becomes one article, all sharing a group tag (defaults to the hostname, e.g.
www.acp.pt). - Bulk upload — CSV or JSON with
title,content, and optionaltags.
Refreshing a website
Re-run From URL with the same link. Keep Replace existing group on (default) — we delete every article tagged with that group first, then re-ingest fresh content. No duplicates, no manual cleanup.
To refresh a single page only, use the circular ↻ button on that row.
Groups & tags
Groups are tags — there is no separate concept. The group tag is just the one shared across a crawl. Use the filter at the top of the table to view by group.
Test match
The right-hand panel lets you type any question and see which articles the semantic search would return, with similarity scores. Use it to verify coverage before going live.
Visual map of your groups: how many articles each one has and how they connect to routing.
A quick way to spot lopsided coverage (e.g. lots of website pages but no pricing article) or empty groups left over from old crawls.
Type a message exactly as a customer would. See the exact reply they'd get on Instagram, plus the classifier's reasoning.
This runs the same pipeline as the live webhook. Use it before publishing rule changes or KB updates — if the simulator gets it right, production will too.
Tip: test edge cases — complaints, vague messages, non-English text — and tweak rules or KB content until the route is what you want.
Force a specific route (ai_reply or human_needed) when a message matches a pattern. Rules win over the AI classifier.
Pattern types
- keyword — case-insensitive substring. Pattern
pricematches “what's the price?” and “PRICELIST”. - regex — a JavaScript regular expression. Use this for word boundaries and alternation, e.g.
\b(reclama|complain|refund)\b.
Priority
Lower number wins. A complaint rule at priority 10 beats a small-talk rule at priority 50.
Examples we seed by default
- Complaints (reclama*, refund, “péssimo”…) → human_needed
- Greetings, thanks, goodbyes (EN + PT) → ai_reply
You usually don't need a rule for “question about the website” — anything classified as a question automatically tries the KB.
Every incoming message with its classification, confidence and route.
Sort by route = human_needed to see what's slipping past the AI. Frequent misses are a signal you're missing a KB article or need a rule.
Semantic search history — what users asked, which articles matched, and the top similarity score.
Low top scores across many queries mean the KB doesn't cover those topics. Add or rewrite articles to fix it.
The endpoint ManyChat (or anything else) calls. Includes a playground and the expected payload shape.
In ManyChat, add an External Request step with:
- Method:
POST - URL:
https://acpconsole.lovable.app/api/manychat/webhook - Header:
Content-Type: application/json - Body:
{ "ig_user_id": "{{user_id}}", "text": "{{last_input_text}}" }
The response contains route, answer, and needs_human. Map them in ManyChat: send answer back to the user, and branch on needs_human to ping a teammate / set a tag.
Global knobs. Right now: the handoff message returned whenever a conversation routes to human_needed.
Keep it short, friendly, and set expectations (“Thanks! Someone from our team will reply shortly.”).