Inspiration to come

Medical students learn a lot of medicine, but they get little practice talking to patients. Taking a history, calming a worried parent or getting a smoker to talk about their habits are skills you only learn by doing. Practice with actors as patients is expensive, hard to schedule and rare. We wanted every student to have a patient available any time, one who reacts like a real person.

What it does

MediMe lets medical students run real consultations with AI patients by voice, like a video call.

  • Before the call, the student opens the patient's file, just like a real doctor: old letters, lab results, X-rays, CT scans, ECGs and PDFs from earlier visits.
  • During the call, the patient talks in real time, each with their own personality, accent and mood. Thomas Brandt is a sarcastic Neapolitan smoker who plays down his cough. Aylin Demir is a worried mother of a baby with breathing problems. Patients only share some facts when the student asks the right question or earns their trust, as real patients do.
  • Brandt appears as a 3D avatar. His lips follow his voice, and his face and hands show his mood: angry, shy, worried, relieved.
  • During the exam, the student can ask for findings and see images or hear lung and heart sounds.
  • After the call, the student gets a score and clinical feedback, like an OSCE examiner would give: which key facts they found, which checklist steps (Calgary-Cambridge) they covered, and the three most important things to improve.
  • Progress shows which cases are done and which skills are improving. Students can share a session with a tutor for review.

How we built it

  • Frontend: Next.js, TypeScript and Tailwind.
  • Backend: FastAPI (Python).
  • Data: Every patient is a knowledge graph in Neo4j: personality, languages, medical history, documents, and facts with a disclosure rule (volunteered, only when asked, only after trust). Before the call, the graph is turned into the patient's prompt, so there are no lookups and no lag during the conversation.
  • Voice: the OpenAI Realtime API over WebRTC, so the patient answers with low latency.
  • 3D avatar: TalkingHead (three.js) in the browser. Lip sync comes from analysing the live audio stream. A small, fast text model reads each answer in parallel and picks the mood, gesture and facial reaction, so the voice is never delayed.
  • Grading: a separate model compares the conversation with the case's hidden solution and a weighted checklist. The voice model never sees that solution.
  • Patient files: we built an importer that turns case packages into patients: it generates PDF reports, fixes the dates on images and creates synthetic lung and heart sounds.
  • Running it: everything runs locally in containers with Podman (Neo4j, API, web).

Challenges we ran into

  • Keeping secrets: a patient that tells everything in the first minute is useless for training. We had to control exactly when and how facts come out.
  • Avatar emotions: our first version let the voice model control the face, and it either ignored the face or delayed its answers. We moved body language to a second model running in parallel. We also had to tune the faces by hand so that "angry" didn't look like pain and "shy" didn't look surprised.
  • Feedback: a doctor tested MediMe and found the feedback too harsh and too focused on emotions. We rebuilt the grader around clinical content and made sure steps that didn't apply no longer counted against the student.
  • A consistent patient history: the patient's memory, their documents and the images all had to match. An X-ray dated this year can't appear in a file from 2022.

Accomplishments that we're proud of

  • Tested by a medical student: they passed the Thomas Brandt case with a score of 72, rated MediMe 9 out of 10, and were really happy with the feedback and said they learned a lot.
  • A patient with a real personality who can be funny, defensive or scared, and who changes when the student shows empathy.
  • A 3D avatar that talks and shows emotions live in the browser, with no game engine.
  • Feedback that is clinically useful. In our tests, a thorough consultation scored 83 to 94 and a rushed one scored 10.
  • Full patient files with real-looking documents, scans and sounds that tell one consistent story.

What we learned

  • Realism comes from the details: what the patient hides, how they react and what they remember from their past.
  • Splitting the work between models (one voice, one body language, one grader) works better and faster than one model doing everything.
  • Feedback from real doctors and students changed our product more than anything else.
  • Structuring the patient data as a knowledge graph keeps the patient consistent and makes new cases easy to add.

What's next for MediMe

  • 3D avatars for every patient, with models that match each patient's age and look.
  • More cases and specialties: breaking bad news, informed consent, psychiatry, emergency medicine.
  • German and English patients with different language levels, for practice with patients who speak little German.
  • Exam mode for universities, so tutors can run OSCE-style assessments with MediMe.
  • Testing with more doctors and students to make the grading match real examiners.

What's next for MediMe

  • 3D avatars for every patient, with models that match each patient's age and look.
  • More cases and specialities: breaking bad news, informed consent, psychiatry, emergency medicine.
  • German and English patients with different language levels, for practice with patients who speak little German.
  • Exam mode for universities, so tutors can run OSCE-style assessments with MediMe.
  • Testing with more doctors and students to make the grading match real examiners.

Built With

Share this project:

Updates

Submission history