Former-commit-id: e418fb44a8
discord-bot-framework
Kye 1 year ago
parent b5df48afd7
commit 42b3868954

@ -22,7 +22,7 @@ from swarms.utils.decorators import error_decorator, log_decorator, timing_decor
ROOT_DIR = "./data/" ROOT_DIR = "./data/"
# main # main
openai_api_key = os.environ["OPENAI_API_KEY"]
class Worker: class Worker:
""" """
@ -71,7 +71,7 @@ class Worker:
self.temperature = temperature self.temperature = temperature
self.human_in_the_loop = human_in_the_loop self.human_in_the_loop = human_in_the_loop
self.llm = llm self.llm = llm
self.openai_api_key = openai_api_key self.openai_api_key = openai_api_key or os.environ["OPENAI_API_KEY"]
self.ai_name = ai_name self.ai_name = ai_name
self.ai_role = ai_role self.ai_role = ai_role
self.setup_tools(external_tools) self.setup_tools(external_tools)

Loading…
Cancel
Save