Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
@@ -4,7 +4,6 @@ import os
|
|
4 |
from huggingface_hub import InferenceClient
|
5 |
import asyncio
|
6 |
import subprocess
|
7 |
-
import gradio as gr
|
8 |
import requests
|
9 |
|
10 |
# ๋ก๊น
์ค์
|
@@ -141,22 +140,9 @@ async def generate_response(message):
|
|
141 |
|
142 |
return f"{user_mention}, {full_response_text}"
|
143 |
|
144 |
-
# Gradio ์ธํฐํ์ด์ค ์ค์
|
145 |
-
iface = gr.Interface(
|
146 |
-
fn=google_search,
|
147 |
-
inputs="text",
|
148 |
-
outputs="text",
|
149 |
-
title="Google Custom Search",
|
150 |
-
description="Enter a search query to get results from Google Custom Search API."
|
151 |
-
)
|
152 |
-
|
153 |
if __name__ == "__main__":
|
154 |
# Discord ํด๋ผ์ด์ธํธ ์คํ
|
155 |
discord_client = MyClient(intents=intents)
|
156 |
|
157 |
-
# Gradio ์ธํฐํ์ด์ค ์คํ
|
158 |
-
logger.info("Starting Gradio interface")
|
159 |
-
iface.launch(share=True)
|
160 |
-
|
161 |
# Discord ๋ด ์คํ
|
162 |
discord_client.run(os.getenv('DISCORD_TOKEN'))
|
|
|
4 |
from huggingface_hub import InferenceClient
|
5 |
import asyncio
|
6 |
import subprocess
|
|
|
7 |
import requests
|
8 |
|
9 |
# ๋ก๊น
์ค์
|
|
|
140 |
|
141 |
return f"{user_mention}, {full_response_text}"
|
142 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
143 |
if __name__ == "__main__":
|
144 |
# Discord ํด๋ผ์ด์ธํธ ์คํ
|
145 |
discord_client = MyClient(intents=intents)
|
146 |
|
|
|
|
|
|
|
|
|
147 |
# Discord ๋ด ์คํ
|
148 |
discord_client.run(os.getenv('DISCORD_TOKEN'))
|