fix: remove pycache files and finalize integration
This commit is contained in:
1 parent
d68417bbc8
commit
5a8fcda993
4 files changed
+11
-10
No files matched your search
Binary file not shown.
+8
-8
@@ -115,14 +115,14 @@ class ConfigManager:
|
||||
# Create a deep copy to avoid modifying original
|
||||
result = copy.deepcopy(config)
|
||||
|
||||
# Decrypt configurations
|
||||
if "configurations" in result and isinstance(result["configurations"], dict):
|
||||
for name, config_data in result["configurations"].items():
|
||||
if isinstance(config_data, dict):
|
||||
# Decrypt API keys for relevant providers
|
||||
provider = config_data.get("provider", "").lower()
|
||||
if provider in ["openai", "openrouter", "mcp"] and "api_key" in config_data:
|
||||
config_data["api_key"] = self._decrypt_data(config_data["api_key"])
|
||||
# Decrypt configurations
|
||||
if "configurations" in result and isinstance(result["configurations"], dict):
|
||||
for name, config_data in result["configurations"].items():
|
||||
if isinstance(config_data, dict):
|
||||
# Decrypt API keys for relevant providers
|
||||
provider = config_data.get("provider", "").lower()
|
||||
if provider in ["openai", "openrouter", "mcp"] and "api_key" in config_data:
|
||||
config_data["api_key"] = self._decrypt_data(config_data["api_key"])
|
||||
|
||||
return result
|
||||
|
||||
|
||||
@@ -10,7 +10,7 @@ from typing import Optional, List, Dict, Any
|
||||
from deepagents import create_deep_agent
|
||||
from langchain.chat_models import init_chat_model
|
||||
from langchain_core.messages import HumanMessage, SystemMessage
|
||||
from langchain.tools import Tool
|
||||
from langchain_core.tools import Tool
|
||||
|
||||
# Import custom tools
|
||||
try:
|
||||
|
||||
+2
-1
@@ -5,7 +5,7 @@ Enables integration with MCP servers like skills.sh to discover and use tools
|
||||
import json
|
||||
import requests
|
||||
from typing import Dict, List, Any, Optional
|
||||
from langchain.tools import Tool
|
||||
from langchain_core.tools import Tool
|
||||
import logging
|
||||
|
||||
logger = logging.getLogger(__name__)
|
||||
@@ -97,6 +97,7 @@ class MCPClient:
|
||||
return self._available_tools
|
||||
except Exception as e:
|
||||
logger.error(f"Failed to list tools from MCP server {self.server_url}: {e}")
|
||||
self._available_tools = []
|
||||
return []
|
||||
|
||||
def call_tool(self, tool_name: str, arguments: Dict[str, Any]) -> Any:
|
||||
|
||||
Reference in new issue
Block a user