Private
Public Access
docs(conductor): update provider count (8 not 5), file sizes, mcp_tool_specs split
product.md and tech-stack.md claimed 5 providers (missing qwen, grok, llama), wrong file sizes (gui_2 260KB vs 437KB, ai_client 116KB vs 166KB, mcp_client 81KB vs 92KB, app_controller 166KB vs 240KB), and described models.py as 132KB centralized registry. Updated to 8 providers, current sizes, and the mcp_tool_specs.py extraction. Centralized Registry Management -> Per-System Registry Management reflects the post-refactor reality (PROVIDERS in ai_client.py, tool registry in mcp_tool_specs.py, models.py is a shim).
This commit is contained in:
@@ -16,13 +16,13 @@ For deep implementation details when planning or implementing tracks, consult `d
|
||||
- **[docs/guide_simulations.md](../docs/guide_simulations.md):** Test framework, mock provider, Puppeteer pattern, test areas by subsystem
|
||||
|
||||
**Per-source-file references (NEW):**
|
||||
- **[docs/guide_gui_2.md](../docs/guide_gui_2.md):** `src/gui_2.py` (260KB): App class lifecycle, ~90 module-level render functions, Multi-Viewport docks, panel registry, ImGuiScope context managers, hot reload support
|
||||
- **[docs/guide_ai_client.md](../docs/guide_ai_client.md):** `src/ai_client.py` (116KB): multi-provider LLM singleton (5 providers), async dispatch via `asyncio.gather`, threading.local source tier tagging, Anthropic ephemeral + Gemini explicit caching, Tier 4 QA error interception
|
||||
- **[docs/guide_api_hooks.md](../docs/guide_api_hooks.md):** `src/api_hooks.py` + `src/api_hook_client.py` (38KB + 31KB): HookServer on `127.0.0.1:8999`, ApiHookClient wrapper, 8+ endpoints, Remote Confirmation Protocol via `/api/ask`
|
||||
- **[docs/guide_mcp_client.md](../docs/guide_mcp_client.md):** `src/mcp_client.py` (81KB, 45 tools): 3-layer security (Allowlist → Validate → Resolve), all native tools (File I/O, Python AST, C/C++ AST, Analysis, Network, Runtime, Beads), ExternalMCPManager (Stdio + SSE), JSON-RPC 2.0 engine
|
||||
- **[docs/guide_app_controller.md](../docs/guide_app_controller.md):** `src/app_controller.py` (166KB): headless orchestrator, AppState dataclass, all subsystem managers, `_predefined_callbacks`/`_gettable_fields` Hook API registries, SyncEventQueue, headless mode
|
||||
- **[docs/guide_multi_agent_conductor.md](../docs/guide_multi_agent_conductor.md):** `src/multi_agent_conductor.py` + `src/dag_engine.py` (28KB + 10KB): TrackDAG (iterative DFS cycle detection, Kahn's topological sort), ExecutionEngine (Auto-Queue / Step Mode), MultiAgentConductor + WorkerPool (concurrency 4), per-ticket Python subprocess spawning via `subprocess.Popen` (the WorkerPool's internal subprocess template, NOT the meta-tooling `mma_exec.py` — that's only used by external AI agents in the meta-tooling domain; see `docs/guide_meta_boundary.md`)
|
||||
- **[docs/guide_models.md](../docs/guide_models.md):** `src/models.py` (132KB): centralized data model registry, `AGENT_TOOL_NAMES` canonical 45-tool list, `PROVIDERS` constant, `parse_plan_md` utility, validation patterns, SDM tags
|
||||
- **[docs/guide_gui_2.md](../docs/guide_gui_2.md):** `src/gui_2.py` (~437KB): App class lifecycle, ~90 module-level render functions, Multi-Viewport docks, panel registry, ImGuiScope context managers, hot reload support
|
||||
- **[docs/guide_ai_client.md](../docs/guide_ai_client.md):** `src/ai_client.py` (~166KB): multi-provider LLM singleton (8 providers: gemini, anthropic, gemini_cli, deepseek, minimax, qwen, grok, llama), async dispatch via `asyncio.gather`, threading.local source tier tagging, Anthropic ephemeral + Gemini explicit caching, Tier 4 QA error interception, inlined `VendorCapabilities` registry (moved from the deleted `src/vendor_capabilities.py`)
|
||||
- **[docs/guide_api_hooks.md](../docs/guide_api_hooks.md):** `src/api_hooks.py` + `src/api_hook_client.py` (~51KB + ~38KB): HookServer on `127.0.0.1:8999`, ApiHookClient wrapper, 8+ endpoints, Remote Confirmation Protocol via `/api/ask`
|
||||
- **[docs/guide_mcp_client.md](../docs/guide_mcp_client.md):** `src/mcp_client.py` (~92KB, 45 tools): 3-layer security (Allowlist → Validate → Resolve), all native tools (File I/O, Python AST, C/C++ AST, Analysis, Network, Runtime, Beads), ExternalMCPManager (Stdio + SSE), JSON-RPC 2.0 engine. Tool specs now live in `src/mcp_tool_specs.py` (typed `ToolSpec` dataclass + `_REGISTRY`); `mcp_client.py` re-exports `TOOL_NAMES` for backward compat.
|
||||
- **[docs/guide_app_controller.md](../docs/guide_app_controller.md):** `src/app_controller.py` (~240KB): headless orchestrator, AppState dataclass, all subsystem managers, `_predefined_callbacks`/`_gettable_fields` Hook API registries, SyncEventQueue, headless mode
|
||||
- **[docs/guide_multi_agent_conductor.md](../docs/guide_multi_agent_conductor.md):** `src/multi_agent_conductor.py` + `src/dag_engine.py` (~30KB + ~11KB): TrackDAG (iterative DFS cycle detection, Kahn's topological sort), ExecutionEngine (Auto-Queue / Step Mode), MultiAgentConductor + WorkerPool (concurrency 4), per-ticket Python subprocess spawning via `subprocess.Popen` (the WorkerPool's internal subprocess template, NOT the meta-tooling `mma_exec.py` — that's only used by external AI agents in the meta-tooling domain; see `docs/guide_meta_boundary.md`)
|
||||
- **[docs/guide_models.md](../docs/guide_models.md):** `src/models.py` is now a ~1.5KB legacy re-export shim (`Metadata = TrackMetadata` alias + `PROVIDERS` lazy `__getattr__`). Data models moved to per-system files: `src/mma.py` (TrackMetadata, Ticket, Track, WorkerContext), `src/project_files.py` (FileItem), `src/type_aliases.py` (typed boundary + per-aggregate dataclasses), `src/mcp_tool_specs.py` (typed ToolSpec registry, 45 tools), `src/result_types.py` (Result[T], ErrorInfo). `VendorCapabilities` lives in `src/ai_client.py` `#region: Vendor Capabilities`.
|
||||
|
||||
**Testing (NEW):**
|
||||
- **[docs/guide_testing.md](../docs/guide_testing.md):** 251 test files, 5 categories, 7 conftest fixtures (`isolate_workspace`, `reset_paths`, `reset_ai_client`, `vlogger`, `kill_process_tree`, `mock_app`, `live_gui` session-scoped), Puppeteer pattern, mock provider, structural testing contract
|
||||
@@ -49,7 +49,7 @@ For deep implementation details when planning or implementing tracks, consult `d
|
||||
|
||||
## Key Features
|
||||
|
||||
- **Multi-Provider Integration:** Supports Gemini, Anthropic, DeepSeek, Gemini CLI (headless), and MiniMax with seamless switching.
|
||||
- **Multi-Provider Integration:** Supports Gemini, Anthropic, DeepSeek, Gemini CLI (headless), MiniMax, Qwen, Grok, and Llama (Ollama) with seamless switching.
|
||||
- **4-Tier Hierarchical Multi-Model Architecture:** Orchestrates an intelligent cascade of specialized models to isolate cognitive loads and minimize token burn.
|
||||
- **Tier 1 (Orchestrator):** Strategic product alignment, setup (`/conductor:setup`), and track initialization (`/conductor:newTrack`) using `gemini-3.1-pro-preview`.
|
||||
- **Tier 2 (Tech Lead):** Technical oversight and track execution (`/conductor:implement`) using `gemini-3-flash-preview`. Maintains persistent context throughout implementation.
|
||||
|
||||
@@ -45,7 +45,7 @@
|
||||
- **src/tool_bias.py:** Implements the `ToolBiasEngine` for semantic tool description nudging and dynamic tooling strategy generation.
|
||||
|
||||
- **src/tool_presets.py:** Extends `ToolPresetManager` to handle nested `Tool` models, weights, and global `BiasProfile` persistence within `tool_presets.toml`.
|
||||
- **src/mcp_client.py:** Implements the native tool registry (45 tools) and the `ExternalMCPManager` for orchestrating third-party Model Context Protocol servers. Provides dynamic tool discovery and validation. See [docs/guide_mcp_client.md](../docs/guide_mcp_client.md) for the complete 3-layer security model (Allowlist → Validate → Resolve) and tool inventory.
|
||||
- **src/mcp_client.py:** Implements the native tool dispatch (45 tools) and the `ExternalMCPManager` for orchestrating third-party Model Context Protocol servers. The typed `ToolSpec` registry now lives in `src/mcp_tool_specs.py` (`ToolSpec` dataclass + `_REGISTRY` + `tool_names()`); `mcp_client.py` re-exports `TOOL_NAMES = mcp_tool_specs.tool_names()` for backward compat. See [docs/guide_mcp_client.md](../docs/guide_mcp_client.md) for the complete 3-layer security model (Allowlist → Validate → Resolve) and tool inventory.
|
||||
- **StdioMCPServer:** Manages local MCP servers via asynchronous subprocess pipes (stdin/stdout/stderr).
|
||||
- **RemoteMCPServer (SSE):** Provides a foundation for remote MCP integration via Server-Sent Events.
|
||||
- **JSON-RPC 2.0 Engine:** Handles asynchronous message routing, request/response matching, and error handling for all external MCP communication.
|
||||
@@ -96,7 +96,7 @@
|
||||
|
||||
## Architectural Patterns
|
||||
|
||||
- **Centralized Registry Management:** Consolidation of critical application constants (e.g., `PROVIDERS`, `AGENT_TOOL_NAMES`) into `src/models.py` as a single source of truth, eliminating redundant list definitions across the UI and Controller.
|
||||
- **Per-System Registry Management:** Critical application constants live in the system that owns them: `PROVIDERS` and `DEFAULT_TOOL_CATEGORIES` in `src/ai_client.py`; `VendorCapabilities` + `_VENDOR_REGISTRY` in `src/ai_client.py` `#region: Vendor Capabilities`; the 45-tool registry in `src/mcp_tool_specs.py` (`ToolSpec` dataclass + `_REGISTRY`, re-exported as `mcp_client.TOOL_NAMES`); `TrackMetadata`/`Ticket`/`Track`/`WorkerContext` in `src/mma.py`; `Result[T]`/`ErrorInfo` in `src/result_types.py`. The legacy `src/models.py` is a ~1.5KB re-export shim only.
|
||||
- **Event-Driven Metrics:** Uses a custom `EventEmitter` to decouple API lifecycle events from UI rendering, improving performance and responsiveness.
|
||||
- **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 and manual ticket transitions (Step Mode) via the GUI's REST API hooks.
|
||||
@@ -117,13 +117,13 @@
|
||||
## Per-Source-File Deep Dives
|
||||
|
||||
For the largest source files, consult the dedicated guides in `docs/`:
|
||||
- **[docs/guide_gui_2.md](../docs/guide_gui_2.md)** — `src/gui_2.py` (260KB main GUI)
|
||||
- **[docs/guide_ai_client.md](../docs/guide_ai_client.md)** — `src/ai_client.py` (116KB multi-provider LLM)
|
||||
- **[docs/guide_api_hooks.md](../docs/guide_api_hooks.md)** — `src/api_hooks.py` + `src/api_hook_client.py` (38KB + 31KB Hook API)
|
||||
- **[docs/guide_mcp_client.md](../docs/guide_mcp_client.md)** — `src/mcp_client.py` (81KB, 45 tools)
|
||||
- **[docs/guide_app_controller.md](../docs/guide_app_controller.md)** — `src/app_controller.py` (166KB headless controller)
|
||||
- **[docs/guide_multi_agent_conductor.md](../docs/guide_multi_agent_conductor.md)** — `src/multi_agent_conductor.py` + `src/dag_engine.py` (28KB + 10KB MMA)
|
||||
- **[docs/guide_models.md](../docs/guide_models.md)** — `src/models.py` (132KB data models)
|
||||
- **[docs/guide_gui_2.md](../docs/guide_gui_2.md)** — `src/gui_2.py` (~437KB main GUI)
|
||||
- **[docs/guide_ai_client.md](../docs/guide_ai_client.md)** — `src/ai_client.py` (~166KB multi-provider LLM, 8 providers; inlined `VendorCapabilities` registry)
|
||||
- **[docs/guide_api_hooks.md](../docs/guide_api_hooks.md)** — `src/api_hooks.py` + `src/api_hook_client.py` (~51KB + ~38KB Hook API)
|
||||
- **[docs/guide_mcp_client.md](../docs/guide_mcp_client.md)** — `src/mcp_client.py` (~92KB, 45 tools; tool specs live in `src/mcp_tool_specs.py`)
|
||||
- **[docs/guide_app_controller.md](../docs/guide_app_controller.md)** — `src/app_controller.py` (~240KB headless controller)
|
||||
- **[docs/guide_multi_agent_conductor.md](../docs/guide_multi_agent_conductor.md)** — `src/multi_agent_conductor.py` + `src/dag_engine.py` (~30KB + ~11KB MMA)
|
||||
- **[docs/guide_models.md](../docs/guide_models.md)** — `src/models.py` is now a ~1.5KB legacy re-export shim (`Metadata = TrackMetadata` alias + `PROVIDERS` lazy `__getattr__`). Data models moved to per-system files (`src/mma.py`, `src/project_files.py`, `src/type_aliases.py`, `src/mcp_tool_specs.py`, `src/result_types.py`).
|
||||
- **[docs/guide_testing.md](../docs/guide_testing.md)** — Test suite architecture (251 files, 7 conftest fixtures)
|
||||
|
||||
ter/ImGui) and the business logic (AppController). All platform-native UI actions, such as file and directory selection, are handled exclusively within the GUI layer.
|
||||
|
||||
Reference in New Issue
Block a user