prediction model
learning the next working set
Updated Oct 4, 2026

Personal ridge regression trained on workout history, checked against repeat-last, with the results and limits of a chronological evaluation.
The old model did not learn
Logit used to multiply a recency-weighted average by fixed recovery, exercise-position, and trend adjustments. Those were rules I chose. Calling them a model did not make their coefficients learned from data.
The replacement fits a small ridge regression to your earlier sessions for the same exercise. It estimates the change in your next anchor set. The parameters come from recorded outcomes, not a table of recovery multipliers. No other account's history enters your fit.
The first recorded-data evaluation does not show an overall accuracy gain over repeating the last session. That matters more than the ML label. The learned forecast must also beat repeat-last in its own chronological validation before Logit uses it.
What the model learns
Each session contributes one anchor. For weighted work, it is the set with the highest capped strength score. For bodyweight work, it is the highest-rep set. The strength score is a comparison proxy, not a measured one-rep maximum.
Four features predict that change: an intercept, the previous relative change, the change in log time between sessions, and the change in exercise position. Gap differences are divided by log 29 and position differences by five. A missing historical position contributes zero. These feature scales are fixed, so future data cannot affect normalization.
Logit solves this four-coefficient system in TypeScript when it produces a recommendation. There is no model service, background training job, or permanent model copy of your workouts. Editing or deleting history changes the next fit after the existing workout-cache invalidation.
A learned forecast has to earn its place
The fit uses at most 60 prior distinct dates. It excludes the requested date and every future date, including when you edit an old workout. If multiple workouts share a date, a deterministic workout-ID tie-break keeps one. A date-only log cannot establish their actual order. Weighted and bodyweight anchors are trained separately, using the most recent anchor's mode.
Two sessions establish the first feature vector. The model then needs eight training transitions and four chronological validation transitions, so learning cannot activate before 14 usable sessions. Each validation prediction is fitted using only earlier outcomes.
The learned model is selected only when its mean absolute relative-change error is more than 5% lower than repeat-last on those four checks. It then refits on all available prior transitions. Otherwise, Logit repeats the last anchor and identifies that fallback in the prediction metadata. Four checks are a conservative product rule, not statistical proof.
What remains a rule
The forecasted strength change is limited to 10% in either direction. Weighted targets keep the last anchor's rep count and translate the learned strength back into load. Bodyweight targets round the learned rep estimate to a positive integer.
Loads still use five-pound or 2.5-kilogram increments. An anchor can rise by at most one increment above the rounded previous load. It can fall by two increments, or three after more than 28 days away. Positive weighted anchors have a one-increment floor. Later sets use the latest five matching sessions' median backoff ratios and rep differences. These are explicit output constraints, not learned physiology.
The existing low, medium, and high confidence labels still describe history depth, consistency, recency, and exercise position. They are not calibrated probabilities. Rep ranges are display guidance, not statistical prediction intervals. Low-confidence targets remain hidden in the current logger and Home guidance.
Recorded-data results
The October 4 evaluation replayed the final third of each eligible exercise history in date order. Each target used only earlier sessions, including for the model-selection checks. Hyperparameters stayed fixed. The runner read completed workouts in a PostgreSQL read-only transaction and exported aggregate metrics, not workout records or identities.
There were 277 held-out targets across 79 exercise histories. The learned forecast was selected for 24 targets, or 8.7%. The other predictions used repeat-last.
| Metric | Learned system | Repeat-last |
|---|---|---|
| Load MAE, 266 weighted targets | 13.01 lb | 12.87 lb |
| Reps MAE, 11 bodyweight targets | 3.18 | 3.55 |
| Mean absolute relative strength error | 29.65% | 29.63% |
The load error is slightly worse than the simple baseline. The small bodyweight sample improves, but eleven targets are not enough to claim a reliable advantage. The relative-strength error passes the runner's predeclared 2% regression tolerance. That tolerance is an engineering check, not a statistical non-inferiority result or a claim of improvement.
The baseline repeats the last anchor's reps and rounds its load to the same gym increments. Scores compare against what people logged, which includes changes in training intent. Historical edits cannot be reconstructed from the current database. This is retrospective evidence, not a prospective trial, and it does not compare against the retired heuristic.
Synthetic checks and reproduction
A separate deterministic evaluation covers stable training, progression, regression, exercise-position changes, session gaps, routine changes, and bodyweight work. Across 2,520 targets, weighted load MAE was 2.05 lb versus 3.22 lb for repeat-last. The gains came from the position and gap scenarios. The other scenarios did not improve after rounding and model selection. Synthetic success does not establish real-user accuracy.
Both runs deliberately inserted target and future records into the input and confirmed that predictions stayed unchanged. They also checked positive outputs, gym increments, and the upward load limit in both units.
Run npm test, then npm run eval:recommendations. The same runner accepts --database with an explicitly configured database environment and --output for an aggregate JSON report. The implementation, evaluation runner, and published report live in the Logit repository.
This model learns repeated logging patterns. It cannot see pain, effort, technique, equipment changes, or a deliberate deload. Its output is a starting suggestion, never a safety assessment or a prescription.