mirror of
https://github.com/KoboldAI/KoboldAI-Client.git
synced 2025-01-22 21:29:59 +01:00
Fix an unfortunate typo in top-a warper
This commit is contained in:
parent
fdb2a7fa4c
commit
42b7a327b2
@ -168,7 +168,7 @@ class TopALogitsWarper(LogitsWarper):
|
||||
|
||||
# Remove tokens with probability less than top_a*(max(probs))^2 (token with 0 are kept)
|
||||
probs_max = probs[..., 0, None]
|
||||
sorted_indices_to_remove = probs >= probs_max * probs_max * self.top_a
|
||||
sorted_indices_to_remove = probs < probs_max * probs_max * self.top_a
|
||||
|
||||
if self.min_tokens_to_keep > 1:
|
||||
# Keep at least min_tokens_to_keep
|
||||
|
Loading…
Reference in New Issue
Block a user