Spaces:
Paused
Paused
remove rep penelty
Browse files
app.py
CHANGED
@@ -34,7 +34,7 @@ def generate(
|
|
34 |
#temperature: float = 0.6,
|
35 |
#top_p: float = 0.9,
|
36 |
#top_k: int = 50,
|
37 |
-
repetition_penalty: float = 1.2,
|
38 |
) -> Iterator[str]:
|
39 |
conversation = []
|
40 |
current_input = ""
|
@@ -65,7 +65,7 @@ def generate(
|
|
65 |
#top_k=top_k,
|
66 |
#temperature=temperature,
|
67 |
#num_beams=1,
|
68 |
-
repetition_penalty=repetition_penalty,
|
69 |
)
|
70 |
t = Thread(target=model.generate, kwargs=generate_kwargs)
|
71 |
t.start()
|
@@ -107,13 +107,13 @@ chat_interface = gr.ChatInterface(
|
|
107 |
# step=1,
|
108 |
# value=50,
|
109 |
# ),
|
110 |
-
gr.Slider(
|
111 |
-
|
112 |
-
|
113 |
-
|
114 |
-
|
115 |
-
|
116 |
-
),
|
117 |
],
|
118 |
stop_btn=None,
|
119 |
examples=[
|
|
|
34 |
#temperature: float = 0.6,
|
35 |
#top_p: float = 0.9,
|
36 |
#top_k: int = 50,
|
37 |
+
#repetition_penalty: float = 1.2,
|
38 |
) -> Iterator[str]:
|
39 |
conversation = []
|
40 |
current_input = ""
|
|
|
65 |
#top_k=top_k,
|
66 |
#temperature=temperature,
|
67 |
#num_beams=1,
|
68 |
+
#repetition_penalty=repetition_penalty,
|
69 |
)
|
70 |
t = Thread(target=model.generate, kwargs=generate_kwargs)
|
71 |
t.start()
|
|
|
107 |
# step=1,
|
108 |
# value=50,
|
109 |
# ),
|
110 |
+
# gr.Slider(
|
111 |
+
# label="Repetition penalty",
|
112 |
+
# minimum=0.1,
|
113 |
+
# maximum=2.0,
|
114 |
+
# step=0.05,
|
115 |
+
# value=1.2,
|
116 |
+
# ),
|
117 |
],
|
118 |
stop_btn=None,
|
119 |
examples=[
|