
An app that designs its own lessons
After six days in Valencia I could just about order two drinks. So I built El Pueblo: a Spanish app that invents its lessons, its game and its screens, for one learner.
Fabian Langer · · 5 min read
Yes, I was on holiday # link
Yes, I was on holiday. No, I couldn't help myself. After six days in Valencia, we could just about order two glasses of Agua de València, the local cocktail. That was about the limit of my Spanish.
So I built a personal app that teaches me Spanish. I started on my phone the day before the flight home, with Claude Code: an AI agent that writes and runs software for you, in this case from a chat on my phone.
I kept building in the hotel and at the airport. It's called El Pueblo, Spanish for “the village”. And it works like a charm.
What a lesson looks like # link
In El Pueblo I read and listen to Spanish and do exercises like matching and dragging words (the app talks to me in Dutch, the lessons are in Spanish). Every lesson ends in a conversation with someone from my own fishing village. Paco the fisherman, for example, who talks way too fast.
Good answers earn monedas de oro, gold pieces, and with those I build up the village. My casita is on level 2, and I'm still 63 gold pieces short of level 3. When I pronounce a sentence well, the building time is cut in half.
Every day a treasure chest opens if I write out three sentences from earlier lessons, from memory. That's not a gimmick: pulling something out of your memory is one of the most effective ways to learn it, known as retrieval practice.
And the words I keep getting wrong come back, again and again, until they stick. After each lesson I give a bit of feedback, and the next lesson takes it into account.
It invents its own next lesson # link
The interesting part is under the hood. El Pueblo makes up its own next lesson. Paco who talks too fast? The app came up with him itself.
It works like a loop. I play a lesson, and the app keeps a log: what went well, what didn't. Claude reads that log with two skills, written instructions an AI agent picks up when it needs them. One is the teach skill by Matt Pocock,6 the other is my own, for game elements.
Then it builds a new version of the app: precisely what I need to learn now, in the form I enjoy. The game elements are chosen by the AI itself, based on the mechanics that make pay-to-win games so addictive. Only here they work for learning. I call it learn-to-win.
I'm not fluent yet. But I've practised every day.
Just hard enough # link
The goal is not just that I come back. The goal is that I keep doing something just beyond what I can do yet.
In educational psychology that's called the zone of proximal development: not so easy that you're bored, not so hard that you give up. The teach skill is built around it.
How hard is right? Research suggests learning goes fastest when you get about 85% right.1 Duolingo works on the same idea: its model predicts how likely you are to get each exercise right, and uses that to tune the difficulty.2
Doesn't Duolingo do that too? # link
Partly. I recently saw a reel of someone who had taken the Duolingo app apart with AI. That's possible now: with an open-source project like Reverse Engineer Anything, an AI agent reads an app's binary code and explains how a feature works.4
What you see there is machine learning that is very cleverly tuned to bring you back. Duolingo has published on this itself: an algorithm picks which reminder you get.3
Impressive, but a different kind of AI. There, a model chooses from fixed exercises in a fixed interface. In El Pueblo, agents decide what I need and what the experience should look like to get me there. The interface isn't fixed: they design it per lesson, for me.
One app, one person # link
This is the trend in software and AI that intrigues me most right now: generative UI. AI that designs the interface itself, the screens, buttons and steps, per person and per moment.
Jakob Nielsen describes the road there:5 first we designed for target groups, then for personas, then we personalised the content. The last step is individualisation: not one app for millions of people, but an app that shapes itself to one.
I'm not the only one exploring this. ChatGPT, Gemini and Claude show answers with visuals and interactive parts, and at Microsoft Build, Steve Sanderson even had an AI hallucinate an entire operating system, live on stage. Three kinds of generative UI, each one different. That's my next article.