diff options
author | Georgi Gerganov <ggerganov@gmail.com> | 2023-05-02 23:09:08 +0300 |
---|---|---|
committer | Georgi Gerganov <ggerganov@gmail.com> | 2023-05-02 23:09:08 +0300 |
commit | 0e6cbff1b7509628c588e661166f6e187137734d (patch) | |
tree | 3f1431d95cf186ea1b2d7afee0722d02e6ef2658 /llama.h | |
parent | 5d5817ca603d4cb451bed26594aa3dcd93f4ec56 (diff) |
llama : fix compile warnings
Diffstat (limited to 'llama.h')
-rw-r--r-- | llama.h | 4 |
1 files changed, 2 insertions, 2 deletions
@@ -192,10 +192,10 @@ extern "C" { // Sampling functions /// @details Repetition penalty described in CTRL academic paper https://arxiv.org/abs/1909.05858, with negative logit fix. - LLAMA_API void llama_sample_repetition_penalty(struct llama_context * ctx, llama_token_data_array * candidates, llama_token * last_tokens, size_t last_tokens_size, float penalty); + LLAMA_API void llama_sample_repetition_penalty(struct llama_context * ctx, llama_token_data_array * candidates, const llama_token * last_tokens, size_t last_tokens_size, float penalty); /// @details Frequency and presence penalties described in OpenAI API https://platform.openai.com/docs/api-reference/parameter-details. - LLAMA_API void llama_sample_frequency_and_presence_penalties(struct llama_context * ctx, llama_token_data_array * candidates, llama_token * last_tokens, size_t last_tokens_size, float alpha_frequency, float alpha_presence); + LLAMA_API void llama_sample_frequency_and_presence_penalties(struct llama_context * ctx, llama_token_data_array * candidates, const llama_token * last_tokens, size_t last_tokens_size, float alpha_frequency, float alpha_presence); /// @details Sorts candidate tokens by their logits in descending order and calculate probabilities based on logits. LLAMA_API void llama_sample_softmax(struct llama_context * ctx, llama_token_data_array * candidates); |