Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 9 additions & 0 deletions docs/migration/stage-12-modal-worker-foundation.md
Original file line number Diff line number Diff line change
Expand Up @@ -208,6 +208,15 @@ metadata so PolicyEngine can correctly recognize conditional labor-supply
analysis. `include_cliffs=true` is supported by this path and is carried through
both output planning and aggregation.

For US SPM calculations, each child artifact stores one compact
`spm_provenance` receipt inside its calculation metadata. The coordinator
validates the requested selection against the forecast, scenario, geography,
county-vintage, and date fields in that receipt, then publishes only the
combined `spm_provenance` object in the completed report. Completed results do
not contain a sibling `spm_config`; the receipt is the sole source of resolved
SPM configuration. Request payloads still accept the partial `spm` selection
and resolve omitted options from the certified bundle before execution.

### Temporary UK local-authority display metadata

Stage 12 detects the local-authority boundary configuration from the complete
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -237,7 +237,8 @@ def validate_end_year(self) -> "BudgetWindowBatchRequest":
class BudgetWindowAnnualImpact(BaseModel):
"""Annual budget-window impact row."""

spm_config: Optional[SPMSelection] = None
model_config = ConfigDict(extra="forbid")

spm_provenance: Optional[SPMComparisonProvenance] = None
year: str
taxRevenueImpact: float
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@

from pydantic import BaseModel, ConfigDict, RootModel

from policyengine_simulation_contract.spm import SPMSelection, SPMComparisonProvenance
from policyengine_simulation_contract.spm import SPMComparisonProvenance

T = TypeVar("T")

Expand Down Expand Up @@ -189,7 +189,6 @@ class CongressionalDistrictImpactOutput(MacroOutputModel):
class SingleYearMacroOutput(MacroOutputModel):
"""Completed response returned by a single-year macro simulation."""

spm_config: SPMSelection | None = None
spm_provenance: SPMComparisonProvenance | None = None

model_version: str
Expand Down
Loading
Loading