3 ms·
And to build on this, take a look at the code change. Currently in llama.cpp there are many techniques for sampling the next token: llama_sample_token_greedy -
by bryan0 3y ago
And to build on this, take a look at the code change. Currently in llama.cpp there are many techniques for sampling the next token:
llama_sample_token_greedy - just take the top probability
llama_sample_top_k - sample only from the top k probabilities
etc ...
this code change adds a new sample:
llama_sample_grammar - sample only from tokens which match the grammar
- dave1010uk 3y agoIf the performance was ok, is there any reason why a sampler couldn't call an API or use a separate fine tuned model?