Skip to content
Open
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
eos token not added to prompt
  • Loading branch information
net-haus committed Nov 22, 2025
commit 077b0593a18cb0a681d4a51925913f6299211253
2 changes: 1 addition & 1 deletion src/llama-vocab-sentencepiece.cpp
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
#include "sentencepiece_processor.h"
#include "filesystem.h"
//#include "filesystem.h"
#include "llama-vocab-sentencepiece.h"
#include <string>
#include <vector>
Expand Down
2 changes: 1 addition & 1 deletion src/llama-vocab.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -2090,7 +2090,7 @@ void llama_vocab::impl::load(llama_model_loader & ml, const LLM_KV & kv) {
} else if (type == LLAMA_VOCAB_TYPE_SPIE) {
pre_type = LLAMA_VOCAB_PRE_TYPE_DEFAULT;
add_bos = false;
add_eos = true;
add_eos = false;
}
else if (type == LLAMA_VOCAB_TYPE_RWKV) {
pre_type = LLAMA_VOCAB_PRE_TYPE_DEFAULT;
Expand Down
2 changes: 2 additions & 0 deletions tests/test-model-load-cancel.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -100,6 +100,8 @@ int main(int argc, char ** argv) {

std::vector<llama_token> tokens = common_tokenize(ctx, str, false, true);

std::vector<llama_token> tokensbos = common_tokenize(ctx, str,true, true);

{
std::vector<llama_chat_message> conversation {
{"user", "Hello, how are you?"},
Expand Down