AI-powered mental health support with enterprise-grade security and professional therapeutic frameworks.
- Therapeutic AI - Evidence-based frameworks including CBT, Schema Therapy, and mindfulness approaches
- Privacy-First - AES-256-GCM encryption, BYOK support, optional local AI (Ollama)
- Multi-Language - English and Dutch with localized CBT exports
- Enterprise Security - Clerk authentication, Convex backend with ownership guards
- Modern Stack - Next.js 16, React 19, AI SDK 6, Tailwind CSS v4
# 1. Install dependencies
bun install
# 2. Set up environment
bun run env:init
bun run encryption:setup
# 3. Configure services
# - Clerk: Create app at clerk.com, add keys to .env.local
# - Convex: Create project at convex.dev, add URL to .env.local
# - Add Clerk webhook: <CONVEX_URL>/clerk-webhook
# 4. Start development (two terminals)
bun run convex:dev # Terminal 1: Convex backend
bun run dev # Terminal 2: Next.js (localhost:4000)See docs/DEVELOPMENT.md for detailed setup instructions.
| Command | Description |
|---|---|
bun run dev |
Start development server |
bun run build |
Build for production |
bun run test |
Run unit tests |
bun run test:e2e |
Run Playwright E2E tests |
bun run qa:ci |
CI checks (lint + typecheck + test + build) |
bun run qa:local-full |
Full local QA (qa:ci + smoke/full Playwright) |
bun run qa:full |
Alias for qa:local-full |
bun run convex:dev |
Start local Convex backend |
bun run lint |
Run ESLint |
The repo also includes a Makefile with higher-level shortcuts for local setup, development, QA, and process control.
| Command | Description |
|---|---|
make setup |
First-time setup, prepares env/encryption/types, then starts Convex + Next.js |
make dev |
Starts Convex + Next.js for daily development |
make build |
Builds the app for production |
make start |
Starts the production server after build |
make doctor |
Runs quick local diagnostics for Bun, env, encryption, app health, and Convex |
| Command | Description |
|---|---|
make test |
Run Jest unit/integration tests |
make coverage |
Run Jest with coverage |
make e2e |
Run Playwright E2E tests |
make qa-smoke |
Run lint, typecheck, and Jest |
make qa-full |
Run full local QA including coverage and E2E |
| Command | Description |
|---|---|
make convex-dev |
Start local Convex dev backend |
make convex-stop |
Stop local Convex processes on common ports |
make convex-health |
Check the configured Convex endpoint |
make next-stop |
Stop the Next.js dev server on port 4000 |
Run make by itself to see the full built-in help output.
src/
├── app/ # Next.js App Router
├── features/ # Feature modules (chat, therapy, CBT)
├── components/ui/ # Shared UI components
├── lib/ # Utilities, API clients, auth
└── ai/ # AI model configuration
convex/ # Backend schema and functions
Tech Stack: Next.js 16 (Turbopack), React 19, TypeScript, Convex, Clerk, AI SDK 6, Tailwind CSS v4, Zod v4
| Mode | Model | Use Case |
|---|---|---|
| Web Search | gpt-oss-120b | Chat with browser tools |
| Regular Chat | gpt-oss-20b | Fast responses |
| Local/Private | gemma3:4b (Ollama) | On-device, maximum privacy |
| BYOK | gpt-5-mini | User-provided OpenAI key |
- Development Guide - Setup, testing, workflows
- Deployment - Production deployment
- Data Model - Database schema
- Changelog - Recent improvements
- ADRs - Architecture decisions
MIT License - see LICENSE for details.
Built with ❤️ for mental health support