Every year, elite independent schools in South Africa quietly offer a rare gift: full scholarships to underprivileged learners from township communities. Most candidates fail the admissions exam — not for lack of intelligence, but because they walk into a room and face a curriculum they have never seen before. The IEB mathematics standard bears little resemblance to what is taught in township schools under the national Department of Education syllabus. The gap is wide, the preparation window is short, and human tutors are expensive and scarce.
We built KasiRise Scholar to close that gap. This is how we did it — and what we learned about building AI for genuine social impact.
The Problem We Were Solving
myKasi360 NPC, registered in 2022, has been building a scholarship preparation programme for Grade 6–9 learners in Mabopane, Winterveldt, Ga-Rankuwa, Kgabalatsane, and Mmakau. The model works: identify bright learners from township schools, prepare them for IEB admissions exams, place them in elite schools on full scholarship. The problem is operational. The organisation faces three chronic constraints:
- Curriculum mismatch — learners encounter IEB mathematics for the first time in the exam hall, almost always underperforming relative to their actual ability
- Resource scarcity — qualified maths tutors are expensive; programme continuity breaks down when funding cycles do
- Selection uncertainty — Grade 6 report cards reveal little about a learner's cognitive potential; resources are sometimes allocated to the wrong cohort
AI could not solve all three at once. But it could make a decisive dent. In late 2025, we began designing a system that would give every enrolled learner access to a world-class maths tutor, on demand, at zero marginal cost per session.
Independently validated. KasiRise Scholar was submitted as the capstone project for the Google × Kaggle 5-Day AI Agents Intensive Course — earned December 18, 2025. The original system design is documented at Kaggle. What follows describes the live production system built from that foundation.
The Architecture: Four Agents, One Pipeline
We designed KasiRise Scholar as a four-agent sequential pipeline. Each agent has a distinct role, a distinct AI model, and a distinct relationship with the learner. Claude Sonnet 4.6 (via the Anthropic API) is the primary engine — handling pedagogy, assessment, and advocacy. Gemini 2.0 Flash with Google Search grounding handles real-time information retrieval.
The Researcher — Real-Time IEB Resource Discovery
When a learner asks about a specific topic, school, deadline, or past paper, the Researcher activates before the Tutor responds. Using Gemini 2.0 Flash with Google Search grounding, it retrieves current, curriculum-aligned resources — Siyavula, Mindset Learn, school-specific bursary information — and passes a structured research context to the Tutor. If the Researcher fails, the system degrades gracefully: the Tutor proceeds without it. No learner session is ever blocked by a research failure.
The Tutor — Socratic Maths Mentorship with Memory
The Tutor is Claude Sonnet 4.6, operating under a strict Socratic system prompt. It never gives answers directly — it asks the question that leads the learner to find the answer themselves. Session history is persisted in Firestore across multiple sessions. The system prompt is dynamically built from the learner's profile: grade, weak areas, topics covered, diagnostic score, and any research context from Agent 1. The Tutor also accepts image uploads — a learner can photograph a textbook problem and the Tutor will guide them through it. LaTeX renders in the browser via KaTeX.
The Examiner — Cognitive Aptitude Through Challenge Mode
IEB admissions tests measure fluid intelligence, not curriculum knowledge. The Examiner serves sequence puzzles and pattern-recognition analogies — problems that assess reasoning ability independent of prior schooling. Each challenge is scored server-side. Correct answers award XP. A gamified leaderboard creates healthy competition across the cohort. The Examiner's data — scores, patterns, speed — feeds directly into the Advocate's essay context.
The Advocate — Scholarship Essay with Human Review Gate
The Advocate only activates once a learner has earned it: a diagnostic score above 60% and at least five tutoring sessions completed. It pulls together the learner's full journey — tutor session history, challenge scores, weak areas addressed, XP earned — and generates a hyper-personalised scholarship application essay. Crucially, no essay reaches a school without passing through a human review gate. A myKasi360 mentor reads, edits, and approves the essay in the admin dashboard before a 30-day shareable link is generated. Human oversight is not a feature; it is an architectural requirement.
What We Built Beyond the Agents
The four agents are the core. But a real product for real learners required more infrastructure.
Diagnostic Gate
Every learner begins with a 10-question diagnostic drawn from a 24-question pool spanning five maths topics. The score determines readiness, personalises the tutor's system prompt, and establishes a baseline for measuring progress over time. It also solves the selection problem: a learner who scores 40% in October and 75% in March has demonstrated growth that a school report cannot show.
Parent Portal
We built a family connection system. Learners generate a 6-character family code in the app. A parent or guardian enters the code on sign-in and is linked to the learner's account. The parent dashboard shows the learner's progress in real time — diagnostic score, sessions completed, weekly streak, XP total, topics mastered, and identified weak areas. The shareable essay page is also visible to parents. When a family is invested, a learner is more likely to persist.
Schools Database
Seventeen IEB schools across four provinces — Gauteng, Western Cape, KwaZulu-Natal, and the Eastern Cape — are surfaced within the app. The Researcher agent can retrieve live scholarship deadline information for specific schools. The admin team can add, edit, or remove schools from the admin dashboard without touching code.
Technical Architecture
| Layer | Technology |
|---|---|
| Primary AI | Claude Sonnet 4.6 via Anthropic API (direct, not via Bedrock or Vertex) |
| Research AI | Gemini 2.0 Flash + Google Search grounding |
| Backend | Firebase Cloud Functions, Node.js 22, Express |
| Database | Firestore (all access via Admin SDK — zero direct client access) |
| Auth | Firebase Auth — Google OAuth, email/password, phone OTP (SA +27) |
| Hosting | Firebase Hosting (PWA, service worker, offline support) |
| Frontend | Vanilla HTML/JS, Tailwind CSS, KaTeX for LaTeX rendering |
We chose the Anthropic API directly — not via a cloud intermediary — to maintain full control over model selection, system prompt construction, and response handling. The API key is stored as a Firebase secret. All user content passes through a sanitisation function before reaching the model. Rate limiting is enforced at two levels: 50 messages per user per day, and a global budget of 5,000 AI messages per day across all users.
Responsible AI by Design
Building AI for children in under-resourced communities carries specific responsibilities. We took several deliberate design decisions:
- Socratic constraint. The Tutor's system prompt instructs Claude never to provide a direct answer. It asks the question that leads the learner to the answer. This is not a restriction — it is the pedagogy. A learner who arrives at an answer through guided reasoning retains it; a learner who copies an AI-generated answer does not.
- POPIA compliance. South Africa's Protection of Personal Information Act governs how we handle learner data. Registration includes explicit POPIA consent. Learners under 18 require parental consent captured at sign-up. No learner data is used for model training.
- Human-in-the-loop for consequential outputs. The scholarship essay is the highest-stakes output in the system. A human mentor must approve it before it reaches a school. The AI drafts; the human decides. This is not a workaround — it is the correct architecture for a consequential, real-world outcome.
- Bot protection. Honeypot fields and rate limiting protect the system from abuse. The platform is not a free AI service — it is a focused tool for a specific cohort with a specific goal.
- Graceful degradation. The Researcher agent failing does not break the Tutor session. An offline service worker ensures learners in bandwidth-constrained environments can still access the static shell and cached content.
Current State: Live in Production
KasiRise Scholar is live at kasirise-scholar.web.app. Version 1.2.0 includes all four agents, the parent portal, the schools admin dashboard, the family code system, and the full gamification loop. The system has been deployed on Firebase and is accessible to learners across South Africa on any device, with offline support for low-connectivity environments.
What We Learned About Building AI for Real-World Impact
"The hardest part was not the AI. It was understanding what the learner needed — and what they did not need — from the AI."
A few things that surprised us:
Resistance to direct answers is a feature, not a bug. Our initial instinct was to make the Tutor more helpful — give more, explain more. But Socratic prompting produces better retention and greater learner confidence. When a learner figures something out, they own it. When the AI tells them, they scroll past it.
Parents are underrated stakeholders. The family connection feature was not in the original design — it emerged from conversations with the myKasi360 team. When parents can see progress, they reinforce it at home. The parent portal has become one of the most-used features.
Multi-model orchestration is powerful but requires discipline. Running Claude and Gemini in the same request pipeline creates real capabilities. But it also creates failure modes. The Researcher-Tutor handoff required careful error handling to ensure Gemini failures never surface as learner-facing errors.
The hardest constraint to maintain is scope. Once a learner is using the platform daily, you want to add everything — homework reminders, video content, peer chat. Resisting that and keeping the system focused on its stated mission — IEB maths preparation — is a daily discipline.
What Comes Next
Phase 3 introduces Challenge Duels: a parent receives a notification when their child completes a challenge puzzle and can attempt the same puzzle asynchronously. A private family leaderboard tracks both scores over time. The goal is not competition — it is shared investment. A parent who has wrestled with the same problem their child just solved is a parent who can have a real conversation about it.
Beyond KasiRise Scholar, Transformer Business Labs is applying Claude's capabilities to enterprise AI transformation — including operational automation for South African businesses processing hundreds of thousands of transactions annually. The lessons from building for constrained, high-stakes environments translate directly: keep the AI focused, keep the human in the loop, and build the safety rails before the features.
What's Next: Phase 3 — Challenge Duels & Family Learning
Development of KasiRise Scholar is ongoing. The current v1.2.0 is a stable, production-ready foundation — but it is not the final form. Phase 3 is being designed based on extensive feedback from the myKasi360 team and early learner sessions. The proposed features are:
Challenge Duels
When a learner completes a challenge puzzle, their parent or guardian receives a notification and can attempt the same puzzle asynchronously. A private family leaderboard tracks both scores over time. The goal is not competition — it is shared investment. A parent who has wrestled with the same problem their child just solved can have a real conversation about it. This feature requires a real-time notification layer (Firestore onSnapshot listeners or server-sent events) — an architectural addition not yet in the system.
Expanded Challenge Library
The current Examiner agent draws from a fixed pool of sequence puzzles and analogies. Phase 3 will introduce dynamic puzzle generation — Claude producing novel, difficulty-calibrated challenges on demand — to prevent learners from pattern-matching answers after repeated attempts.
Progress Notifications
Automated milestone notifications to parents when their child hits a streak, completes a topic, or unlocks the Advocate tab. Keeps families engaged across the weeks of preparation without requiring them to actively check the dashboard.
Infrastructure Upgrades
Phase 3 will also include a migration from Firebase Gen 1 to Gen 2 Cloud Functions (for better cold-start performance and concurrency), and an upgrade of the Anthropic SDK from v0.39 to the current v0.80 — which introduces significant improvements to streaming and tool-use handling that will benefit the Tutor and Examiner agents.
These features are proposed — not yet committed to a delivery date. They will be scoped and sequenced based on learner feedback gathered through the current cohort.
The Larger Opportunity
Every year, elite IEB schools across South Africa offer scholarships to underprivileged learners — a pipeline that exists, but that township candidates are chronically underprepared to enter. The vast majority of those scholarships go to learners whose families could afford private tutors or who attended well-resourced feeder schools. KasiRise Scholar does not level the playing field. But it reduces the gradient. A Grade 7 learner in Winterveldt who has completed 30 Socratic tutoring sessions and three rounds of cognitive challenge questions walks into that admissions exam with something they did not have before: preparation.
That is what AI for good looks like in practice — not a grand promise, but a specific, measurable intervention in a specific, documented problem. We are proud to have built it with Claude at the centre, and we intend to keep building.