Architecture
How Sypnia Learn is built: its parts, how they connect, and why exercises run outside the engine.
On this page
- You, App, the CLI or your agent call the API or the MCP server.
- A lesson is rendered for your level and filled with items from your project.
- Your project is read with your permissions: the map, the tables, the traces, the repository.
- An exercise becomes a branch; its checks are sent as a job.
- The runner checks the branch in a sandbox and sends back each result.
- Explanations and hints come from Sypnia AI, at your level.
- When a lesson is done, a note is written in your memory.
Read this diagram as text
The engine is one service with the API, the MCP server, the lesson renderer, the binder that reads your project, the exercise service, the check orchestrator, the offers listener and the memory writer. It keeps its state in Postgres and course files and videos in object storage. Exercises never run inside the engine: a runner checks them in a sandbox.
| Part | What it does | Language | Open source |
|---|---|---|---|
| Learn engine: API, MCP, renderer, binder, exercises, checks, offers, memory writer | everything in the diagram’s frame | TypeScript (Node 22) | yes, AGPL-3.0 |
@sypnia/learn: the lesson format, the CLI, the client | for learners, authors and their tools | TypeScript | yes, MIT |
| The runner | checks exercises in a sandbox | Sypnia Agent’s sandbox (Rust), or a Docker runner | yes |
| Sypnia’s courses | the lessons and videos presented by Santi | Markdown and video | no |
Console at learn.app.sypnia.com | courses, progress and settings in the browser | TypeScript (React, @sypnia/ui) | no |
Why TypeScript
Learn spends its time rendering Markdown and calling other products, not on a hot path. Writing the engine in the same language as @sypnia/learn means the CLI, the console and the engine read lesson files with the same parser, so a lesson that passes learn lint renders the same everywhere.
Why exercises run outside
An exercise is someone’s code. Running it inside the engine would put every learner’s work next to everyone’s progress. The runner is a separate sandbox with only the branch, no secrets and no production access.
What happens when you open a lesson, start an exercise, check it, ask for an explanation, and get an offer.
The tables of the Learn engine and what each one holds.
How Sypnia Cloud runs Learn on AWS: the services, where each part runs, and how it scales.
What happens to a lesson, an exercise or your progress when a part of Learn, or a product it uses, fails.
Where Learn's code, the lesson format and the sample project live.