Skip to content

Latest commit

Β 

History

1 Commit

Folders and files

NameName
Last commit message
Last commit date
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

AI Smart Notes App

An AI-powered study and knowledge assistant that converts topics and questions into structured, easy-to-understand study notes.

πŸ“Œ Project Overview

AI Smart Notes App is a full-stack web application designed to help students learn faster and organize knowledge more effectively.

A user can enter a topic or question such as:

Explain Machine Learning in detail.

The application uses AI to generate structured learning content including:

  • Short Summary
  • Simple Explanation
  • Important Points
  • Key Terms
  • Step-by-Step Explanation
  • Examples
  • Advantages and Disadvantages
  • Frequently Asked Questions
  • Study Notes

✨ Features

πŸ€– AI Study Assistant

Generate intelligent explanations and notes from any topic or question.

πŸ“ Smart Notes

Convert large or complex topics into organized study material.

πŸ“š Structured Learning

AI-generated responses can be organized into:

  1. Summary
  2. Simple Explanation
  3. Important Points
  4. Key Terms
  5. Detailed Explanation
  6. Examples
  7. Advantages
  8. Disadvantages
  9. FAQs

πŸ” Authentication

The backend supports user authentication using JWT.

🌐 Full-Stack Architecture

The application is designed with a separate frontend and backend.

πŸ› οΈ Technology Stack

Frontend

  • React
  • Vite
  • JavaScript
  • HTML5
  • CSS3

Backend

  • Python
  • Flask
  • Flask-CORS
  • Python-dotenv
  • Requests
  • PyJWT
  • OpenAI API

Development Tools

  • VS Code
  • PowerShell
  • npm
  • Python Virtual Environment

πŸ“ Project Structure

AI-Smart-Notes-App/
β”‚
β”œβ”€β”€ README.md
β”œβ”€β”€ requirements.txt
β”œβ”€β”€ .env
β”‚
β”œβ”€β”€ backend/
β”‚   β”œβ”€β”€ app.py
β”‚   β”‚
β”‚   β”œβ”€β”€ config/
β”‚   β”‚   └── config.py
β”‚   β”‚
β”‚   β”œβ”€β”€ routes/
β”‚   β”‚   β”œβ”€β”€ auth_routes.py
β”‚   β”‚   └── ...
β”‚   β”‚
β”‚   β”œβ”€β”€ models/
β”‚   β”‚   └── ...
β”‚   β”‚
β”‚   └── services/
β”‚       └── ...
β”‚
β”œβ”€β”€ frontend/
β”‚   β”œβ”€β”€ package.json
β”‚   β”œβ”€β”€ index.html
β”‚   β”œβ”€β”€ src/
β”‚   β”‚   β”œβ”€β”€ App.jsx
β”‚   β”‚   β”œβ”€β”€ main.jsx
β”‚   β”‚   β”œβ”€β”€ components/
β”‚   β”‚   └── pages/
β”‚   β”‚
β”‚   └── public/
β”‚
└── .venv/

βš™οΈ Backend Setup

Open PowerShell in the project directory.

1. Create virtual environment

python -m venv .venv

2. Activate virtual environment

.venv\Scripts\Activate.ps1

You should see:

(.venv)

3. Install dependencies

python -m pip install -r requirements.txt

If openai or PyJWT is missing:

python -m pip install openai PyJWT

4. Configure environment variables

Create a .env file in the project root.

OPENAI_API_KEY=your_api_key_here
SECRET_KEY=your_secret_key

Do not commit .env or your API key to GitHub.

5. Run backend

Because the backend uses imports such as config.config and routes.auth_routes, run it from the backend directory:

cd backend
python app.py

The backend should start at:

http://127.0.0.1:5000

🎨 Frontend Setup

Open a second PowerShell terminal.

Go to the frontend:

cd "E:\IIT DELHI PROJECT\AI-Smart-Notes-App\frontend"

Install dependencies:

npm install

Run the development server:

npm run dev

Vite should display a URL similar to:

http://localhost:5173

Open that URL in your browser.

▢️ Running the Complete Application

You need two terminals.

Terminal 1 β€” Backend

cd "E:\IIT DELHI PROJECT\AI-Smart-Notes-App\backend"
python app.py

Terminal 2 β€” Frontend

cd "E:\IIT DELHI PROJECT\AI-Smart-Notes-App\frontend"
npm run dev

Then open the frontend URL shown by Vite.

πŸ”‘ Environment Variables

The application may require the following variables:

Variable Purpose
OPENAI_API_KEY Connects the application to the OpenAI API
SECRET_KEY Flask/JWT security
DATABASE_URL Database connection, if configured

Never publish API keys or passwords in source code.

πŸ”Œ API Architecture

The frontend communicates with the Flask backend through HTTP APIs.

Example architecture:

User
  β”‚
  β–Ό
React Frontend
  β”‚
  β”‚ HTTP / REST API
  β–Ό
Flask Backend
  β”‚
  β”œβ”€β”€ Authentication
  β”‚
  β”œβ”€β”€ Notes Management
  β”‚
  β”œβ”€β”€ AI Service
  β”‚
  └── Database
        β”‚
        β–Ό
     Stored Notes

🧠 AI Generation Flow

User enters topic
        β”‚
        β–Ό
React Frontend
        β”‚
        β–Ό
Flask API
        β”‚
        β–Ό
AI Service
        β”‚
        β–Ό
AI-generated content
        β”‚
        β–Ό
Structured Study Notes
        β”‚
        β–Ό
React UI

πŸ§ͺ Example

User Input

Explain Machine Learning in detail.

Generated Content

Summary
Machine Learning is a branch of AI that enables computers
to learn patterns from data.

Important Points
- Supervised Learning
- Unsupervised Learning
- Reinforcement Learning

Key Terms
- Dataset
- Model
- Training
- Prediction

Examples
- Spam detection
- Recommendation systems
- Image classification

πŸš€ Future Enhancements

  • PDF upload and summarization
  • AI-generated quizzes
  • Flashcards
  • Voice input
  • Text-to-speech
  • Note search
  • Note categories
  • Bookmarking
  • Study progress tracking
  • Personalized learning paths
  • Dark mode
  • Multi-language support
  • Export notes to PDF
  • Database integration
  • User dashboard

πŸ”’ Security

For development:

  • Keep API keys inside .env.
  • Never expose secret keys in frontend code.
  • Do not commit .env to Git.
  • Use JWT securely for authentication.
  • Validate user input on the backend.

Add .env to .gitignore:

.env
.venv/
__pycache__/
node_modules/

πŸ› Troubleshooting

npm run dev gives ENOENT package.json

Make sure you are inside the frontend directory:

cd frontend
npm install
npm run dev

ModuleNotFoundError: No module named 'jwt'

Install PyJWT:

python -m pip install PyJWT

ModuleNotFoundError: No module named 'openai'

Install OpenAI:

python -m pip install openai

ModuleNotFoundError: No module named 'config'

Run the backend from the backend directory:

cd backend
python app.py

requirements.txt installation was cancelled

Run:

python -m pip install -r requirements.txt

and allow the installation to finish.

πŸ“„ License

This project is developed as an educational/project application.

πŸ‘¨β€πŸ’» Author

er.chand rain

Built using React, Flask, Python and AI technologies.

About

m a passionate developer interested in Artificial Intelligence, Full-Stack Development, and AI-powered applications.

Topics

Resources

Stars

1 star

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages