This section explains how MIH Bot models project domains, enforces task transitions, and schedules reminders in production using cron-based workers.
Projects provide the governance boundary. Tasks are immutable units tracked within that boundary.
A project acts as a container for team ownership, channel routing, and visibility rules. Each project generates a unique prefix (for example, WEB) that MIH Bot uses to produce task IDs like WEB-T001, WEB-T002, and so on.
Visibility can be Public (discoverable by all permitted users) or Private (restricted to approved members). Dedicated channels allow project updates, embed cards, and reminders to stay context-local.
Every status transition is command-driven and auditable.
Task creation starts in To Do. When the assignee executes /start_task, status transitions to In Progress and timestamp tracking starts.
The assignee submits work with /submit_task, which opens a Discord modal for accomplishments, blockers, and effort notes. Submission transitions the task to Under Review and notifies admins in REVIEW_CHANNEL_ID.
Admins finalize status using approval or rejection actions. Approval marks Done; rejection returns the task to In Progress with feedback attached to the record.
Reminder jobs execute in Philippine Time (PHT) and are gated by status + deadline windows.
Jobs query MongoDB for candidate tasks and suppress reminders for terminal states to reduce alert fatigue. This model ensures high compliance for shift-based and fixed-time assignments.