Skip to content

Commit

Permalink
llama : remove "first token must be BOS" restriction (ggerganov#2153)
Browse files Browse the repository at this point in the history
  • Loading branch information
oobabooga authored Jul 9, 2023
1 parent db4047a commit 1d16309
Showing 1 changed file with 0 additions and 6 deletions.
6 changes: 0 additions & 6 deletions llama.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1291,12 +1291,6 @@ static bool llama_eval_internal(

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 int N = n_tokens;
Expand Down

0 comments on commit 1d16309

Please sign in to comment.