Agentic Postgres Challenge Submission
dAttendance: An Agent-First Attendance Platform on Smart Postgres
Tags: devchallenge # agenticpostgreschallenge # ai # postgres
This is a submission for the Agentic Postgres Challenge with Tiger Data
What I Built dAttendance is a modern, AI-powered, multi-tenant attendance management system designed for educational institutions. It automates attendance using face recognition, but with a unique twist: it’s built as an agent-first application powered by Agentic Postgres.
My goal was to create a system where AI agents and human administrators can collaborate safely and efficiently. The platform supports multiple institutions with complete data isolation and provides distinct roles (Super…
Agentic Postgres Challenge Submission
dAttendance: An Agent-First Attendance Platform on Smart Postgres
Tags: devchallenge # agenticpostgreschallenge # ai # postgres
This is a submission for the Agentic Postgres Challenge with Tiger Data
What I Built dAttendance is a modern, AI-powered, multi-tenant attendance management system designed for educational institutions. It automates attendance using face recognition, but with a unique twist: it’s built as an agent-first application powered by Agentic Postgres.
My goal was to create a system where AI agents and human administrators can collaborate safely and efficiently. The platform supports multiple institutions with complete data isolation and provides distinct roles (Super Admin, Institute Admin, Teacher, Student) to manage the entire academic ecosystem. The core of the system is an AI agent that processes class photos/videos to mark attendance, with a human-in-the-loop workflow for verification, all orchestrated through the power of database forking.
Demo Project Repository: https://github.com/Abid-Noyon/digitalAttendance/tree/development Live Application: https://dt.promely.com/
How to Use and Test dAttendance To experience the full power of the platform, please follow this guide to test the features available for each user role.
Testing Credentials: To fully test the application, please use the following credentials:
-
Superadmin:
-
Username: abid@promely.com
-
Password: abid2552
Admin:
- Username: adminabid@gmail.com
- Password: 8n.30]kK4EW’
Teacher:
- Username: dccteacher@gmail.com
- Password: 8n.30]kK4EW’
Student:
- Username: tanjim@gmail.com
- Password: 8n.30]kK4EW’
- The Teacher Experience: AI Collaboration with Database Forks Log in as a Teacher. The Teacher Dashboard is the central hub for managing courses and orchestrating the AI attendance agent.
Walkthrough:
- From the “My Courses” list, select a course to manage.
- Click to take attendance and upload a class photo or video. This action triggers our AI agent and, crucially, creates a fast, zero-copy database fork for this specific session.
- You’ll receive a real-time notification when the AI agent has finished processing the attendance within the isolated fork.
- Navigate to the “Review Attendance” page. Here, you are interacting with the forked data, not the live production database. You can safely:
- Confirm students the AI recognized with high confidence.
- Verify or correct the AI’s “best guesses” for uncertain faces.
- Manually mark any remaining students.
- Once you finalize the record, the verified data is merged back into the main database, and the temporary fork is discarded. This showcases our safe, agent-human collaboration workflow.
![Teacher: My Courses here]](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/n54dng99why3qddm35yd.png)
- The Student Experience: Real-Time Feedback Log in as a Student. The student dashboard provides transparent access to personal attendance records.
Walkthrough:
- Students can view all their enrolled courses and current attendance percentages.
- After a teacher finalizes an attendance session, students receive a real-time notification and can see their updated status in the attendance grid. This provides immediate, accurate feedback.
- Students can also manage their profile photos, which are used to train the facial recognition model.
- The Institute Admin Experience: Smart Search & Management Log in as an Institute Admin. This dashboard is for managing the entire institution, powered by intelligent search.
Walkthrough:
- Use the Smart Search bar to query your institution’s data using natural language, powered by pg_text. Try queries like:
- “Show me all students in the Computer Science department”
- “Find teachers who teach more than two courses”
- Manage the academic structure by creating departments and courses.
- Approve pending profiles for new teachers and students, ensuring data integrity before they are entered into the system.
- The Super Admin Experience: Platform-Wide Control Log in as a Super Admin. This dashboard provides a high-level view of all institutions on the platform.
Walkthrough:
- Monitor aggregate statistics across all institutions.
- Manage institution accounts (activate, deactivate, or onboard new ones).
- Oversee the health of background services, like the Celery workers that power our AI agents.
How I Used Agentic Postgres dAttendance leverages several key Agentic Postgres features to deliver a unique and powerful experience:
- Fast, Zero-Copy Forks for Agent-Powered Attendance Review:
- When a teacher initiates an attendance session, dAttendance dynamically creates a zero-copy database fork.
- An AI agent (our facial recognition module) processes attendance data exclusively within this isolated fork. This ensures the main production database remains untouched and safe during AI processing.
- Teachers access a “Review Attendance” dashboard that queries this temporary fork. Here, they can manually verify, correct, and approve the AI-generated attendance.
- Upon approval, the validated data is seamlessly merged back into the main database, and the fork is discarded. This workflow exemplifies multi-agent collaboration (AI agent + human teacher) and provides a robust, auditable mechanism for AI-driven data entry.
pg_textfor Natural Language “Smart Search”:
- I’ve implemented an intelligent search for administrators, powered by pg_text.
- An underlying AI agent interprets natural language queries and translates them into efficient pg_text searches and SQL operations, providing relevant results instantly. This transforms data retrieval from rigid queries to intuitive conversations.
- Tiger CLI for Admin Productivity Hacks:
- To enhance administrator productivity, I’ve built a custom CLI tool (tiger_admin.py) that wraps the Tiger CLI.
- This tool allows for quick management of database forks, such as creating a new database branch for an academic term (create-term-fork ) or cleaning up old, merged forks. This significantly simplifies database lifecycle management.
Overall Experience Building with Agentic Postgres has been an eye-opening experience. The fast, zero-copy forking feature is a game-changer for AI-driven workflows, providing unparalleled isolation and safety for agent operations. It allowed me to design a human-in-the-loop system that I wouldn’t have easily achieved with traditional database setups.
The power of pg_text for enabling natural language interaction with complex datasets was also a pleasant surprise, making the application significantly more user-friendly and intelligent. The ability to quickly spin up and manage database environments via the Tiger CLI also greatly accelerated development. This challenge has truly pushed the boundaries of what I thought was possible with a database, proving that Postgres can indeed be the brain of sophisticated AI systems.