refac: toolkit -> tools

This commit is contained in:
Timothy Jaeryang Baek
2024-11-16 17:54:38 -08:00
parent a1ce8422fd
commit 0a8f69285c
3 changed files with 53 additions and 53 deletions

View File

@@ -4,7 +4,7 @@ from typing import Awaitable, Callable, get_type_hints
from open_webui.apps.webui.models.tools import Tools
from open_webui.apps.webui.models.users import UserModel
from open_webui.apps.webui.utils import load_toolkit_module_by_id
from open_webui.apps.webui.utils import load_tools_module_by_id
from open_webui.utils.schemas import json_schema_to_model
log = logging.getLogger(__name__)
@@ -40,7 +40,7 @@ def get_tools(
module = webui_app.state.TOOLS.get(tool_id, None)
if module is None:
module, _ = load_toolkit_module_by_id(tool_id)
module, _ = load_tools_module_by_id(tool_id)
webui_app.state.TOOLS[tool_id] = module
extra_params["__id__"] = tool_id