> ## Documentation Index
> Fetch the complete documentation index at: https://calendar-effects.mintlify.site/llms.txt
> Use this file to discover all available pages before exploring further.

# 0003. An expandable event calendar

* **Date:** 2026-10-26
* **Status:** Agreed 2026-11-25 (proposed by Mahad)
* **Agreed by:** Mahad (2026-11-25), for the team

## Context

The plan fixed three events: Black Friday, Cyber Monday and Prime Day. We want to be able to add others, such as Halloween or Chinese New Year, without rewriting the pipeline each time.

## Decision

Events are data, not code:

* **`config/event_types.csv`** lists every event type, with a category, a region, an in-scope flag and a **date rule**: `fixed`, `nth_weekday`, `offset` or `listed`.
* **`config/event_dates.csv`** holds sourced dates for `listed` events, such as lunar-calendar holidays and announced sales.
* **A's calendar builder** turns both files into the `events` table. The `events` table gains an `event_end_date` column for multi-day events.
* Pipeline code reads events only through that table and `common.contracts.load_event_types`, never by hard-coded names.
* `tests/test_event_calendar.py` checks every row, so adding an event can't silently break anything.

In scope to start: US Thanksgiving (as an anchor), Black Friday, Cyber Monday, Prime Day, Halloween and Chinese New Year. Candidates (`in_scope = no`): Canadian Thanksgiving, Christmas, Boxing Day, Singles' Day, Valentine's Day and Diwali.

## Alternatives considered

* **Hard-coded event list in code:** simplest, but every new event means a code change in several places.
* **A holidays library only:** it doesn't cover company sales like Prime Day, and a calendar in our own repo is easier to cite and check.

## Consequences

* **A:** the calendar builder implements the four rule types, fills `event_dates.csv` with sources, and verifies dates by hand (as the plan already says).
* **C and D:** treat `event_type` as an open set. Group results by `category` and `region` from the registry.
* **B:** decide which Wikipedia pages represent each event's attention (e.g., `Halloween`, `Chinese_New_Year`).
* **Scope:** every added event is more analysis and more report space. Keep `in_scope = yes` to what the team can explain in five pages.


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.