Releases: deepdeyiitgn/studybot
StudyBot v1
Hi, I'm Deep Dey 
AI-Powered Learner | JEE Aspirant | Content Creator | Building Tomorrow, Today
📌 Table of Contents
- About Me
- StudyBot — Project Overview
- Tech Stack
- Pinned Projects
- Journey & Milestones
- Get Involved
- Contact & Socials
About Me 🚀
Hello! I’m Deep Dey, a JEE aspirant and creator building StudyBot — a modular Discord assistant to help students study smarter and play lighter.
StudyBot — Project Overview
StudyBot is a modular Discord bot that blends study tools (reminders, todos, announcements) with light social games and community features. It supports both prefix (!) and slash (/) commands and is designed to be extended via cogs.
Key features:
- Interactive Quiz with leaderboard & detailed feedback
- Reminders, Todos, Announcements, AFK system
- Games: Memory match, word scramble, math challenge, emoji quiz
- Ads/promotions, media handling, and admin tools
New Study-focused features (added):
- Pomodoro / Focus timer with DM notifications and session logging
- Daily study logs and weekly leaderboard
- Streak and productivity tracker
- Doubt collector for mentors and a
/motivateAI-powered motivational reply (uses Gemini when configured)
StudyBot — Features & Usage (detailed)
This section documents the study-first features in StudyBot, how to use them from Discord, and how they connect to the website and AI services.
- Pomodoro Focus Timer
- What: Start a focused study session (default 25 min) and get notified when time's up.
- Why: Encourages focused study with short sprints and breaks.
- How (Discord):
/focus start 25or!focus start 25— stop with/focus stop. - Website: active sessions are exposed at
/api/active_focusfor dashboard display.
- Daily Study Log System
- What: Log study time by subject/topic and view consolidated history.
- Why: Track study hours and generate weekly insights.
- How (Discord):
/log math 2h integrationor!log subject:math time:2h topic:integration. - View:
/logs viewor!logs viewto list recent logs.
- Study Streak & Productivity Tracker
- What: Automatically tracks daily study streaks and highest streak.
- Why: Habit building and motivation via streaks.
- How (Discord):
/streakor!streakshows current and highest streak. - Storage: streaks are persisted in the SQLite DB (
streakstable).
- Reminder & Schedule Manager
- What: Schedule one-off or relative reminders that trigger in-channel or via DM.
- Why: Keeps users accountable for study sessions and events.
- How (Discord):
/remind 19:00 "Start Organic Chemistry"or!remind 10m Take a break. - Notes: Reminders are persisted and dispatched by a background scheduler.
- Doubt Collector
- What: Submit study doubts/questions that create private threads for mentor review.
- Why: Organizes student questions and provides a private workflow for mentors.
- How (Discord):
/doubt How do I solve projectile motion?or!doubt <question>. - Admin:
!set_doubt_channel #channeland!set_mentor_role @Mentorto configure.
- Motivational AI Responder
- What: Sends motivational replies and context-sensitive encouragements.
- Why: Helps students stay motivated when they report low morale.
- How (Discord):
/motivateor/motivate I feel demotivated— will use Gemini if configured, otherwise fall back to built-in prompts.
- Study Partner Mode
- What: Simulates a study partner with periodic check-ins in a channel.
- Why: Provides social accountability and regular reminders during focus sessions.
- How (Discord):
/partner start 25to start a partner session and/partner stopto end.
- Leaderboard (Competitive Mode)
- What: Ranks students by logged study time (per-server leaderboard) and displays XP/levels.
- Why: Drives friendly competition and engagement.
- How (Discord):
/leaderboard,/rankshows your level and XP. - Website: leaderboard data can be pulled from
/api/leaderboardfor the dashboard.
- Quote / Motivation of the Day
- What: Daily motivational quote posted automatically (configurable hour).
- Why: Keeps morale high and provides a small, positive nudge every day.
- How: Configured by
QUOTE_HOUR(UTC) in environment orconfig.json.
- Focus Room (Voice Channel Guard)
- What: Make a voice channel a distraction-free focus room; auto-mute new joiners.
- Why: Maintain silence and reduce interruptions during voice study sessions.
- How (Discord):
/focusroom start 30(requires Manage/Mute permissions) and/focusroom stop.
- Live Ping & Uptime Dashboard
- What: Small Flask site bundled with the bot exposes endpoints used by the website.
- Why: Show real-time bot status and active sessions on your site.
- Endpoints:
/api/active_focus,/stats,/api/leaderboard(checkbot.pyfor exact routes).
- StudyBot Analytics Page
- What: Visualize users, total hours, streaks and subject breakdowns.
- Why: Helps server admins and students review progress over time.
- How: The site reads aggregated data from the bot's API endpoints and the DB.
- AI Study Suggestion System
- What: Suggests next subject or topic to balance study time using simple heuristics or Gemini.
- Why: Helps students target weak subjects and balance preparation.
- How: The mentor cog analyzes study logs; improvements route through the AI Mentor when configured.
- Progress Tracker (per-subject)
- What: Track subject-wise completion percentage (e.g. JEE progress tracker).
- How (Discord):
/progress update math 70and/progress view. - Website: shows progress bars per subject.
- (Voice input control is an optional advanced feature)
- What: (MVP not included) Accept voice commands or short audio clips to control the bot (start timers, logs).
- Why: Hands-free interaction.
- Notes: This requires speech-to-text (Whisper/Cloud) and is marked as an enhancement.
- Voice Command Mode (experimental)
- What & How: If implemented, the bot can parse short audio uploads or VC speech and map to commands like
start timer 30.
- AI Mentor Mode
- What: Generates personalized revision plans using Gemini (or mock fallback text).
- How (Discord):
/mentor plan chemistry 5or!mentor plan chemistry 5. - Notes: Requires
gemini_api_keyconfigured to use real model generation; otherwise the cog returns a helpful mock plan.
- Reward & Level System
- What: Earn XP for study logs, streaks and focus sessions; unlock badges and titles.
- How:
/rankshows XP, level, and badges. The DB stores achievements and wallets for future economy features.
- (Custom reports and exports)
- What: Weekly exports or JSON snapshots can be added; currently, DB tables and endpoints make it straightforward to build exports.
- AI Productivity Coach (weekly summaries)
- What: Weekly performance analysis and actionable feedback generated by Gemini or fallback templates.
- How: Implemented as a planned scheduled job — can be added to
cogs/ascoach.pyto send summaries to users or channels.
Bonus visual features
- Animated favicon, active-users widget, rotating banners and a live quote ticker — the site includes placeholders and examples in
index.html.
How to use the most common study commands (examples)
-
Start a focus session (Pomodoro):
/focus start 25— starts a 25-minute session/focus stop— stops and credits the session
-
Log study time manually:
/log math 2h integrationor!log subject:math time:2h topic:integration
-
View today's/your recent logs:
/logs view
-
Streaks & ranks:
/streak— your streak/rank— your level, XP and streak
-
Reminders & schedule:
/remind 18:30 Start Organic Chemistry!remind 10m Take a short break
-
Doubts:
/doubt How do I approach projectile motion?- Admins:
/set_doubt_channel #doubtsand/set_mentor_role @Mentor
-
Study partner:
/partner start 50— starts a 50-minute co-study session in the channel
-
Focus room (voice):
/focusroom start 30— lock voice channel into focus mode (auto-mutes new joiners)
-
AI Mentor & Coach:
/mentor plan chemistry 5— generates a 5-day plan (Gemini if configured)
Gemini / AI Notes
- To enable Gemini-based responses, add your API key to
config.jsonor.envasgemini_api_key. - The mentor cog (
cogs/mentor.py) will use Gemini when available and fall back to a helpful mock plan otherwise. - For production usage, be mindful of API quotas and set reasonable timeouts in your environment.
Troubleshooting
- If slash commands don't appear: wait a few minutes; the bot syncs commands on startup. Use
python bot.py --syncif available. - If reminders or scheduled jobs don't run reliably: consider installing
APSchedulerand wiring it into the bot for robust scheduling. - Database errors: ensure
aiosqliteis installed and thedata/folder is writable. The DB file isdata/studybot.db.
Contributing & Next steps
- Add new cogs in the
cogs/folder and exportasync def setup(bot). - Suggested follow-ups:
- Consolidate reminder persistence into ...