Skip to content

Commit 125b235

Browse files
committed
feat: Update llama.cpp
1 parent 901fe02 commit 125b235

File tree

2 files changed

+8
-4
lines changed

2 files changed

+8
-4
lines changed

llama_cpp/llama_cpp.py

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -199,14 +199,18 @@ def byref(obj: CtypesCData, offset: Optional[int] = None) -> CtypesRef[CtypesCDa
199199

200200
# enum llama_vocab_type {
201201
# LLAMA_VOCAB_TYPE_NONE = 0, // For models without vocab
202-
# LLAMA_VOCAB_TYPE_SPM = 1, // SentencePiece
203-
# LLAMA_VOCAB_TYPE_BPE = 2, // Byte Pair Encoding
204-
# LLAMA_VOCAB_TYPE_WPM = 3, // WordPiece
202+
# LLAMA_VOCAB_TYPE_SPM = 1, // LLaMA tokenizer based on byte-level BPE with byte fallback
203+
# LLAMA_VOCAB_TYPE_BPE = 2, // GPT-2 tokenizer based on byte-level BPE
204+
# LLAMA_VOCAB_TYPE_WPM = 3, // BERT tokenizer based on WordPiece
205205
# };
206206
LLAMA_VOCAB_TYPE_NONE = 0
207+
"""For models without vocab"""
207208
LLAMA_VOCAB_TYPE_SPM = 1
209+
"""LLaMA tokenizer based on byte-level BPE with byte fallback"""
208210
LLAMA_VOCAB_TYPE_BPE = 2
211+
"""GPT-2 tokenizer based on byte-level BPE"""
209212
LLAMA_VOCAB_TYPE_WPM = 3
213+
"""BERT tokenizer based on WordPiece"""
210214

211215

212216
# // note: these values should be synchronized with ggml_rope

vendor/llama.cpp

0 commit comments

Comments
 (0)