euparliamentmonitor 0.9.19 → 0.9.21
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +2 -2
- package/package.json +4 -3
- package/scripts/aggregator/editorial-brief-resolver.d.ts +38 -0
- package/scripts/aggregator/editorial-brief-resolver.js +32 -0
- package/scripts/aggregator/generator/render-one.js +35 -0
- package/scripts/aggregator/html/localize-body.d.ts +32 -0
- package/scripts/aggregator/html/localize-body.js +69 -0
- package/scripts/aggregator/html/shell.d.ts +10 -0
- package/scripts/aggregator/html/shell.js +11 -1
- package/scripts/aggregator/markdown-renderer.d.ts +23 -24
- package/scripts/aggregator/markdown-renderer.js +39 -25
- package/scripts/aggregator/metadata/artifact-highlight.d.ts +15 -22
- package/scripts/aggregator/metadata/artifact-highlight.js +14 -230
- package/scripts/aggregator/metadata/artifact-walker.d.ts +34 -0
- package/scripts/aggregator/metadata/artifact-walker.js +177 -0
- package/scripts/aggregator/metadata/editorial-highlight.d.ts +15 -0
- package/scripts/aggregator/metadata/editorial-highlight.js +53 -0
- package/scripts/aggregator/metadata/priority-finding-highlight.js +7 -2
- package/scripts/aggregator/metadata/resolve-helpers.js +9 -3
- package/scripts/aggregator/metadata/text-utils.js +7 -0
- package/scripts/aggregator/metadata/translated-sibling.d.ts +23 -0
- package/scripts/aggregator/metadata/translated-sibling.js +39 -0
- package/scripts/aggregator/reader-guide/builder.js +3 -1
- package/scripts/aggregator/reader-guide/labels.d.ts +7 -0
- package/scripts/aggregator/reader-guide/labels.js +22 -0
- package/scripts/aggregator/reader-intelligence-guide.d.ts +1 -1
- package/scripts/aggregator/reader-intelligence-guide.js +1 -1
- package/scripts/aggregator/seo-entity-extractor.d.ts +45 -0
- package/scripts/aggregator/seo-entity-extractor.js +211 -0
- package/scripts/constants/articles/breaking-strings-central.d.ts +8 -0
- package/scripts/constants/articles/breaking-strings-central.js +105 -0
- package/scripts/constants/articles/breaking-strings-east.d.ts +8 -0
- package/scripts/constants/articles/breaking-strings-east.js +203 -0
- package/scripts/constants/articles/breaking-strings-nordic.d.ts +8 -0
- package/scripts/constants/articles/breaking-strings-nordic.js +252 -0
- package/scripts/constants/articles/breaking-strings-west.d.ts +8 -0
- package/scripts/constants/articles/breaking-strings-west.js +154 -0
- package/scripts/constants/articles/breaking.d.ts +0 -1
- package/scripts/constants/articles/breaking.js +9 -6
- package/scripts/constants/articles/dashboard/ar.d.ts +8 -0
- package/scripts/constants/articles/dashboard/ar.js +71 -0
- package/scripts/constants/articles/dashboard/da.d.ts +8 -0
- package/scripts/constants/articles/dashboard/da.js +71 -0
- package/scripts/constants/articles/dashboard/de.d.ts +8 -0
- package/scripts/constants/articles/dashboard/de.js +71 -0
- package/scripts/constants/articles/dashboard/en.d.ts +8 -0
- package/scripts/constants/articles/dashboard/en.js +71 -0
- package/scripts/constants/articles/dashboard/es.d.ts +8 -0
- package/scripts/constants/articles/dashboard/es.js +71 -0
- package/scripts/constants/articles/dashboard/fi.d.ts +8 -0
- package/scripts/constants/articles/dashboard/fi.js +71 -0
- package/scripts/constants/articles/dashboard/fr.d.ts +8 -0
- package/scripts/constants/articles/dashboard/fr.js +71 -0
- package/scripts/constants/articles/dashboard/he.d.ts +8 -0
- package/scripts/constants/articles/dashboard/he.js +71 -0
- package/scripts/constants/articles/dashboard/index.d.ts +7 -0
- package/scripts/constants/articles/dashboard/index.js +33 -0
- package/scripts/constants/articles/dashboard/ja.d.ts +8 -0
- package/scripts/constants/articles/dashboard/ja.js +71 -0
- package/scripts/constants/articles/dashboard/ko.d.ts +8 -0
- package/scripts/constants/articles/dashboard/ko.js +71 -0
- package/scripts/constants/articles/dashboard/nl.d.ts +8 -0
- package/scripts/constants/articles/dashboard/nl.js +71 -0
- package/scripts/constants/articles/dashboard/no.d.ts +8 -0
- package/scripts/constants/articles/dashboard/no.js +71 -0
- package/scripts/constants/articles/dashboard/sv.d.ts +8 -0
- package/scripts/constants/articles/dashboard/sv.js +71 -0
- package/scripts/constants/articles/dashboard/zh.d.ts +8 -0
- package/scripts/constants/articles/dashboard/zh.js +71 -0
- package/scripts/constants/articles/dashboard.d.ts +7 -2
- package/scripts/constants/articles/dashboard.js +4 -8
- package/scripts/constants/articles/deep-analysis/ar.d.ts +8 -0
- package/scripts/constants/articles/deep-analysis/ar.js +75 -0
- package/scripts/constants/articles/deep-analysis/da.d.ts +8 -0
- package/scripts/constants/articles/deep-analysis/da.js +75 -0
- package/scripts/constants/articles/deep-analysis/de.d.ts +8 -0
- package/scripts/constants/articles/deep-analysis/de.js +75 -0
- package/scripts/constants/articles/deep-analysis/en.d.ts +8 -0
- package/scripts/constants/articles/deep-analysis/en.js +75 -0
- package/scripts/constants/articles/deep-analysis/es.d.ts +8 -0
- package/scripts/constants/articles/deep-analysis/es.js +75 -0
- package/scripts/constants/articles/deep-analysis/fi.d.ts +8 -0
- package/scripts/constants/articles/deep-analysis/fi.js +75 -0
- package/scripts/constants/articles/deep-analysis/fr.d.ts +8 -0
- package/scripts/constants/articles/deep-analysis/fr.js +75 -0
- package/scripts/constants/articles/deep-analysis/he.d.ts +8 -0
- package/scripts/constants/articles/deep-analysis/he.js +75 -0
- package/scripts/constants/articles/deep-analysis/index.d.ts +7 -0
- package/scripts/constants/articles/deep-analysis/index.js +33 -0
- package/scripts/constants/articles/deep-analysis/ja.d.ts +8 -0
- package/scripts/constants/articles/deep-analysis/ja.js +75 -0
- package/scripts/constants/articles/deep-analysis/ko.d.ts +8 -0
- package/scripts/constants/articles/deep-analysis/ko.js +75 -0
- package/scripts/constants/articles/deep-analysis/nl.d.ts +8 -0
- package/scripts/constants/articles/deep-analysis/nl.js +75 -0
- package/scripts/constants/articles/deep-analysis/no.d.ts +8 -0
- package/scripts/constants/articles/deep-analysis/no.js +75 -0
- package/scripts/constants/articles/deep-analysis/sv.d.ts +8 -0
- package/scripts/constants/articles/deep-analysis/sv.js +75 -0
- package/scripts/constants/articles/deep-analysis/zh.d.ts +8 -0
- package/scripts/constants/articles/deep-analysis/zh.js +75 -0
- package/scripts/constants/articles/deep-analysis.d.ts +4 -3
- package/scripts/constants/articles/deep-analysis.js +3 -7
- package/scripts/constants/articles/localized-keywords-central.d.ts +8 -0
- package/scripts/constants/articles/localized-keywords-central.js +118 -0
- package/scripts/constants/articles/localized-keywords-nordic.d.ts +8 -0
- package/scripts/constants/articles/localized-keywords-nordic.js +303 -0
- package/scripts/constants/articles/localized-keywords.js +4 -2
- package/scripts/constants/articles/swot-builder-central.d.ts +8 -0
- package/scripts/constants/articles/swot-builder-central.js +90 -0
- package/scripts/constants/articles/swot-builder-nordic.d.ts +8 -0
- package/scripts/constants/articles/swot-builder-nordic.js +216 -0
- package/scripts/constants/articles/swot.js +4 -2
- package/scripts/constants/articles/week-ahead-eu.d.ts +12 -0
- package/scripts/constants/articles/week-ahead-eu.js +278 -0
- package/scripts/constants/articles/week-ahead-global.d.ts +12 -0
- package/scripts/constants/articles/week-ahead-global.js +278 -0
- package/scripts/constants/articles/week-ahead.d.ts +4 -7
- package/scripts/constants/articles/week-ahead.js +11 -535
- package/scripts/constants/world-bank/category-map-analysis.d.ts +9 -0
- package/scripts/constants/world-bank/category-map-analysis.js +204 -0
- package/scripts/constants/world-bank/category-map-legislative.d.ts +9 -0
- package/scripts/constants/world-bank/category-map-legislative.js +130 -0
- package/scripts/constants/world-bank/category-map-periodic.d.ts +9 -0
- package/scripts/constants/world-bank/category-map-periodic.js +176 -0
- package/scripts/constants/world-bank/category-map.d.ts +3 -26
- package/scripts/constants/world-bank/category-map.js +8 -501
- package/scripts/discover-untranslated-briefs.js +123 -4
- package/scripts/generators/news-indexes/per-language.js +21 -7
- package/scripts/generators/political-intelligence/html.js +39 -8
- package/scripts/generators/sitemap/html.js +25 -7
- package/scripts/mcp/ep/client.d.ts +0 -1
- package/scripts/mcp/ep/client.js +0 -65
- package/scripts/mcp/ep/error-classifier.d.ts +2 -2
- package/scripts/mcp/ep/error-classifier.js +2 -2
- package/scripts/mcp/ep/tools-list.d.ts +13 -0
- package/scripts/mcp/ep/tools-list.js +79 -0
- package/scripts/mcp/ep-mcp-client.d.ts +1 -0
- package/scripts/mcp/ep-mcp-client.js +1 -0
- package/scripts/mcp/imf/client.d.ts +3 -64
- package/scripts/mcp/imf/client.js +18 -207
- package/scripts/mcp/imf/http-transport.d.ts +92 -0
- package/scripts/mcp/imf/http-transport.js +232 -0
- package/scripts/mcp/transport/connection.d.ts +25 -53
- package/scripts/mcp/transport/connection.js +90 -250
- package/scripts/mcp/transport/process.d.ts +62 -0
- package/scripts/mcp/transport/process.js +147 -0
- package/scripts/mcp/transport/reconnect.d.ts +73 -0
- package/scripts/mcp/transport/reconnect.js +96 -0
- package/scripts/validate-brief-translations.js +122 -6
- package/scripts/constants/articles/breaking-strings-eu.d.ts +0 -7
- package/scripts/constants/articles/breaking-strings-global.d.ts +0 -7
- package/scripts/constants/articles/dashboard-builder-eu.d.ts +0 -7
- package/scripts/constants/articles/dashboard-builder-global.d.ts +0 -7
- package/scripts/constants/articles/deep-analysis-strings-eu.d.ts +0 -7
- package/scripts/constants/articles/deep-analysis-strings-global.d.ts +0 -7
- package/scripts/constants/articles/localized-keywords-eu.d.ts +0 -7
- package/scripts/constants/articles/swot-builder-eu.d.ts +0 -7
|
@@ -0,0 +1,204 @@
|
|
|
1
|
+
// SPDX-FileCopyrightText: 2024-2026 Hack23 AB
|
|
2
|
+
// SPDX-License-Identifier: Apache-2.0
|
|
3
|
+
/**
|
|
4
|
+
* @module Constants/WorldBank/CategoryMapAnalysis
|
|
5
|
+
* @description Analytical category indicator mappings.
|
|
6
|
+
*/
|
|
7
|
+
import { ArticleCategory } from '../../types/index.js';
|
|
8
|
+
import { WB_INDICATORS, N, PRI, SEC } from './indicator-catalog.js';
|
|
9
|
+
/** Analytical category indicator mappings */
|
|
10
|
+
export const CATEGORY_INDICATOR_MAP_ANALYSIS = {
|
|
11
|
+
[ArticleCategory.DEEP_ANALYSIS]: {
|
|
12
|
+
category: ArticleCategory.DEEP_ANALYSIS,
|
|
13
|
+
enrichmentStrategy: 'Maximum enrichment — deep analysis articles should include comprehensive economic context. Use COMMITTEE_INDICATOR_MAP for the primary committee, plus 2-3 cross-cutting indicators.',
|
|
14
|
+
primaryIndicators: [
|
|
15
|
+
{
|
|
16
|
+
indicatorId: WB_INDICATORS.GDP_GROWTH,
|
|
17
|
+
name: N.GDP_GROWTH,
|
|
18
|
+
relevance: 'Macro context for deep analysis',
|
|
19
|
+
usage: 'Establish economic baseline for multi-perspective analysis',
|
|
20
|
+
priority: PRI,
|
|
21
|
+
},
|
|
22
|
+
{
|
|
23
|
+
indicatorId: WB_INDICATORS.UNEMPLOYMENT,
|
|
24
|
+
name: N.UNEMPLOYMENT,
|
|
25
|
+
relevance: 'Social dimension of policy analysis',
|
|
26
|
+
usage: 'Labor market lens for 5-why analysis',
|
|
27
|
+
priority: PRI,
|
|
28
|
+
},
|
|
29
|
+
{
|
|
30
|
+
indicatorId: WB_INDICATORS.CO2_EMISSIONS,
|
|
31
|
+
name: N.CO2,
|
|
32
|
+
relevance: 'Environmental dimension of policy analysis',
|
|
33
|
+
usage: 'Environmental lens for 5-why analysis',
|
|
34
|
+
priority: PRI,
|
|
35
|
+
},
|
|
36
|
+
],
|
|
37
|
+
secondaryIndicators: [
|
|
38
|
+
{
|
|
39
|
+
indicatorId: WB_INDICATORS.GINI_INDEX,
|
|
40
|
+
name: N.GINI,
|
|
41
|
+
relevance: 'Inequality dimension',
|
|
42
|
+
usage: 'Social equity lens for distributional analysis',
|
|
43
|
+
priority: SEC,
|
|
44
|
+
},
|
|
45
|
+
{
|
|
46
|
+
indicatorId: WB_INDICATORS.TRADE,
|
|
47
|
+
name: N.TRADE,
|
|
48
|
+
relevance: 'External dimension',
|
|
49
|
+
usage: 'Geopolitical lens for trade impact analysis',
|
|
50
|
+
priority: SEC,
|
|
51
|
+
},
|
|
52
|
+
],
|
|
53
|
+
maxWBCalls: 5,
|
|
54
|
+
},
|
|
55
|
+
[ArticleCategory.QUARTER_AHEAD]: {
|
|
56
|
+
category: ArticleCategory.QUARTER_AHEAD,
|
|
57
|
+
enrichmentStrategy: 'Quarterly economic outlook covering the next ~90 days (≈3 plenary sessions). Pair headline growth/inflation indicators with the dominant policy domain of the upcoming dossier pipeline.',
|
|
58
|
+
primaryIndicators: [
|
|
59
|
+
{
|
|
60
|
+
indicatorId: WB_INDICATORS.GDP_GROWTH,
|
|
61
|
+
name: N.GDP_GROWTH,
|
|
62
|
+
relevance: 'Quarterly growth trajectory',
|
|
63
|
+
usage: 'Frame the macro backdrop for the upcoming quarter',
|
|
64
|
+
priority: PRI,
|
|
65
|
+
},
|
|
66
|
+
{
|
|
67
|
+
indicatorId: WB_INDICATORS.INFLATION,
|
|
68
|
+
name: N.INFLATION,
|
|
69
|
+
relevance: 'Quarterly price-stability context',
|
|
70
|
+
usage: 'Anchor monetary-policy salience for the quarter',
|
|
71
|
+
priority: PRI,
|
|
72
|
+
},
|
|
73
|
+
],
|
|
74
|
+
secondaryIndicators: [
|
|
75
|
+
{
|
|
76
|
+
indicatorId: WB_INDICATORS.UNEMPLOYMENT,
|
|
77
|
+
name: N.UNEMPLOYMENT,
|
|
78
|
+
relevance: 'Quarterly employment outlook',
|
|
79
|
+
usage: 'Preview labour-market salience',
|
|
80
|
+
priority: SEC,
|
|
81
|
+
},
|
|
82
|
+
],
|
|
83
|
+
maxWBCalls: 3,
|
|
84
|
+
},
|
|
85
|
+
[ArticleCategory.QUARTER_IN_REVIEW]: {
|
|
86
|
+
category: ArticleCategory.QUARTER_IN_REVIEW,
|
|
87
|
+
enrichmentStrategy: 'Quarterly retrospective comparing start-vs-end indicators across ~90 days. Surface delta vs prior quarter to assess legislative throughput against macro conditions.',
|
|
88
|
+
primaryIndicators: [
|
|
89
|
+
{
|
|
90
|
+
indicatorId: WB_INDICATORS.GDP_GROWTH,
|
|
91
|
+
name: N.GDP_GROWTH,
|
|
92
|
+
relevance: 'Quarterly economic outturn',
|
|
93
|
+
usage: 'Benchmark legislative output against growth',
|
|
94
|
+
priority: PRI,
|
|
95
|
+
},
|
|
96
|
+
{
|
|
97
|
+
indicatorId: WB_INDICATORS.UNEMPLOYMENT,
|
|
98
|
+
name: N.UNEMPLOYMENT,
|
|
99
|
+
relevance: 'Quarterly employment outturn',
|
|
100
|
+
usage: 'Assess labour-market direction',
|
|
101
|
+
priority: PRI,
|
|
102
|
+
},
|
|
103
|
+
],
|
|
104
|
+
secondaryIndicators: [
|
|
105
|
+
{
|
|
106
|
+
indicatorId: WB_INDICATORS.INFLATION,
|
|
107
|
+
name: N.INFLATION,
|
|
108
|
+
relevance: 'Quarterly inflation outturn',
|
|
109
|
+
usage: 'Place price stability in context',
|
|
110
|
+
priority: SEC,
|
|
111
|
+
},
|
|
112
|
+
],
|
|
113
|
+
maxWBCalls: 3,
|
|
114
|
+
},
|
|
115
|
+
[ArticleCategory.TERM_OUTLOOK]: {
|
|
116
|
+
category: ArticleCategory.TERM_OUTLOOK,
|
|
117
|
+
enrichmentStrategy: 'Multi-year structural outlook to next EP election. Lean on long-run growth/employment/climate indicators and trade openness to ground term-end mandate-fulfilment probability.',
|
|
118
|
+
primaryIndicators: [
|
|
119
|
+
{
|
|
120
|
+
indicatorId: WB_INDICATORS.GDP_GROWTH,
|
|
121
|
+
name: N.GDP_GROWTH,
|
|
122
|
+
relevance: 'Long-run growth context to election',
|
|
123
|
+
usage: 'Anchor coalition-trajectory narrative in macro reality',
|
|
124
|
+
priority: PRI,
|
|
125
|
+
},
|
|
126
|
+
{
|
|
127
|
+
indicatorId: WB_INDICATORS.UNEMPLOYMENT,
|
|
128
|
+
name: N.UNEMPLOYMENT,
|
|
129
|
+
relevance: 'Long-run employment trajectory',
|
|
130
|
+
usage: 'Connect mandate fulfilment to labour-market outcomes',
|
|
131
|
+
priority: PRI,
|
|
132
|
+
},
|
|
133
|
+
{
|
|
134
|
+
indicatorId: WB_INDICATORS.CO2_EMISSIONS,
|
|
135
|
+
name: N.CO2,
|
|
136
|
+
relevance: 'Climate-target trajectory through term-end',
|
|
137
|
+
usage: 'Score Green-Deal mandate progress',
|
|
138
|
+
priority: PRI,
|
|
139
|
+
},
|
|
140
|
+
],
|
|
141
|
+
secondaryIndicators: [
|
|
142
|
+
{
|
|
143
|
+
indicatorId: WB_INDICATORS.RD_EXPENDITURE,
|
|
144
|
+
name: N.RD,
|
|
145
|
+
relevance: 'Innovation investment over the term',
|
|
146
|
+
usage: 'Frame competitiveness mandate progress',
|
|
147
|
+
priority: SEC,
|
|
148
|
+
},
|
|
149
|
+
{
|
|
150
|
+
indicatorId: WB_INDICATORS.TRADE,
|
|
151
|
+
name: N.TRADE,
|
|
152
|
+
relevance: 'Trade openness over the term',
|
|
153
|
+
usage: 'Frame strategic-autonomy posture',
|
|
154
|
+
priority: SEC,
|
|
155
|
+
},
|
|
156
|
+
],
|
|
157
|
+
maxWBCalls: 4,
|
|
158
|
+
},
|
|
159
|
+
[ArticleCategory.ELECTION_CYCLE]: {
|
|
160
|
+
category: ArticleCategory.ELECTION_CYCLE,
|
|
161
|
+
enrichmentStrategy: 'Dual retrospective + forecast brief around the EP election window. Use the broadest indicator set to ground both mandate-delivery scorecard and seat-projection bands.',
|
|
162
|
+
primaryIndicators: [
|
|
163
|
+
{
|
|
164
|
+
indicatorId: WB_INDICATORS.GDP_GROWTH,
|
|
165
|
+
name: N.GDP_GROWTH,
|
|
166
|
+
relevance: 'Term-spanning growth performance',
|
|
167
|
+
usage: 'Bridge retrospective and forecast halves',
|
|
168
|
+
priority: PRI,
|
|
169
|
+
},
|
|
170
|
+
{
|
|
171
|
+
indicatorId: WB_INDICATORS.INFLATION,
|
|
172
|
+
name: N.INFLATION,
|
|
173
|
+
relevance: 'Cost-of-living salience pre-election',
|
|
174
|
+
usage: 'Inform voter-segmentation modelling',
|
|
175
|
+
priority: PRI,
|
|
176
|
+
},
|
|
177
|
+
{
|
|
178
|
+
indicatorId: WB_INDICATORS.UNEMPLOYMENT,
|
|
179
|
+
name: N.UNEMPLOYMENT,
|
|
180
|
+
relevance: 'Employment salience pre-election',
|
|
181
|
+
usage: 'Inform voter-segmentation modelling',
|
|
182
|
+
priority: PRI,
|
|
183
|
+
},
|
|
184
|
+
],
|
|
185
|
+
secondaryIndicators: [
|
|
186
|
+
{
|
|
187
|
+
indicatorId: WB_INDICATORS.CO2_EMISSIONS,
|
|
188
|
+
name: N.CO2,
|
|
189
|
+
relevance: 'Green-Deal salience pre-election',
|
|
190
|
+
usage: 'Quantify incumbent climate track record',
|
|
191
|
+
priority: SEC,
|
|
192
|
+
},
|
|
193
|
+
{
|
|
194
|
+
indicatorId: WB_INDICATORS.TRADE,
|
|
195
|
+
name: N.TRADE,
|
|
196
|
+
relevance: 'Strategic-autonomy salience',
|
|
197
|
+
usage: 'Inform geopolitical voter-segmentation',
|
|
198
|
+
priority: SEC,
|
|
199
|
+
},
|
|
200
|
+
],
|
|
201
|
+
maxWBCalls: 4,
|
|
202
|
+
},
|
|
203
|
+
};
|
|
204
|
+
//# sourceMappingURL=category-map-analysis.js.map
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @module Constants/WorldBank/CategoryMapLegislative
|
|
3
|
+
* @description Legislative cycle category indicator mappings.
|
|
4
|
+
*/
|
|
5
|
+
import { ArticleCategory } from '../../types/index.js';
|
|
6
|
+
import type { CategoryIndicatorEntry } from './category-map.js';
|
|
7
|
+
/** Legislative cycle category indicator mappings */
|
|
8
|
+
export declare const CATEGORY_INDICATOR_MAP_LEGISLATIVE: Partial<Record<ArticleCategory, CategoryIndicatorEntry>>;
|
|
9
|
+
//# sourceMappingURL=category-map-legislative.d.ts.map
|
|
@@ -0,0 +1,130 @@
|
|
|
1
|
+
// SPDX-FileCopyrightText: 2024-2026 Hack23 AB
|
|
2
|
+
// SPDX-License-Identifier: Apache-2.0
|
|
3
|
+
/**
|
|
4
|
+
* @module Constants/WorldBank/CategoryMapLegislative
|
|
5
|
+
* @description Legislative cycle category indicator mappings.
|
|
6
|
+
*/
|
|
7
|
+
import { ArticleCategory } from '../../types/index.js';
|
|
8
|
+
import { WB_INDICATORS, N, PRI, SEC } from './indicator-catalog.js';
|
|
9
|
+
/** Legislative cycle category indicator mappings */
|
|
10
|
+
export const CATEGORY_INDICATOR_MAP_LEGISLATIVE = {
|
|
11
|
+
[ArticleCategory.PROPOSITIONS]: {
|
|
12
|
+
category: ArticleCategory.PROPOSITIONS,
|
|
13
|
+
enrichmentStrategy: 'Map each legislative proposal to its policy domain, then fetch the 2-3 most relevant indicators for the dominant domain. Use to explain "why this legislation matters" with economic evidence.',
|
|
14
|
+
primaryIndicators: [
|
|
15
|
+
{
|
|
16
|
+
indicatorId: WB_INDICATORS.GDP_GROWTH,
|
|
17
|
+
name: N.GDP_GROWTH,
|
|
18
|
+
relevance: 'Economic backdrop for legislative proposals',
|
|
19
|
+
usage: 'Frame the economic context driving new legislation',
|
|
20
|
+
priority: PRI,
|
|
21
|
+
},
|
|
22
|
+
{
|
|
23
|
+
indicatorId: WB_INDICATORS.UNEMPLOYMENT,
|
|
24
|
+
name: N.UNEMPLOYMENT,
|
|
25
|
+
relevance: 'Employment impact of proposed legislation',
|
|
26
|
+
usage: 'Assess labor market implications of proposals',
|
|
27
|
+
priority: PRI,
|
|
28
|
+
},
|
|
29
|
+
],
|
|
30
|
+
secondaryIndicators: [
|
|
31
|
+
{
|
|
32
|
+
indicatorId: WB_INDICATORS.INFLATION,
|
|
33
|
+
name: N.INFLATION,
|
|
34
|
+
relevance: 'Cost-of-living context for consumer legislation',
|
|
35
|
+
usage: 'Contextualize price-related regulation proposals',
|
|
36
|
+
priority: SEC,
|
|
37
|
+
},
|
|
38
|
+
{
|
|
39
|
+
indicatorId: WB_INDICATORS.TRADE,
|
|
40
|
+
name: N.TRADE,
|
|
41
|
+
relevance: 'Trade impact of market regulation proposals',
|
|
42
|
+
usage: 'Assess trade implications of single market legislation',
|
|
43
|
+
priority: SEC,
|
|
44
|
+
},
|
|
45
|
+
{
|
|
46
|
+
indicatorId: WB_INDICATORS.CO2_EMISSIONS,
|
|
47
|
+
name: N.CO2,
|
|
48
|
+
relevance: 'Environmental proposals and Green Deal progress',
|
|
49
|
+
usage: 'Quantify environmental impact of green proposals',
|
|
50
|
+
priority: SEC,
|
|
51
|
+
},
|
|
52
|
+
],
|
|
53
|
+
maxWBCalls: 3,
|
|
54
|
+
},
|
|
55
|
+
[ArticleCategory.MONTH_AHEAD]: {
|
|
56
|
+
category: ArticleCategory.MONTH_AHEAD,
|
|
57
|
+
enrichmentStrategy: 'Provide a macroeconomic snapshot for the upcoming month. Focus on 2-3 headline indicators that set the economic backdrop for upcoming parliamentary business.',
|
|
58
|
+
primaryIndicators: [
|
|
59
|
+
{
|
|
60
|
+
indicatorId: WB_INDICATORS.GDP_GROWTH,
|
|
61
|
+
name: N.GDP_GROWTH,
|
|
62
|
+
relevance: 'Economic outlook for upcoming legislative agenda',
|
|
63
|
+
usage: 'Set the macroeconomic scene for the month ahead',
|
|
64
|
+
priority: PRI,
|
|
65
|
+
},
|
|
66
|
+
{
|
|
67
|
+
indicatorId: WB_INDICATORS.INFLATION,
|
|
68
|
+
name: N.INFLATION,
|
|
69
|
+
relevance: 'Cost-of-living pressures shaping policy priorities',
|
|
70
|
+
usage: 'Explain why certain issues dominate the upcoming agenda',
|
|
71
|
+
priority: PRI,
|
|
72
|
+
},
|
|
73
|
+
],
|
|
74
|
+
secondaryIndicators: [
|
|
75
|
+
{
|
|
76
|
+
indicatorId: WB_INDICATORS.UNEMPLOYMENT,
|
|
77
|
+
name: N.UNEMPLOYMENT,
|
|
78
|
+
relevance: 'Labor market context for employment legislation',
|
|
79
|
+
usage: 'Preview employment-related legislative activity',
|
|
80
|
+
priority: SEC,
|
|
81
|
+
},
|
|
82
|
+
],
|
|
83
|
+
maxWBCalls: 3,
|
|
84
|
+
},
|
|
85
|
+
[ArticleCategory.MONTH_IN_REVIEW]: {
|
|
86
|
+
category: ArticleCategory.MONTH_IN_REVIEW,
|
|
87
|
+
enrichmentStrategy: 'Retrospective economic assessment: how do the month\'s legislative achievements relate to current economic conditions? Use indicators to measure the "so what" of passed legislation.',
|
|
88
|
+
primaryIndicators: [
|
|
89
|
+
{
|
|
90
|
+
indicatorId: WB_INDICATORS.GDP_GROWTH,
|
|
91
|
+
name: N.GDP_GROWTH,
|
|
92
|
+
relevance: 'Economic context for legislative achievements',
|
|
93
|
+
usage: 'Assess whether legislation addressed economic realities',
|
|
94
|
+
priority: PRI,
|
|
95
|
+
},
|
|
96
|
+
{
|
|
97
|
+
indicatorId: WB_INDICATORS.UNEMPLOYMENT,
|
|
98
|
+
name: N.UNEMPLOYMENT,
|
|
99
|
+
relevance: 'Labor market conditions during the review period',
|
|
100
|
+
usage: 'Evaluate employment-focused legislation effectiveness',
|
|
101
|
+
priority: PRI,
|
|
102
|
+
},
|
|
103
|
+
],
|
|
104
|
+
secondaryIndicators: [
|
|
105
|
+
{
|
|
106
|
+
indicatorId: WB_INDICATORS.INFLATION,
|
|
107
|
+
name: N.INFLATION,
|
|
108
|
+
relevance: 'Price stability context for the reviewed period',
|
|
109
|
+
usage: 'Measure economic conditions during the legislative month',
|
|
110
|
+
priority: SEC,
|
|
111
|
+
},
|
|
112
|
+
{
|
|
113
|
+
indicatorId: WB_INDICATORS.FDI_NET,
|
|
114
|
+
name: N.FDI,
|
|
115
|
+
relevance: 'Investment climate during the review period',
|
|
116
|
+
usage: 'Assess investment implications of passed legislation',
|
|
117
|
+
priority: SEC,
|
|
118
|
+
},
|
|
119
|
+
],
|
|
120
|
+
maxWBCalls: 3,
|
|
121
|
+
},
|
|
122
|
+
[ArticleCategory.COMMITTEE_REPORTS]: {
|
|
123
|
+
category: ArticleCategory.COMMITTEE_REPORTS,
|
|
124
|
+
enrichmentStrategy: 'Use COMMITTEE_INDICATOR_MAP to select indicators per committee. Each committee section should include 1-2 indicators from its domain mapping.',
|
|
125
|
+
primaryIndicators: [],
|
|
126
|
+
secondaryIndicators: [],
|
|
127
|
+
maxWBCalls: 3,
|
|
128
|
+
},
|
|
129
|
+
};
|
|
130
|
+
//# sourceMappingURL=category-map-legislative.js.map
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @module Constants/WorldBank/CategoryMapPeriodic
|
|
3
|
+
* @description Periodic review category indicator mappings.
|
|
4
|
+
*/
|
|
5
|
+
import { ArticleCategory } from '../../types/index.js';
|
|
6
|
+
import type { CategoryIndicatorEntry } from './category-map.js';
|
|
7
|
+
/** Periodic review category indicator mappings */
|
|
8
|
+
export declare const CATEGORY_INDICATOR_MAP_PERIODIC: Partial<Record<ArticleCategory, CategoryIndicatorEntry>>;
|
|
9
|
+
//# sourceMappingURL=category-map-periodic.d.ts.map
|
|
@@ -0,0 +1,176 @@
|
|
|
1
|
+
// SPDX-FileCopyrightText: 2024-2026 Hack23 AB
|
|
2
|
+
// SPDX-License-Identifier: Apache-2.0
|
|
3
|
+
/**
|
|
4
|
+
* @module Constants/WorldBank/CategoryMapPeriodic
|
|
5
|
+
* @description Periodic review category indicator mappings.
|
|
6
|
+
*/
|
|
7
|
+
import { ArticleCategory } from '../../types/index.js';
|
|
8
|
+
import { WB_INDICATORS, N, PRI, SEC } from './indicator-catalog.js';
|
|
9
|
+
/** Periodic review category indicator mappings */
|
|
10
|
+
export const CATEGORY_INDICATOR_MAP_PERIODIC = {
|
|
11
|
+
[ArticleCategory.WEEK_AHEAD]: {
|
|
12
|
+
category: ArticleCategory.WEEK_AHEAD,
|
|
13
|
+
enrichmentStrategy: 'Light economic context: 1-2 headline indicators to frame the upcoming parliamentary week. Only include when specific agenda items have clear economic dimensions.',
|
|
14
|
+
primaryIndicators: [
|
|
15
|
+
{
|
|
16
|
+
indicatorId: WB_INDICATORS.GDP_GROWTH,
|
|
17
|
+
name: N.GDP_GROWTH,
|
|
18
|
+
relevance: 'Quick economic pulse for the week',
|
|
19
|
+
usage: 'One-line economic context in the article lede',
|
|
20
|
+
priority: PRI,
|
|
21
|
+
},
|
|
22
|
+
],
|
|
23
|
+
secondaryIndicators: [
|
|
24
|
+
{
|
|
25
|
+
indicatorId: WB_INDICATORS.UNEMPLOYMENT,
|
|
26
|
+
name: N.UNEMPLOYMENT,
|
|
27
|
+
relevance: 'Employment context if labor agenda items exist',
|
|
28
|
+
usage: 'Only include when employment topics are on the agenda',
|
|
29
|
+
priority: SEC,
|
|
30
|
+
},
|
|
31
|
+
],
|
|
32
|
+
maxWBCalls: 2,
|
|
33
|
+
},
|
|
34
|
+
[ArticleCategory.WEEK_IN_REVIEW]: {
|
|
35
|
+
category: ArticleCategory.WEEK_IN_REVIEW,
|
|
36
|
+
enrichmentStrategy: 'Retrospective economic context for weekly review. Include when votes or decisions had clear economic implications.',
|
|
37
|
+
primaryIndicators: [
|
|
38
|
+
{
|
|
39
|
+
indicatorId: WB_INDICATORS.GDP_GROWTH,
|
|
40
|
+
name: N.GDP_GROWTH,
|
|
41
|
+
relevance: "Economic backdrop for the week's decisions",
|
|
42
|
+
usage: 'Frame voting outcomes in economic context',
|
|
43
|
+
priority: PRI,
|
|
44
|
+
},
|
|
45
|
+
],
|
|
46
|
+
secondaryIndicators: [
|
|
47
|
+
{
|
|
48
|
+
indicatorId: WB_INDICATORS.TRADE,
|
|
49
|
+
name: N.TRADE,
|
|
50
|
+
relevance: 'If trade-related legislation was debated',
|
|
51
|
+
usage: 'Only include for trade-relevant weekly activity',
|
|
52
|
+
priority: SEC,
|
|
53
|
+
},
|
|
54
|
+
],
|
|
55
|
+
maxWBCalls: 2,
|
|
56
|
+
},
|
|
57
|
+
[ArticleCategory.MOTIONS]: {
|
|
58
|
+
category: ArticleCategory.MOTIONS,
|
|
59
|
+
enrichmentStrategy: 'Selective enrichment: only include economic data when motions/resolutions directly address economic policy. Map voting topics to relevant indicators.',
|
|
60
|
+
primaryIndicators: [],
|
|
61
|
+
secondaryIndicators: [
|
|
62
|
+
{
|
|
63
|
+
indicatorId: WB_INDICATORS.GDP_GROWTH,
|
|
64
|
+
name: N.GDP_GROWTH,
|
|
65
|
+
relevance: 'For economy-related motions',
|
|
66
|
+
usage: 'Only when motions address economic governance',
|
|
67
|
+
priority: SEC,
|
|
68
|
+
},
|
|
69
|
+
{
|
|
70
|
+
indicatorId: WB_INDICATORS.UNEMPLOYMENT,
|
|
71
|
+
name: N.UNEMPLOYMENT,
|
|
72
|
+
relevance: 'For employment-related motions',
|
|
73
|
+
usage: 'Only when motions address labor policy',
|
|
74
|
+
priority: SEC,
|
|
75
|
+
},
|
|
76
|
+
],
|
|
77
|
+
maxWBCalls: 2,
|
|
78
|
+
},
|
|
79
|
+
[ArticleCategory.BREAKING_NEWS]: {
|
|
80
|
+
category: ArticleCategory.BREAKING_NEWS,
|
|
81
|
+
enrichmentStrategy: 'Minimal enrichment — breaking news prioritizes speed over depth. Only include one indicator if the breaking event has immediate economic significance.',
|
|
82
|
+
primaryIndicators: [],
|
|
83
|
+
secondaryIndicators: [
|
|
84
|
+
{
|
|
85
|
+
indicatorId: WB_INDICATORS.GDP_GROWTH,
|
|
86
|
+
name: N.GDP_GROWTH,
|
|
87
|
+
relevance: 'Economic context for market-moving decisions',
|
|
88
|
+
usage: 'Only for economically significant breaking events',
|
|
89
|
+
priority: SEC,
|
|
90
|
+
},
|
|
91
|
+
],
|
|
92
|
+
maxWBCalls: 1,
|
|
93
|
+
},
|
|
94
|
+
[ArticleCategory.YEAR_AHEAD]: {
|
|
95
|
+
category: ArticleCategory.YEAR_AHEAD,
|
|
96
|
+
enrichmentStrategy: 'Comprehensive economic outlook for the legislative year. Include broad macroeconomic indicators and trend analysis.',
|
|
97
|
+
primaryIndicators: [
|
|
98
|
+
{
|
|
99
|
+
indicatorId: WB_INDICATORS.GDP_GROWTH,
|
|
100
|
+
name: N.GDP_GROWTH,
|
|
101
|
+
relevance: 'Annual economic growth trajectory',
|
|
102
|
+
usage: 'Set the economic scene for the legislative year',
|
|
103
|
+
priority: PRI,
|
|
104
|
+
},
|
|
105
|
+
{
|
|
106
|
+
indicatorId: WB_INDICATORS.INFLATION,
|
|
107
|
+
name: N.INFLATION,
|
|
108
|
+
relevance: 'Price stability outlook',
|
|
109
|
+
usage: 'Frame monetary policy context for the year',
|
|
110
|
+
priority: PRI,
|
|
111
|
+
},
|
|
112
|
+
{
|
|
113
|
+
indicatorId: WB_INDICATORS.UNEMPLOYMENT,
|
|
114
|
+
name: N.UNEMPLOYMENT,
|
|
115
|
+
relevance: 'Employment outlook',
|
|
116
|
+
usage: 'Preview employment-related legislative priorities',
|
|
117
|
+
priority: PRI,
|
|
118
|
+
},
|
|
119
|
+
],
|
|
120
|
+
secondaryIndicators: [
|
|
121
|
+
{
|
|
122
|
+
indicatorId: WB_INDICATORS.CO2_EMISSIONS,
|
|
123
|
+
name: N.CO2,
|
|
124
|
+
relevance: 'Climate targets for the year',
|
|
125
|
+
usage: 'Assess Green Deal progress trajectory',
|
|
126
|
+
priority: SEC,
|
|
127
|
+
},
|
|
128
|
+
{
|
|
129
|
+
indicatorId: WB_INDICATORS.RD_EXPENDITURE,
|
|
130
|
+
name: N.RD,
|
|
131
|
+
relevance: 'Innovation investment trends',
|
|
132
|
+
usage: 'Preview technology and research policy outlook',
|
|
133
|
+
priority: SEC,
|
|
134
|
+
},
|
|
135
|
+
],
|
|
136
|
+
maxWBCalls: 3,
|
|
137
|
+
},
|
|
138
|
+
[ArticleCategory.YEAR_IN_REVIEW]: {
|
|
139
|
+
category: ArticleCategory.YEAR_IN_REVIEW,
|
|
140
|
+
enrichmentStrategy: 'Annual retrospective with comprehensive economic assessment. Compare start-of-year vs end-of-year indicators to measure legislative impact.',
|
|
141
|
+
primaryIndicators: [
|
|
142
|
+
{
|
|
143
|
+
indicatorId: WB_INDICATORS.GDP_GROWTH,
|
|
144
|
+
name: N.GDP_GROWTH,
|
|
145
|
+
relevance: 'Annual economic performance',
|
|
146
|
+
usage: 'Assess legislative achievements against economic outcomes',
|
|
147
|
+
priority: PRI,
|
|
148
|
+
},
|
|
149
|
+
{
|
|
150
|
+
indicatorId: WB_INDICATORS.UNEMPLOYMENT,
|
|
151
|
+
name: N.UNEMPLOYMENT,
|
|
152
|
+
relevance: 'Annual employment trend',
|
|
153
|
+
usage: 'Evaluate employment-focused legislative track record',
|
|
154
|
+
priority: PRI,
|
|
155
|
+
},
|
|
156
|
+
{
|
|
157
|
+
indicatorId: WB_INDICATORS.CO2_EMISSIONS,
|
|
158
|
+
name: N.CO2,
|
|
159
|
+
relevance: 'Annual climate progress',
|
|
160
|
+
usage: 'Measure Green Deal legislative impact',
|
|
161
|
+
priority: PRI,
|
|
162
|
+
},
|
|
163
|
+
],
|
|
164
|
+
secondaryIndicators: [
|
|
165
|
+
{
|
|
166
|
+
indicatorId: WB_INDICATORS.INFLATION,
|
|
167
|
+
name: N.INFLATION,
|
|
168
|
+
relevance: 'Price stability over the year',
|
|
169
|
+
usage: 'Retrospective economic conditions assessment',
|
|
170
|
+
priority: SEC,
|
|
171
|
+
},
|
|
172
|
+
],
|
|
173
|
+
maxWBCalls: 3,
|
|
174
|
+
},
|
|
175
|
+
};
|
|
176
|
+
//# sourceMappingURL=category-map-periodic.js.map
|
|
@@ -1,21 +1,9 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* @module Constants/WorldBank/CategoryMap
|
|
3
|
-
* @description
|
|
4
|
-
*
|
|
5
|
-
* Not every article type benefits equally from economic data:
|
|
6
|
-
* - **PROPOSITIONS**: High value — legislative proposals often have direct economic impact
|
|
7
|
-
* - **MONTH_AHEAD/MONTH_IN_REVIEW**: High value — monthly economic overview adds depth
|
|
8
|
-
* - **COMMITTEE_REPORTS**: High value — each committee has domain-specific indicators
|
|
9
|
-
* - **WEEK_AHEAD/WEEK_IN_REVIEW**: Medium value — useful for contextualization
|
|
10
|
-
* - **MOTIONS**: Medium value — voting outcomes may relate to economic conditions
|
|
11
|
-
* - **BREAKING_NEWS**: Low value — urgency trumps enrichment
|
|
12
|
-
* - **DEEP_ANALYSIS**: High value — analytical depth benefits from data
|
|
3
|
+
* @description Category indicator map — assembled from legislative, periodic, and analysis sub-modules.
|
|
13
4
|
*/
|
|
14
|
-
import { ArticleCategory } from '../../types/index.js';
|
|
5
|
+
import type { ArticleCategory } from '../../types/index.js';
|
|
15
6
|
import type { IndicatorMapping } from './committee-map.js';
|
|
16
|
-
/**
|
|
17
|
-
* Maps an article category to recommended World Bank indicators.
|
|
18
|
-
*/
|
|
19
7
|
export interface CategoryIndicatorEntry {
|
|
20
8
|
/** Article category value */
|
|
21
9
|
readonly category: ArticleCategory;
|
|
@@ -28,17 +16,6 @@ export interface CategoryIndicatorEntry {
|
|
|
28
16
|
/** Maximum recommended World Bank MCP calls per article generation run */
|
|
29
17
|
readonly maxWBCalls: number;
|
|
30
18
|
}
|
|
31
|
-
/**
|
|
32
|
-
* Maps article categories to World Bank indicators for economic context enrichment.
|
|
33
|
-
*
|
|
34
|
-
* Not every article type benefits equally from economic data:
|
|
35
|
-
* - **PROPOSITIONS**: High value — legislative proposals often have direct economic impact
|
|
36
|
-
* - **MONTH_AHEAD/MONTH_IN_REVIEW**: High value — monthly economic overview adds depth
|
|
37
|
-
* - **COMMITTEE_REPORTS**: High value — each committee has domain-specific indicators
|
|
38
|
-
* - **WEEK_AHEAD/WEEK_IN_REVIEW**: Medium value — useful for contextualization
|
|
39
|
-
* - **MOTIONS**: Medium value — voting outcomes may relate to economic conditions
|
|
40
|
-
* - **BREAKING_NEWS**: Low value — urgency trumps enrichment
|
|
41
|
-
* - **DEEP_ANALYSIS**: High value — analytical depth benefits from data
|
|
42
|
-
*/
|
|
19
|
+
/** Full category indicator map for all article categories */
|
|
43
20
|
export declare const CATEGORY_INDICATOR_MAP: Readonly<Record<ArticleCategory, CategoryIndicatorEntry>>;
|
|
44
21
|
//# sourceMappingURL=category-map.d.ts.map
|