A comprehensive AI-powered study assistant that transforms handwritten notes, textbook pages, and diagrams into interactive learning materials. Built for the Codestorm AI Competition Final Round.
- Image Upload & OCR: Upload photos of handwritten notes, textbook pages, or diagrams with automatic text extraction using Tesseract.js
- AI Content Analysis: Generate summaries and explanations using OpenAI GPT-4o
- Interactive Quiz Generation: Auto-generated MCQs, short answer questions, and flashcards
- AI Chat Assistant: Contextual chat interface that references your uploaded study materials
- User Authentication: Secure user accounts with email verification via Supabase
- Steganography Detection: Advanced image analysis to detect hidden data using LSB analysis, statistical analysis, and bit plane analysis
- Real-time Processing: Live status updates during image processing and analysis
- Responsive Design: Modern, clean interface optimized for students
- Frontend: Next.js 15, React, TypeScript, Tailwind CSS
- Backend: Next.js API Routes, Supabase (PostgreSQL)
- AI/ML: OpenAI GPT-4o, Tesseract.js OCR
- Storage: Vercel Blob for image storage
- Authentication: Supabase Auth with Row Level Security
- Deployment: Vercel
- Node.js 18+ and npm
- Supabase account and project
- OpenAI API key
- Vercel account (for deployment)
Create a .env.local file with the following variables:
```env
NEXT_PUBLIC_SUPABASE_URL=your_supabase_url NEXT_PUBLIC_SUPABASE_ANON_KEY=your_supabase_anon_key SUPABASE_SERVICE_ROLE_KEY=your_supabase_service_role_key
OPENAI_API_KEY=your_openai_api_key
BLOB_READ_WRITE_TOKEN=your_blob_token
NEXT_PUBLIC_DEV_SUPABASE_REDIRECT_URL=http://localhost:3000/protected ```
-
Clone and Install ```bash git clone cd ai-study-helper npm install ```
-
Database Setup
- Run the SQL scripts in the
scripts/folder in your Supabase SQL editor:001_create_database_schema.sql002_create_profile_trigger.sql
- Run the SQL scripts in the
-
Environment Configuration
- Copy
.env.exampleto.env.local - Fill in your API keys and database URLs
- Copy
-
Development ```bash npm run dev ``` Open http://localhost:3000
-
Production Deployment
- Deploy to Vercel with one click
- Environment variables are automatically configured via integrations
The application uses the following main tables:
profiles- User profile informationstudy_sessions- Study session managementuploaded_images- Image metadata and extracted textai_content- Generated summaries, explanations, and quizzeschat_messages- Chat conversation history
All tables are protected with Row Level Security (RLS) policies.
- Row Level Security: All database operations are user-scoped
- Authentication: Email verification required
- File Validation: Image type and size restrictions
- Steganography Detection: Identifies potentially malicious hidden content
This application addresses all competition requirements:
- Photo Upload: Drag & drop interface with multiple file support
- Text Extraction: OCR using Tesseract.js with support for various handwriting qualities
- AI Summaries: Concise, student-friendly content summaries
- Explanations: Concept clarifications in simple language
- Quiz Generation: MCQs, short answers, and flashcards
- Handwritten Notes: Clear and messy handwriting support
- Textbook Pages: Dense text and highlighted content
- Diagrams: Labeled diagrams with text extraction
- Mixed Quality: Tilted, low-resolution, and cropped images
- Real-world Scenarios: Classroom notes, textbook scanning, quick captures
- Steganography Detection: Advanced security feature using multiple analysis techniques
- Interactive Chat: AI assistant with context from uploaded materials
- Real-time Processing: Live status updates and streaming responses
- Comprehensive Analytics: Detailed analysis results and confidence scoring
The application is deployed and accessible at: https://ai-study-helper.vercel.app
- Zero-config deployment on Vercel
- Automatic HTTPS and global CDN
- Environment variable management via Vercel dashboard
- Database integration with Supabase
- File storage with Vercel Blob
- Sign Up: Create an account with email verification
- Upload Images: Drag & drop or select study material photos
- AI Processing: Wait for automatic text extraction and analysis
- Review Content: Read generated summaries and explanations
- Take Quizzes: Test understanding with auto-generated questions
- Chat Assistant: Ask questions about your materials
- Security Check: Review steganography detection results
The innovative steganography detection feature uses multiple analysis techniques:
- LSB Analysis: Examines least significant bits for hidden patterns
- Statistical Analysis: Chi-square tests and pixel correlation analysis
- Bit Plane Analysis: Complexity analysis across different bit planes
- Confidence Scoring: Provides detection confidence percentage
- Detailed Reports: Technical analysis with visual indicators
This project was built for the Codestorm AI Competition. For questions or feedback, please contact the development team.
This project is created for educational purposes as part of the Codestorm AI Competition.
Built with ❤️ for the Codestorm AI Competition Final Round