From c94b169a444e1f5af7a94047260e3ec6cac78f87 Mon Sep 17 00:00:00 2001
From: Kye <kye@apacmediasolutions.com>
Date: Thu, 20 Jul 2023 10:58:31 -0400
Subject: [PATCH] clean up

Former-commit-id: 1d022f4fe9af3853e0825adbf499f1d4a9133157
---
 swarms/swarms.py | 10 +++++++++-
 1 file changed, 9 insertions(+), 1 deletion(-)

diff --git a/swarms/swarms.py b/swarms/swarms.py
index 2b7bc849..bb0c86d4 100644
--- a/swarms/swarms.py
+++ b/swarms/swarms.py
@@ -36,12 +36,15 @@ class Swarms:
         except Exception as e:
             logging.error(f"Failed to initialize language model: {e}")
 
-    def initialize_tools(self, llm_class):
+    def initialize_tools(self, llm_class, extra_tools=None):
         """
         Init tools
         
         Params:
             llm_class (class): The Language model class. Default is OpenAI
+
+        extra_tools = [CustomTool()]
+            worker_tools = swarms.initialize_tools(OpenAI, extra_tools)
         """
         try:
             llm = self.initialize_llm(llm_class)
@@ -56,6 +59,11 @@ class Swarms:
                 WebpageQATool(qa_chain=load_qa_with_sources_chain(llm)),
             ]
 
+            if extra_tools:
+                tools.extend(extra_tools)
+
+
+
             assert tools is not None, "tools is not initialized"
             return tools