forked from MrAli-Code/GirlfriendGPT
-
Notifications
You must be signed in to change notification settings - Fork 0
/
deploy.py
38 lines (31 loc) · 1.09 KB
/
deploy.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
import os
import uuid
from steamship import Steamship
from steamship.cli.cli import deploy
from steamship.data.manifest import Manifest
try:
deploy()
except SystemExit as err:
exit()
manifest = Manifest.load_manifest()
client = Steamship(workspace=f"girlfriend-ai-{uuid.uuid1()}")
bot = client.use(
package_handle=manifest.handle,
version=manifest.version,
instance_handle=f"{manifest.handle}-{manifest.version.replace('.', '-')}",
config={
"bot_token": os.environ.get("BOT_TOKEN")
or input(
"Paste your telegram bot token\nLearn how to create one here: https://github.com/EniasCailliau/GirlfriendGPT/blob/main/docs/register-telegram-bot.md)\n: "
),
"elevenlabs_voice_id": os.environ.get("ELEVENLABS_VOICE_ID", ""),
"elevenlabs_api_key": os.environ.get("ELEVENLABS_API_KEY", ""),
},
)
bot.wait_for_init()
print(client.config.workspace_handle)
print(bot.package_version_handle)
print(
f"""Chat with your bot here:
https://www.steamship.com/workspaces/{client.config.workspace_handle}/packages/{bot.handle}"""
)