Compare commits

..

1 Commits

Author SHA1 Message Date
copilot-swe-agent[bot] 1e11ff5b40 Initial plan 2025-11-17 17:31:28 +00:00
62 changed files with 4600 additions and 5823 deletions
+200 -252
View File
File diff suppressed because it is too large Load Diff
@@ -18,10 +18,9 @@ This package provides an intelligent assistant for building multi-agent systems
using YAML configurations. It can be used directly as an agent or integrated
with ADK tools and web interfaces.
"""
from __future__ import annotations
from . import agent # Import to make agent.root_agent available
from .adk_agent_builder_assistant import AgentBuilderAssistant
from .agent_builder_assistant import AgentBuilderAssistant
__all__ = [
'AgentBuilderAssistant',
@@ -13,9 +13,8 @@
# limitations under the License.
"""Agent Builder Assistant instance for ADK web testing."""
from __future__ import annotations
from .adk_agent_builder_assistant import AgentBuilderAssistant
from .agent_builder_assistant import AgentBuilderAssistant
# Create the agent instance using the factory
# The root_agent variable is what ADK looks for when loading agents
@@ -13,7 +13,6 @@
# limitations under the License.
"""Agent factory for creating Agent Builder Assistant with embedded schema."""
from __future__ import annotations
from pathlib import Path
import textwrap
@@ -416,8 +415,3 @@ class AgentBuilderAssistant:
with open(template_path, "r", encoding="utf-8") as f:
return f.read()
# Expose a module-level root_agent so the AgentLoader can find this built-in
# assistant when requested as "__adk_agent_builder_assistant".
root_agent = AgentBuilderAssistant.create_agent()
@@ -75,9 +75,6 @@ Always reference this schema when creating configurations to ensure compliance.
- **CRITICAL TIMING**: Ask for model selection IMMEDIATELY after determining LlmAgent is needed, BEFORE presenting any design
- **MANDATORY CONFIRMATION**: Say "Please confirm what model you want to use" - do NOT assume or suggest defaults
- **EXAMPLES**: "gemini-2.5-flash", "gemini-2.5-pro", etc.
- **ALLOWED MODELS ONLY**: Only mention or propose "gemini-2.5-flash" or
"gemini-2.5-pro". Treat any request for gemini-1.5-* or older models as
unsupported and redirect to one of the 2.5 options.
- **RATIONALE**: Only LlmAgent requires model specification; workflow agents do not
- **DEFAULT MODEL**: If user says "use default" or "proceed with default model", use: {default_model}
* This is the actual model name, NOT the literal string "default"
@@ -13,7 +13,6 @@
# limitations under the License.
"""Sub-agents for Agent Builder Assistant."""
from __future__ import annotations
from .google_search_agent import create_google_search_agent
from .url_context_agent import create_url_context_agent
@@ -13,7 +13,6 @@
# limitations under the License.
"""Sub-agent for Google Search functionality."""
from __future__ import annotations
from google.adk.agents import LlmAgent
from google.adk.tools import google_search
@@ -13,7 +13,6 @@
# limitations under the License.
"""Sub-agent for URL context fetching functionality."""
from __future__ import annotations
from google.adk.agents import LlmAgent
from google.adk.tools import url_context
@@ -13,7 +13,6 @@
# limitations under the License.
"""Tools for Agent Builder Assistant."""
from __future__ import annotations
from .cleanup_unused_files import cleanup_unused_files
from .delete_files import delete_files
@@ -13,7 +13,6 @@
# limitations under the License.
"""File deletion tool for Agent Builder Assistant."""
from __future__ import annotations
from datetime import datetime
from pathlib import Path
@@ -13,7 +13,6 @@
# limitations under the License.
"""Project explorer tool for analyzing structure and suggesting file paths."""
from __future__ import annotations
from pathlib import Path
from typing import Any
@@ -13,7 +13,6 @@
# limitations under the License.
"""ADK AgentConfig schema query tool for dynamic schema information access."""
from __future__ import annotations
from typing import Any
from typing import Dict
@@ -13,7 +13,6 @@
# limitations under the License.
"""Configuration file reader tool for existing YAML configs."""
from __future__ import annotations
from pathlib import Path
from typing import Any
@@ -13,7 +13,6 @@
# limitations under the License.
"""File reading tool for Agent Builder Assistant."""
from __future__ import annotations
from pathlib import Path
from typing import Any
@@ -13,7 +13,6 @@
# limitations under the License.
"""ADK knowledge search tool."""
from __future__ import annotations
from typing import Any
import uuid
@@ -13,7 +13,6 @@
# limitations under the License.
"""ADK source code search tool for Agent Builder Assistant."""
from __future__ import annotations
from pathlib import Path
import re
@@ -31,7 +31,6 @@ import jsonschema
import yaml
from ..utils import load_agent_config_schema
from ..utils.path_normalizer import sanitize_generated_file_path
from ..utils.resolve_root_directory import resolve_file_path
from .write_files import write_files
@@ -178,9 +177,8 @@ async def write_config_files(
# Step 1: Validate all configs before writing any files
for file_path, config_content in configs.items():
normalized_input_path = sanitize_generated_file_path(file_path)
file_result = _validate_single_config(
normalized_input_path, config_content, project_folder_name
file_path, config_content, project_folder_name
)
result["files"][file_path] = file_result
@@ -199,7 +197,7 @@ async def write_config_files(
rename_applied,
sanitized_name,
rename_warning,
) = _determine_target_file_path(normalized_input_path, agent_name)
) = _determine_target_file_path(file_path, agent_name)
file_result["target_file_path"] = target_path
file_result["rename_applied"] = rename_applied
@@ -13,7 +13,6 @@
# limitations under the License.
"""File writing tool for Agent Builder Assistant."""
from __future__ import annotations
from datetime import datetime
from pathlib import Path

Some files were not shown because too many files have changed in this diff Show More