Skip to content

Activation generator and ledger are hardcoded in the loop; ledger.py and milp_bidding.py import upward from core.simulator #4

Description

@dim-sous

What is wrong

Two more concrete types the loop constructs by hand, and two imports that point the wrong way.

Hardcoded in the loop:

  • core/simulator/core.py:45 imports and :84 constructs ActivationSignalGenerator(reg_p, tp.dt_pi). A different regulation signal model — recorded FCR data, a different spectral shape, a deterministic stress profile — is a core edit.
  • core/simulator/core.py:32 imports compute_ledger and calls it at the end of the run. A different scoring — say, a settlement rule for another market — is a core edit.

Upward imports (leaf → trunk):

  • core/accounting/ledger.py:29from core.simulator.traces import SimTraces
  • core/planners/milp_bidding.py:1035from core.simulator.synthetic_day import make_synthetic_day (inside a function body, which is how these hide)

Nothing forbids either today because no boundary is declared. Once #1 lands the ledger is devkit and may import the simulator freely — but a planner importing the synthetic day is a product module reaching into the harness and becomes a hard violation of the one-way rule.

Done when

Phase 1 of the platform epic. Depends on #1.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    engineseams, run schema, data model

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions