AI-Powered SMS Chatbot for a Healthcare Lab Business
How we helped a healthcare company automate 80% of their customer support using GPT-4, RASA, and LangChain — deployed on AWS in weeks, not months.
80%
Queries Handled Automatically
24/7
Support Without Extra Headcount
3x
Faster Response Time
60%
Reduction in Support Costs
System Architecture

Full System Architecture

PMD Customer Support Chatbot
The Situation
PMD Healthcare, a growing lab business serving patients across the US, was spending thousands of dollars every month on a support team that answered the same questions repeatedly. Patients would SMS in asking about their test results, appointment slots, turnaround times, and general FAQs. The support team was burnt out, response times were slow, and the business was losing patients to competitors who responded faster. They needed a smarter solution — one that could scale without scaling headcount.
The Problem
The challenge was not just building a chatbot. They needed a system smart enough to understand natural language over SMS, handle complex real-world queries like rescheduling appointments, checking live order status, and retrieving turnaround times — and still fall back gracefully when it did not know the answer. Off-the-shelf chatbot tools could not handle this level of complexity or integrate with their existing management systems.
What We Built
We designed and deployed a custom AI chatbot on AWS EC2 that integrates directly with PMD's patient management system. When a patient sends an SMS, the SMS Gateway captures it and routes it to our RASA CALM intent classifier. If the intent is recognized, a specialized LangChain agent takes over and calls the right API to fetch live data. If it is unrecognized, a GPT-4 RAG pipeline using Chroma Vector DB generates a contextual, accurate response using past conversation history and the company FAQ knowledge base. Nothing falls through the cracks — every query gets a fast, accurate response.
How It Works
From SMS to smart response in seconds.
Patient Sends SMS
The patient texts a question from their phone. The SMS Gateway captures the message and forwards it along with the patient's phone number to our chatbot server running on AWS EC2. The phone number is used to retrieve conversation history and patient context for personalized responses.
Intent Classification
RASA CALM attempts to classify the intent of the message. If a known intent is detected — such as checking an appointment, asking about turnaround time, or querying an order — a specialized LangChain agent is triggered. If classification fails, RASA NLU runs as a secondary fallback layer.
Agent Takes Action
Purpose-built LangChain agents handle specific tasks by making real API calls to PMD's management system. This includes rescheduling appointments, checking order status, retrieving test result availability, and providing turnaround time estimates — all in real time.
RAG Handles Unclassified Queries
For anything that falls outside defined intents, GPT-4 generates a contextual response using a RAG pipeline. The pipeline queries Chroma Vector DB which is indexed with the company's FAQ knowledge base, past conversation history, and relevant documentation to produce accurate, human-quality answers.
Response Delivered in Seconds
A clean, accurate SMS response is sent back to the patient within seconds of their original message. Full conversation context is logged and stored for future interactions, enabling the system to get smarter with every exchange.
Tech Stack
FAQ
Common questions about this project
How long did it take to build and deploy?
The full system — including RASA training, LangChain agent development, AWS deployment, and management system integration — was delivered in under 6 weeks from kickoff to production launch.
Can this work with any SMS provider?
Yes. The architecture is SMS-provider agnostic. We built it with Twilio but it can be integrated with any SMS Gateway that supports webhooks, including AWS SNS, Vonage, and MessageBird.
What happens when the bot does not know the answer?
The RAG pipeline powered by GPT-4 handles unknown queries using the company FAQ knowledge base and conversation history. If confidence is still too low, the system gracefully escalates to a human agent rather than giving a wrong answer.
Is patient data secure?
Yes. All data is processed and stored on AWS EC2 within a private VPC. No patient data is sent to third-party services. The system is designed with healthcare data privacy requirements in mind.
Can this be built for other industries?
Absolutely. The same architecture — SMS Gateway, intent classification, LangChain agents, and RAG fallback — can be adapted for any business that handles high-volume customer queries over SMS, WhatsApp, or email.
From The Client
What PMD Healthcare has to say
"Innovex Solution transformed our patient communication completely. The AI system now handles SMS inquiries instantly with accurate responses, reducing our staff workload significantly and improving patient satisfaction."
Dr. Cynthia Roldan
Sinai PICU/Peds Practice, Maryland
Ready to automate your business?
This is what we can build for you.
If your team is spending time on tasks a smart system can handle, we should talk. Book a free call and we will show you exactly what is possible.