KoboldAI / KoboldAI-Client

For GGUF support, see KoboldCPP: https://github.com/LostRuins/koboldcpp
https://koboldai.com
GNU Affero General Public License v3.0
3.51k stars 758 forks source link

Duplicate condition in else-if chain #305

Open KosRud opened 1 year ago

KosRud commented 1 year ago

I think the second if block in the code below will never be triggered (it has identical condition to the first).

Also the condition contains setlabeltypical (locally typical sampling?), but inside the if block it references settopa (top-a sampling?).

https://github.com/KoboldAI/KoboldAI-Client/blob/75fecb86cc327af809d2934270e321c6de961d32/static/application.js#L2649-L2654

Top-a sounds similar to top-k and top-p so I'd assume it's a separate parameter for its own sampling method, but I wasn't able to find any information on what top-a sampling is.


Edit: found a comment regarding top-a sampling (line 169 in the code below)

https://github.com/KoboldAI/KoboldAI-Client/blob/cf3aebbd8f47f8b5db106c654deeb2000827cf17/warpers.py#L153-L179