• exec/chat_llm.js

    From Rob Swindell (on Debian Linux)@1:103/705 to Git commit to main/sbbs/master on Monday, August 10, 2026 03:17:45
    https://gitlab.synchro.net/main/sbbs/-/commit/a7718428415a389396c1ec21
    Modified Files:
    exec/chat_llm.js
    Log Message:
    chat_llm: treat a repeated question as a failed answer

    Reply-text similarity cannot detect a stuck conversation. A user asked
    the same question three times running and got three answers that meant
    the same thing but scored only 0.33-0.58 against each other, because
    the model rewords itself at this temperature. Genuinely new answers on
    a single topic score 0.42-0.62, so the ranges overlap and no threshold separates them.

    The question itself is the reliable signal: someone retyping what they
    just asked is telling you the previous answer did not land, whatever
    its wording. When the incoming question matches one of that speaker's
    own recent questions, the previous answer is treated as a repeat
    outright, bypassing the similarity test, and the existing regenerate- then-deflect path runs.

    Only the speaker's own turns are compared -- the bot restating a
    question back is not the user asking twice. Similarity still governs
    whether the REGENERATED answer counts as another repeat, at a looser
    threshold, since the strict one would essentially never fire there.
    --- SBBSecho 3.37-Linux
    * Origin: Vertrauen - [vert/cvs/bbs].synchro.net (1:103/705)