Workflow · Production

Duolingo Roleplay: multi-prompt LLM orchestration for personalized language practice

The problem

A naive single prompt telling an LLM to practice a language with a learner does not produce a targeted, level-appropriate, or structurally satisfying learning experience.

Workflow diagram · grounded in source
1
Learner starts Roleplay session
trigger
“When you progress through a Roleplay session in Duolingo, you're having a back-and-forth conversation with one of our world characters.”
2
Narrator opens and structures session
ai_action
“The narrator sets the scene, communicates the objective, steers the conversation back to the objective at hand, and ties the conversation in a nice bow at the end. Narration adds structure by giving the conversation a beginning, middle, …”
3
Flow chart selects specialized prompt
routing
“You can think of the "rules" governing which Oscars take over the conversation at a given time as an intricate flow chart. Some Oscars can only speak after the narrator says something, others only after you've given a response, and other…”
4
Context injected into selected prompt
integration
“Every prompt is injected with a scenario that sets the scene. This includes the setting, the character's role, what the character wants to do, and a learning objective appropriate for your CEFR level.”
5
Specialized prompt generates response
ai_action
“every time Oscar responds in your conversation, a different prompt is controlling what he says. Each separate prompt is hyper-focused on crafting a very specific type of response for Oscar. For instance, one prompt is optimized for formi…”
6
Transcript passed for continuity
integration
“each time he transfers you to another Oscar, he provides a transcript of the conversation so far. This way, the Oscar you're talking to knows exactly where you are in the conversation”
Reported outcome

Duolingo's Roleplay feature uses a multi-prompt LLM architecture to deliver targeted, CEFR-aligned, character-consistent language practice that dynamically adapts to whatever the learner says.

Reported metrics
Language learning experience qualitytargeted, delightful, and useful language learning experience
Learner experience improvementmore entertaining, more personalized, and most importantly, more effective
Reported stack
LLMs
Source
https://blog.duolingo.com/chatbot-language-practice/
Read source ↗

Frequently asked questions

What did this team achieve with this AI workflow?

Duolingo's Roleplay feature uses a multi-prompt LLM architecture to deliver targeted, CEFR-aligned, character-consistent language practice that dynamically adapts to whatever the learner says.

What tools did this team use?

LLMs.

What results were reported?

Language learning experience quality: targeted, delightful, and useful language learning experience; Learner experience improvement: more entertaining, more personalized, and most importantly, more effective (source-reported, not independently verified).

How is this workflow AI workflow structured?

Learner starts Roleplay session → Narrator opens and structures session → Flow chart selects specialized prompt → Context injected into selected prompt → Specialized prompt generates response → Transcript passed for continuity.