Flex — Constraint-Explicit Work Planner
Sole designer, implementer, and verifier
2026-07-01 — present
A local-first work planner that combines recognized load, actual work, leave, and daily/weekly caps into one deterministic allocation contract, exposing infeasible targets as explicit gaps instead of forced over-allocation.
System Architecture
Problem Solving
Forced allocation above remaining capacity would hide an infeasible plan
Apply daily/weekly caps and fixed plans first, compute allocatable time, then return the remaining gap as an explicit state
Preserves hard limits while displaying insufficient_slots and the remaining gap
A date override could unexpectedly overwrite the whole monthly plan
Lock the selected date first, preview conflicts, then deterministically redistribute only the remainder
Shows change scope and conflict boundaries in preview without external writes
Synthetic scenarios
Deterministic fixtures reproduce the code paths and boundaries without operational or personal data.
Project Description
The planner normalizes monthly targets and per-date constraints, applies fixed plans first, and selectively activates only the dates needed for the remaining allocation. When capacity is insufficient, it preserves hard limits and returns the remaining gap and status. The date-override UI previews conflicts and excess while calculating redistribution of the remaining dates; the public implementation stops at this synthetic-fixture preview boundary.
Highlights
- One allocator contract for fixed-plan priority, selective minimum activation, and hard-limit preservation
- Infeasibility exposed as a remaining gap and reason
- Date-override preview and redistribution calculation for remaining dates
- Synthetic scenarios, public-boundary scan, and Python/Playwright CI
Performance Metrics
| Performance Metrics | Before | After |
|---|---|---|
| Infeasible state | Risk of forced allocation | insufficient_slots + gap (hard limits preserved) |
| Date-change scope | Risk of full-month overwrite | fixed date + remainder redistribution (preview and redistribution boundary) |
Tech Decisions
- ▶Restored the existing _minimum_activation flow so minimum work remains a selective activation floor rather than a mandatory seed
- ▶Kept the decision surface reproducible through URL/local state without adding external-system integration
Lessons Learned
- •A planner must model infeasibility before optimizing, or it will distort reality.
- •User overrides remain predictable when the fixed scope is separated from redistribution of the remainder.