Leornian (Old English): to read, study, or learn.
- Health Data Tracking: Customize and log daily health/wellness metrics
- WHOOP Integration: Seamless connection with WHOOP wearable devices
- Interactive Chat: AI assistant for health queries and recommendations
- React
- Vite
- Tailwind CSS
- Node.js
- Express
- TypeScript
- Prisma
- PostgreSQL
- JWT
- OpenAI
- WHOOP API
- Node.js (v18+)
- PostgreSQL
- Docker (optional, for database)
git clone https://github.com/realjackcrew/leornian.git
cd leornian
chmod +x install.sh
./install.shOption A: Docker (Recommended)
cd server
docker-compose up -dOption B: Local PostgreSQL
- Install PostgreSQL locally
- Create a database named
leornian_db
Copy the example environment files and add your API keys:
cd server
cp .env.example .env
cd ../client
cp .env.example .envRequired API Key Links:
- OpenAI
- Whoop (requires active membership)
- Google OAuth
- Resend
cd server
npx prisma generate
npx prisma migrate deployTerminal 1 - Backend:
cd server
npm run devTerminal 2 - Frontend:
cd client
npm run dev- Frontend: http://localhost:5173
- Backend API: http://localhost:4000
- Sign Up - Create your account on the homepage
- Set Up Profile - Configure your health tracking preferences
- Connect Devices - Link your WHOOP device (optional)
- Start Logging - Begin tracking your daily health metrics
- Get Insights - Chat with the AI assistant about your health data
# Client
npm run dev # Start dev server
npm run build # Production build
npm run preview # Preview build
# Server
npm run dev # Start dev server
npm run build # Build TypeScript
npm run start # Production servernpx prisma generate # Generate client
npx prisma migrate dev # Run migrations
npx prisma studio # Open database GUI
npx prisma migrate reset # Reset database- JWT-based authentication
- Password hashing with bcrypt
- CORS protection
- Input validation and sanitization
- Query to JSON object conversion (prevents SQL injection)
MIT