| # Full reference trajectory configuration - SQLAssistant-A2A project | |
| # | |
| # This configuration is ported from the SQLAssistant-MCP version with the core kept consistent: | |
| # - It evaluates the same Agent / LLM / Tool structure | |
| # - It uses the same 6 trajectory metrics + path diversity metrics | |
| # Only the trajectory hierarchy is adapted to the actual A2A execution path: | |
| # - Top-level SPAN: sql_assistant_workflow_a2a | |
| # - Second-level SPAN: a2a_execution | |
| # - Then three stage SPANs: generate_sql → check_compliance → interpret_results | |
| # - Intermediate framework SPANs such as a2a_call_xxx / xxx_server_execution are also required steps in the reference trajectory | |
| # Project name (determines where to collect traces from RESULTS/<model>/<project_name>/test_results) | |
| project_name: "SQLAssistant-A2A" | |
| # Trajectory extraction types: same as the MCP version; extracts a multi-layer structure | |
| extract_types: | |
| - "SPAN" # Multi-level SPAN structure (including *_a2a, a2a_execution, generate_sql, etc.) | |
| - "Chain" # Kickoff chain for each Crew | |
| - "Agent" # Agent for each Crew | |
| - "LLM" # LLM calls | |
| - "Tool" # Tool calls | |
| # The A2A version also has no chapter-style repeatable patterns | |
| repeatable_patterns: [] | |
| # ========================================================================== | |
| # Reference trajectory (Ground Truth) - A2A architecture, based on code design + trace examples | |
| # ========================================================================== | |
| # | |
| # Ideal execution path hierarchy (no retries, no errors): | |
| # | |
| # [SPAN] sql_assistant_workflow_a2a | |
| # └─ [SPAN] a2a_execution | |
| # ├─ [SPAN] generate_sql | |
| # │ └─ [SPAN] a2a_call_sql_generation | |
| # │ └─ [SPAN] sql_generation_server_execution | |
| # │ └─ [Chain] Crew***.kickoff | |
| # │ ├─ [AGENT] Expert SQL Query Generator | |
| # │ │ ├─ [LLM] * | |
| # │ │ ├─ [Tool] get_database_schema | |
| # │ │ └─ [LLM] * | |
| # │ └─ [AGENT] Senior SQL Code Reviewer | |
| # │ ├─ [LLM] * | |
| # │ ├─ [Tool] validate_sql_syntax | |
| # │ ├─ [LLM] * | |
| # │ ├─ [Tool] get_database_schema | |
| # │ └─ [LLM] * | |
| # ├─ [SPAN] check_compliance | |
| # │ └─ [SPAN] a2a_call_compliance_checker | |
| # │ └─ [SPAN] compliance_checker_server_execution | |
| # │ └─ [Chain] Crew***.kickoff | |
| # │ └─ [AGENT] Data Security and Compliance Auditor | |
| # │ ├─ [LLM] * | |
| # │ ├─ [Tool] get_database_schema | |
| # │ └─ [LLM] * | |
| # └─ [SPAN] interpret_results | |
| # └─ [SPAN] a2a_call_result_interpreter | |
| # └─ [SPAN] result_interpreter_server_execution | |
| # └─ [Chain] Crew***.kickoff | |
| # └─ [AGENT] Business Intelligence Analyst | |
| # ├─ [LLM] * | |
| # ├─ [Tool] run_sql_query | |
| # └─ [LLM] * | |
| # | |
| # Notes: | |
| # - In real A2A traces, framework-level SPANs such as [SPAN] a2a_call_sql_generation and | |
| # [SPAN] sql_generation_server_execution are inserted between stages; | |
| # these intermediate SPANs are now required matching steps. | |
| # - Business retries (business_retry N) and orchestrator-level retries (retry N) are not written into the reference trajectory; | |
| # during evaluation, extra steps and retries are allowed by the in_order / any_order metrics. | |
| reference_trajectory: | |
| # ===== Top-level SPAN (A2A top-level workflow) ===== | |
| - "SPAN: sql_assistant_workflow_a2a" | |
| # ===== Second-level SPAN (A2A execution wrapper) ===== | |
| - "SPAN: a2a_execution" | |
| # ===== Stage 1: Generate SQL (SQLGenerationCrew) ===== | |
| - "SPAN: generate_sql" | |
| - "SPAN: a2a_call_sql_generation" | |
| - "SPAN: sql_generation_server_execution" | |
| - "Chain: Crew***.kickoff" | |
| # Agent 1: SQL Generator (uses key schema exploration tools) | |
| - "Agent: Expert SQL Query Generator" | |
| - "LLM: *" # Decide overall generation strategy | |
| - "Tool: get_database_schema" # Read full schema | |
| - "LLM: *" # Generate candidate SQL based on schema | |
| # Other exploration tools (list_tables / get_table_sample / get_column_stats) are considered optional | |
| # Agent 2: SQL Reviewer (syntax and structure checks) | |
| - "Agent: Senior SQL Code Reviewer" | |
| - "LLM: *" # Read and understand the generated SQL | |
| - "Tool: validate_sql_syntax" # Required: syntax validation | |
| - "LLM: *" # Analyze syntax validation results | |
| - "Tool: get_database_schema" # Required: verify tables/columns exist based on schema | |
| - "LLM: *" # Revise SQL based on schema checks | |
| # ===== Stage 2: Check Compliance (ComplianceCheckerCrew) ===== | |
| - "SPAN: check_compliance" | |
| - "SPAN: a2a_call_compliance_checker" | |
| - "SPAN: compliance_checker_server_execution" | |
| - "Chain: Crew***.kickoff" | |
| - "Agent: Data Security and Compliance Auditor" | |
| - "LLM: *" # Initial read of SQL and identify potential risks | |
| - "Tool: get_database_schema" # Required: assess sensitivity with schema context | |
| - "LLM: *" # Provide PASS/FAIL decision | |
| # ===== Stage 3: Interpret Results (ResultInterpreterCrew) ===== | |
| # Note: only entered when compliance passes | |
| - "SPAN: interpret_results" | |
| - "SPAN: a2a_call_result_interpreter" | |
| - "SPAN: result_interpreter_server_execution" | |
| - "Chain: Crew***.kickoff" | |
| - "Agent: Business Intelligence Analyst" | |
| - "LLM: *" # Understand the business question and SQL | |
| - "Tool: run_sql_query" # Required: execute SQL to get real data | |
| - "LLM: *" # Produce business interpretation based on results (count_rows is an optional stats tool) | |
| # Target tool list (used by the single_tool_use metric) | |
| # Consistent with the MCP version; covers all core tools (including some optional tools) | |
| target_tools: | |
| # SQL Generation stage - Generator | |
| - "Tool: get_database_schema" | |
| - "Tool: get_table_sample" | |
| - "Tool: get_column_stats" | |
| - "Tool: list_tables" | |
| # SQL Generation stage - Reviewer | |
| - "Tool: validate_sql_syntax" | |
| - "Tool: check_table_exists" | |
| # Compliance stage (shares get_database_schema / check_table_exists; do not duplicate) | |
| # Result Interpretation stage | |
| - "Tool: run_sql_query" | |
| - "Tool: count_rows" | |
| # Models to evaluate (same as the MCP version; only the path changes to SQLAssistant-A2A) | |
| models: | |
| - "GPT-5" | |
| - "GPT-4o-mini" | |
| - "DeepSeek-V3-1" | |
| - "DeepSeek-R1" | |
| - "Gemini-2.5-flash" | |
| - "Gemini-2.5-flash-nothinking" | |
| - "Qwen3-235b" | |
| # Usage (brief): | |
| # - Run from: RQ-Failure_Breakdown/SQLAssistant-A2A | |
| # python3 evaluate_trajectory-Filter_Tools.py --config reference_trajectory.yaml | |
| # - evaluate_trajectory-Filter_Tools.py will automatically read execution_path.md from | |
| # RESULTS/<model>/SQLAssistant-A2A/test_results based on project_name. | |