$ show umacloud/umadev
UmaDev is an AI-powered development agent that orchestrates multiple first-class AI coding CLIs (Claude Code, Codex, Grok Build, Kimi Code, OpenCode) as subprocesses, providing a unified terminal UI, governance, knowledge retrieval, and a spec-driven pipeline. It acts as a 'project manager' for AI coding agents, handling planning, execution, review, and acceptance. The architecture is a multi-crate Rust workspace with a TUI (ratatui), agent orchestration, governance engine, knowledge retrieval (BM25 + optional local embeddings), contract validation, and cross-platform process management. It is distributed via npm with platform-specific binaries. The codebase demonstrates high craftsmanship with pervasive fail-open patterns, bounded resource usage, and extensive testing. Key subsystems include a deterministic governance engine with 113 content checks, a hybrid retrieval system with CJK-aware tokenization, a cross-process run lock with boot-id liveness, and a host-owned Git commit transaction with rollback. While primarily an application, it includes a curated knowledge corpus (~400 markdown files) and an offline embedding model, giving it a hybrid character. The repository is actively maintained with a clear release pipeline and CI/CD. Notable design patterns include: fail-open governance (every check wrapped in catch_unwind), bounded file system operations (RootedDir with no-follow, size limits), circuit breaker for compaction, and source tree fingerprinting for freshness. The codebase is well-structured with clear separation of concerns across 11 crates, though some files are large hotspots (e.g., app.rs, director_loop.rs). Overall, it is a sophisticated, production-quality tool for AI-assisted software development.
The LLM identified 4 files worth highlighting for reuse:
RootedDir: A filesystem safety abstraction that enforces no-follow symlink protection, bounded reads with per-file and aggregate byte limits, atomic writes with PID-qualified temp names, and parent-directory anchoring to prevent path traversal. Reusable in any Rust project needing secure file operations without external dependencies beyond standard library and fs2.
Secret redaction module: Regex-based redaction of secrets (API keys, tokens, passwords) from text and JSON strings, with bounded depth and node limits to prevent DoS. Designed for fail-open operation (never leaks secrets even on malformed input). Reusable in any application that needs to sanitize logs or diagnostics before storage or display.
CJK-aware tokenizer: Pure Rust tokenization that extracts bigrams and trigrams for Chinese/Japanese/Korean text and lowercase ASCII tokens (≥2 chars) for English. Used as the foundation for BM25 retrieval. Reusable in any multilingual search or NLP pipeline that needs lightweight, dependency-free tokenization.
Owner liveness module: Implements a three-valued owner liveness rule (Live/Abandoned/AgeOnly) using boot-id, PID, and age. Provides dependency-free aliveness probes for cross-process locks without requiring external coordination services. Reusable in any system that needs to detect stale locks across process restarts.