Files
AstrBot/main.py
T
Soulter 51ee4fc9b3 feat: 支持持久化历史记录
fix: 修复了一些已知问题
2022-12-16 23:13:15 +08:00

23 lines
635 B
Python

import cores.qqbot.core as qqBot
from cores.openai.core import ChatGPT
import asyncio
import yaml
import threading
# from cores.database.conn import dbConn
def main():
# 读取参数
# with open('configs/config.yaml', 'r', encoding='utf-8') as f:
# cfg = yaml.safe_load(f)
# chatGPT_configs = cfg['openai']['chatGPTConfigs']
# print(chatGPT_configs)
#实例化ChatGPT
chatgpt = ChatGPT()
# db = dbConn()
# #执行qqBot
# qqBot.initBot(chatgpt, db)
qqBot.initBot(chatgpt)
if __name__ == "__main__":
# qqbot_thread = threading.Thread(target=main)
# qqbot_thread.start()
main()