tripleS-Dev
commited on
Commit
•
d28008c
1
Parent(s):
8c33a68
start
Browse files
bot.py
CHANGED
@@ -1,5 +1,5 @@
|
|
1 |
import os
|
2 |
-
|
3 |
import discord
|
4 |
from discord.ext import commands
|
5 |
from discord import app_commands
|
@@ -7,6 +7,8 @@ import funtion
|
|
7 |
import cosmo2hex
|
8 |
from typing import Optional
|
9 |
import typing
|
|
|
|
|
10 |
|
11 |
tree_guild = 1207625911709597737
|
12 |
|
@@ -47,9 +49,21 @@ async def collect(interaction: discord.Interaction, name: str, count: Optional[i
|
|
47 |
|
48 |
|
49 |
|
50 |
-
|
51 |
-
|
52 |
-
if toker:
|
53 |
client.run(toker)
|
54 |
-
|
55 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
import os
|
2 |
+
import threading
|
3 |
import discord
|
4 |
from discord.ext import commands
|
5 |
from discord import app_commands
|
|
|
7 |
import cosmo2hex
|
8 |
from typing import Optional
|
9 |
import typing
|
10 |
+
import gradio as gr
|
11 |
+
|
12 |
|
13 |
tree_guild = 1207625911709597737
|
14 |
|
|
|
49 |
|
50 |
|
51 |
|
52 |
+
def run():
|
53 |
+
toker = os.getenv['super_cosmo']
|
|
|
54 |
client.run(toker)
|
55 |
+
|
56 |
+
def greet(name):
|
57 |
+
return "Hello " + name + "!"
|
58 |
+
|
59 |
+
demo = gr.Interface(fn=greet, inputs="textbox", outputs="textbox")
|
60 |
+
|
61 |
+
if __name__ == "__main__":
|
62 |
+
t1 = threading.Thread(target=demo.launch)
|
63 |
+
t2 = threading.Thread(target=run)
|
64 |
+
|
65 |
+
t1.start()
|
66 |
+
t2.start()
|
67 |
+
|
68 |
+
t1.join()
|
69 |
+
t2.join()
|