Skip to main content

Ubiquitous language

Use these exact names in code, API and conversation. The repository's .claude/rules/domain-model.md is the agent-facing source; every term below maps to a code identifier. Terms whose code name differs from the spoken name are flagged in the last column.

TermMeaningCode identifierName differs?
ProcessCapacityThe usable throughput of one warehouse process at one site for one time window; the minimum across its registered constraints.processcapacity.ProcessCapacityno
CapacityConstraintOne named limiting factor (type + rate) attached to a ProcessCapacity: LABOR, LOCATION, EQUIPMENT, STATION, CONVEYOR, BUFFER, REPLENISHMENT.processcapacity.ConstraintType + CapacityRate, paired in ConstraintEntryyes: no CapacityConstraint type exists; the pair is ConstraintEntry
Binding constraintThe constraint type producing the minimum (of an aggregate, a step or the bottleneck step).EffectiveRate() second result; StepResult.Binding; CapacityPlan.BottleneckConstraint(); JSON binding_constraint / bottleneck_constraintyes: Binding / BottleneckConstraint
CapacityRateA quantity + native unit + period, for example 4000 UNIT / HOUR. Never compared across units without a WorkloadProfile.processcapacity.CapacityRateno
Native unitThe unit of every constraint on one ProcessCapacity: UNIT, LINE, ORDER or PACKAGE.processcapacity.CapacityUnit (UnitUnit, UnitLine, UnitOrder, UnitPackage)yes: CapacityUnit
CapacityWindowThe [start, end) period a capacity is valid for. A capacity with no window is incomplete by definition.processcapacity.CapacityWindowno
CoversWindow C covers planning window W when C.start <= W.start and C.end >= W.end; a window covers itself (ADR 0003).CapacityWindow.Covers; ProcessCapacityRepository.FindCoveringno
WorkloadProfilePer-warehouse conversion factors (units per order, packages per order) used to normalize native rates into ORDER. Supplied on each request.processcapacity.WorkloadProfile, NormalizeToOrderRate; JSON units_per_order, packages_per_orderno
ProcessTypeA warehouse process step such as PICK, REBIN, PACK.processcapacity.ProcessType and processpath.ProcessType (two string types, to avoid an import cycle)no
ProcessPathAn ordered, non-empty sequence of process types a workload flows through. Since ADR 0025 stage 3 it is always the steps of an ACTIVE process flow consumed from process-path-management; the local declaration is gone.processpath.ProcessPath via pathOfFlow; table none (the process_paths table dropped with migration 0019)no
ProcessPathCapacityThe normalized end-to-end throughput of a ProcessPath: the minimum of its steps, plus the bottleneck step and its binding constraint.processcapacity.PathCapacityResult from ComposeProcessPathCapacityyes: PathCapacityResult
Step compositionA step's candidates (covering constraints, newest window start per type, plus the derived STATION constraint) normalized to ORDER; the minimum wins.processcapacity.ComposeStepCapacity, StepInput, StepResultno
StationStandardOperator-declared throughput of ONE station of a process at a site, in UNIT, PACKAGE or ORDER.processcapacity.StationStandardno
Station countHow many work-center stations facility-layout tallied for an activity across a site's zones. Has no throughput of its own.StorageTallyReader.StationCount; table location_slot_tally (tally_type = 'STATION')yes: a tally bucket, not a type
Storage positionsStorage slots per zone and location type; a read model, not a throughput.tally.Bucket; GetStorageCapacity; JSON storage_positionsyes: Bucket
Site / locationA planning location is a site (building) code such as SIM1, also the first dash-separated segment of that site's facility zone ids.the location string on every type; building_id in the labor payloadyes: building_id upstream
CapacityPlanAssigned demand for a site and window, compared with the ProcessPathCapacity; yields shortage and bottleneck. Lifecycle DRAFT then PUBLISHED.capacityplan.CapacityPlan, StatusDraft, StatusPublishedno
Site idThe canonical site a plan is scoped to: a facility-layout Site site_code. Stated on create, never inferred from warehouse or location.CapacityPlan.SiteID(); JSON site_idno
Assigned demandThe orders a plan must serve in its window, stated or defaulted from expected demand.CapacityPlan.AssignedDemand(); JSON assigned_demandno
DemandSourceWhere the assigned demand came from: request or orders.capacityplan.DemandSource (DemandSourceRequest, DemandSourceOrders)no
Capacity over windowPath capacity (ORDER per hour) times the window's hours.CapacityPlan.CapacityOverWindow(); JSON capacity_over_windowno
Shortagemax(0, assigned demand - capacity over window), in orders. Equal is not a shortage.CapacityPlan.Shortage()no
BottleneckThe process-path step limiting end-to-end flow, and the constraint type binding it.
Process flowAn ordered sequence of path_id + process_type stages owned by process-path-management (its ADR 0042); this context keeps an event-fed copy (process_flows, ADR 0025) and a flow's steps are its stages' process_type values in order.processflow.Flow; table process_flows
Path sourceWhich declaration a read resolved while both existed (ADR 0025 stages 1-2): flow (an ACTIVE flow won) or local. Since stage 3 the flows are the only source and every read says flow; the enum keeps local for readers written against stage 1.ProcessPath.Source; JSON sourcePathCapacityResult.BottleneckStep; CapacityPlan.BottleneckStep(); event BottleneckDetected
Expected demandOrders order-management has promised at a site, counted by promise cutoff in [start, end). Zero orders means no data.demand.Order, demand.Summary, GetExpectedDemand; table order_demandno
Promise cutoffThe instant by which an order is promised; decides which window it counts in.demand.Order.PromiseAt(); upstream promise_dateyes: promise_date upstream, promise_at here
Released linesLines released by an order's latest allocation pass. NOT units.demand.Order.ReleasedLines(); JSON released_linesno

