beomi commited on
Commit
b3d5578
1 Parent(s): 98b3f59

Add guide for oobabooga/text-generation-webui

Browse files
Files changed (1) hide show
  1. README.md +26 -0
README.md CHANGED
@@ -146,6 +146,32 @@ TBD
146
  *Llama-2 Original 7B used https://huggingface.co/meta-llama/Llama-2-7b-hf (No tokenizer updated)
147
 
148
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
149
  ---
150
 
151
  > Below is the original model card of the Llama-2 model.
 
146
  *Llama-2 Original 7B used https://huggingface.co/meta-llama/Llama-2-7b-hf (No tokenizer updated)
147
 
148
 
149
+ ## Note for oobabooga/text-generation-webui
150
+
151
+ Remove `ValueError` at `load_tokenizer` function(line 109 or near), in `modules/models.py`.
152
+
153
+ ```python
154
+ diff --git a/modules/models.py b/modules/models.py
155
+ index 232d5fa..de5b7a0 100644
156
+ --- a/modules/models.py
157
+ +++ b/modules/models.py
158
+ @@ -106,7 +106,7 @@ def load_tokenizer(model_name, model):
159
+ trust_remote_code=shared.args.trust_remote_code,
160
+ use_fast=False
161
+ )
162
+ - except ValueError:
163
+ + except:
164
+ tokenizer = AutoTokenizer.from_pretrained(
165
+ path_to_model,
166
+ trust_remote_code=shared.args.trust_remote_code,
167
+ ```
168
+
169
+ Since Llama-2-Ko uses FastTokenizer provided by HF tokenizers NOT sentencepiece package,
170
+ it is required to use `use_fast=True` option when initialize tokenizer.
171
+
172
+ Apple Sillicon does not support BF16 computing, use CPU instead. (BF16 is supported when using NVIDIA GPU)
173
+
174
+
175
  ---
176
 
177
  > Below is the original model card of the Llama-2 model.