Session 54: Progression #229
Labels
No labels
accessibility
area:accounts
area:ai-evals
area:look
area:maps
area:platform
area:rides-progress
area:riding
area:today-plan-coach
area:ui-shell
bot:blocked
bot:failed
bot:pr
bot:waiting
bot:working
bug
documentation
duplicate
enhancement
good first issue
help wanted
invalid
later
now
owner-check
parked
question
ready
session
wontfix
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
ckreidl/trainer#229
Loading…
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
54 · Progression, and unplanned rides as bonus
Phase: Adaptive coaching 5/5 (owner request 2026-11-08) · Branch:
session/54-progression· Depends on: 53The owner's 12-week plan had one VO2max session, a build block 91% easy with hard minutes shrinking each week, and weekly loads that didn't progress. Re-plans also stripped planned tempo and sweet spot after polo, group rides and a long lunch ride. Nothing in the rules checks progression, and the re-plan treats a logged ride's numbers as the whole story. This session adds progression rules on planned load, a floor on hard minutes, and makes unplanned riding a bonus: it counts for fitness and fatigue but never moves the prescription by itself, and whether it replaces a planned quality session is the ride chat's call.
Read first
docs/requirements.md→ "Coaching dialogue and adaptability" (FR-23) and the foundations tabledocs/decisions.md: the 2026-11-08 adaptive coaching entry (the owner's 200/350/500/150 example; no fixed block-to-block margin)src/domain/rules/(periodisation.ts,intensity-distribution.ts,key-workout-protection.tsforhardZone/hardMinSec,shared.ts,config.ts,clamp.ts,index.ts),src/domain/plan/workout.ts(workoutTimeInZones),src/domain/plan/plan.ts(datedWeeks)src/ai/prompts/generate.ts,src/ai/prompts/replan.ts, session 50's ride-chat and End chat inputsevals/(the "unplanned long ride" re-plan scenario)Goal
progression, new rule). For each non-taper mesocycle, over planned ride TSS (the sessions as the plan prescribes them, never ridden): each loading week (all but the recovery week) carries at least the week before's load, so the last loading week is the block's peak. A week a clamp trimmed, the athlete edited or that is past doesn't break it (the same treatment as session 53's recovery floor; reuse it). Error, with no mechanical fix (the coach repairs).keyWorkout.hardZone). Each build or specialty block's mean weekly hard minutes over loading weeks is at least the preceding base block's. Each build or specialty loading week has at leastminQualityRides2 rides with at leastkeyWorkout.hardMinSecin zone 4+, when the week has at leastminDays4 training days andminHours4 (config; resolved per week from session 52). Errors, repaired by the coach.Rules
src/domain/stays pure; every bound inRULES_CONFIGwith tests at, under and over it, and overridable per user (validator and settings).newViolations, so an active plan that already breaks progression isn't rejected for it; the next generate fixes it.Tests
bun run evalandbun run eval:replanstay 100% compliant; compare hard minutes per block before and after withevals/show-plan.tsfor the owner's control athlete and record it indocs/history.md.Out of scope
Taper load rules (the open follow-up), heart-rate or RPE hardness for logged rides. Note anything else under Follow-ups.
Done when
The new rules pass their tests, both evals stay 100% compliant, and the owner's control plan shows rising weekly load within blocks, a build peak above the base peak and more build hard minutes than base; unit, typecheck, lint, format, audit and e2e pass. Add an owner check under Follow-ups → Now: generate a new plan and read weeks 5–12 against the 2026-11-08 complaints. Update FR-23's "not yet built" and the foundations table (periodisation, intensity distribution). Finish with the end-of-session ritual in
CLAUDE.md.Moved from
prompts/54-progression.mdon 2026-11-08.