Skip to content

Commit

Permalink
preclamp to the first 100 logits
Browse files Browse the repository at this point in the history
  • Loading branch information
Nexesenex committed Aug 12, 2024
1 parent a287d4c commit 8de3d5a
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions gpttype_adapter.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -843,8 +843,8 @@ int mirostat, float mirostat_tau, float mirostat_eta, float dry_multiplier, floa
sample_grammar(file_format, n_vocab, &candidates_p, grammar);
}

//prefilter to top 5k tokens for improved speed
llama_sample_top_k(nullptr, &candidates_p, 5000, 1);
//prefilter to top "pick a nucmber" tokens for improved speed (KCPP-official default is 5k)
llama_sample_top_k(nullptr, &candidates_p, 100, 1);

if (mirostat == 1 || mirostat == 2)
{
Expand Down

0 comments on commit 8de3d5a

Please sign in to comment.