remove eos

This commit is contained in:
zhangkaihuo 2024-04-01 17:00:07 +08:00
parent 9ecc666b94
commit 8502a015a5

View file

@ -796,7 +796,7 @@ int main(int argc, char ** argv) {
// deal with end of text token in interactive mode
auto last_token = llama_sampling_last(ctx_sampling);
if (last_token == llama_token_eos(model) || last_token == 122753)
if (last_token == llama_token_eos(model))
{
LOG("found EOS token\n");
@ -922,7 +922,7 @@ int main(int argc, char ** argv) {
}
// end of text token
if (!embd.empty() && (embd.back() == llama_token_eos(model) || embd.back() == 122753) && !(params.instruct || params.interactive || params.chatml)) {
if (!embd.empty() && (embd.back() == llama_token_eos(model)) && !(params.instruct || params.interactive || params.chatml)) {
LOG_TEE(" [end of text]\n");
break;
}