formatting and missed int
in llama_token_to_piece
This commit is contained in:
parent
efe287f026
commit
0f8418079c
2 changed files with 2 additions and 2 deletions
|
@ -10266,7 +10266,7 @@ static std::string llama_decode_text(const std::string & text) {
|
||||||
}
|
}
|
||||||
|
|
||||||
// does not write null-terminator to buf
|
// does not write null-terminator to buf
|
||||||
int32_t llama_token_to_piece(const struct llama_model * model, llama_token token, char * buf, int length) {
|
int32_t llama_token_to_piece(const struct llama_model * model, llama_token token, char * buf, int32_t length) {
|
||||||
if (0 <= token && token < llama_n_vocab(model)) {
|
if (0 <= token && token < llama_n_vocab(model)) {
|
||||||
switch (llama_vocab_get_type(model->vocab)) {
|
switch (llama_vocab_get_type(model->vocab)) {
|
||||||
case LLAMA_VOCAB_TYPE_SPM: {
|
case LLAMA_VOCAB_TYPE_SPM: {
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue