Migrate Control Room to v0.6 public API - #11
Merged
Conversation
Migrate the Hosoe Simple and Standard Control Room generators to the CGE-Core v0.6 public workflow. Generated scripts now use CGE, SplCGE/StdCGE, solve_benchmark(), benchmark.scenario(), Scenario.set(), Scenario.solve(), benchmark.value(), and Result.compare() instead of the legacy PyCGE BASE/SIM state machine. Update Hosoe-facing Control Room terminology from BASE/SIM to benchmark/scenario where it describes the public workflow. Migrate the frozen generated-code fixture and regression tests to the v0.6 public API. Preserve the validated dedicated IFPRI and CAMCGE execution paths. No economic equations, engine behavior, or closure abstractions are changed.
miraflor
marked this pull request as ready for review
August 28, 2026 16:13
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Migrate the Control Room's Hosoe Simple and Standard code generation to the
CGE-Core v0.6 public API.
Changes
Generated Hosoe scripts now use:
CGESplCGE/StdCGEsolve_benchmark()benchmark.scenario()benchmark.value()Scenario.set()Scenario.solve()Result.compare()Remove generated-code dependence on:
PyCGEmodel_calibrate()model_sim()model_modify_sim()model_solve()model_compare()Update Hosoe-facing Control Room terminology from BASE/SIM to
benchmark/scenario where it represents the public workflow.
Update the Control Room target from v0.5.0 to v0.6.0.
Migrate the frozen Standard-CGE tariff fixture to the public v0.6 lifecycle.
Add regression guards ensuring the Control Room continues to generate the
public API rather than drifting back to the legacy engine interface.
Preserve the dedicated IFPRI and CAMCGE generators unchanged.
Scope
This PR does not change:
engine.py;Validation
The Control Room regression suite passes locally, including execution of the
frozen v0.6 generated script with a real solver.
Merge policy
Do not merge until all CI checks are green.