ProcessCapacity events​

TermMeaningWhereUpstream name
ProcessCapacityRegisteredThe aggregate's first (native) constraint was registered: it came into being.processcapacity.ProcessCapacityRegistered; ProcessCapacity.AddConstraintno
ProcessCapacityChangedA registration moved the effective rate — its value, its binding constraint, or both.processcapacity.ProcessCapacityChanged; ProcessCapacity.AddConstraintno
Planned capacityThis context's capacity figure for a path and a window: the path capacity of a capacity plan (and, with ADR 0023, a shift's labour plan). Not wes-work-planning's live remaining admission capacity.CapacityPlan.PathCapacity, CapacityPlanPublishedno
Remaining admission capacitywes-work-planning's live figure: how much more work a release-fed path admits before its WIP limit, per CPT cutoff (PathCapacityChanged). Read by order promising, never computed here.none here (wes-work-planning WorkPool.RemainingCapacity())no

Requirement side (ADR 0022, ADR 0023)​

The terms of the labour requirement: how much labour the demand needs. Labour supply (who is available, certified, assigned, and how many heads are committed) belongs to workforce-management; the engineered standards belong to labor-performance; execution (release, balancing) belongs to wes-work-planning.

TermMeaningCode identifierName differs?
Labour standardlabor-performance's engineered seconds for one task of a task type (PICK, PACK, SLAM), optionally per handling unit and per site, with an effective start. This context keeps a local copy of the facts and resolves the one in force at read time: a site-scoped row beats a fleet-wide one, then the latest effective_from at or before the window start, then the latest as_of. Only task-type-only rows (no handling unit) price a plan.laborstandard.Standard, laborstandard.Resolve; table labor_standards; events LaborStandardDefined / LaborStandardRevisedyes: the code and the producer spell it labor
Labour requirementPer step of a capacity plan's path: tasks x standard_seconds / 3600 labour hours and those hours divided by the window hours as average heads. tasks is the released lines of the counted orders for PICK when the demand came from orders, else assigned_demand x tasks_per_order[step]. Unknown (never guessed) with reason no-labor-standard or no-task-factor. Computed at plan creation and stored with the plan; informational, on no event.capacityplan.LabourRequirement, RequireLabour; JSON labour_requirement (process_type, standard_seconds, standard_site_scoped, tasks, required_labour_hours, required_average_heads, known, reason)no
Workload forecastThe volume a process path is expected to receive at a site, as CPT buckets. One per (site_id, path_id); a receipt replaces the buckets as a whole; at least one bucket. It was wes-work-planning's charge forecast.workloadforecast.Forecast; table workload_forecasts; event WorkloadForecastReceivedyes: wes called it ChargeForecast
Forecast bucket{cpt, quantity}: a non-negative whole number of units due at one critical pull time (RFC 3339).workloadforecast.Bucket; JSON buckets[].cpt, buckets[].quantityno
Labour planThe heads a process path needs for one shift at one site, at a planned rate for a number of hours. One per (site_id, shift_id, path_id). Invariants: planned_heads <= installed_stations, hours > 0, rate > 0, rate x heads x hours finite. It was wes-work-planning's path plan.labourplan.Plan, labourplan.Spec; table labour_plans; event LabourPlanCommittedyes: wes called it PathPlan
Planned headsThe labour plan's head count: the requirement this context publishes.Spec.PlannedHeads; JSON planned_headsno
Heads sourceWhere the planned heads came from: request (the caller sent them) or forecast (derived).labourplan.HeadsSource (HeadsFromRequest, HeadsFromForecast); JSON heads_sourceno
Derived headsPlanned heads computed when the caller omits them: ceil(units with a cpt in [shift_start, shift_start + hours) / (rate x hours)). Needs shift_start and a stored forecast with at least one bucket in that window; otherwise 422 missing-planned-heads. Zero buckets in the shift is no data, never zero heads.labourplan.DeriveHeads; Forecast.QuantityDueIn; CommitLabourPlan.deriveHeadsno
Committed headsThe heads workforce-management committed for the same (site, shift, path) in its ShiftPlanCommitted (its planned_heads field). Supply, not requirement; recorded, never used to change the plan.labourplan.Commitment.Heads; table labour_plan_commitments.committed_headsyes: the upstream field is planned_heads
Labour plan driftcommitted_heads - planned_heads for one key: positive when workforce committed more heads than the plan needs. Raised as LabourPlanDriftDetected only when non-zero and different from the last drift recorded for the key; every computed drift is recorded (zero included). Never corrects either side.labourplan.Drift, CompareHeads, ShouldRaise; column last_drift_heads; event LabourPlanDriftDetected (drift_heads)no
Station warningAn advisory string on a labour plan answer when the facility-layout tally knows at least one but fewer stations of the activity named like the path (path id upper-cased) than installed_stations. Computed on every read, never stored; the number stays as sent.usecases.stationWarnings; JSON warningsno
Process-path codeThe path_id of a forecast, a labour plan or a committed-heads row, in its canonical form: trimmed and upper case (pick and PICK are PICK). REST accepts any case; storage and published events carry the canonical form. Same rule as the LABOR constraint's ProcessType.workloadforecast.CanonicalPathID, labourplan.CanonicalPathIDyes (path_id)
ShiftThe shift a labour plan is for, as a caller-chosen shift_id (matched exactly as sent); shift_start and hours give its window [shift_start, shift_start + hours).Spec.ShiftID, Spec.ShiftStart, labourplan.ShiftEndno