VaahAI
VaahAI is a multi-agent AI CLI tool built with Microsoft's Autogen Framework, designed to enhance code quality and development workflows through AI-powered code review, auditing, generation, and scaffolding capabilities.
🌟 Features
- Multi-Agent Architecture: Specialized AI agents collaborate to perform complex tasks
- Code Review: Comprehensive code review focusing on quality, style, security, and performance
- Interactive Code Improvements: Apply suggested code changes with interactive UI and safety features
- Multiple Output Formats: Rich terminal output, markdown reports, HTML reports, and interactive mode
- Code Audit: Security vulnerability detection, compliance checking, and architectural assessment
- Code Generation: AI-powered code generation from natural language descriptions
- Multiple LLM Support: OpenAI, Claude, Junie, and local models via Ollama
- Intelligent Model Selection: Filter and recommend models based on capabilities (text, code, vision, etc.)
- Flexible Configuration: Layered configuration system with global defaults and project-specific settings
- Git Integration: Commit applied changes, generate meaningful commit messages, and prepare pull requests
🚀 Getting Started
Prerequisites
- Python 3.10+
- Poetry (Python package manager)
- Git
- Docker (optional, for code execution)
Installation
# Install from PyPI
pip3 install vaahai
# Or clone the repository
git clone https://github.com/webreinvent/vaahai.git
cd vaahai
# Create a virtual environment in any of your favorite environment managers:
conda create -n vaahai310 python=3.10
conda activate vaahai310
# Install dependencies with Poetry
poetry install
Quick Start
# Initialize configuration
vaahai config init
# Show current configuration
vaahai config show
# List available models
vaahai model list
# Run a simple test to verify installation
vaahai helloworld run
Development Setup
# Install development dependencies
poetry install --with dev
# Install pre-commit hooks
pre-commit install
# Run tests
poetry run pytest
# Run tests with coverage
poetry run pytest --cov=vaahai
# Format code
poetry run black vaahai
poetry run isort vaahai
# Lint code
poetry run flake8 vaahai
poetry run mypy vaahai
# Run all pre-commit hooks manually
pre-commit run --all-files
For more details on development tools, see Development Tools Documentation.
Configuration
# Run the configuration wizard
poetry run vaahai config init
# Or manually edit the configuration file
nano ~/.vaahai/config.toml
🛠️ Usage
CLI Command Structure
VaahAI provides a modular CLI organized into logical command groups. The command structure follows this hierarchy:
vaahai [command_group] [command] [action] [options]
Where:
vaahaiis the main CLI applicationcommand_groupis one of the logical groups (core, project, dev)commandis a specific command within that groupactionis a subcommand or action for that commandoptionsare additional flags and parameters
Enhanced Help System
VaahAI features a Rich-formatted custom help system that provides visually appealing and well-organized help information:
- Styled headers and descriptions with visual separation
- Organized tables for commands, options, and environment variables
- Consistent formatting across all commands and subcommands
- Detailed descriptions and usage examples
- Color-coded elements for improved readability
To access the enhanced help for any command:
# Main CLI help
vaahai --help
# Command group help
vaahai [command_group] --help
# Specific command help
vaahai [command_group] [command] --help
# Command action help
vaahai [command_group] [command] [action] --help
Global Options
--version,-v: Display the current version of VaahAI and exit--verbose,-V: Enable verbose output with detailed logs and information--quiet,-q: Suppress non-essential output--config: Specify an alternative configuration file path--help,-h: Show help message and exit
Core Commands
vaahai config: Configuration managementvaahai config init: Set up initial configurationvaahai config show: Display current configuration
vaahai version: Display version information
Project Commands
vaahai review: Code review commandsvaahai review [PATH]: Run a code review on specified pathvaahai review --format [rich|markdown|html|interactive]: Select output formatvaahai review --apply-changes: Enable code change acceptance in interactive modevaahai review --category [security|performance|style|quality]: Filter by categoryvaahai review --severity [critical|high|medium|low]: Filter by severityvaahai review --dry-run: Preview changes without modifying filesvaahai review --backup-dir [PATH]: Specify directory for file backups
vaahai audit: Security and compliance audit commandsvaahai audit run: Run a security/compliance audit on specified path
Development Commands
vaahai dev helloworld: Test command to verify proper functioningvaahai dev helloworld run: Execute the hello world testvaahai dev helloworld --help: Show help for the hello world command- Shows detailed debug information including provider, prompt template, and rendered prompt
vaahai helloworld: Simplified version of the hello world command- Features location-based personalization with culturally relevant greetings
- Detects user's location/timezone automatically
- Use
--devflag to see detailed information
vaahai dev showcase: Demonstrate Rich formatting capabilitiesvaahai dev prompts: Demonstrate InquirerPy prompt capabilities
All commands support the --help flag for detailed usage information. For backward compatibility, direct command access (e.g., vaahai helloworld instead of vaahai dev helloworld) is also supported.
Interactive Prompts
VaahAI CLI uses InquirerPy to provide interactive command-line prompts with rich styling. The prompt utilities include:
- Text input with validation
- Password input with masking
- Confirmation prompts (yes/no)
- Selection from a list of options
- Multi-selection from a list of options
- Fuzzy search selection
- Number input with range validation
- Path selection with auto-completion
All prompts support non-interactive mode with default values or appropriate error handling.
Basic Commands
# Show help information
vaahai --help
# Show help for a specific command group
vaahai dev --help
# Show help for a specific command
vaahai dev helloworld --help
# Test installation and configuration
vaahai dev helloworld run
# Or using backward compatibility
vaahai helloworld run
# Review code in a file or directory
vaahai review ./my_project --category security --severity high
# Or with interactive code change acceptance
vaahai review ./my_project --format interactive --apply-changes
# Audit a project for security and compliance
vaahai audit run --path ./my_project --security --compliance owasp
# Show version information
vaahai version
# Apply suggested changes
vaahai apply --file review_suggestions.json
# Commit the changes
vaahai commit --message "Fix code quality issues in app.py"
Example Workflow
# Initialize configuration
vaahai config init
# Review a Python file with interactive code changes
vaahai review ./app.py --format interactive --apply-changes
# Or generate an HTML report
vaahai review ./app.py --format html
# Apply suggested changes
vaahai apply --file review_suggestions.json
# Commit the changes
vaahai commit --message "Fix code quality issues in app.py"
Terminal Output
VaahAI CLI uses Rich for consistent, styled terminal output. Output behavior can be controlled with:
- Verbose mode: Set
--verboseflag orVAAHAI_VERBOSE=1environment variable - Quiet mode: Set
--quietflag orVAAHAI_QUIET=1environment variable
For more details on the Rich integration, see the Rich Integration Documentation.
🧪 Testing
VaahAI includes a comprehensive test suite organized into unit tests and integration tests:
vaahai/test/
├── unit/ # Tests for individual components
│ ├── test_cli_utils.py # Tests for console output utilities
│ ├── test_help_utils.py # Tests for help formatting utilities
│ └── test_version.py # Tests for version command
└── integration/ # Tests for component interactions
└── test_config_integration.py # Tests for config command
Run the test suite:
# Run all tests
poetry run pytest
# Run tests with coverage report
poetry run pytest --cov=vaahai
# Run specific test file
poetry run pytest vaahai/test/unit/test_cli_utils.py
# Run tests matching a pattern
poetry run pytest -k "config"
For more details on testing, see Testing Guide and Test Implementation.
🏗️ Project Structure
vaahai/
├── ai_docs/ # AI-specific documentation
├── ai_prompts/ # Prompt templates for AI agents
├── docs/ # User and developer documentation
│ └── cli/ # CLI-specific documentation
├── specs/ # Project specifications and requirements
├── vaahai/ # Main package
│ ├── agents/ # Agent implementations
│ ├── cli/ # CLI commands and handlers
│ │ ├── commands/ # Command implementations
│ │ │ ├── core/ # Core command group
│ │ │ │ ├── config/ # Configuration commands
│ │ │ │ └── version/ # Version commands
│ │ │ ├── project/ # Project command group
│ │ │ │ ├── audit/ # Audit commands
│ │ │ │ └── review/ # Code review commands
│ │ │ ├── dev/ # Development command group
│ │ │ │ ├── helloworld/ # Hello world test command
│ │ │ │ └── showcase/ # Rich formatting showcase
│ │ │ └── helloworld/ # Legacy direct command (for backward compatibility)
│ │ ├── main.py # CLI entry point
│ │ └── utils/ # CLI utilities
│ │ ├── console.py # Rich formatting utilities
│ │ └── help.py # Custom help formatting
│ ├── config/ # Configuration management
│ ├── llm/ # LLM provider integrations
│ └── utils/ # Utility functions and helpers
└── tests/ # Test suite
└── cli/ # CLI tests
📝 Documentation
For more detailed documentation, please refer to:
- Project Plan
- Features Specification
- Technical Architecture
- User Guide
- API Reference
- CLI Documentation
- Review System Documentation
🤝 Contributing
We welcome contributions from the community! Please see our Contributing Guidelines for more details on how to get involved.
📄 License
This project is licensed under the MIT License - see the LICENSE file for details.
🙏 Acknowledgements
- Microsoft Autogen Framework
- Typer
- InquirerPy
- All our contributors and supporters
Metadata
Release files for vaahai 0.2.24
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| vaahai-0.2.24.tar.gz | 127.8 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| vaahai-0.2.24-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 300.5 kB
Release files / vaahai-0.2.24.tar.gz
| Download URL | vaahai-0.2.24.tar.gz |
|---|---|
| Size | 127.8 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
a313d039a61a6503b4a1bfbd7f65a45f861087a09afad6cba797d74feb2e5eba
|
|
BLAKE2b-256 checksum How to use checksums |
1ccc7fea702bf0eb75df4ac1f2be175fa1a69e972b436d6bb7271a9237ed3a1a
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
poetry/2.1.3 CPython/3.13.3 Darwin/24.5.0
|
Release files / vaahai-0.2.24-py3-none-any.whl
| Download URL | vaahai-0.2.24-py3-none-any.whl |
|---|---|
| Size | 172.8 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
3a632e59db36d92f00647e37d8d2aa397e6d70510389bc2d5aa24a5a3704c62a
|
|
BLAKE2b-256 checksum How to use checksums |
78bd5b6732447a6f38678e40345b5ef0a313d2997418fa2b3bac0ae69b5d29a7
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
poetry/2.1.3 CPython/3.13.3 Darwin/24.5.0
|