An intelligent exam preparation platform powered by RAG (Retrieval-Augmented Generation) technology, supporting IIT-JEE, NEET, and EAMCET exam preparation.
This is a monorepo containing both the frontend (Next.js) and backend (FastAPI) in a single Git repository for easier development and deployment.
Easiest Method - Using npm:
npm run devAlternative Methods:
- Windows Batch: Double-click
start.bat - PowerShell: Run
.\start.ps1
For detailed setup instructions, see STARTUP_GUIDE.md
- AI-Powered Question Generation: Generate exam questions using advanced AI models
- Multiple Exam Types: Support for IIT-JEE, NEET, and EAMCET
- Document Upload: Upload study materials for RAG-based question generation
- Performance Analytics: Track your progress and performance over time
- Subscription Management: Flexible subscription plans
- Multi-Model Support: Choose from various AI models for question generation
- Question Caching: Fast question delivery with intelligent caching
- Google OAuth: Sign in with your Google account
- Next.js 16 - React framework
- TypeScript - Type-safe development
- Tailwind CSS - Utility-first CSS framework
- Framer Motion - Animation library
- Recharts - Data visualization
- NextAuth - Authentication
- FastAPI - Modern Python web framework
- PostgreSQL - Relational database
- SQLAlchemy - ORM
- Pinecone - Vector database for RAG
- OpenAI/Groq - AI model providers
- Redis - Caching layer
- bcrypt - Password hashing
Exam/
βββ backend/ # FastAPI backend
β βββ main.py # Main application entry
β βββ database.py # Database models and setup
β βββ rag_service.py # RAG implementation
β βββ model_service.py # AI model management
β βββ requirements.txt # Python dependencies
β βββ .env # Environment variables
βββ exam-app/ # Next.js frontend
β βββ src/
β β βββ app/ # Next.js app directory
β β βββ components/ # React components
β βββ package.json # Node dependencies
β βββ next.config.js # Next.js configuration
βββ package.json # Root package.json for running both servers
βββ start.bat # Windows batch startup script
βββ start.ps1 # PowerShell startup script
βββ STARTUP_GUIDE.md # Detailed startup instructions
- Python 3.8+
- Node.js 16+
- PostgreSQL
- Redis (optional, for caching)
-
Clone the repository
git clone <repository-url> cd Exam
-
Install dependencies
# Install root dependencies npm install # Install backend dependencies cd backend pip install -r requirements.txt cd .. # Install frontend dependencies cd exam-app npm install cd ..
-
Configure environment variables
Create a
.envfile in thebackendfolder:DATABASE_URL=postgresql://user:password@localhost:5432/examai PINECONE_API_KEY=your_pinecone_api_key OPENAI_API_KEY=your_openai_api_key REDIS_URL=redis://localhost:6379 PORT=8000
-
Run the application
npm run dev
The application will be available at:
- Frontend: http://localhost:3000
- Backend API: http://localhost:8000
- API Docs: http://localhost:8000/docs
- Startup Guide - Detailed instructions for running the application
- Git Guide - Monorepo workflow and Git best practices
- Troubleshooting - Common issues and solutions
- PRD Compliance Check - Product requirements compliance
- Migration Guide - Database migration information
This is a monorepo - both frontend and backend are in one Git repository.
# Quick start
git add .
git commit -m "feat: Your feature description"
git push origin master
# Or use the helper script
git-commit.batFor detailed Git workflows, see GIT_GUIDE.md
- Sign Up/Login: Create an account or sign in with Google
- Upload Study Materials: Upload PDFs for RAG-based question generation
- Generate Questions: Select subject, difficulty, and exam type
- Take Exams: Practice with AI-generated questions
- Track Progress: View your performance analytics
- Manage Subscription: Upgrade for premium features
POST /auth/signup- Register new userPOST /auth/login- Login userPOST /auth/google-signin- Google OAuth login
POST /generate-questions- Generate exam questionsGET /models- Get available AI modelsGET /exam-types- Get supported exam types
POST /upload-document- Upload study materialGET /documents- List uploaded documents
GET /performance/analytics- Get performance analyticsGET /performance/subject-wise- Subject-wise performance
GET /subscription/plans- Get subscription plansPOST /subscription/subscribe- Subscribe to a plan
For complete API documentation, visit http://localhost:8000/docs after starting the backend.
cd backend
pytestcd exam-app
npm testThe backend can be deployed to platforms like:
- Render
- Heroku
- AWS EC2
- Google Cloud Run
The frontend can be deployed to:
- Vercel (recommended for Next.js)
- Netlify
- AWS Amplify
- Fork the repository
- Create a feature branch (
git checkout -b feature/amazing-feature) - Commit your changes (
git commit -m 'Add amazing feature') - Push to the branch (
git push origin feature/amazing-feature) - Open a Pull Request
This project is licensed under the MIT License.
- Your Name - Initial work
- OpenAI for GPT models
- Pinecone for vector database
- FastAPI and Next.js communities
Need Help? Check out the STARTUP_GUIDE.md for detailed setup instructions.