Spaces:
Running
on
CPU Upgrade
Running
on
CPU Upgrade
Disable chat api
Browse files
utils.py
CHANGED
@@ -20,6 +20,7 @@ def get_app(
|
|
20 |
for model_name in models:
|
21 |
with gr.Column(visible=model_name == default_model) as column:
|
22 |
gr.load(name=model_name, src=src, accept_token=accept_token, **kwargs)
|
|
|
23 |
columns.append(column)
|
24 |
|
25 |
model.change(
|
@@ -30,4 +31,8 @@ def get_app(
|
|
30 |
queue=False,
|
31 |
)
|
32 |
|
33 |
-
|
|
|
|
|
|
|
|
|
|
20 |
for model_name in models:
|
21 |
with gr.Column(visible=model_name == default_model) as column:
|
22 |
gr.load(name=model_name, src=src, accept_token=accept_token, **kwargs)
|
23 |
+
|
24 |
columns.append(column)
|
25 |
|
26 |
model.change(
|
|
|
31 |
queue=False,
|
32 |
)
|
33 |
|
34 |
+
for k, v in list(demo.fns.items()):
|
35 |
+
if isinstance(v.api_name, str) and "chat" in v.api_name:
|
36 |
+
del demo.fns[k]
|
37 |
+
|
38 |
+
return demo
|