mirror of
https://github.com/ggerganov/llama.cpp.git
synced 2024-12-25 10:54:36 +00:00
llama : remove "first token must be BOS" restriction (#2153)
This commit is contained in:
parent
db4047ad5c
commit
1d16309969
@ -1291,12 +1291,6 @@ static bool llama_eval_internal(
|
|||||||
|
|
||||||
LLAMA_ASSERT((!tokens && embd) || (tokens && !embd));
|
LLAMA_ASSERT((!tokens && embd) || (tokens && !embd));
|
||||||
|
|
||||||
// enforce that the first token is BOS
|
|
||||||
if (tokens && n_past == 0 && tokens[0] != llama_token_bos()) {
|
|
||||||
fprintf(stderr, "%s: first token must be BOS\n", __func__);
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
|
|
||||||
const int64_t t_start_us = ggml_time_us();
|
const int64_t t_start_us = ggml_time_us();
|
||||||
|
|
||||||
const int N = n_tokens;
|
const int N = n_tokens;
|
||||||
|
Loading…
Reference in New Issue
Block a user