From 72bbb02dc99e31ddbb918706f21105caa1e4bf2f Mon Sep 17 00:00:00 2001 From: decoded Date: Wed, 15 Mar 2023 15:15:40 -0500 Subject: [PATCH] update --- storage/bot/plugins/openai_plugin.py | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/storage/bot/plugins/openai_plugin.py b/storage/bot/plugins/openai_plugin.py index 0b383ef..6c609a2 100644 --- a/storage/bot/plugins/openai_plugin.py +++ b/storage/bot/plugins/openai_plugin.py @@ -28,6 +28,18 @@ if SERVICES_OPENAI: ####################################################################################### dir_path = os.path.dirname(os.path.realpath(__file__)) + + ####################################################################################### + ####################################################################################### + + PATH='%s/../personalities' % dir_path + FILE='%s/../personalities/default.db' % dir_path + if not os.path.exists(PATH): + os.mkdir(PATH) + if not os.path.exists(FILE): + f=open(FILE,'w') + f.write("") + f.close() ####################################################################################### #######################################################################################