Spaces:
Runtime error
Runtime error
Commit
·
e042374
1
Parent(s):
6d86124
Update app.py
Browse files
app.py
CHANGED
@@ -7,13 +7,6 @@ import requests
|
|
7 |
title = "A conversation with Gandalf (GPTJ-6B) 🧙"
|
8 |
description = ""
|
9 |
article = """
|
10 |
-
<p> To reset you need to reload the page </p>
|
11 |
-
<h2> Parameters: </h2>
|
12 |
-
<ul>
|
13 |
-
<li><i>temperature</i>: (sampling temperature) higher values means the model will take more risks.</li>
|
14 |
-
<li><i>max_new_tokens</i>: Max number of tokens in generation.</li>
|
15 |
-
</ul>
|
16 |
-
|
17 |
<img src='http://www.simoninithomas.com/test/gandalf.jpg', alt="Gandalf"/>"""
|
18 |
theme="huggingface"
|
19 |
examples = [[0.9, 1.1, 50, "Hey Gandalf! How are you?"], [0.9, 1.1, 50, "Hey Gandalf, why you didn't use the great eagles to fly Frodo to Mordor?"]]
|
@@ -78,7 +71,6 @@ def chat(top_p, temperature, max_new_tokens, message):
|
|
78 |
iface = gr.Interface(
|
79 |
chat,
|
80 |
[
|
81 |
-
#gr.inputs.Slider(minimum=0.5, maximum=1, step=0.05, default=0.9, label="top_p"),
|
82 |
gr.inputs.Slider(minimum=0.5, maximum=1.5, step=0.1, default=1.1, label="temperature"),
|
83 |
gr.inputs.Slider(minimum=20, maximum=250, step=10, default=50, label="max_new_tokens"),
|
84 |
"text",
|
|
|
7 |
title = "A conversation with Gandalf (GPTJ-6B) 🧙"
|
8 |
description = ""
|
9 |
article = """
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
10 |
<img src='http://www.simoninithomas.com/test/gandalf.jpg', alt="Gandalf"/>"""
|
11 |
theme="huggingface"
|
12 |
examples = [[0.9, 1.1, 50, "Hey Gandalf! How are you?"], [0.9, 1.1, 50, "Hey Gandalf, why you didn't use the great eagles to fly Frodo to Mordor?"]]
|
|
|
71 |
iface = gr.Interface(
|
72 |
chat,
|
73 |
[
|
|
|
74 |
gr.inputs.Slider(minimum=0.5, maximum=1.5, step=0.1, default=1.1, label="temperature"),
|
75 |
gr.inputs.Slider(minimum=20, maximum=250, step=10, default=50, label="max_new_tokens"),
|
76 |
"text",
|