diff --git a/llama.cpp b/llama.cpp index c6327af62fc70..569d06e725502 100644 --- a/llama.cpp +++ b/llama.cpp @@ -1831,6 +1831,7 @@ static void llm_load_vocab( for (int i = 0; i < n_merges; i++) { const std::string word = gguf_get_arr_str(ctx, merges_keyidx, i); + GGML_ASSERT(codepoints_from_utf8(word).size() >= 0); std::string first; std::string second;