What problem does it solve? Raw design values (hex colors, typography tuples, spacing pixels, radii) scattered across many SCREEN_SPEC files need to be converged into canonical foundations docs without losing provenance or silently resolving conflicts. ## Core Features & Use Cases - Token extraction: Parses SCREEN_SPEC files to union hex colors, typography tuples, spacing values, and radii, then buckets each into role tokens per per-foundation rules. - Idempotent writes: Re-runs only add new tokens, never overwrite locked role mappings, and route conflicts or off-grid values to a Review queue section. - Provenance tracking: Every token cites its source SCREEN_SPEC paths and usage counts, and TASK_STATE.md gets an extraction summary line. - Use Case: After documenting a dozen screens with raw values, run this to generate foundations/color.md, typography.md, spacing.md, and radii.md as the single source of truth for the design system. ## Quick Start Extract the color, typography, spacing, and radii foundations from all SCREEN_SPEC files under design/screens into the docs/research foundations folder.