Lola Send is a conversational AI platform that enables financial institutions to deploy intelligent agents on messaging channels. Built on Celai, the platform processes inbound messages through an ordered middleware pipeline, routes conversations to the appropriate agent based on sender state, and delivers formatted responses back through the originating channel.
The application is stateless by design — session state and conversation history live in Redis, identity and compliance data live in backend services. This separation enables horizontal scaling and ensures no sensitive data persists in the application layer.
Architecture layers
| Layer | Technology | Purpose |
|---|
| Framework | Celai (proprietary) | Message gateway, agent orchestration, middleware pipeline |
| Channels | WhatsApp, Telegram, Chatwoot | Messaging connectors — pluggable |
| AI models | Google Gemini (Vertex AI), OpenAI | Agent reasoning, response refinement, message enhancement |
| State | Redis | Session state, conversation history (stateless app) |
| Middleware | Auth, contact decoding, commands, Chatwoot | Pre-processing pipeline before agent routing |
| Security | JWT (EC keys), HMAC, AES encryption, Doppler | Auth, callback integrity, secret management |
| Deployment | Docker (non-root), Railway | Containerized cloud deployment |
Message flow
Every inbound message follows the same deterministic path through the platform:
-
Channel reception — A sender’s message arrives via WhatsApp webhook and is received by the
WhatsappConnector, which normalizes the payload into Celai’s internal message format.
-
MessageGateway — The central HTTP server accepts the normalized message and passes it into the middleware pipeline.
-
Middleware pipeline — The message flows through an ordered chain of processors:
CommandsAuthMiddleware — intercepts and authorizes slash commands
PayhubAuthMiddleware — authenticates the sender by phone number and injects identity into message metadata
ContactDecodingMiddleware — normalizes contact information
ChatwootMiddleware — syncs the conversation to Chatwoot for human agent visibility and handoff
-
LogicRouter — Evaluates the sender’s identity and compliance status to select the appropriate agent: onboarding, sender home, blocked, pending CIP, or service unavailable.
-
Agent processing — The selected
MacawAssistant processes the message using its system prompt, AI model, and declared tool functions. Tool functions retrieve all factual data — quotes, recipients, operations — from backend services. The model never generates this data.
-
Message enhancement — The agent’s response passes through the Gemini-powered message enhancer, which formats the output with WhatsApp-specific styling (bold, lists, spacing).
-
Channel delivery — The
WhatsappConnector formats the enhanced response for the WhatsApp Business API and delivers it to the sender.
Lola Send does not make compliance decisions — it orchestrates the conversational flow and routes senders based on verdicts returned by the bank’s compliance services.
Bank control points
Financial institutions retain direct control over the following aspects of the platform:
| Control point | What the bank configures |
|---|
| Agent prompts | System prompts that define agent tone, behavior, and conversational boundaries |
| Tool availability | Which backend service calls each agent can invoke |
| Middleware ordering | The sequence and composition of the pre-processing pipeline |
| Channel allowlists | WhatsApp number allowlists for controlled rollouts and phased deployments |
| Escalation triggers | Conditions under which a conversation routes to a live human agent via Chatwoot |
| Chatwoot handoff rules | How and when conversations sync to the omnichannel dashboard |
| LogicRouter rules | Agent selection criteria based on sender state and compliance status |
AI model strategy
Lola Send uses a multi-model architecture where each model serves a specific, bounded role:
| Role | Model | Provider | Purpose |
|---|
| Agent reasoning | GPT-4o | OpenAI | Primary conversation logic and tool invocation |
| Response refinement | GPT-4.1 | OpenAI | Blend model for tone, clarity, and brand consistency |
| Message enhancement | Gemini 2.5 Flash Lite | Google (Vertex AI) | Language detection and structured output formatting |
Gemini powers the message enhancement pipeline — the last stage before responses reach the sender. It runs on Google Cloud Vertex AI, which supports VPC Service Controls to keep all inference traffic within the bank’s GCP perimeter. No conversation data leaves the controlled network boundary during enhancement.
The bank can configure model selection per agent via MacawSettings and select the enhancement model independently. Model provider choices are driven by data governance requirements — not locked to a single vendor.
The bank can modify agent behavior by updating system prompts and tool availability without changes to application code. This separation of configuration from logic enables rapid iteration on conversational flows.