feat(regulatory): seed-cross-source-signals.mjs — add REGULATORY_ACTION signal type
Context
Part of the Regulatory RSS pipeline. Depends on #2492 and #2493 (the seeder must be writing regulatory:actions:v1 before this is useful).
This is task 3/4.
What to change in scripts/seed-cross-source-signals.mjs
1. Add to SOURCE_KEYS array
'regulatory:actions:v1',
2. Add to TYPE_CATEGORY map
CROSS_SOURCE_SIGNAL_TYPE_REGULATORY_ACTION: 'policy',
3. Add to BASE_WEIGHT map
CROSS_SOURCE_SIGNAL_TYPE_REGULATORY_ACTION: 2.0,
4. Add extractor function
function extractRegulatoryAction(d) {
const payload = d['regulatory:actions:v1'];
if (!payload) return [];
const cutoff = Date.now() - 48 * 3600 * 1000;
const recent = (payload.actions || [])
.filter(a => new Date(a.publishedAt).getTime() > cutoff && a.tier !== 'low');
if (recent.length === 0) return [];
return recent.slice(0, 3).map(a => {
const tierMult = a.tier === 'high' ? 1.5 : 1.0;
const score = BASE_WEIGHT['CROSS_SOURCE_SIGNAL_TYPE_REGULATORY_ACTION'] * tierMult;
return {
id: `regulatory:${a.id}`,
type: 'CROSS_SOURCE_SIGNAL_TYPE_REGULATORY_ACTION',
theater: 'Global Markets',
summary: `${a.agency}: ${a.title}`,
severity: scoreTier(score),
severityScore: score,
detectedAt: new Date(a.publishedAt).getTime(),
contributingTypes: [],
signalCount: 0,
};
});
}
5. Add to extractors[] array
extractRegulatoryAction,
Severity math
| Tier | Score | scoreTier() result |
|---|---|---|
high |
2.0 × 1.5 = 3.0 | HIGH |
medium |
2.0 × 1.0 = 2.0 | MEDIUM |
low |
filtered out | not emitted |
Composite escalation unlock
'policy' is a new category not currently in TYPE_CATEGORY. Adding it means REGULATORY_ACTION (policy) + VIX_SPIKE (financial) + COMMODITY_SHOCK (economic) = 3 distinct categories in Global Markets → detectCompositeEscalation() fires. This compound scenario (regulatory action during market stress + commodity dislocation) was previously invisible.
Acceptance criteria
regulatory:actions:v1appears inSOURCE_KEYSextractRegulatoryActionadded to extractor list- HIGH-tier actions produce severity
HIGHsignals - MEDIUM-tier actions produce severity
MEDIUMsignals - Missing key returns
[]gracefully - Composite escalation fires in Global Markets when policy + financial + economic categories co-fire
Implemented in #2568.
This wires the regulatory payload into cross-source signals:
- adds
regulatory:actions:v1to the source-key set - introduces
CROSS_SOURCE_SIGNAL_TYPE_REGULATORY_ACTIONwithpolicycategorization and base weight2.0 - emits recent high/medium-tier regulatory actions as
Global Marketssignals - adds focused unit coverage for extractor behavior and policy+financial+economic composite escalation
This branch is currently stacked on #2567, which itself depends on #2564.
Follow-up work remains tracked in #2495.
"Got it! This looks like a solid plan for integrating regulatory actions. I’ll keep an eye on the changes in #2492 and #2493 to make sure everything aligns. Excited to see the composite escalation in action!"
On Mon, Mar 30, 2026, 6:43 PM Lucas Passos @.***> wrote:
lspassos1 left a comment (koala73/worldmonitor#2494) https://github.com/koala73/worldmonitor/issues/2494#issuecomment-4158837146
Implemented in #2568 https://github.com/koala73/worldmonitor/pull/2568.
This wires the regulatory payload into cross-source signals:
- adds regulatory:actions:v1 to the source-key set
- introduces CROSS_SOURCE_SIGNAL_TYPE_REGULATORY_ACTION with policy categorization and base weight 2.0
- emits recent high/medium-tier regulatory actions as Global Markets signals
- adds focused unit coverage for extractor behavior and policy+financial+economic composite escalation
This branch is currently stacked on #2567 https://github.com/koala73/worldmonitor/pull/2567, which itself depends on #2564 https://github.com/koala73/worldmonitor/pull/2564.
Follow-up work remains tracked in #2495 https://github.com/koala73/worldmonitor/issues/2495.
— Reply to this email directly, view it on GitHub https://github.com/koala73/worldmonitor/issues/2494?email_source=notifications&email_token=CAXZCSRJ4UQFBALW6JPPCXT4TMBC3A5CNFSNUABFM5UWIORPF5TWS5BNNB2WEL2JONZXKZKDN5WW2ZLOOQXTIMJVHA4DGNZRGQ3KM4TFMFZW63VKON2WE43DOJUWEZLEUVSXMZLOOSWGM33PORSXEX3DNRUWG2Y#issuecomment-4158837146, or unsubscribe https://github.com/notifications/unsubscribe-auth/CAXZCSW4C34SZHM4O5X7FLL4TMBC3AVCNFSM6AAAAACXERAA3OVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHM2DCNJYHAZTOMJUGY . You are receiving this because you are subscribed to this thread.Message ID: @.***>