Agent Zero AI framework
merge MCP clients
frdel69c3ac310b72
diff --cc agent.pyindex 9785ddd51,8c8ade8a5..97c6d544a--- a/agent.py+++ b/agent.py@@@ -1,9 -1,12 +1,12 @@@import asyncio+ import nest_asyncio+ nest_asyncio.apply()+from collections import OrderedDictfrom dataclasses import dataclass, field-from datetime import datetime-import json-from typing import Any, Awaitable, Coroutine, Optional, Dict, TypedDict+from datetime import datetime, timezone+from typing import Any, Awaitable, Coroutine, Dict+from enum import Enumimport uuidimport modelsdiff --cc docker/run/fs/ins/install_A0.shindex 8f110a6b7,8fb6eeb84..d110877b9--- a/docker/run/fs/ins/install_A0.sh+++ b/docker/run/fs/ins/install_A0.sh@@@ -1,6 -1,8 +1,9 @@@#!/bin/bash+set -e+ # Exit immediately if a command exits with a non-zero status.+ # set -e+# branch from parameterif [ -z "$1" ]; thenecho "Error: Branch parameter is empty. Please provide a valid branch name."@@@ -8,18 -10,26 +11,26 @@@fiBRANCH="$1"- # clone project repo branch- git clone -b "$BRANCH" "https://github.com/frdel/agent-zero" "/git/agent-zero"+ git clone -b "$BRANCH" "https://github.com/frdel/agent-zero" "/git/agent-zero" || {+ echo "CRITICAL ERROR: Failed to clone repository. Branch: $BRANCH"+ exit 1+ }- # setup python environment. "/ins/setup_venv.sh" "$@"-# Ensure the virtual environment and pip setup-pip install --upgrade pip ipython requests--# Install some packages in specific variants-pip install torch --index-url https://download.pytorch.org/whl/cpu+# moved to base image+# # Ensure the virtual environment and pip setup+# pip install --upgrade pip ipython requests+# # Install some packages in specific variants+# pip install torch --index-url https://download.pytorch.org/whl/cpu+ pip install -v mcp==1.3.0 || {+ echo "ERROR: Failed during separate attempt to install mcp==1.3.0. Will proceed to full requirements.txt install anyway."+ }+ python -c "import mcp; from mcp import ClientSession; print(f'DEBUG: mcp and mcp.ClientSession imported successfully after separate install. mcp path: {mcp.__file__}')" || {+ echo "ERROR: mcp package or mcp.ClientSession NOT importable after separate mcp==1.3.0 installation attempt. Full requirements.txt will run next."+ }+# Install remaining A0 python packagespip install -r /git/agent-zero/requirements.txtdiff --cc requirements.txtindex 06b24bff9,a906b43bf..91ee3b7d9--- a/requirements.txt+++ b/requirements.txt@@@ -1,9 -1,9 +1,11 @@@++a2wsgi==1.10.8ansio==0.0.1beautifulsoup4==4.12.3browser-use==0.1.40docker==7.1.0duckduckgo-search==6.1.12faiss-cpu==1.8.0.post1++fastmcp==2.3.4flask[async]==3.0.3flask-basicauth==0.2.0flaredantic==0.1.4@@@ -20,6 -20,6 +22,7 @@@ langchain-openai==0.3.openai-whisper==20240930lxml_html_clean==0.3.1markdown==3.7++mcp==1.9.0newspaper3k==0.2.8paramiko==3.5.0playwright==1.52.0@@@ -31,7 -31,6 +34,5 @@@ tiktoken==0.8.unstructured==0.15.13unstructured-client==0.25.9webcolors==24.6.0-mcp==1.3.0+ nest-asyncio==1.6.0-crontab==1.0.1+crontab==1.0.1- fastmcp==2.3.4- mcp==1.9.0- a2wsgi==1.10.8