A modular, self-aware AI platform with plugin architecture, multi-tenant support, and enterprise-grade capabilities for both local and cloud deployment.
-
Authentication System
- Better Auth integration with email/password
- Bcrypt password hashing
- Role-based access control (RBAC) - admin, developer, team member, user
- Session management with database persistence
- Email verification
- Password reset functionality
- Multi-database support (SQLite/PostgreSQL)
-
User Management
- User activity tracking
- GDPR-compliant data export
- GDPR-compliant data deletion
- User feedback and rating system
-
Multi-Tenant Architecture
- Tenant isolation and data segregation
- Tenant provisioning and management
- Tenant-specific configuration
- Resource limits and quota tracking
- Usage tracking system
-
Email Service
- Configurable email providers (SMTP, SendGrid, etc.)
- Tenant-specific email configuration
- Email templates for verification, password reset, and welcome
- Framework: Next.js 15 (App Router)
- Language: TypeScript (strict mode)
- Database: Drizzle ORM with SQLite/PostgreSQL support
- Authentication: Better Auth
- Styling: Tailwind CSS + shadcn/ui
- Email: Nodemailer
- Testing: Vitest
- Node.js 22+ LTS
- pnpm 9+
- Clone the repository:
git clone <repository-url>
cd projectaware- Install dependencies:
pnpm install- Set up environment variables:
cp .env.example .envEdit .env and configure:
- Database URL
- Better Auth secret (generate a secure random string)
- Email service credentials
- Generate database schema:
pnpm db:generate- Push schema to database:
pnpm db:push- Run development server:
pnpm devOpen http://localhost:3000 to see the application.
projectaware/
├── src/
│ ├── app/ # Next.js app directory
│ │ ├── api/ # API routes
│ │ ├── login/ # Login page
│ │ ├── register/ # Registration page
│ │ └── dashboard/ # Dashboard page
│ ├── db/ # Database layer
│ │ ├── schema/ # Drizzle schemas
│ │ └── index.ts # Database connection
│ ├── lib/ # Core libraries
│ │ ├── auth/ # Authentication utilities
│ │ ├── email/ # Email service
│ │ ├── users/ # User management
│ │ ├── tenants/ # Multi-tenant system
│ │ └── utils/ # Utility functions
│ └── middleware.ts # Next.js middleware
├── drizzle.config.ts # Drizzle configuration
├── next.config.ts # Next.js configuration
└── tailwind.config.ts # Tailwind configuration
See .env.example for all required environment variables:
DATABASE_URL: Database connection stringDATABASE_TYPE:sqliteorpostgresqlBETTER_AUTH_SECRET: Secret key for Better AuthENCRYPTION_KEY: 32-character key for encrypting sensitive dataSMTP_*: Email service configurationMULTI_TENANT: Enable/disable multi-tenant mode
pnpm dev- Start development serverpnpm build- Build for productionpnpm start- Start production serverpnpm lint- Run ESLintpnpm type-check- Run TypeScript compiler checkpnpm format- Format code with Prettierpnpm db:generate- Generate database migrationspnpm db:push- Push schema to databasepnpm db:studio- Open Drizzle Studiopnpm test- Run tests with Vitest
- Phase 1: Foundation & Authentication
- Phase 2: Core Infrastructure & Database
- Phase 3: Plugin System & Extensibility
- Phase 4: AI Core & Conversation Engine
- Phase 5: User Portals & Interfaces
- Phase 6-10: Advanced features, security, monitoring, testing, launch
See TODO.md for detailed roadmap.
See LICENSE file for details.
Built with Next.js, Better Auth, Drizzle ORM, and other amazing open-source technologies.