aboutsummaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
authorGeorgi Gerganov <ggerganov@gmail.com>2023-05-02 23:09:08 +0300
committerGeorgi Gerganov <ggerganov@gmail.com>2023-05-02 23:09:08 +0300
commit0e6cbff1b7509628c588e661166f6e187137734d (patch)
tree3f1431d95cf186ea1b2d7afee0722d02e6ef2658 /tests
parent5d5817ca603d4cb451bed26594aa3dcd93f4ec56 (diff)
llama : fix compile warnings
Diffstat (limited to 'tests')
-rw-r--r--tests/test-sampling.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/tests/test-sampling.cpp b/tests/test-sampling.cpp
index 7eee4f6..8ce59af 100644
--- a/tests/test-sampling.cpp
+++ b/tests/test-sampling.cpp
@@ -131,7 +131,7 @@ void test_repetition_penalty(
llama_token_data_array candidates_p = { candidates.data(), candidates.size(), false };
llama_sample_softmax(nullptr, &candidates_p);
DUMP(&candidates_p);
- llama_sample_repetition_penalty(nullptr, &candidates_p, (llama_token *)last_tokens.data(), last_tokens.size(), penalty);
+ llama_sample_repetition_penalty(nullptr, &candidates_p, (const llama_token *) last_tokens.data(), last_tokens.size(), penalty);
llama_sample_softmax(nullptr, &candidates_p);
DUMP(&candidates_p);
@@ -160,7 +160,7 @@ void test_frequency_presence_penalty(
llama_token_data_array candidates_p = { candidates.data(), candidates.size(), false };
llama_sample_softmax(nullptr, &candidates_p);
// DUMP(&candidates_p);
- llama_sample_frequency_and_presence_penalties(nullptr, &candidates_p, (llama_token *)last_tokens.data(), last_tokens.size(), alpha_frequency, alpha_presence);
+ llama_sample_frequency_and_presence_penalties(nullptr, &candidates_p, (const llama_token *) last_tokens.data(), last_tokens.size(), alpha_frequency, alpha_presence);
llama_sample_softmax(nullptr, &candidates_p);
// DUMP(&candidates_p);