The owner was not mainly losing orders because replies were slow. People were using fake purchase intent to reach her directly, then turning a business conversation into harassment or unwanted personal contact.
The service verifies WhatsApp ingress, restores conversation state, loads the owner's published menu and operating rules, applies deterministic safety and order policy, and uses AI only inside those boundaries. A customer does not reach the owner just by saying they want to order. The owner console is reserved for qualified orders, legitimate support exceptions, ambiguous cases, and credible safety concerns.
Role
System designer and engineer
For
House of Gazelle pilot
Stage
Pilot
Walkthrough
Watch it run
Pilot walkthrough / 2 min 19 s / Silent, captioned on screen
Recreated chat and owner-console screens follow a genuine order, an order outside the published rules, and an abusive thread that receives no reply.
Conversation replay
Each conversation beside what the system decided
A customer asks for the menu and orders. The total comes from published prices and the order is not surfaced until it is complete.
Can I see your menu?
Here's the current verified Gazelle's Kitchen menu, with one meal for each ordering day and its price. Tell me what you'd like to order.
I want 2 plates of Jollof rice and Beefdo
Thanks. I have 2 × Jollof Rice & Beefdo for pickup. The current item total is ₦24,000. Pick-up is at the collection point the kitchen has published. Please reply with your full name so the team can confirm your order.
IngressSigned WhatsApp message accepted
FactsMenu and prices read from what the owner published
Rule2 × ₦12,000 = ₦24,000, worked out by rule
ReplyWorded by the AI layer inside the policy decision
OwnerNot surfaced yet: the customer's name is still outstanding
My part
What I built
Designed the conversation-state model for business chat, order qualification, support, warnings, silencing, human review, and closure.
Implemented signed WhatsApp ingress, normalisation, duplicate-safe processing, persisted state, guarded outbound delivery, and owner-facing exception handling.
Separated language generation from business authority so a model cannot qualify an order, expose the owner, or override a safety decision.
Built the mobile-first owner console around only the work that actually needs a person: qualified orders, support exceptions, safety review, and takeover.
Expanded validation with deterministic simulations, generated conversations, fuzzed sequences, and production-mode smoke checks.
Decisions
The choices that shaped it
Purchase intent is not owner access
The core invariant is that saying 'I want to order' is insufficient. A conversation reaches the owner only after deterministic qualification is complete or a legitimate support or safety exception requires human judgement.
Policy owns authority, AI owns wording
The model can help interpret and phrase a response, but application code owns order completeness, owner surfacing, safety state, takeover state, and whether any outbound message is allowed.
Personal threads stay outside the model by default
Greetings, personal chat, and clearly off-purpose messages are handled by deterministic policy. This reduces needless engagement and avoids sending sensitive conversation to a model unless the configured policy explicitly allows it.
Owner controls are a separate trust boundary
The customer-facing assistant cannot silently mutate published menu or operating rules. The owner publishes those facts and handles exceptional cases through an authenticated console.
Retries cannot become duplicate business actions
Inbound and outbound processing uses duplicate-resistant records and bounded retry behaviour so webhook redelivery or a crash does not create duplicate replies or repeated owner work.
What has been shown to work
A production-mode smoke test on a fresh database verified health, owner-console delivery, Meta verification, a signed menu request, and a personal message that produced no reply.
The merged pilot includes a 39-message personal-chat corpus that must produce no reply, no draft, and no owner task.
The current hardening branch reports 881 of 881 tests passing across 700 simulated conversations and 2,392 conversation steps, including 390 generated or fuzz scenarios.
Tests cover order mutation rules, threats, owner takeover, duplicate delivery, stale outbound messages, per-contact ordering, and business-rule enforcement.
The real-number Meta acceptance checks remain a release gate, so this case study does not present the pilot as a fully completed public rollout.
Current stage and limits
The core pilot is merged and deployable, while the current hardening branch and reduced real-Meta acceptance checks are still in progress.
Payment evidence review must never be treated as proof that money settled in a bank account.
This public case study omits credentials, private prompts, customer records, operational thresholds, and owner-only runbooks.
Screens
From the product
The owner is behind a deterministic qualification and safety gate, not behind a conversational prompt.
Technical detailOpen the system view
SYSTEM ARCHITECTURE
Owner gate for a WhatsApp ordering line
Signed WhatsApp messages are normalised, ordered per contact and checked against the owner's published facts and deterministic order and safety policy. The AI layer only words replies inside that decision, and the owner console receives qualified or explicitly escalated work.
actorWhatsApp contact
Genuine customer, off-purpose chat or abuse
controlSigned ingress
Signature check, normalisation and deduplication
dataConversation state
Per-contact ordering, stage and takeover
dataPublished facts
Owner's menu, windows, fulfilment and boundaries
controlOrder and safety policy
Deterministic qualification and containment
workerAI wording layer
Classification and phrasing inside policy
serviceGuarded outbox
Duplicate-safe, stale-aware delivery
interfaceOwner console
Qualified orders, exceptions and safety review
01WhatsApp contactmessageSigned ingress
02Signed ingressverified eventConversation state
03Published factsauthoritative rulesOrder and safety policy
04Conversation statecontextOrder and safety policy
05Order and safety policyallowed reply scopeAI wording layer
06AI wording layerproposed wordingGuarded outbox
07Order and safety policyqualified or escalatedOwner console
08Guarded outboxreply or silenceWhatsApp contact
Security and privacy
WhatsApp webhook signatures are verified before processing.
House of Gazelle data is isolated in a private server-only database schema with no anonymous or authenticated client access.
The assistant is prohibited from exposing the owner's personal life, location, relationship status, or private contact information.
Generic server errors, bounded input handling, rate limits, and audit records reduce accidental data leakage and make exceptional actions reviewable.
Built with
Node.jsTypeScriptFastifyPostgreSQLSupabaseWhatsApp Cloud APIRailwayStructured AI classification
Work with me
If you are planning something similar, a 30-minute consultation covers feasibility, suitable tools and next steps. From $25.