quantalogic 0.50.2__py3-none-any.whl → 0.50.3__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- quantalogic/tools/__init__.py +1 -1
- quantalogic/tools/composio/composio.py +20 -2
- {quantalogic-0.50.2.dist-info → quantalogic-0.50.3.dist-info}/METADATA +1 -1
- {quantalogic-0.50.2.dist-info → quantalogic-0.50.3.dist-info}/RECORD +7 -7
- {quantalogic-0.50.2.dist-info → quantalogic-0.50.3.dist-info}/LICENSE +0 -0
- {quantalogic-0.50.2.dist-info → quantalogic-0.50.3.dist-info}/WHEEL +0 -0
- {quantalogic-0.50.2.dist-info → quantalogic-0.50.3.dist-info}/entry_points.txt +0 -0
quantalogic/tools/__init__.py
CHANGED
@@ -32,7 +32,7 @@ class LazyLoader:
|
|
32
32
|
# Map of tool names to their import paths and optional status
|
33
33
|
_TOOL_IMPORTS = {
|
34
34
|
"AgentTool": (".agent_tool", False),
|
35
|
-
"ComposioTool": (".composio.composio",
|
35
|
+
"ComposioTool": (".composio.composio", True),
|
36
36
|
"GenerateDatabaseReportTool": (".database.generate_database_report_tool", False),
|
37
37
|
"SQLQueryToolAdvanced": (".database.sql_query_tool_advanced", False),
|
38
38
|
"MarkdownToDocxTool": (".document_tools.markdown_to_docx_tool", True),
|
@@ -4,12 +4,24 @@ import json
|
|
4
4
|
import os
|
5
5
|
import traceback
|
6
6
|
from datetime import datetime
|
7
|
-
from typing import Any, Dict, Optional
|
7
|
+
from typing import Any, Dict, Optional, Union
|
8
8
|
|
9
|
-
from composio import Action, ComposioToolSet
|
10
9
|
from loguru import logger
|
11
10
|
from pydantic import BaseModel, ConfigDict, Field
|
12
11
|
|
12
|
+
# Try to import composio, but don't fail if it's not installed
|
13
|
+
try:
|
14
|
+
from composio import Action, ComposioToolSet
|
15
|
+
COMPOSIO_AVAILABLE = True
|
16
|
+
except ImportError:
|
17
|
+
logger.warning("composio module not installed. ComposioTool will not be available.")
|
18
|
+
COMPOSIO_AVAILABLE = False
|
19
|
+
# Create dummy classes to avoid errors
|
20
|
+
class Action:
|
21
|
+
pass
|
22
|
+
class ComposioToolSet:
|
23
|
+
pass
|
24
|
+
|
13
25
|
from quantalogic.tools.tool import Tool, ToolArgument
|
14
26
|
|
15
27
|
|
@@ -96,6 +108,12 @@ class ComposioTool(Tool):
|
|
96
108
|
need_validation: Whether this specific instance needs validation
|
97
109
|
**data: Additional data for tool initialization
|
98
110
|
"""
|
111
|
+
# Check if composio is available
|
112
|
+
if not COMPOSIO_AVAILABLE:
|
113
|
+
logger.error("ComposioTool cannot be initialized: composio module is not installed")
|
114
|
+
raise ImportError("The 'composio' package is required to use ComposioTool. "
|
115
|
+
"Install it with 'pip install composio' or include it in your dependencies.")
|
116
|
+
|
99
117
|
logger.info(f"Initializing ComposioTool for action: {action}")
|
100
118
|
start_time = datetime.now()
|
101
119
|
|
@@ -38,9 +38,9 @@ quantalogic/server/templates/index.html,sha256=nDnXJoQEm1vXbhXtgaYk0G5VXj0wwzE6K
|
|
38
38
|
quantalogic/task_file_reader.py,sha256=oPcB4vTxJ__Y8o7VVABIPOkVw3tGDMdQYwdK27PERlE,1440
|
39
39
|
quantalogic/task_runner.py,sha256=c2QVGKZfHA0wZIBUvehpjMvtRaKZuhuYQerjIiCC9iY,10053
|
40
40
|
quantalogic/tool_manager.py,sha256=vNA7aBKgdU3wpw_goom6i9rg_64pNZapNxvg4cUhhCI,6983
|
41
|
-
quantalogic/tools/__init__.py,sha256=
|
41
|
+
quantalogic/tools/__init__.py,sha256=Hpgt8RslYAwAfaKYunTFz_tsNdIZUXH5ovssNZu0H0c,5142
|
42
42
|
quantalogic/tools/agent_tool.py,sha256=MXCXxWHRch7VK4UWhtRP1jeI8Np9Ne2CUGo8vm1oZiM,3064
|
43
|
-
quantalogic/tools/composio/composio.py,sha256=
|
43
|
+
quantalogic/tools/composio/composio.py,sha256=1FJ8lyZUslQpewX7WUF-sanF0f52gmL0-ZQFBXkiqaE,18373
|
44
44
|
quantalogic/tools/database/generate_database_report_tool.py,sha256=lGgER2VuHqnxliPM806tbwJh7WRW9HJcbBLL7QMvVBQ,1861
|
45
45
|
quantalogic/tools/database/sql_query_tool_advanced.py,sha256=Vale-5nR3e-Mm4joOBII8T1PbLcshXYbM8Mp4TJsS30,9425
|
46
46
|
quantalogic/tools/document_tools/markdown_to_docx_tool.py,sha256=r5AOyQfpcDoqQ6_g2uYyVjTEPtfeNn4mDmmefNZmJyM,22553
|
@@ -141,8 +141,8 @@ quantalogic/version_check.py,sha256=JyQFTNMDWtpHCLnN-BiakzB2cyXf6kUFsTjvmSruZi4,
|
|
141
141
|
quantalogic/welcome_message.py,sha256=o4tHdgabNuIV9kbIDPgS3_2yzJhayK30oKad2UouYDc,3020
|
142
142
|
quantalogic/xml_parser.py,sha256=AKuMdJC3QAX3Z_tErHVlZ-msjPemWaZUFiTwkHz76jg,11614
|
143
143
|
quantalogic/xml_tool_parser.py,sha256=Vz4LEgDbelJynD1siLOVkJ3gLlfHsUk65_gCwbYJyGc,3784
|
144
|
-
quantalogic-0.50.
|
145
|
-
quantalogic-0.50.
|
146
|
-
quantalogic-0.50.
|
147
|
-
quantalogic-0.50.
|
148
|
-
quantalogic-0.50.
|
144
|
+
quantalogic-0.50.3.dist-info/LICENSE,sha256=xx0jnfkXJvxRnG63LTGOxlggYnIysveWIZ6H3PNdCrQ,11357
|
145
|
+
quantalogic-0.50.3.dist-info/METADATA,sha256=8yPjleuhCSPRiv7lwPRB5vObHFWMyrU0Ih7A4W2PA1Y,22785
|
146
|
+
quantalogic-0.50.3.dist-info/WHEEL,sha256=Nq82e9rUAnEjt98J6MlVmMCZb-t9cYE2Ir1kpBmnWfs,88
|
147
|
+
quantalogic-0.50.3.dist-info/entry_points.txt,sha256=h74O_Q3qBRCrDR99qvwB4BpBGzASPUIjCfxHq6Qnups,183
|
148
|
+
quantalogic-0.50.3.dist-info/RECORD,,
|
File without changes
|
File without changes
|
File without changes
|