TL;DR
Regnotify is an integrated ecosystem designed to eliminate the “registration race” common in AUC. By synthesizing a Telegram Bot for instant notifications, a Web Scraper to monitor university databases, and a Backtracking Algorithm to generate conflict-free schedules, the system removes the need for manual monitoring and provides students with an optimized path to course enrollment.
Problem
In many universities, high-demand courses have strictly limited seating. Students are often forced to manually refresh web portals repeatedly to secure a “dropped” seat—a high-friction experience where the primary barrier to entry is the lack of real-time information.
Existing solutions were either manual (repetitive page refreshing) or passive (static waitlists). There was a clear need for an active system that could:
- Monitor database changes in real-time.
- Notify users instantly via a mobile-friendly interface.
- Optimize the resulting schedule based on complex constraints, such as “Hidden Labs” and overlapping time blocks.
Design Iterations
The system architecture evolved through three distinct engineering phases:
1. The Data Acquisition Layer (Scraping & Parsing)
The foundation of the system is a robust scraper (Banner.py). Moving beyond standard HTTP requests, the system implements multi-pass logic to query the university’s backend. It parses complex HTML tables to extract critical metadata, including CRNs, instructor names, and—most importantly—real-time remaining seat counts.
2. The Notification Engine (Delta-Logic)
The Notifier module serves as the system’s “brain.” Rather than broadcasting raw data, it performs a differential analysis:
- It compares the current state of the database against the previous scrape.
- If a change in
remaining_seatsis detected, it triggers an asynchronous notification via the Telegram API. - This logic ensures that users are only alerted when actionable changes occur, significantly reducing “noise” while maintaining high-speed delivery.
3. The Scheduling Algorithm (Backtracking)
To navigate the complexities of scheduling multiple courses across varying days and times, I implemented a backtracking algorithm in schedule_builder.py.
- Constraint Satisfaction: The algorithm ensures that no two courses overlap in time.
- Dynamic Filtering: It accounts for “Hidden Labs” by adjusting logic for specific course sections.
- Optimization: It generates multiple valid schedule permutations, allowing users to select the configuration that best aligns with their personal preferences.
Technical Details
Automated State Management
The Telegram bot utilizes a ConversationHandler to manage complex user workflows. This architecture allows the system to guide users through a multi-step onboarding process—selecting semesters, inputting CRNs, and confirming selections—while maintaining state across asynchronous interactions.
Data Persistence & Scalability
I utilized Deta DB for its low-latency performance and seamless integration with Python. The database schema is partitioned into three primary modules:
- Banner: Current course availability data.
- Users: Telegram IDs and personalized user preferences.
- Stats: System health metrics (e.g., tracking the number of unique courses per semester).
Backend Architecture
The system employs a dual-backend architecture to optimize for different use cases:
- FastAPI: Powers the high-concurrency “Notifier” service, handling incoming webhooks and automated scraping tasks.
- Flask: Powers the user-facing web portal, providing a streamlined GUI for students to manage profiles and generate schedules.
Results & Key Metrics
- Real-time Alerting: Reduced the latency between a seat becoming available and a student notification to under 10 minutes (depending on the scraping interval).
- Automated Validation: The
CourseDataExtractorvalidates CRNs against the master database before allowing a user to add them to their “watch list,” ensuring data integrity. - Conflict-Free Guarantee: The backtracking algorithm ensures that any generated schedule is mathematically guaranteed to have zero time-block overlaps.
Samples from the Bot’s Telegram Interface
1. Course Availability Notification
2. Adding a Course to the Watchlist
3. Dropping a Course from the Watchlist
4. Finding Core Courses in certain Time Blocks
Current Status
Unfortunately, the system is currently not operational due to the university’s recent migration to a new registration platform as well as Deta has been discontinued. However, the system’s architecture and algorithms remain a strong foundation for future iterations, and I am actively exploring alternative hosting solutions and scraping methodologies to restore functionality.