Batho v1.4.1 Technical Whitepaper
Bidirectional AST Traversal & Hypergraph Orchestrator
Document Version: 1.4.1
Date: July 2026
Classification: Public — Enterprise Technical Reference
Author: Batho Core Team
Status: Production-Ready
Executive Summary
Batho (Bidirectional AST Traversal & Hypergraph Orchestrator) is a deterministic, production-grade code intelligence engine that transforms raw codebases into queryable, time-aware structured hypergraphs. Version 1.4.1 delivers a unified configuration schema (batho.yaml), a high-performance Arrow IPC Bundle storage format, lossless bidirectional traversal support, a streamlined 8-command CLI interface, and an Arrow-backed columnar graph backend with auto-selection for memory-efficient large-codebase indexing. Batho is designed for polyglot enterprises managing millions of lines of code across hundreds of repositories.
Key Value Propositions
| Metric | Value |
|---|---|
| Supported Languages | 40+ via tree-sitter |
| Context Compression | Up to 10x for LLM injection |
| Incremental Patch Speed | 10–100x faster than full re-index |
| Test Coverage | 864 automated tests |
| Cache Hit Rate | >95% on typical PR-sized changes |
| Snapshot Retention | 90 days default, configurable |
| Max Indexed Files | 200,000 per repository |
System Architecture at a Glance
Figure 1: Batho v1.4.1 System Architecture Overview - High-level data flow from source inputs through the core engine to consumption interfaces.
List of Figures
| Figure | Title | Section |
|---|---|---|
| Figure 1 | Batho v1.4.1 System Architecture Overview | Overview |
| Figure 2 | High-Level System Architecture | Architecture Overview |
| Figure 3 | Data Flow Pipeline | Architecture Overview |
| Figure 4 | Subsystem Interactions | Core Subsystems |
| Figure 5 | Graph Consistency Model | Code Graph Engine |
| Figure 6 | Cross-File Resolution Process | Code Graph Engine |
| Figure 7 | Token Budget Algorithm | BSG Compression |
| Figure 8 | Incremental Patch Lifecycle | Time Machine |
| Figure 9 | Security Architecture Overview | Security & Governance |
| Figure 10 | Zero-Code-Execution Guarantee | Security & Governance |
| Figure 11 | BSG Interceptor Pipeline | Security & Governance |
| Figure 12 | Interceptor Sequence | Security & Governance |
| Figure 13 | Audit Logging Pipeline | Security & Governance |
| Figure 14 | Integrity Chain | Security & Governance |
| Figure 15 | Chain of Custody Flow | Security & Governance |
| Figure 16 | Threat Model | Security & Governance |
| Figure 17 | Cache Strategy | Performance & Scalability |
| Figure 18 | Deployment Architecture | Deployment & Operations |
| Figure 19 | Configuration Loading Flow | Deployment & Operations |
| Figure 20 | CI/CD Pipeline Flow | Deployment & Operations |
| Figure 21 | Command Taxonomy | Deployment & Operations |
| Figure 22 | Monitoring Stack | Deployment & Operations |
| Figure 23 | Backup Flow | Deployment & Operations |
| Figure 24 | Schema Dependency Graph | Appendix |
| Figure 25 | Arrow Bundle Architecture | Storage & Persistence Layer |
| Figure 26 | MVCC Generation Lifecycle | Storage & Persistence Layer |
| Figure 27 | Arrow Store Compaction Pipeline | Storage & Persistence Layer |
| Figure 28 | Unified Cache Architecture | Storage & Persistence Layer |
| Figure 29 | Dependency Indexing Pipeline | Dependency Intelligence |
| Figure 30 | Integrity Check & Repair Pipeline | Integrity & Repair System |
| Figure 31 | Orchestrator → Module Delegation Flow | Infrastructure & Shared Services |
| Figure 32 | Plugin Dependency Graph | BSG Compression |
Table of Contents
- Architecture Overview
- Core Subsystems
- Storage & Persistence Layer
- Deterministic Code Graph Engine
- BSG Compression & LLM Injection
- Dependency Intelligence
- Time Machine & Incremental Patching
- Integrity & Repair System
- Security & Governance
- Performance & Scalability
- Infrastructure & Shared Services
- Deployment & Operations
- Appendix: Schema Reference
Document Control
| Version | Date | Author | Changes |
|---|---|---|---|
| 1.4.1 | 2026-08-26 | Batho Core Team | Review hardening, thread safety, path sanitization, atomic writes, and documentation updates |
| 1.4.0 | 2026-08-04 | Batho Core Team | Stdlib expansion to 27 languages, graph builder phases 4-5, BSG interceptors, and security/performance hardening |
| 1.3.2 | 2026-07-27 | Batho Core Team | H2 path traversal hardening, H5 Unicode identifier extraction support |
| 1.3.1 | 2026-07-22 | Batho Core Team | Entity ID UX gap fix, CLI root resolution bug fix, test isolation |
| 1.3.0 | 2026-07-22 | Batho Core Team | Arrow graph backend with auto-selection, build metrics accuracy, memory optimization, documentation cleanup |
| 1.2.1 | 2026-07-20 | Batho Core Team | Bug fixes (patch.py NameError, registry race, atomic cache writes), MCP tool improvements, docs version alignment |
| 1.2.0 | 2026-07-05 | Batho Core Team | Added MCP Server, multi-repo registry, community detection, prompts/resources, SKILL.md |
| 1.1.1 | 2026-06-29 | Batho Core Team | Added Storage, Dependency, Integrity, and Infrastructure sections; added BSG plugin catalog; renumbered sections |
| 1.1.0 | 2026-06-10 | Batho Core Team | Refactored to v1.1.0 (unified batho.yaml, 7 CLI commands, Arrow IPC format, removed legacy subsystems) |
| 1.0.0 | 2026-05-17 | Batho Core Team | Initial whitepaper for Batho v1 |
For the latest documentation, visit:
- CLI Reference:
batho --help