The engine room behind the LMS.
An AI content engine that writes adaptive lessons and quizzes from a teacher's own material, and a serverless automation layer that runs billing, parent messaging, reports and notifications every day without anyone at the desk. Plus the TTC Online enrollment engine, tested in n8n against the GoHighLevel API.
The AI content engine
A teacher pastes a reading, notes or a chapter and chooses the question types. The engine plans, generates in parallel, checks every item and returns a complete adaptive quiz or a three-level lesson, ready to schedule.
Grounded by design
Every prompt carries hard rules: use only what is in the source text, stay at the students' grade level, and write each item in seven versions (three Bloom's levels, Guided, Power Round, Deep Think and Quick Check). The topic planner works only from the source, so nothing outside the lesson can enter the quiz.
Output the system can trust
Responses pass through a provider normalizer that understands OpenAI chat, OpenAI Responses, Anthropic content blocks and Gemini candidates. Text is cleaned of code fences and smart quotes, broken JSON is repaired, and a strict and a lenient parser compete; the one that yields more gradable items wins.
Exact counts, exact types
Each batch is checked against the question types it was assigned. A wrong type triggers one corrective retry with an explicit reminder. If the merged result is short, small top-up batches run until the requested count is reached, and every item is renumbered so IDs never collide.
Failure handled, not hidden
Errors are classified as retryable or final. Rate limits and overloads wait 12 to 15 seconds and try again; timeouts and empty answers retry once. A Make scenario that answers "Accepted" instead of content is detected and reported in plain words.
Cost-aware
An economy mode for free automation plans plans topics locally, sends larger batches and caps retries, so a full adaptive quiz costs the fewest possible operations. If the endpoint is ever unavailable, the teacher gets a ready prompt for any AI assistant instead.
Adaptive at run time
Generation is only half of it. While a student answers, the quiz picks which of the seven versions to show next from speed, accuracy and error streaks, keeping the same item count and points for everyone.
Serverless automation with a leader lock
The LMS has no backend server. Automation runs from the staff devices that are already open, so it has to be safe when several are open at once.
Monthly billing
Bills for the month are generated automatically, including an early run for bills due on the first.
Payment reminders
Before the due date, on the due date and while overdue, with optional automatic deactivation and a per-account hold.
Weekly reports
Per-student, per-course performance reports at a set day and time, every one or more weeks, resumed if interrupted.
Monthly report cards
Grades, effort and a short comment, emailed to each family on schedule.
One relay for every message
The LMS decides what to send and when. A single webhook relay per program delivers it by SMS and email, and every message is logged with its delivery status.
Push notifications
Firebase Cloud Messaging on the LMS's own project: new lessons and quizzes for a grade, due-tomorrow and leaving-soon alerts once a day, a teacher's private message, and a checked assignment, delivered to phones even when the LMS is closed.
Ledger to Google Sheets
Payment sessions sync to a Google Sheet through an Apps Script web app, throttled and written with a heartbeat timestamp, so any downstream automation can tell how fresh the data is before acting on it.
The missing piece: where each family comes from
The live TTC Online flow (sign-up, trial, billing, payment proofs) runs inside my LMS. This prototype adds the part it lacks, tracking and CRM follow-up, as a tested automation. Parents come in from our Facebook reel and use the same sign-up form as the live site, each child gets a trial account on the spot, three days of follow-up respect quiet hours, and the family is credited to the source that brought them in. It runs live in the browser, and as an n8n workflow against the GoHighLevel API v2.

Two real n8n executions: a sibling sign-up (same parent, new trial) and a CRM outage (three retries, dead-letter queue, ops alert).
Rules that come from running a real center
- A second child is a sibling, never a duplicate
- Texts never contain words carriers filter, so sign-in goes out as "u:" and "p:"
- One free trial per child: the same child with the same email or mobile is stopped
- Confirming payment stops every reminder at once
- Every CRM call retries three times, then the sign-up is kept and the team is alerted
- Ten automated tests guard all of it
Why it is built this way
No single provider
The engine speaks to one endpoint. Behind it, an Apps Script can try several AI providers in turn, or a Make scenario can be swapped in. Changing models never touches the LMS.
The machine checks; people decide
Generated content lands as a draft the teacher schedules. Automation removes the routine work and leaves the judgment calls with a person.
Free-tier engineering
Leases, throttles, resumable runs and quota pauses keep a whole school's automation inside free plans, which is what makes it viable for a small center and for the schools that license it.
See it from the teacher's side
Sign in with the demo teacher account (username teacher, password 1234) and open Quizzes or Lessons to generate content.