Update app.py
Browse files
app.py
CHANGED
@@ -1,8 +1,8 @@
|
|
1 |
import gradio as gr
|
2 |
import g4f
|
3 |
-
#
|
4 |
-
#
|
5 |
-
#
|
6 |
|
7 |
# Automatic selection of provider
|
8 |
|
@@ -17,14 +17,17 @@ def chatbot_interaction(input_text):
|
|
17 |
messages=[{"role": "user", "content": input_texxt}],
|
18 |
stream=True,
|
19 |
)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
20 |
Q = ""
|
21 |
for message in response:
|
22 |
print(message, flush=True, end='')
|
23 |
Q += message
|
24 |
-
print()
|
25 |
-
print()
|
26 |
-
print()
|
27 |
-
print("réponse:", Q)
|
28 |
return Q
|
29 |
iface = gr.Interface(
|
30 |
fn=chatbot_interaction,
|
|
|
1 |
import gradio as gr
|
2 |
import g4f
|
3 |
+
#
|
4 |
+
#
|
5 |
+
# supporte args
|
6 |
|
7 |
# Automatic selection of provider
|
8 |
|
|
|
17 |
messages=[{"role": "user", "content": input_texxt}],
|
18 |
stream=True,
|
19 |
)
|
20 |
+
print()
|
21 |
+
print()
|
22 |
+
print()
|
23 |
+
print("réponse")
|
24 |
+
print()
|
25 |
+
print()
|
26 |
+
print()
|
27 |
Q = ""
|
28 |
for message in response:
|
29 |
print(message, flush=True, end='')
|
30 |
Q += message
|
|
|
|
|
|
|
|
|
31 |
return Q
|
32 |
iface = gr.Interface(
|
33 |
fn=chatbot_interaction,
|