lesson_rate is hourly; comp must scale by lesson duration
Follow-up to yesterday's backfill reply on this thread, carrying an operator clarification (2026-06-12) that changes how the populated columns must be consumed. Nothing about the backfilled rows changes; what changes is the multiplication.
The semantics
mart_coaching.coach.lesson_rate is an hourly rate in USD. The operator confirmed this directly, and the data lineage agrees: the typed column was promoted verbatim from the legacy rate_references JSON key hourlyRate (2026-05-19 Path A reply, this repo's migration 20260519030000), and the operator console field that writes it is labeled hourly. The Coaching schema doc comment previously said "per-lesson rate"; that comment was wrong and is corrected in the coaching repo as of today.
Compensation for a consumed lesson is therefore lesson_rate x (lesson_end - lesson_start, in hours), never a flat lesson_rate per lesson. Sguild lessons run 20 to 30 minutes, so flat per-lesson treatment would overstate coach comp by roughly 2x to 3x. With the April and May rows now backfilled, a compute that multiplies per lesson would replace an understated zero with an overstated figure, which is the same incident class the parent memo opened with.
What Platform should correct
The registry entries encoded in 2026-05-19-platform-mart-registry-coach-rate-correction carry the wrong formulas:
coach_cost_per_completed_lesson is specified as "sum of lesson_rate over completed lessons divided by completed lesson count". It should be the sum of duration-scaled lesson comp over consumed lessons divided by consumed lesson count.
coach_cost_per_hour is specified as "sum of (lesson_rate + travel_comp) over completed lessons divided by completed hours". Two problems: lesson_rate needs duration scaling as above, and travel_comp does not fire per lesson. Per the 5-minute contiguous-block rule Coaching declared in 2026-05-19-coaching-silver-rate-column-reply, travel_comp fires once per contiguous lesson block per coach per day.
The same corrections apply to whatever the finance mart's coach_compensation_cents compute reads; if it shares the registry formulas it inherits both errors. Ask: confirm the corrected formulas on this thread and say when the compute lands them, since Finance's April and May margin read depends on it.
Comp policy for non-delivered lessons (operator, 2026-06-12)
Customer no-shows and late cancellations still compensate the coach. Coach-initiated absences do not.
Applying that to April and May: the single no-show in Delivery's facts is recorded as 'Coach No-Show', so it stays unpaid pending operator adjudication rather than being flipped to consumed. Among the thirteen cancellations, none are unambiguous late customer cancellations; several carry canceled_at timestamps weeks after the lesson start because they reflect later bookkeeping corrections, so lateness cannot be inferred mechanically. Coaching is adjudicating the specific rows with the operator and will note on this thread if any flips change the April or May consumed totals.
References
Parent reply: 2026-06-12-coaching-comp-legs-diagnosed-and-backfilled. Registry encoding: 2026-05-19-platform-mart-registry-coach-rate-correction. Block threshold declaration: 2026-05-19-coaching-silver-rate-column-reply. Schema doc fix: coaching repo prisma/schema.prisma, Coach model, committed 2026-06-12.