BestDealOn

Handbook › Callbots

Knowledge base

How the bot uses it

  • The voice instructions say to answer product and company questions only from kb_answer and product_search results. If nothing comes back, the bot says it doesn't know and offers a message (src/xai.js:115 [bdo]).
  • kb_answer searches local KB files. Each file can have front matter (title, source, aliases, type). Answers come back as passages with citations (src/kb.js:1-20). Spoken variants are normalized, so "Li-Fi" and "lie fi" match (src/kb.js SYN).
  • note_unanswered logs a gap. Gaps can be downloaded as /admin/kb-gaps.csv (src/app.js:474 [bdo]).

Two formats

FormatUsed byDoc
rfsafe-kbOut of scope (RF Safe)docs/KB_FORMAT.md
callbots-kb v1[bdo] any branded business. Template in kb/template/docs/KB_TEMPLATE.md; src/kbtemplate.js

callbots-kb v1 (the per-business template, [bdo])

Folder layout (kb/template/):

  • business.md
  • escalation.md
  • links.json (bare domains)
  • products-services.jsonl
  • pricing.jsonl
  • faq.jsonl
  • policies.jsonl

Rules (docs/KB_TEMPLATE.md):

  • kind is one of: business, product, service, pricing, faq, policy, escalation.
  • Every card needs a source, and that source must be on brand.kb_allow_domains.
  • Empty placeholder cards are rejected.
  • The bundle's tenant must match the tenant it is loaded into.
  • The position field is spoken as "<team name>'s answer: …".

Check and pack:

node scripts/kb-template.js check kb/<id>
node scripts/kb-template.js bundle kb/<id> <id> out.jsonl.gz

Upload: PUT /admin/tenants/<id>/kb-bundle (src/app.js:223 [bdo]). It is used only with the owner's approval.

Best Deal On KB today

  • kb/bestdealon/ [bdo] holds the cards plus 01-products.md, 02-audience.md, 03-get-started.md, 05-faq.md and 06-contact.md.
  • The tenant loads it with kb.dirs (deploy/bestdealon/tenants/bestdealon.json).
  • Pricing questions get "take a message" (commit 67ff802).
  • The draft source is at (Callbots workspace draft). Open questions for John: the tagline, prices, Promptinator, bizinator.ai sources, a sign-up link, business hours and transfers, and the script approval.

Open KB work

  • None tracked here for Best Deal On; see /admin/kb-gaps.csv.