Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
@@ -15,7 +15,7 @@ def format_prompt(message, history):
|
|
15 |
return prompt
|
16 |
|
17 |
def generate(
|
18 |
-
prompt, history, temperature=0.9, max_new_tokens=
|
19 |
):
|
20 |
temperature = float(temperature)
|
21 |
if temperature < 1e-2:
|
@@ -28,7 +28,7 @@ def generate(
|
|
28 |
top_p=top_p,
|
29 |
repetition_penalty=repetition_penalty,
|
30 |
do_sample=True,
|
31 |
-
seed=
|
32 |
)
|
33 |
|
34 |
print(prompt, history)
|
@@ -106,4 +106,4 @@ with gr.Blocks(css=css) as demo:
|
|
106 |
examples=[["What is the secret to life?"], ["Write me a recipe for pancakes."]]
|
107 |
)
|
108 |
|
109 |
-
demo.
|
|
|
15 |
return prompt
|
16 |
|
17 |
def generate(
|
18 |
+
prompt, history, temperature=0.9, max_new_tokens=2000, top_p=0.9, repetition_penalty=1.2,
|
19 |
):
|
20 |
temperature = float(temperature)
|
21 |
if temperature < 1e-2:
|
|
|
28 |
top_p=top_p,
|
29 |
repetition_penalty=repetition_penalty,
|
30 |
do_sample=True,
|
31 |
+
seed=50,
|
32 |
)
|
33 |
|
34 |
print(prompt, history)
|
|
|
106 |
examples=[["What is the secret to life?"], ["Write me a recipe for pancakes."]]
|
107 |
)
|
108 |
|
109 |
+
demo.launch(debug=True)
|