recommend_model: needs_distribution drops every macro model, and horizon is ignored
Maintainer antworten meist innerhalb von 1 Tag
Dieses Issue hat noch niemand übernommen.
Bewertung
- Schwierigkeit
- 4/5
- Geschätzter Aufwand
- 3-5 Tage
- Anfängerfreundlichkeit
- 48/100
Rechercherichtung
Start in integration/src/policyengine_macro/capabilities.py at recommend, then trace the registered model capabilities and the MCP tool definition that exposes horizon. Check how incidence tools are registered and tested before choosing an approach. Done means distribution requests return useful guidance for macro candidates and the unused horizon argument is removed or given defined routing behavior, with tests covering both.
Vom Indexierungsmodell aus dem Issue-Text verfasst.
Beschreibung
Problem
recommend_model (integration/src/policyengine_macro/capabilities.py, recommend) routes on question_type and country only. Two of its inputs do less than a caller expects:
needs_distribution=Truedrops every macro model. The filter keeps onlype-microsimandog+microsim. Sorecommend("economic_shock", "us", needs_distribution=True)returns no model, with the "no registered model supports this request" warning. But the suite does answer that question:frbus_shock_incidence,hank_shock_incidence(andhank_shock(include_distribution=True)),svar_inflation_incidenceanddefine_scenario_incidenceall produce household distributions. The same is true forforecast/economic_diagnosis(UK, viasvar_inflation_incidence) andclimate_policy_scenario(viadefine_scenario_incidence).horizonis ignored. It is echoed back but never used, so "long run" and "next four quarters" route the same way. (The MCP docstring now says so, on branchvahid/r5-api-scenarios.)
Evidence
Matrix run on 6 Nov 2026 (all 10 question types × uk/us/fr × needs_distribution):
economic_shockuk/us,forecastuk,economic_diagnosisuk,climate_policy_scenariouk,structural_changeuk,translated_policy_scenariouk: a candidate withneeds_distribution=False, none withTrue.
Options
- Register the incidence pairs as capability entries (
frb-us+microsim,us-hank+microsim,boe-svar+microsim,define-uk+microsim). Each needs its own quality block, so this is the honest route, but it is more work. - Keep the registry and add an
incidence_toolshint to the response whenneeds_distributionfilters out a macro candidate: "frb-us has no distribution itself; frbus_shock_incidence overlays its labour-market path on the US microsim". - Leave it as it is and document that
needs_distributionmeans "the model itself is distributional".
For horizon: either drop the argument, or define a small vocabulary (short_run, medium_term, long_run) and match it against each model's horizon field.
Recommendation
Option 2 now (small, no new quality claims). Drop horizon from the tool until there is a vocabulary, so no caller thinks it is doing something.
🤖 Generated with Claude Code
- Vorherrschende Sprache
- HTML
- Sterne
- 3
- Forks
- 1
- Ø Merge
- 1 T. 20 Std.
- Gemergte PRs (30 T.)
- 53
Entwicklungsumgebung
- Kein Dockerfile und keine Docker-Compose-Datei
- Keine Pull-Request-Vorlage
- Beitragsleitfaden lesen
Erste Schritte
- Lesen Sie das ganze Issue und danach den Beitragsleitfaden des Projekts.
- Schreiben Sie ins Issue, dass Sie es übernehmen — das erspart doppelte Arbeit.
- Forken Sie das Repository und arbeiten Sie in einem Branch.
- Öffnen Sie einen Pull Request, der die Issue-Nummer nennt.
Mehr aus PolicyEngine/macro
-
HANK incidence overlay omits the model's labour-tax financingEvtl. vergeben Ein verknüpfter Pull Request ist offen oder bereits gemergt. Offenquestion
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 67/100
PolicyEngine/macro#214 · 2 Kommentare ·
Maintainer antworten meist innerhalb von 1 Tag
-
Hosted score_reform (OBR, default window) has not finished within 10 minutes since the 30 Oct deployOffen
Schwierigkeit 4/5 1-2 Tage Anfängerfreundlichkeit 25/100
PolicyEngine/macro#243 · 1 Kommentar ·
Maintainer antworten meist innerhalb von 1 Tag
-
Referee review of the model pages (6 Nov 2026)Evtl. vergeben Ein verknüpfter Pull Request ist offen oder bereits gemergt. Offenquestion
Schwierigkeit 5/5 Über eine Woche Anfängerfreundlichkeit 22/100
PolicyEngine/macro#227 · 5 Kommentare ·
Maintainer antworten meist innerhalb von 1 Tag
-
question
Schwierigkeit 4/5 3-5 Tage Anfängerfreundlichkeit 30/100
PolicyEngine/macro#223 · 2 Kommentare ·
Maintainer antworten meist innerhalb von 1 Tag
-
UK SVAR adapter publishes log-difference YoY as if it were the simple rateEvtl. vergeben Ein verknüpfter Pull Request ist offen oder bereits gemergt. Offenbug
Schwierigkeit 4/5 3-5 Tage Anfängerfreundlichkeit 45/100
PolicyEngine/macro#208 · 2 Kommentare ·
Maintainer antworten meist innerhalb von 1 Tag
Alle Issues in PolicyEngine/macro
Ähnliche Issues
-
triage
Schwierigkeit 1/5 Unter einer Stunde Anfängerfreundlichkeit 64/100
-
enhancement
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 78/100
meetecho/juturna_nodes#43 ·
Maintainer antworten meist innerhalb von 2 Tagen
-
bug
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 77/100
ranxianglei/billion-context#7860 ·
Maintainer antworten meist innerhalb von 1 Tag
-
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 66/100
-
`RequestHandler.build_request_kwargs` drops empty request bodies such as `{}` or `""`Evtl. vergeben @abhirajadhikary06 hat das heute übernommen. Offen
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 75/100
typesense/typesense-python#170 ·
Maintainer antworten meist innerhalb von 1 Tag