Build AI Patient Simulation: Lessons from Encountive
How Encountive Was Built: Real-Time AI Patient Simulation for Nurse Education
Notes from my conversation with Douglas Tully, Co-founder and CIO of Encountive, on vibe coding, AI safety, enterprise sales and mentorship
▶ Watch the full episode on the Codersarts Podcast
Founders in healthcare, education and corporate training keep asking us the same question: "Can we build an AI that people can actually practice with, not just chat with?"
A generic chatbot is not enough for that. A training simulation has to stay in character, respond as fast as a human would, follow the rules of the profession, and then tell the learner exactly what they did right and wrong, measured against an accepted standard.
Get any of those wrong and the product either feels fake or teaches the wrong thing.
Douglas Tully (Doug) has built exactly that. Doug spent 24 years at Hewlett Packard Enterprise, finishing in North America AI Strategy, and has more than 30 years in banking, telecom and enterprise systems, including running AOL's login database and mail routing. Today he is co-founder and CIO of Encountive, a browser-based platform where nurses talk to lifelike AI patients and an AI "preceptor" scores each conversation against industry rubrics. The product already runs five programs, is expanding beyond nursing, and is in proof-of-concept with its first customers.
In this post I break down how it was built: the persona design, the voice latency problem, the evaluation layer, model choice, security, cost, and how Doug is taking it to market. The same pattern works for any role-play training product: sales calls, customer support, interviews, compliance, therapy practice, legal intake.
Note: Encountive is an education and training tool that uses artificial patient data. Nothing in this post is clinical advice or a claim about patient outcomes. AI simulations support, not replace, accredited training and qualified educators.
Key takeaways
One small team, years of work: Doug estimates that without AI-assisted development, what they built would take five people three to four years.
Latency is the product: a competitor's demo took four seconds to reply. Encountive shrinks the speech model's context and runs a separate model for speech to keep replies near-instant.
Scoring against rubrics, not opinions: every session is transcribed and an AI preceptor evaluates it against established nursing rubrics, so feedback is consistent and checkable.
Model independence: Claude, OpenAI and Gemini are wired in and can be switched with a single setting.
Cost control: open-source models run in-house where possible; frontier-model spend is still about $1,200 a month across all of Doug's products.
Never use AI for math: calculations, measurements and balances belong in normal code.
1. The problem: nurse training that doesn't scale
Traditional nurse simulation relies on hired actors. Each actor is given a condition ("you have diabetes and hurt your foot"), flown to a site, and nurses act out the encounter. While nurses train, someone has to cover their shifts. It is expensive, hard to schedule and limited to whatever the actor remembers about the condition.
Meanwhile, demand is rising. Doug pointed to survey after survey showing a growing crunch in upskilling nurses as the baby-boom generation ages and needs more care.
Encountive turns the encounter into software. The very first lesson puts the learner on the phone with Margaret Ellis, a patient who has been waiting on hold. The conversation is live and spoken. A common way to fail the very first lesson: not verifying the patient's name and date of birth before discussing her health, which HIPAA requires.
Because it runs in a browser, a nurse can practice for 15 minutes at a time, at home or at school, repeat a lesson from scratch as often as needed, and do it without classmates watching.
What it means for your product: if your industry trains people with role-play, actors or shadowing, the cost and scheduling pain is your business case. Start by mapping one real encounter end to end: who speaks first, what must happen, what counts as failure.
2. Build vs reuse: move fast, then buy what the market ships
Encountive started with the CEO, an experienced nurse educator who had run physical simulation labs, building prototypes with vibe coding. Doug joined to turn those prototypes into a real AI product with integrations and live speech.
Doug was candid about how fast the market moved. More than once, they started building a component and a week or two later a vendor released the same thing. His rule now: if a tested product or open-source option exists, use it instead of paying the pain of building and debugging it yourself. Build only what makes you different.
They also chose US-first instead of global from day one. Spelling (color vs colour), speech patterns and even drug names differ between the US and the UK because of how trademarks and licensing work. Getting one market right before localizing avoids teaching the wrong terms.
What it means for your product: decide early which parts are your edge (personas, scoring, domain content) and which are commodity (speech, auth, hosting). And pick one market's rules and vocabulary first; localization in regulated domains is real work, not a translation step.
3. Designing AI patients: scaffolds plus personality
Every Encountive patient starts from the same markdown "skeleton": the basic framework, infrastructure and connectivity. On top of that the team adds the case: the condition, symptoms and history, and the character traits.
Personality matters. Margaret Ellis has a cat. You only learn that if the conversation goes there, which is exactly how real patients behave. A generic AI model has no personality; a good simulation needs one.
Doug highlighted one advantage over actors: the AI patient carries the full symptom profile of its condition, so it can give a learner more consistent and more complete information than an actor who may forget details.
Because each module is built from the same skeleton, a fix found in one module can be applied everywhere. And schools can extend the library themselves, building new patients on the same tested framework instead of starting over.
The range goes well beyond routine care. Encountive's hospice program trains nurses for the opposite of usual care: keeping a patient comfortable rather than prolonging life, handling families with different cultural and religious practices around death, and dealing with relatives who want everything done.
What it means for your product: treat personas as structured, versioned content, not one-off prompts. A shared scaffold plus case-specific layers lets you add cases fast, test them consistently and let customers author their own.
4. The engine: real-time voice without the uncanny pause
This is where most AI simulations fail. Doug watched a competitor's demo, in a controlled environment, where he could say hello and count four seconds before the AI answered. No person waits four seconds to respond, so the illusion breaks immediately.
His explanation: large context windows are attractive because you don't have to keep feeding information in, but more tokens in and out means more latency.
Encountive deliberately keeps the context small for the live conversation and runs two models side by side: one tuned for speech, one for regular processing. Settings such as temperature are tuned per model.
A simplified flow of a session:
Learner's browser (voice)
-> SaaS application
-> Speech model (small context, low latency)
-> Patient persona (markdown scaffold + case + personality)
-> Live transcript
-> AI preceptor (evaluation model)
-> Rubric score + feedback
-> Learner record (stored under a learner ID)
What it means for your product: in any voice product, set a latency budget before you pick a model. Split the real-time path from the heavy reasoning path, keep the live context tight, and measure response time in realistic conditions, not demos.
Have conversation data or training scenarios already? We can run a short feasibility check: build one persona, test it on your real scenarios, and measure latency and accuracy before you commit to a full build. Talk to Codersarts
5. The preceptor: feedback you can trust
After the conversation, an AI preceptor reads the full transcript and evaluates how the learner handled it: what they missed, what they did well, and where they made mistakes. Scores are validated against rubrics that are already established in nursing education, which is how the team keeps feedback medically accurate.
The preceptor is also interactive. Learners can ask it follow-up questions, so it acts like the mentor who would normally debrief them after a simulation. Doug's point about learning in general applies here: a video can teach you a skill, but you also need someone to tell you, "this is where you went wrong, and here's how to fix it."
As models improve, the team plans to add deeper medical content to this layer.
What it means for your product: evaluation is what turns a chatbot into a training product. Anchor scoring to an external standard (rubric, checklist, regulation), make each judgment traceable to a point in the transcript, and let learners question the feedback.
6. Model strategy: switchable, stable, and partly in-house
Encountive has the APIs for Claude, OpenAI and Gemini built in and can switch between them with a single setting. Doug's background in 24x7 banking and telecom systems shows: he tracks each provider's stability reports and ties the product to whichever is most reliable at the time. He uses these general frontier models because they have stayed ahead of more specialized ones.
The same persona script can behave slightly differently on each model because they are trained differently, but Doug says results stay consistent. The biggest cause of problems is not the model; it is prompts that are not clear enough.
He also runs open-source models in-house on a well-specced mini PC with a 2 TB drive, so any machine on his network can call them at no per-token cost. His caveats from experience:
Open source does not mean it will run on your hardware. Large models need serious memory and ideally a GPU.
Smaller models often lack features such as vision, voice or medical terminology.
Local models do not know current events and have no built-in search.
His tip for choosing one: describe your constraints to an AI assistant (open source, lightweight, needs voice or vision, your region's requirements) and ask which models fit.
What it means for your product: put an abstraction layer between your product and any single model provider from day one. Route routine work to cheaper or local models and keep frontier models for what needs them.
7. Production: SaaS delivery, security and cost
Delivery. Encountive is software as a service. Hospitals and schools often cannot install executables because of security policies, so a browser-based product removes a major buying obstacle. Augmented reality is next: the team is developing for Android XR headsets and XREAL glasses using WebXR, targeting the first half of 2027, with distribution through the Android app store.
Security and privacy. Encountive uses artificial patients, not real patient records, so it is not handling real patient health information. Doug treats learner data as sensitive anyway:
Learners are stored under generic learner IDs, and the database is keyed on those IDs rather than names
The team follows GDPR principles even though it is US-first, because it is simpler to meet the strictest common standard
HIPAA behavior is part of what learners are tested on (identity checks before discussing health)
Editor's note: replacing names with IDs is pseudonymization, not full anonymization; it should be combined with encryption at rest and access controls.
What stays out of AI. Doug's strongest rule: "The worst thing you can do is give it math." AI is fuzzy logic. Calculations, measurements, balances and business rules should be deterministic code. It is faster, costs nothing per call and cannot hallucinate.
Cost. Despite in-house models, Doug spends about $1,200 a month on tokens across all his products, which is why every call that can be local or deterministic should be.
Layer | What Encountive uses |
Delivery | Browser-based SaaS; AR (WebXR) in development |
Frontend development | Bolt, Lovable and Claude, all working on one GitHub repository |
Frontier models | Claude, OpenAI, Gemini, switchable with one setting |
Local models | Open-source models on an in-house mini PC |
Persona content | Reusable markdown scaffolds plus case layers |
Evaluation | AI preceptor scoring against nursing rubrics |
Data | Database keyed on learner IDs |
Testing | AI-generated regression tests created with each release |
What it means for your product: pick a delivery model your buyer's IT team can approve, design privacy in even when the law doesn't require it, and keep anything numeric or rule-based out of the model.
Already have an AI app that is slow, inaccurate or too expensive to run? We audit the prompts, model routing, latency and token spend, then fix what matters most. Talk to Codersarts
8. How a small team ships like a big one: vibe coding with discipline
Doug is a strong supporter of vibe coding, and very clear about its limits.
It can't see your whole system. An AI agent cannot reason across all the applications in a bank's lines of business, so you must design modular parts and handle integration yourself.
Scope your instructions. Ask it to fix an error on one screen without naming the screen, and it may change error handling across the whole app.
Error handling is the most common gap he sees in vibe-coded apps.
Read the code. Vibe tools hide the code on purpose, but the small details they hide cause the biggest bugs.
His controls: a full checklist for every build (did we review this, does it have proper error handling), reusable markdown files that carry guardrails across modules, AI-generated regression tests created at each release so they never need rebuilding, and written standard operating procedures for each tool. Developers can use Bolt, Lovable or Claude, whichever makes them fastest, because everything goes into the same GitHub repository and no single person is the only one who understands the code.
What it means for your product: vibe coding gets you to a demo fast. Getting to production takes engineering: integration, error handling, tests and review. That gap is where most AI-built apps break.
9. Go-to-market and lessons
Targeted outreach. Doug runs an AI agent that researches potential customers and gives him five a week, each with a briefing on whether the organization's activities fit. He reaches out to one a day and tracks everything in Google Sheets instead of a full CRM. His reasoning: spread a fixed budget across ten prospects and each gets little; focus on two and each gets five times more.
Look past the obvious buyers. Encountive targets nursing schools and also simulation centers, where hospitals and educators rent space to run scenarios.
POCs with a buying commitment. Every proof of concept has measurable success criteria and a written agreement: if it succeeds, the customer buys (price negotiated); if not, no commitment. Only serious buyers sign, and a successful POC becomes an internal reference. Encountive currently has three customers in this process.
Protect the idea. Get an NDA signed before you pitch. Encountive also filed a patent; Doug warned it is not cheap for a small company.
Practice the pitch. Local events such as 1 Million Cups let founders pitch weekly and get feedback before a real customer sees it.
Relationships still close deals. At HPE, a client gave Doug an employee badge. When projects came up, they called him before IBM or Dell. For large enterprises, he advises finding out who their preferred or prime vendors are and working through them.
What it means for your product: for B2B healthcare and education, structured POCs and a narrow, well-researched target list beat broad campaigns. Build the measurement into the product so the POC proves itself.
How to build an AI patient simulation: step by step
Pick one encounter and its standard. Choose a real scenario and the rubric, checklist or regulation that defines a good outcome.
Write the persona scaffold. A reusable markdown template for framework, behavior rules and connectivity, then a case layer with condition, history and personality.
Set a latency budget. Decide the maximum reply time (well under human pause length) before choosing models.
Split the pipeline. A small-context speech model for the live conversation; a separate model for transcript analysis and scoring.
Build the evaluator. Score the transcript against the rubric, link each judgment to the conversation, and let learners ask follow-up questions.
Add a model abstraction layer. Support at least two providers and route cheap tasks to local or smaller models.
Design privacy and access in. Pseudonymous learner IDs, encryption, browser-based delivery your buyers' IT can approve.
Pilot with measurable criteria. Run a POC with clear success metrics and a buying commitment, then expand the case library.
Readiness checklist
Area | Question to ask | Good answer |
Use case | Which exact encounter are we simulating first? | One named scenario with a defined pass/fail |
Standard | What does "correct" mean? | An external rubric or checklist, signed off by a domain expert |
Personas | Can we add cases without rebuilding? | Shared scaffold plus case layers, versioned |
Latency | How fast does the AI reply in real use? | Measured in realistic conditions, close to a human pause |
Evaluation | Can a learner see why they lost points? | Each score tied to a point in the transcript |
Models | What if a provider fails or raises prices? | Switchable providers behind one interface |
Math and rules | Is anything numeric decided by the model? | No; deterministic code handles it |
Privacy | What learner data do we store, and how? | Pseudonymous IDs, encryption, minimal personal data |
Delivery | Can the buyer's IT approve it? | Browser-based, no installation |
Quality | How do we stop regressions? | Automated regression tests with every release |
Sales | How do we prove value? | Time-boxed POC with metrics and a buy commitment |
Doug's advice on getting expert help
Doug's view is that no founding team knows everything. Four people can split the work early on, but as a company grows it needs mentors and experienced people who have done it before. He uses AI to cover areas where the founders lack experience, but he is clear that vibe coding does not replace someone who can read code, handle integration and get error handling right. His advice: find people who know more than you in the areas you're weakest, and offer your own expertise in return.
Build your AI simulation product with Codersarts
The Encountive pattern fits any field where people learn by practicing conversations: nursing and allied health, pharmacy, patient communication, customer support, sales training, hiring interviews, compliance and legal intake, hospitality and language learning.
At Codersarts we build AI agents, voice assistants, retrieval-based assistants and evaluation pipelines for clients worldwide. We can help you:
Paid discovery or POC: one persona, one scenario, measured latency and scoring accuracy, so you know it works before a full build
Full product build: persona scaffolds, real-time voice, evaluator, learner dashboard and admin authoring tools
Evaluation design: turning your rubric into consistent, explainable AI scoring, with test sets to keep it accurate
Production and security: model abstraction, cost routing, pseudonymous data design, browser delivery and monitoring
Rescue and audit: fixing vibe-coded or prototype apps that are slow, hallucinate, lack error handling or cost too much to run
Start a conversation: https://www.codersarts.com/contact
Explore our AI services: https://ai.codersarts.com
Connect with Douglas Tully
Douglas Tully is co-founder and CIO of Encountive, an AI simulation platform for nurse education. He spent 24 years at Hewlett Packard Enterprise, including two years in North America AI Strategy, and has more than 30 years of experience in banking and telecom systems. He has founded five companies, co-authored two books on applying technology to healthcare education, and wrote HPE's SQL best practices guide. He is based in Tampa, Florida.
Encountive: https://encountive.com
FAQ
What is an AI patient simulation? It is software where a learner has a live, usually spoken, conversation with an AI that plays a patient with a defined condition, history and personality. After the conversation, the system evaluates the learner's performance against a standard such as a nursing rubric.
Why not just use ChatGPT for role-play training? A general chatbot doesn't stay reliably in character, has no defined case, isn't tuned for low-latency voice and doesn't score you against a professional standard. A simulation product adds structured personas, a real-time speech pipeline, a rubric-based evaluator and learner records.
What data do I need to build one? You need well-defined scenarios (case details, expected behaviors, failure points) and the rubric that defines good performance, ideally reviewed by a domain expert. You do not need real patient records; Encountive uses entirely artificial patient data.
How do you stop the AI patient from giving wrong information? Keep each patient's facts in a structured case layer, keep the live context focused, test cases against expected answers, and have a domain expert review personas. Anything numeric or rule-based should be handled by code, not the model.
How much does it cost to run? It depends on usage, voice minutes and model choice. As one reference point, Doug spends about $1,200 a month on frontier-model tokens across all his products, while running open-source models in-house to reduce that bill. A discovery phase is the best way to estimate costs for your volume.
Should I fine-tune a model or use prompts and scaffolds? Most teams should start with strong prompts, structured persona scaffolds and a good evaluator on top of frontier models. Fine-tuning makes sense later, when you have enough reviewed transcripts and a stable, repeated task.
How do you make AI voice conversations feel natural? Control latency. Keep the live context small, use a model tuned for speech on the real-time path, move heavy analysis to a separate model after the conversation, and test reply times in realistic conditions.
How is the learner's performance scored? The conversation is transcribed, and an evaluation model compares it with an established rubric, flags missed steps (such as identity verification) and explains each finding. Learners can ask the evaluator follow-up questions.
Which AI model is best for this? There is no permanent best. Encountive supports Claude, OpenAI and Gemini behind one setting and picks based on stability and results. Building for switching matters more than the first choice.
Can I run the models on my own servers? Yes, for some tasks. Open-source models can run in-house, but you need enough memory and ideally a GPU, and smaller models may lack voice, vision or domain vocabulary. Most products combine local models with frontier APIs.
Which industries can use this pattern? Any field that trains through conversation: healthcare, pharmacy, customer support, sales, recruiting, compliance, legal intake, hospitality and language learning.
Can Codersarts build an AI patient simulation or role-play training product for us? Yes. Codersarts can build the personas, real-time voice pipeline, rubric-based evaluator and learner platform, starting with a paid discovery or POC on one scenario. We also audit and fix existing AI training apps. Contact us.
About the author
Jitendra Singh is the founder and CEO of Codersarts and host of the Codersarts Podcast, where he talks with founders and tech leaders about building real products with AI.
Connect on LinkedIn: https://www.linkedin.com/in/jitendra-singh-sofstack/
▶ Watch the full conversation with Douglas Tully
Want to be a guest on the Codersarts Podcast? Email jitendra@codersarts.com with your name, role and the topic you'd like to talk about.


Comments