Files
coursehub/includes
root e6f60f7f20 Send the advisor a course index plus retrieved details instead of the whole catalogue
Every question used to carry the full catalogue (~39k tokens on this
library, 41% of it per-section sizes). Now the model gets one line per
course as a stable, cacheable index, and paths/tags/blurb only for the
~25 courses a local term match against the conversation picks out (plus
anything in progress or already cited). Typical prompts land at 7-10k
tokens and the model reads the relevant courses in depth.

Duplicate copies of a course (same folder key) are collapsed before the
prompt is built; progress on a dropped copy counts for the kept one and a
recommendation is steered back to the copy the learner is part-way
through. Finished courses become a single id list. Reasons are capped at
15 words / 120 chars, which also shrinks every replayed follow-up turn.

Thinking mode is off for advisor calls (ADVISOR_REASONING = 'off').

Claude-Session: https://claude.ai/code/session_011gkaBpxtBdCBwdLL3R6Pfo
2026-09-09 00:00:50 +00:00
..