Update app.py
Browse files
app.py
CHANGED
@@ -6,6 +6,8 @@ from g4f import Provider, models
|
|
6 |
from langchain.llms.base import LLM
|
7 |
|
8 |
from langchain_g4f import G4FLLM
|
|
|
|
|
9 |
|
10 |
|
11 |
nest_asyncio.apply()
|
@@ -26,9 +28,12 @@ def echo_all(message):
|
|
26 |
provider=Provider.ChatgptLogin,
|
27 |
)
|
28 |
|
29 |
-
res = llm(user_input)
|
30 |
-
|
31 |
-
|
|
|
|
|
|
|
32 |
|
33 |
#bot.infinity_polling()
|
34 |
def addition(nombre1, nombre2):
|
|
|
6 |
from langchain.llms.base import LLM
|
7 |
|
8 |
from langchain_g4f import G4FLLM
|
9 |
+
from gradio_client import Client
|
10 |
+
|
11 |
|
12 |
|
13 |
nest_asyncio.apply()
|
|
|
28 |
provider=Provider.ChatgptLogin,
|
29 |
)
|
30 |
|
31 |
+
#res = llm(user_input)
|
32 |
+
client = Client("https://docfile-qaz2.hf.space/")
|
33 |
+
result = client.predict(
|
34 |
+
user_input, # str in 'query' Textbox component
|
35 |
+
api_name="/predict")
|
36 |
+
bot.reply_to(message,client)
|
37 |
|
38 |
#bot.infinity_polling()
|
39 |
def addition(nombre1, nombre2):
|