tokenize nothing for antiprompt if no reverse

This commit is contained in:
rabidcopy 2023-03-22 11:22:56 -05:00 committed by GitHub
parent da0837f55f
commit c4efdb22af
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -250,7 +250,7 @@ int main(int argc, char ** argv) {
}
// tokenize the first reverse prompt
auto first_antiprompt = ::llama_tokenize(ctx, params.prompt,false);
auto first_antiprompt = ::llama_tokenize(ctx,"",false);
if (!params.antiprompt.empty()) {
auto first_antiprompt = ::llama_tokenize(ctx, params.antiprompt.front(), false);
}