Coral is a multi-agent system designed to audit local repositories. It uses a team of specialized AI agents to crawl your codebase, map its architecture, identify potential issues, and generate comprehensive documentation.
- Multi-Agent Architecture:
- The Architect: Maps directory structure and dependency trees.
- The Critic: Identifies code smells, security vulnerabilities, and missing tests.
- The Writer: Synthesizes agent reports into professional documentation.
- Flexible LLM Support: Works with local Ollama instances or any OpenAI-compatible API (OpenAI, Groq, etc.).
- Local First: Audits your local directories without needing to push to a remote server.
- Python 3.8+
- Ollama (for local execution) or an OpenAI API Key.
-
Clone the repository:
git clone https://github.com/yourusername/coral.git cd coral -
Install dependencies:
pip install -r requirements.txt
Coral automatically detects your LLM provider based on environment variables.
Ensure Ollama is running and has the llama3 model pulled:
ollama pull llama3Running Coral without an OPENAI_API_KEY will default to Ollama.
Set your API key and (optionally) the base URL and model:
# Windows (PowerShell)
$env:OPENAI_API_KEY = "your-api-key"
$env:OPENAI_API_BASE = "https://api.openai.com/v1" # Optional
$env:OPENAI_MODEL = "gpt-4" # Optional
# Linux/macOS
export OPENAI_API_KEY="your-api-key"Run the auditor on any local directory:
python main.py /path/to/your/repoBy default, the output is saved to CORAL_README.md. You can specify a custom output path:
python main.py /path/to/repo --output MY_AUDIT.mdContributions are welcome! Please see CONTRIBUTING.md for details.
This project is licensed under the MIT License - see the LICENSE file for details.