AI-Powered Learning. On-Chain Credentials. Real Rewards.
Contracts · API · Frontend · AI · Indexer
ChainLearn is a personalized learning management system that rewards learners with on-chain tokens and verifiable credentials — built on Stellar with Soroban smart contracts.
We believe education is the gateway to financial inclusion. ChainLearn makes learning accessible, rewarding, and verifiable for anyone with a Stellar wallet — especially in emerging markets where traditional credentials are hard to obtain and easy to forge.
Connect Wallet → Pick a Course → Learn → Take a Quiz → Earn Tokens → Get Certified
- Connect your Stellar wallet (Freighter, Albedo, LOBSTR)
- Choose from AI-curated courses adapted to your background, goals, and pace
- Learn with dynamic content generated by Cohere's LLM
- Quiz and earn SEP-41 tokens for scores above 50%
- Complete all modules and mint an on-chain NFT credential
| Stellar | Ethereum | |
|---|---|---|
| Transaction fee | ~$0.00001 | $1–50+ |
| Finality | 3–5 seconds | 12+ seconds |
| Built-in DEX | Yes (SDEX) | No |
| Micro-rewards viable | Yes | No |
Stellar's low fees make learning micro-rewards economically viable — something impossible on chains where gas exceeds reward value.
┌─────────────┐ ┌─────────────┐ ┌─────────────┐
│ Frontend │────▶│ API Server │────▶│ AI Service │
│ (Next.js) │◀────│ (Fastify) │◀────│ (FastAPI) │
└──────┬──────┘ └──────┬──────┘ └──────────────┘
│ │
▼ ▼
┌─────────────┐ ┌─────────────┐ ┌─────────────┐
│ Stellar │ │ PostgreSQL │ │ Indexer │
│ (Soroban) │ │ + Redis │ │ (Events) │
└─────────────┘ └─────────────┘ └─────────────┘
| Repo | Stack | Purpose |
|---|---|---|
| chainlearn-contracts | Rust, Soroban SDK | On-chain logic — token rewards, NFT credentials, progress tracking |
| chainlearn-api | TypeScript, Fastify, Drizzle ORM, PostgreSQL | Business logic, user management, Stellar tx submission |
| chainlearn-frontend | TypeScript, Next.js, Tailwind, shadcn/ui | User-facing web app with wallet integration |
| chainlearn-ai | Python, FastAPI, Cohere | AI-powered course content, quiz generation, feedback |
| chainlearn-indexer | TypeScript, Fastify | Soroban event listener — indexes on-chain activity |
| chainlearn-infra | Docker, Terraform, Kubernetes | Infrastructure as code |
| chainlearn-docs | Markdown, OpenAPI | Architecture docs, API specs, diagrams |
Three Soroban contracts power the on-chain layer:
- Learn Token — SEP-41 fungible token. Mints proportional rewards for quiz performance.
- Credential NFT — Verifiable course completion certificates stored on Stellar.
- Progress Tracker — Enrolls learners, tracks module completion and quiz scores on-chain.
| Layer | Technology |
|---|---|
| Smart Contracts | Soroban (Rust) |
| Blockchain | Stellar Network |
| Token Standard | SEP-41 |
| AI/ML | Cohere (command-nightly, embed-english-v3.0) |
| Frontend | Next.js 14, Tailwind CSS, shadcn/ui |
| Backend | Fastify, TypeScript, Drizzle ORM |
| Database | PostgreSQL, Redis |
| Wallet | Freighter, Albedo, Stellar Wallets Kit |
# Clone all repos
git clone https://github.com/ChainLearnOfficial/chainlearn-contracts.git
git clone https://github.com/ChainLearnOfficial/chainlearn-api.git
git clone https://github.com/ChainLearnOfficial/chainlearn-frontend.git
git clone https://github.com/ChainLearnOfficial/chainlearn-ai.git
git clone https://github.com/ChainLearnOfficial/chainlearn-indexer.git
# Start infrastructure
cd chainlearn-infra && docker compose -f docker/docker-compose.dev.yml up -d
# Deploy contracts to testnet
cd ../chainlearn-contracts && ./scripts/deploy.sh testnet
# Build AI knowledge index
cd ../chainlearn-ai && python scripts/build_index.py
# Start services (each in a separate terminal)
cd ../chainlearn-api && npm run dev
cd ../chainlearn-ai && uvicorn src.main:app --reload
cd ../chainlearn-indexer && npm run dev
cd ../chainlearn-frontend && npm run devWe welcome contributions across all repositories. Look for issues labeled:
good first issue— Great for newcomerstests— Help us improve coveragebug— Fix something brokenenhancement— Build new features
See the issue tracker in each repo for details.
See individual repositories for license information.
Built with care for learners everywhere.
