Skip to content

yashtaksale/focusforge

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

24 Commits
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation


Typing SVG


Β  Β 


🧠 What Problem Does This Solve?

❌ Before FocusForge

  • Students plan randomly with no priority logic
  • Hard subjects get equal time as easy ones
  • No tracking β†’ no accountability
  • Phone distractions silently kill study sessions
  • Exam panic from poor time management

βœ… After FocusForge

  • AI generates a priority-weighted timetable
  • Difficult subjects automatically get more time
  • Real-time progress tracking with visual charts
  • AI detects phone usage and alerts you instantly
  • Calm, structured, deadline-aware scheduling

πŸ’‘ Core Insight: Students don't fail from lack of knowledge β€” they fail from poor planning and constant distractions. FocusForge solves both.


πŸ–ΌοΈ Screenshots

🏠 Dashboard β€” Add Subjects & Track Progress

Dashboard

πŸ”΄ Deep Focus Mode β€” AI Phone Detection Live

Deep.Focus.Mode.mp4

πŸ“… Generated Timetable β€” Priority-Weighted Sessions

Generated Timetable

✨ Features

πŸ“… Smart Scheduling Engine

Generates a full study timetable based on subject difficulty, exam dates, and your available hours. Every session includes a specific time slot, study approach, and step-by-step actions.

πŸ”΄ Deep Focus Mode (Most Unique Feature)

A dedicated focus page powered by TensorFlow.js + COCO-SSD. The AI watches through your webcam and detects phone usage in real time. Get caught β†’ instant alert. A distraction counter tracks every lapse.

⚑ Priority-Weighted Algorithm

Not all subjects deserve equal time. The engine computes a priority_score per subject and allocates sessions accordingly β€” urgent + difficult subjects always come first.

πŸ“Š Progress Dashboard

Visual doughnut chart with per-subject completion bars. See your overall progress percentage, completed sessions, and remaining workload at a glance.

πŸ”” Smart Study Reminders

Browser push notifications scheduled to fire at 30 min, 10 min, 5 min, and the exact moment your session starts β€” so you never miss a slot.

🧠 Study Strategy Engine

Detects whether a subject is Coding, Mathematics, or Theory and generates a tailored learning approach β€” not just hours allocated, but how to use them effectively.


⚑ Core Algorithm

The heart of FocusForge is its priority-weighted scheduling engine:

priority_score = difficulty_weight Γ— time_sensitivity_factor

πŸ“Š Difficulty Weights

Level Weight Effect
🟒 Easy 1.0Γ— Fewer, lighter sessions
🟑 Medium 2.0Γ— Balanced allocation
πŸ”΄ Hard 3.5Γ— More, intensive sessions

⏳ Time Sensitivity

Days to Exam Multiplier Label
≀ 3 days 1.5Γ— 🚨 Critical
≀ 7 days 1.2Γ— πŸ”₯ High
> 7 days 1.0Γ— πŸ“… Normal

Result: A Hard subject with 3 days left gets 3.5 Γ— 1.5 = 5.25Γ— the weight of an Easy subject with plenty of time β€” automatically pushed to earlier, longer, higher-priority sessions.


πŸ› οΈ Tech Stack


Python 3.11

Django 6.0

JavaScript

HTML5

CSS3

SQLite

TensorFlow.js

πŸ—οΈ System Architecture

β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
β”‚           Browser  (HTML / CSS / JS)        β”‚
β”‚    Chart.js  Β·  TensorFlow.js  Β·  Fetch API β”‚
β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”¬β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜
                     β”‚  REST API calls
β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β–Όβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
β”‚          Django REST Framework              β”‚
β”‚   Authentication  Β·  Serializers  Β·  Views  β”‚
β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”¬β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜
                     β”‚
β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β–Όβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
β”‚              Service Layer                  β”‚
β”‚   services.py  β€”  Scheduling Algorithm      β”‚
β”‚   Priority score  Β·  Time allocation        β”‚
β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”¬β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜
                     β”‚
β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β–Όβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
β”‚             SQLite Database                 β”‚
β”‚         Subject  Β·  StudySession            β”‚
β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜

