From 0a6389239517f713de440f19924bca73eead0b0d Mon Sep 17 00:00:00 2001 From: Ed_ Date: Fri, 6 Mar 2026 13:28:45 -0500 Subject: [PATCH] docs(conductor): Synchronize docs for track 'Asynchronous Tool Execution Engine'. --- conductor/product.md | 2 +- conductor/tech-stack.md | 3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/conductor/product.md b/conductor/product.md index a66e704..77c88a5 100644 --- a/conductor/product.md +++ b/conductor/product.md @@ -42,7 +42,7 @@ For deep implementation details when planning or implementing tracks, consult `d - **Worker Spawn Interceptor:** A mandatory security gate that intercepts every sub-agent launch. Provides a GUI modal allowing the user to review, modify, or reject the worker's prompt and file context before it is sent to the API. - **Strict Memory Siloing:** Employs tree-sitter AST-based interface extraction (Skeleton View, Curated View) and "Context Amnesia" to provide workers only with the absolute minimum context required, preventing hallucination loops. - **Explicit Execution Control:** All AI-generated PowerShell scripts require explicit human confirmation via interactive UI dialogs before execution, supported by a global "Linear Execution Clutch" for deterministic debugging. -- **Asynchronous Event-Driven Architecture:** Uses an `AsyncEventQueue` to link GUI actions to the backend engine, ensuring the interface remains fully responsive during multi-model generation and parallel worker execution. +- **Parallel Tool Execution:** Executes independent tool calls (e.g., parallel file reads) concurrently using an asynchronous execution engine, significantly reducing end-to-end latency for complex AI turns. - **Automated Tier 4 QA:** Integrates real-time error interception in the shell runner, automatically forwarding technical failures to cheap sub-agents for 20-word diagnostic summaries injected back into the worker history. - **Detailed History Management:** Rich discussion history with branching, timestamping, and specific git commit linkage per conversation. - **In-Depth Toolset Access:** MCP-like file exploration, URL fetching, search, and dynamic context aggregation embedded within a multi-viewport Dear PyGui/ImGui interface. diff --git a/conductor/tech-stack.md b/conductor/tech-stack.md index 0e34a2f..ce0d36f 100644 --- a/conductor/tech-stack.md +++ b/conductor/tech-stack.md @@ -42,11 +42,12 @@ - **mma-exec / mma.ps1:** Python-based execution engine and PowerShell wrapper for managing the 4-Tier MMA hierarchy and automated documentation mapping. - **dag_engine.py:** A native Python utility implementing `TrackDAG` and `ExecutionEngine` for dependency resolution, cycle detection, transitive blocking propagation, and programmable task execution loops. - **Thread-Local Context Isolation:** Utilizes `threading.local()` for managing per-thread AI client context (e.g., source tier tagging), ensuring thread safety during concurrent multi-agent execution. +- **Asynchronous Tool Execution Engine:** Refactored MCP tool dispatch and AI client loops to use `asyncio.gather` and `asyncio.to_thread`, enabling parallel execution of independent tool calls within a single AI turn to reduce latency. ## Architectural Patterns - **Event-Driven Metrics:** Uses a custom `EventEmitter` to decouple API lifecycle events from UI rendering, improving performance and responsiveness. -- **Asynchronous Event Bus:** Employs an `AsyncEventQueue` based on `asyncio.Queue` to manage the communication between the UI and the backend multi-agent orchestrator without blocking. +- **Synchronous Event Queue:** Employs a `SyncEventQueue` based on `queue.Queue` to manage communication between the UI and backend agents, maintaining responsiveness through a threaded execution model. - **Synchronous IPC Approval Flow:** A specialized bridge mechanism that allows headless AI providers (like Gemini CLI) to synchronously request and receive human approval for tool calls via the GUI's REST API hooks. - **Interface-Driven Development (IDD):** Enforces a "Stub-and-Resolve" pattern where cross-module dependencies are resolved by generating signatures/contracts before implementation.