AA
aakashsharma7/AI-Tutor
A powerful AI-powered educational tutoring system that helps students learn and understand various topics through interactive sessions.
๐ AI Tutor Application
A powerful AI-powered educational tutoring system that helps students learn and understand various topics through interactive sessions.
๐ Table of Contents
- Overview
- Features
- Tech Stack
- Project Structure
- Getting Started
- Environment Variables
- API Documentation
- Deployment
๐ Overview
AI Tutor is an educational platform that leverages artificial intelligence to provide personalized tutoring experiences. The application consists of a modern frontend built with React and a robust backend powered by FastAPI.
โจ Features
- ๐ Secure authentication with JWT and Google OAuth
- ๐ค AI-powered tutoring sessions
- ๐ Document analysis and assistance
- ๐ฌ Interactive learning experience
- ๐ฑ Responsive design for all devices
- ๐ Real-time updates and caching
๐ ๏ธ Tech Stack
Frontend
- โ๏ธ React.js
- ๐จ Tailwind CSS
- ๐ Redux for state management
- ๐ฑ Responsive design
- ๐ JWT authentication
Backend
- ๐ Python
- โก FastAPI
- ๐๏ธ SQLAlchemy
- ๐ JWT & OAuth2
- ๐ค Google Gemini AI
- ๐ฆ PostgreSQL
๐ Project Structure
ai-tutor/
โโโ frontend/ # Frontend React application
โ โโโ public/ # Static files
โ โโโ src/ # Source files
โ โ โโโ components/ # React components
โ โ โโโ pages/ # Page components
โ โ โโโ services/ # API services
โ โ โโโ store/ # Redux store
โ โ โโโ utils/ # Utility functions
โ โโโ package.json # Frontend dependencies
โ
โโโ backend/ # Backend FastAPI application
โโโ alembic/ # Database migrations
โโโ migrations/ # Migration versions
โโโ app.py # Main application file
โโโ models.py # Database models
โโโ schemas.py # Pydantic schemas
โโโ database.py # Database configuration
โโโ requirements.txt # Backend dependencies
๐ Getting Started
Prerequisites
- Node.js (v14 or higher)
- Python (v3.8 or higher)
- PostgreSQL
Frontend Setup
cd frontend
npm install
npm startBackend Setup
cd backend
python -m venv venv
source venv/bin/activate # On Windows: venv\Scripts\activate
pip install -r requirements.txt
uvicorn app:app --reload๐ Environment Variables
Frontend (.env)
REACT_APP_API_URL=http://localhost:8000
REACT_APP_GOOGLE_CLIENT_ID=your_google_client_id
Backend (.env)
DATABASE_URL=postgresql://user:password@localhost:5432/ai_tutor
SECRET_KEY=your_secret_key
GOOGLE_CLIENT_ID=your_google_client_id
GOOGLE_CLIENT_SECRET=your_google_client_secret
GEMINI_API_KEY=your_gemini_api_key
FRONTEND_URL=http://localhost:3000
๐ API Documentation
The API documentation is available at /docs when running the backend server. Key endpoints include:
- ๐
/token- Authentication endpoint - ๐ค
/users/me- Get current user info - ๐
/tutor- AI tutoring endpoint - ๐ค
/upload- Document upload and analysis - ๐
/health- Health check endpoint
๐ Deployment
Frontend Deployment (Vercel)
cd frontend
vercelBackend Deployment
cd backend
# Configure your production environment variables
uvicorn app:app --host 0.0.0.0 --port 8000๐ License
This project is licensed under the MIT License - see the LICENSE file for details.
๐ค Contributing
Contributions are welcome! Please feel free to submit a Pull Request.
On this page
Languages
JavaScript55.5%Python39.4%CSS3.7%Mako0.9%HTML0.5%
Contributors
Created April 10, 2025
Updated April 15, 2025