Clean separation of concerns β€” the frontend is fully decoupled from the backend via REST API. Any layer can be swapped independently.


πŸ“‘ API Reference

Method Endpoint Description
GET /api/subjects/ List all subjects
POST /api/subjects/ Create a subject
PUT /api/subjects/<id>/ Update subject details
DELETE /api/subjects/<id>/ Delete a subject
POST /api/generate/ Generate full timetable
GET /api/sessions/ Get all study sessions
PATCH /api/sessions/<id>/complete/ Mark session complete
GET /api/progress/ Overall progress stats
GET /api/timetable/export_pdf/ Export plan as PDF

πŸ—ƒοΈ Data Model

User
 └── Subject
      β”œβ”€β”€ name
      β”œβ”€β”€ exam_date
      β”œβ”€β”€ difficulty              (1=Easy Β· 2=Medium Β· 3=Hard)
      β”œβ”€β”€ selected_topics         (JSON array)
      β”œβ”€β”€ study_start_time
      └── study_end_time
           β”‚
           β–Ό
      StudySession
        β”œβ”€β”€ date
        β”œβ”€β”€ start_time / end_time
        β”œβ”€β”€ hours_allocated
        β”œβ”€β”€ priority_label        (Critical Β· High Β· Medium Β· Low)
        β”œβ”€β”€ approach
        β”œβ”€β”€ technique
        β”œβ”€β”€ steps                 (JSON array)
        └── completed             (Boolean)

βš™οΈ Quick Start

# 1. Clone the repository
git clone https://github.com/yashtaksale/focusforge.git
cd focusforge/studyplanner

# 2. Create and activate virtual environment
python -m venv venv
source venv/bin/activate        # Mac / Linux
venv\Scripts\activate           # Windows

# 3. Install dependencies
pip install -r requirements.txt

# 4. Environment setup
echo "SECRET_KEY=your-secret-key-here" > .env
echo "DEBUG=True" >> .env

# 5. Run migrations and start server
python manage.py migrate
python manage.py runserver

Open http://localhost:8000 β€” register an account and generate your first plan in under a minute.


πŸ“ Project Structure

focusforge/
β”œβ”€β”€ manage.py
β”œβ”€β”€ requirements.txt
β”œβ”€β”€ .env
β”‚
β”œβ”€β”€ planner/                    ← main application
β”‚   β”œβ”€β”€ models.py               ← Subject, StudySession models
β”‚   β”œβ”€β”€ serializers.py          ← DRF serializers
β”‚   β”œβ”€β”€ views.py                ← API endpoints
β”‚   β”œβ”€β”€ services.py             ← 🧠 scheduling algorithm
β”‚   β”œβ”€β”€ urls.py
β”‚   └── tests.py
β”‚
β”œβ”€β”€ studyplanner/               ← project configuration
β”‚   β”œβ”€β”€ settings.py
β”‚   └── urls.py
β”‚
β”œβ”€β”€ templates/
β”‚   β”œβ”€β”€ index.html              ← main dashboard
β”‚   β”œβ”€β”€ focus.html              ← deep focus mode
β”‚   └── login.html
β”‚
└── static/
    β”œβ”€β”€ css/style.css
    └── js/script.js

πŸ—ΊοΈ Roadmap

Status Feature
βœ… Shipped Priority-weighted timetable generation
βœ… Shipped Deep Focus Mode with AI phone detection
βœ… Shipped Progress dashboard with Chart.js
βœ… Shipped Smart browser push notifications
βœ… Shipped PDF timetable export
βœ… Shipped Topic-based session scheduling
πŸ”„ Planned Mobile app (React Native)
πŸ”„ Planned Cloud deployment (Render / AWS)
πŸ”„ Planned AI-powered topic recommendations
πŸ”„ Planned Predicted exam readiness score
πŸ”„ Planned Collaborative study rooms

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

Yash Taksale
Computer Science Engineering

Β 

⭐ If FocusForge impressed you, drop a star β€” it takes 2 seconds and means everything.


"Discipline beats motivation. Motivation is fleeting. Systems are permanent."

About

AI-powered study planner with priority-based timetable generation, progress tracking, and Deep Focus Mode with live phone detection.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors