- The paper introduces a hierarchical five-agent system that combines LLM reasoning with deterministic tools to assess code correctness, style, security, and maintainability.
- It employs parallel execution with asynchronous methods and retry logic, supporting diverse input modalities including files, directories, and GitHub repos.
- Evaluation shows high description accuracy and actionable recommendations for small to medium projects, while noting limitations in handling large repositories and security analysis.
Code Broker: A Multi-Agent System for Automated Code Quality Assessment
Architectural Overview
Code Broker introduces a hierarchical, five-agent multi-agent system for automated code quality assessment, implemented via Googleโs Agent Development Kit (ADK). The architecture integrates both LLM-based agents and deterministic static analysis tools to generate comprehensive code quality reports. The orchestrator initiates a sequential pipeline, which fans out to three parallel specialist assessorsโCorrectness, Style, and Descriptionโculminating in a consolidated report generated by an Improvement Recommender. Each agent operates with a narrowly defined responsibility and explicit interface, promoting modularity and extensibility.

Figure 1: Hierarchical five-agent architecture of Code Broker. The orchestrator coordinates a sequential pipeline, which fans-out to three parallel assessors before the Improvement Recommender synthesises a final report.
Methodology
The system supports multiple input modalities: standalone files, directory trees, and GitHub repositories. Repository access leverages PyGithub for file enumeration under API rate constraints, and large files are chunked to fit within the modelโs context window, although this reduces long-range reasoning accuracy.
The Correctness Assessor combines Gemini LLM reasoning with findings from a wrapped Pylint ADK tool, supplying evidence-grounded output. The Style Assessor enforces PEP 8 and project convention adherence. The Description Generator frames the codebaseโs purpose and architecture, anchoring subsequent assessments. Parallel execution with asyncio is employed for assessor agents, with retry logic (max three attempts) for robustness against transient faults.
Scoring spans four axesโcorrectness, security, style, and maintainabilityโeach rated 0โ10, referencing both static and semantic evidence. Reports are rendered in both Markdown and HTML with structured, rationale-backed recommendations.
Session memory, implemented via ADKโs InMemoryMemoryService, allows retrieval of prior assessments, facilitating limited conversational history and context carryover, albeit without persistent storage.
Evaluation Results
A qualitative system study evaluated Code Broker across three classes: toy scripts (~50โ200 LOC), medium-sized multi-module utilities (~500โ2000 LOC), and public GitHub repositories. Human assessment focused on the accuracy and specificity of descriptions, evidence-based correctness analysis, relevance of style feedback, actionability of recommendations, and general report readability.
- Description Accuracy: Consistently high for small to medium projects; moderate for large repositories due to context fragmentation.
- Correctness Analysis: High for smaller projects; medium for larger ones with coverage gaps resulting from chunking.
- Style Feedback: Remains highly relevant across cases.
- Actionable Recommendations: Concrete and prioritizable, although sometimes lacking architectural depth for complex, multi-file inputs.
Notably, security assessment is heuristic due to the absence of a dedicated scanner, and multi-file aggregation can reduce architectural coherence.
Limitations
Key limitations include:
- Reliance on Geminiโs context window, leading to chunking and possible cross-file reasoning deficits for large repositories.
- Ephemeral session memory; no durable historical tracking or repository-level index.
- Python-centric tooling (Pylint); extension to other languages requires non-trivial integration.
- Security scoring remains limited to heuristicsโBandit or analogous tools are not yet incorporated.
- Static analysis focus: dynamic issues (e.g., concurrency, runtime exceptions) cannot be detected.
- Like any LLM-dependent system, output is potentially vulnerable to hallucinations, especially in the absence of tool grounding.
- Evaluation is qualitative and author-assessed; no blinded or statistically rigorous benchmarks.
Implications and Future Directions
The modular multi-agent formulation illustrated by Code Broker demonstrates the viability of integrating deterministic tools with LLM reasoning in a production-aligned workflow. Its parallel assessment strategy improves responsiveness and independence of analysis, while hierarchical orchestration supports extensibility (e.g., additional assessors for security, performance, etc.).
Advancements could include:
- Expansion to additional languages via language-specific static analyzers.
- Persistent repository-level memory for aggregation of code quality histories.
- Integration of normative checkers and specialized security agents, addressing the current security grounding gap.
- Formal, large-scale quantitative benchmarking including labeled datasets and blinded human evaluation.
- Incremental analysis for pull requests and CI/CD integration.
- Deployment as a fully-packaged Python CLI tool with artifact pinning, versioning, and module test coverage.
- Commercialization possibilities with value-added SaaS tiers offering enhanced analysis, reporting, or team dashboarding.
The theoretical implications suggest the effectiveness of fine-grained agent decomposition for complex, context-sensitive software engineering tasks, affirming design patterns discussed in recent multi-agent system literature (Benkovich et al., 1 Feb 2026, Cai et al., 11 Nov 2025).
Conclusion
Code Brokerโs multi-agent, LLM-grounded architecture offers a practical, extensible approach to automated code quality assessment for Python codebases. While effective for structured, actionable developer feedback, current limitationsโespecially regarding security, persistent memory, language generality, and large project analysisโdelineate clear directions for future research and deployment. The system forms a concrete foundation for integrating agentic toolchains in software engineering pipelines, providing a basis for further exploration of robustness, reliability, and scalability dimensions in agent-based code analysis systems.