Update app.py
Browse files
app.py
CHANGED
@@ -285,7 +285,7 @@ def respond(
|
|
285 |
):
|
286 |
llama = Llama("models/madlad400-3b-mt-q8_0.gguf")
|
287 |
#tokens = llama.tokenize(f"<2ja>{message}")#
|
288 |
-
tokens = llama.tokenize(f"{
|
289 |
llama.encode(tokens)
|
290 |
tokens = [llama.decoder_start_token()]
|
291 |
for token in llama.generate(tokens, top_k=40, top_p=0.95, temp=1, repeat_penalty=1.0):
|
|
|
285 |
):
|
286 |
llama = Llama("models/madlad400-3b-mt-q8_0.gguf")
|
287 |
#tokens = llama.tokenize(f"<2ja>{message}")#
|
288 |
+
tokens = llama.tokenize(f"<2ja>{message}".encode("utf-8"))
|
289 |
llama.encode(tokens)
|
290 |
tokens = [llama.decoder_start_token()]
|
291 |
for token in llama.generate(tokens, top_k=40, top_p=0.95, temp=1, repeat_penalty=1.0):
|