Files
CatoandClaude Fable 5.2 a7e1ee51e8 Heidis Rückblick: a review the learner asks for, once a week at most (#448)
* feat(coach): «Heidis Rückblick», a review the learner asks for, once a week at most

A review of the learner's own practice record, on the personal page. It runs
only on its button and not again for seven days: no timer, no page load and
no end of a sitting starts it.

- Facts are counted by plain code from the learner model (topics and
  situations missed most, what is due, how hard the questions were).
- Proposals are a closed list built from those facts: a grammar topic by
  itself, a situation again, the due reviews, one step easier or harder.
- One model call (`/api/coach`, free models or the learner's own key) gets
  counts and names and returns two or three sentences and an order; an id it
  made up is dropped. In gsw the sentences pass the variety check or are not
  shown.
- An account is counted per week in `usage_meter` (kind `coach-reviews`);
  without one the learner's record holds the date and a caller gets two a day.
- Without a model the same proposals show with a dictionary sentence.
- Declared on the privacy page (`pathReview`).

Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>

* fix(coach): the variety's name comes from the pack, not from the prompt

lib/variety/leak.test.ts refused the review prompt naming the variety and the
route comparing against its locale code. Both read the pack now.

Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>

---------

Co-authored-by: Claude Fable 5.2 <noreply@anthropic.com>
2026-12-03 10:59:57 +01:00
..