Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
@@ -162,7 +162,11 @@ async def chat_stream(
|
|
162 |
for ppm in local_data
|
163 |
]
|
164 |
|
165 |
-
|
|
|
|
|
|
|
|
|
166 |
|
167 |
#######
|
168 |
# if internet_option:
|
@@ -180,14 +184,12 @@ async def chat_stream(
|
|
180 |
}
|
181 |
|
182 |
palm_if, response_txt = gen_text(
|
183 |
-
|
184 |
parameters=parameters
|
185 |
)
|
186 |
|
187 |
ppm = res[idx]
|
188 |
-
ppm.
|
189 |
-
PingPong(instruction_txtbox, response_txt)
|
190 |
-
)
|
191 |
|
192 |
return "", "", ppm.build_uis(), str(res), gr.update(interactive=True), "off"
|
193 |
|
|
|
162 |
for ppm in local_data
|
163 |
]
|
164 |
|
165 |
+
ppm = res[idx]
|
166 |
+
ppm.add_pingpong(
|
167 |
+
PingPong(instruction_txtbox, response_txt)
|
168 |
+
)
|
169 |
+
prompt = build_prompts(ppm, global_context, ctx_num_lconv)
|
170 |
|
171 |
#######
|
172 |
# if internet_option:
|
|
|
184 |
}
|
185 |
|
186 |
palm_if, response_txt = gen_text(
|
187 |
+
prompt,
|
188 |
parameters=parameters
|
189 |
)
|
190 |
|
191 |
ppm = res[idx]
|
192 |
+
ppm.replace_last_pong(response_txt)
|
|
|
|
|
193 |
|
194 |
return "", "", ppm.build_uis(), str(res), gr.update(interactive=True), "off"
|
195 |
|