A personalised AI tutor Mini App for the World ecosystem that verifies human learners and delivers adaptive lessons, feedback, and progress tracking.
Built for EthGlobal Cannes 2026 — World prize tracks.
Online learning is plagued by bots, duplicate accounts, and lack of accountability. AI tutoring tools have no way to verify that learners are real people, leading to abuse of free resources and meaningless progress tracking. There's no "one learner, one identity" guarantee.
ProofLearn is a Mini App inside World App that combines World ID 4.0 verification with an AI-powered adaptive tutor. Every learner proves they're a unique human before they can start learning, creating a trusted 1:1 relationship between person and learning profile.
- World ID 4.0 ensures one human = one learner identity with zero-knowledge proofs
- MiniKit 2.0 provides native Mini App experience (walletAuth, haptics, share)
- Mini App distribution reaches 23M+ World App users directly
- IDKitRequestWidget with
orbLegacypreset for human verification - RP signature generation via
signRequest()from@worldcoin/idkit/signing - Backend verification against
developer.world.org/api/v4/verify/{rp_id} - Nullifier-based one-human-one-learner enforcement
allow_legacy_proofs: truefor backwards compatibility during migration
- Orb verified: Unlimited lessons
- Document verified: 20 lessons/day
- Selfie verified: 5 lessons/day — verify with Orb for full access
- Credential type extracted from IDKit response and stored per learner
- Higher-tier re-verification upgrades access automatically
- MiniKitProvider wraps the entire app for SDK initialisation
- MiniKit.isInstalled() detects World App environment
- MiniKit.sendHapticFeedback() on lesson load, answer submission, correct/incorrect
- MiniKit.shareContacts() invite friends from World App contacts
- Web Share API for sharing progress (works in World App webview)
- @worldcoin/mini-apps-ui-kit-react for native World App components
- 3 subjects: Mathematics, Language Learning (English, French, Hungarian, Ukrainian, Spanish), Coding
- 3 skill levels: Beginner, Intermediate, Advanced
- Personalised micro-lessons with explanations and exercises
- Multiple question types: open-ended, multiple choice, code
- AI-powered answer evaluation with detailed feedback
- Adaptive difficulty based on performance history
- Confetti celebration on correct answers + milestone achievements
- 5 multiple-choice questions, 60-second timer
- All questions pre-generated in parallel (no loading between questions)
- Instant answer feedback with auto-advance
- Results screen with score, time, and answer review
- Follow-up questions after each lesson for deeper understanding
- General learning Q&A via dedicated Mentor tab
- Strictly education-only — refuses off-topic questions
- Top 20 verified learners ranked by lessons completed
- One person = one entry (World ID sybil resistance)
- Shows credential badge, accuracy, and streak
- Completion count, accuracy rate, learning streak
- Per-subject breakdown with visual progress bars
- Strength and weakness identification
- Recent lesson history with scores
- World ID nullifier-based deduplication
- Tiered access based on credential strength
- Server-side proof verification via v4 API
- Rate limiting on all API endpoints
- No sensitive data trusted from client
┌─────────────────────────────────────────┐
│ World App │
│ ┌───────────────────────────────────┐ │
│ │ ProofLearn Mini App │ │
│ │ ┌─────────┐ ┌──────────────┐ │ │
│ │ │ IDKit │ │ MiniKit 2.0 │ │ │
│ │ │ 4.0 │ │ WalletAuth │ │ │
│ │ │ Verify │ │ Haptics │ │ │
│ │ └────┬────┘ └──────┬───────┘ │ │
│ └───────│──────────────│────────────┘ │
└──────────│──────────────│────────────────┘
│ │
┌──────▼──────────────▼──────────┐
│ Next.js API Routes │
│ /api/rp-signature │
│ /api/verify (→ v4 API) │
│ /api/tutor/* /api/learner │
├─────────────┬──────────────────┤
│ Session │ Rate Limiter │
│ (JWT+DB) │ (in-memory) │
├─────────────┴──────────────────┤
│ AI Tutor Service │
│ Claude API │
├────────────────────────────────┤
│ Prisma ORM + SQLite │
│ Learner │ Lesson │ Session │
└────────────────────────────────┘
| Layer | Technology |
|---|---|
| Frontend | Next.js 15, React 19, Tailwind CSS 4 |
| Backend | Next.js API Routes |
| Database | Prisma ORM + SQLite |
| AI | Anthropic Claude API |
| Verification | World ID 4.0 (IDKit), RP signatures |
| Mini App | MiniKit SDK 2.0 (provider, walletAuth, haptics) |
| Validation | Zod |
| Testing | Vitest |
- Node.js 18+ (check with
node -v) - npm (comes with Node) or pnpm
- A World Developer Portal account at developer.world.org
- An Anthropic API key from console.anthropic.com
-
Clone and install:
git clone https://github.com/valera-grinenko-ai/prooflearn.git cd prooflearn npm install -
Create your
.env:cp .env.example .env
-
Fill in your credentials:
# From https://developer.world.org — create an app and copy these NEXT_PUBLIC_APP_ID=app_your_id NEXT_PUBLIC_RP_ID=rp_your_id RP_SIGNING_KEY=your_hex_signing_key # From https://console.anthropic.com ANTHROPIC_API_KEY=sk-ant-your_key # Generate with: openssl rand -hex 32 SESSION_SECRET=your_random_secret_here
-
Initialise the database and start:
npx prisma db push npm run dev
-
Open in World App — enter your dev URL in the Developer Portal (use ngrok or tunnelmole for HTTPS), scan the QR code with World App, and verify with your real World ID.
npm run db:seed # creates a learner with 5 completed lessonsUseful for testing the progress dashboard without completing lessons first.
| Variable | Required | What it does |
|---|---|---|
NEXT_PUBLIC_APP_ID |
Yes | World App ID (app_xxx) from Developer Portal |
NEXT_PUBLIC_RP_ID |
Yes | Relying Party ID (rp_xxx) from Developer Portal |
RP_SIGNING_KEY |
Yes | Hex signing key. Server-only — never expose client-side. |
ANTHROPIC_API_KEY |
Yes | Claude API key — powers all lesson generation and evaluation |
DATABASE_URL |
Yes | Default: file:./dev.db (SQLite). Swap to Postgres URL for prod. |
SESSION_SECRET |
Yes | JWT signing secret, 32+ chars. Generate with openssl rand -hex 32. |
NEXT_PUBLIC_APP_URL |
No | Default: http://localhost:3000. Used for share links. |
| Method | Path | Description |
|---|---|---|
| GET | /api/auth/nonce |
Generate SIWE nonce for walletAuth |
| POST | /api/rp-signature |
Generate RP signature for IDKit 4.0 |
| POST | /api/verify |
Verify World ID proof via v4 API |
| GET | /api/learner |
Get learner profile |
| PATCH | /api/learner |
Update preferences |
| POST | /api/tutor/lesson |
Generate a personalised lesson |
| POST | /api/tutor/evaluate |
Evaluate an answer with AI feedback |
| POST | /api/tutor/chat |
AI mentor chat |
| GET | /api/progress |
Get progress stats and breakdown |
| POST | /api/reset |
Reset learner progress |
npm test # run all tests
npm run test:watch # watch modeTests cover: verification logic, AI tutor (mocked Anthropic client), rate limiting, World ID 4.0 (RP signature generation).
- World ID: Real verification requires World App or Simulator. A skip button exists for local testing.
- AI: Requires an Anthropic API key. No offline/mock mode.
- Database: SQLite for local dev. Production should use PostgreSQL.
- On-chain credential storage for learning certificates
- Spaced repetition algorithm for optimised review scheduling
- Peer-to-peer study sessions between verified learners
- MiniKit payments for premium content
MIT
Built with Claude AI assistance for EthGlobal Cannes 2026.