1 Commits

Author SHA1 Message Date
Elie Habib
f210c5511a feat(regulatory): add tier classification and Redis publish (#2691)
* feat(regulatory): add tier classification and Redis publish

Builds on the fetch/parse layer from #2564. Adds keyword-based tier
classification (high/medium/low/unknown) and publishes to Redis via
runSeed with 6h TTL.

- HIGH: enforcement, fraud, penalty, injunction, etc.
- MEDIUM: rulemaking, guidance, investigation, etc.
- LOW: routine notices matching title patterns
- Register REGULATORY_ACTIONS_KEY in cache-keys.ts

Closes #2493

Co-authored-by: Lucas Passos <lspassos1@users.noreply.github.com>

* fix(regulatory): reject empty payloads, add health monitoring

- validateFn now requires actions.length > 0 to prevent overwriting
  a healthy snapshot with an empty one on parser regression
- Register regulatory:actions:v1 in STANDALONE_KEYS (api/health.js)
- Add seed-meta:regulatory:actions to SEED_META (maxStaleMin: 360,
  3x the 2h cron interval)
- Add seed-health.js monitoring (intervalMin: 120)

---------

Co-authored-by: Lucas Passos <lspassos1@users.noreply.github.com>
2026-04-04 23:19:33 +04:00