llama.cpp/llama_cpp
Sigbjørn Skjæret dbcf64cf07
feat: Support SPM infill (#1492)
* Support SPM infill

* typo--

* one less layer of parenthesis necessary

* new required internals

* manually add bos/eos if model requires it

* add bos even when unknown

This is identical behaviour to llama.cpp

I guess any model that doesn't use BOS is recent enough to have the add_bos_token metadata.

* don't add bos/eos on non-infill pre-tokenized prompt

* add tokenizer hack to remove leading space in suffix

* I keep forgetting metadata are strings

* check if bos exists

* add example

* add cls/sep instead of bos/eos for WPM vocab

* simplify

* color-code filtered suffix

---------

Co-authored-by: Andrei Betlen <abetlen@gmail.com>
2024-06-13 03:45:24 -04:00
..
server feat: adding rpc_servers parameter to Llama class (#1477) 2024-06-04 10:38:21 -04:00
__init__.py chore: Bump version 2024-06-10 11:14:33 -04:00
_internals.py feat: Support SPM infill (#1492) 2024-06-13 03:45:24 -04:00
_logger.py fix: Use llama_log_callback to avoid suppress_stdout_stderr 2024-02-05 21:52:12 -05:00
_utils.py fix: Suppress all logs when verbose=False, use hardcoded fileno's to work in colab notebooks. Closes #796 Closes #729 2024-04-30 15:45:34 -04:00
llama.py feat: Support SPM infill (#1492) 2024-06-13 03:45:24 -04:00
llama_cache.py Move cache classes to llama_cache submodule. 2024-01-17 09:09:12 -05:00
llama_chat_format.py fix: Avoid duplicate special tokens in chat formats (#1439) 2024-06-04 10:15:41 -04:00
llama_cpp.py feat: Update llama.cpp 2024-06-07 02:02:12 -04:00
llama_grammar.py fix: UTF-8 handling with grammars (#1415) 2024-04-30 14:33:23 -04:00
llama_speculative.py Add speculative decoding (#1120) 2024-01-31 14:08:14 -05:00
llama_tokenizer.py fix: LlamaHFTokenizer now receives pre_tokens 2024-02-23 12:23:24 -05:00
llama_types.py feat: Allow for possibly non-pooled embeddings (#1380) 2024-04-25 21:32:44 -04:00
llava_cpp.py feat: Generic Chat Formats, Tool Calling, and Huggingface Pull Support for Multimodal Models (Obsidian, LLaVA1.6, Moondream) (#1147) 2024-04-30 01:35:38 -04:00
py.typed Add py.typed 2023-08-11 09:58:48 +02:00