GLOBAL.md — Non-Negotiable Project Rules¶
These rules apply to every change, by any contributor or agent. If a task seems to require breaking one, stop and raise it instead of working around it.
Scientific rules¶
- Simplified models must preserve their explicitly defined invariants (area, installed power, scheduled power per timestep, occupancy, and the glazing quantities required by the chosen window level).
- Every transformation is traceable: each target zone references its source zones, and each transformed schedule records its source schedules, aggregation method, and weights.
- Source and target representations must not silently change program assumptions.
- Geometry effects must not be confounded with changes to internal loads or schedules.
- Setpoints are controls, not additive loads. Their aggregation rule is explicit and recorded in experiment metadata.
- Validation failures block conversion (
Convert2BEM,Convert2IDF) unless explicitly overridden, and the override is recorded. - Research equivalence rules change only together with the research documentation in
docs/.
Architecture rules¶
- Core logic is independent of Rhino and Grasshopper wherever possible.
Lod.Corehas no dependency on Grasshopper or on any UI code.- Grasshopper components are thin adaptors over domain and service classes; they contain no research workflow.
- Pipeline objects (
IGeneratedPlan,IFloor,IGeneratedBuilding, program presets) are plain C# types. RhinoCommon/Grasshopper types appear only inLod.Grasshopper: Goo wrappers, previews, andConvert2BEM. - Tool-specific formats (ClimateStudio inputs, IDF) appear only in the converters, which consume
IGeneratedBuilding. - Plan generation, plan simplification, floor aggregation, equivalent-property aggregation, validation, and conversion are separate, independently replaceable services.
- Simulation is a separate step after conversion, outside the pipeline.
Lod.Simulationruns EnergyPlus on a written IDF and a weather file and changes no pipeline object. Tests that run EnergyPlus are opt-in; plaindotnet testnever needs EnergyPlus.
Quality rules¶
- Behavioral changes require tests; core transformations are developed test-first.
- Public pipeline types and Grasshopper component inputs/outputs are documented in
docs/; breaking changes get a decision-log entry. Component GUIDs never change once merged. - Generation is deterministic: randomness requires an explicit seed that is stored in metadata; no process-global random state.
- Numerical tolerances are defined centrally in a tolerance configuration, never as scattered constants.
- Expected failures use structured result types; exceptions carry actionable context.
- Geometry is never repaired silently. Any repair is deterministic, documented, and returned as a warning.
- Core libraries do not write to the console.
Git rules¶
- Focused commits: one logical change per commit.
- Commit messages use
type(scope): summary(see AGENTS.md). - No secrets, credentials, or
.envfiles. - No generated build artifacts, caches, simulation outputs, or user-specific IDE state.
- No agent, model, provider, or tool identification in commit messages, and no attribution footers or co-author trailers for tools.
- No force pushes to shared branches unless explicitly authorized.