Plans004 2026 02 20 Format Layer
Completed
- T-001: Scaffold @packages/format package
- T-002: Define Report TypeScript types
- T-003: Implement DuckDB client helper
- T-004: revenue.ts — Revenue section reader
- T-005: orders.ts — Program progress section reader
- T-006: marketing.ts — Channel marketing section reader
- T-007: schools.ts — School progress section reader
- T-008: report.ts — Report assembler
- T-009: index.ts — CLI entry point
- T-010: bun install + type-check
- T-011: End-to-end format verification
In Progress
- None yet
Blocked
- None
Pending
- None
Learnings
best_yearwas implemented per-unit for the same month across years.Reportand section types are exported from@packages/format/@source/index.tsfor downstream consumers.bun run --filterexecutes in package context, so DB paths should be resolved from project root.duckdb-asyncwas unstable under Bun in this flow;@duckdb/node-apiis stable in-repo.
Questions
- None yet
Next
- Use
output/monthly/2026-02-report.jsonas the handoff input for Plan 006 (Present layer). - Keep
@packages/formatbindings on@duckdb/node-apiunless Bun runtime compatibility changes.