overview: youtube link
Sprout builds personalised learning pathways on any topic. Interested in fauna from darkest Peru? Or perhaps you are cramming for a linear algebra exam. Describe the topic, upload your notes, and watch Sprout's multi-agents autonomously generate a three-dimensional learning network which adapts to you. Gone are the days of scrolling through endless AI chat logs. With Sprout you can explore your own 3D knowledge network using natural hand movements (not keyboard or mouse) and navigate ideas as if you are exploring your own mind. Dive into a concept node to start learning. Sprout's teaching follows one core methodology: the learner should reach the answer themselves, Sprout is just there to show them the path. With quiz, code, text and drawing based learning blocks, Sprout's multi-media approach tests our learners holistically. With an integrated support chat and voice tutor powered by ElevenLabs, Sprout guides learners to reach the answer themselves.
Overview and setup guide for the two services in this repo:
sprout-backend/: Express + TypeScript API with Claude-powered agents, SQLite (Drizzle), S3 document uploads, and a Python hand-tracking websocket.sprout-frontend/: Next.js 16 app that visualizes and runs the learning graph, streams agent activity over SSE, and can be steered by hand tracking.
- Node.js 20+ and npm.
- Anaconda/Miniconda (or Python 3.11+) for the computer-vision hand tracking service.
- Anthropic API key.
- AWS credentials and an S3 bucket for document uploads (skip uploads if you don’t set these).
- Webcam access (for hand tracking).
-
Backend API
cd sprout-backend- Create
.env(see Env Reference below). - Install deps:
npm install - Apply DB schema:
npm run db:migrate(createssprout.dblocally) - Run API:
npm run dev(http://localhost:8000; health at/api/health)
-
Computer-vision hand tracking (Anaconda)
cd sprout-backend- Ensure conda exists:
conda --version(install Miniconda if missing). - Create env:
conda create -n sprout-cv python=3.11 -y - Activate:
conda activate sprout-cv - Install CV deps:
pip install -r requirements.txt - Run the WS server:
python backend.py(opensws://localhost:8765; keep running while using the UI)
-
Frontend
cd sprout-frontend- Create
.env.local(see Env Reference). - Install deps:
npm install - Run dev server:
npm run dev(http://localhost:3000). The app proxies/backend-api/*to the backend and directly connects tohttp://localhost:8000for SSE.
-
Use it
- Start all three processes in separate terminals: Python hand tracker → backend → frontend.
- Open http://localhost:3000, add a topic (branch), upload docs if desired, and watch agents stream progress in the activity card.
- Toggle “Hand tracking” in the bottom-right of the graph view to drive the pointer with your webcam.
ANTHROPIC_API_KEY=your_key
AWS_ACCESS_KEY_ID=your_key
AWS_SECRET_ACCESS_KEY=your_secret
AWS_REGION=us-east-1
AWS_S3_BUCKET=your-bucket
DB_PATH=./sprout.db # optional; default shown
PORT=8000 # optional
NEXT_PUBLIC_BACKEND_ORIGIN=http://localhost:8000
NEXT_PUBLIC_BACKEND_PROXY_PREFIX=/backend-api # matches next.config.ts rewrite
NEXT_PUBLIC_SMALL_AGENTS=false # set true to use cheaper agent mode
- SQLite DB lives at
sprout-backend/sprout.db; migrations are insprout-backend/drizzle/and generated fromsrc/db/schema.ts. - A default user (
00000000-0000-0000-0000-000000000000) is auto-seeded at server start. - Agent SSE endpoints:
/api/agents/topics/:topicNodeId/run,/api/agents/concepts/:conceptNodeId/run, plus diagnostic + review routes. Seesprout-backend/AGENTS.mdfor flows and events.
- Backend:
npm run dev,npm run db:migrate,npm run db:generate,npm run db:push,npm run build && npm start. - Frontend:
npm run dev,npm run build && npm start,npm run lint/npm run format(Biome).
- Hand tracking not moving: ensure
python backend.pyis running in thesprout-cvconda env and the browser camera permission is granted. - Uploads fail: confirm AWS creds/bucket in
.env; S3 is required for document uploads. - SSE stops: the frontend bypasses the proxy for streaming; verify
NEXT_PUBLIC_BACKEND_ORIGINmatches the backend URL and CORS is enabled (it is by default insrc/index.ts).