Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
@@ -13,7 +13,7 @@ llm = Llama(model_path = 'Llama-2-ko-7B-chat-gguf-q4_0.bin',
|
|
13 |
)
|
14 |
|
15 |
def gen(x, max_new_tokens):
|
16 |
-
output = llm(f"Q: {x} A: ", max_tokens=
|
17 |
|
18 |
return output['choices'][0]['text'].replace('▁',' ')
|
19 |
|
|
|
13 |
)
|
14 |
|
15 |
def gen(x, max_new_tokens):
|
16 |
+
output = llm(f"Q: {x} A: ", max_tokens=max_new_tokens, stop=["Q:", "\n"], echo=True)
|
17 |
|
18 |
return output['choices'][0]['text'].replace('▁',' ')
|
19 |
|