Refactor agents and tools (#91)

* Move tools to agents

* Move agents to dedicate place

* Remove subclassing BaseAgent from BaseTool
This commit is contained in:
Nguyen Trung Duc (john)
2023-11-30 09:52:08 +07:00
committed by GitHub
parent 4256030b4f
commit 8e3a1d193f
24 changed files with 126 additions and 124 deletions

View File

@@ -3,17 +3,12 @@ from unittest.mock import patch
import pytest
from openai.types.chat.chat_completion import ChatCompletion
from kotaemon.agents.base import AgentType
from kotaemon.agents.langchain import LangchainAgent
from kotaemon.agents.react import ReactAgent
from kotaemon.agents.rewoo import RewooAgent
from kotaemon.agents.tools import BaseTool, GoogleSearchTool, LLMTool, WikipediaTool
from kotaemon.llms.chats.openai import AzureChatOpenAI
from kotaemon.pipelines.agents.base import AgentType
from kotaemon.pipelines.agents.langchain import LangchainAgent
from kotaemon.pipelines.agents.react import ReactAgent
from kotaemon.pipelines.agents.rewoo import RewooAgent
from kotaemon.pipelines.tools import (
BaseTool,
GoogleSearchTool,
LLMTool,
WikipediaTool,
)
FINAL_RESPONSE_TEXT = "Final Answer: Hello Cinnamon AI!"