Get up and running with AutoCodeAI in 5 minutes!
- Docker (for sandboxed code execution)
- Python 3.11+
- API Key for your chosen LLM provider (OpenAI, DeepSeek, or local Ollama)
# 1. Clone the repository
git clone https://github.com/yourusername/autocodeai.git
cd autocodeai
# 2. Install dependencies
pip install -r requirements.txt
# 3. Configure environment
cp .env.example .env
# Edit .env and add your API key:
# For OpenAI:
# LLM_MODE=openai
# OPENAI_API_KEY=sk-your-key-here
# For DeepSeek:
# LLM_MODE=deepseek
# DEEPSEEK_API_KEY=your-key-here
# 4. Start the server
uvicorn main:app --reload
# 5. Open the web UI
open http://localhost:8000You should see the AutoCodeAI web interface! 🎉
# 1. Clone and configure
git clone https://github.com/yourusername/autocodeai.git
cd autocodeai
cp .env.example .env
# Edit .env with your API keys
# 2. Start everything
docker compose up --build
# 3. Access the UI
open http://localhost:8000This starts:
- AutoCodeAI backend (port 8000)
- ChromaDB vector database (port 8001)
- Web UI
- Open
http://localhost:8000 - Type a task in the text area:
Create a REST API endpoint for user registration with email validation, password hashing, and proper error handling. Include unit tests. - Click "🚀 Run Agents"
- Watch the agents work in real-time!
curl -X POST http://localhost:8000/api/agent/run \
-H "Content-Type: application/json" \
-d '{
"task": "Write a binary search function with comprehensive pytest tests",
"context_files": []
}'import asyncio
from services.orchestrator import Orchestrator
async def main():
orch = Orchestrator()
results = await orch.run(
task="Create a FastAPI endpoint for file upload with size validation",
context_files=[],
callback=lambda msg: print(msg, end="", flush=True)
)
print("\n\n✅ Task complete!")
for result in results:
print(f"- {result['type']}: {result['step']}")
asyncio.run(main())Try these examples to see AutoCodeAI in action:
Create a Python class for managing a TODO list with add, remove, complete,
and list methods. Include full pytest coverage with fixtures.
Build a FastAPI endpoint for user authentication using JWT tokens.
Include login, register, and protected routes. Add unit tests.
Write a function to parse CSV files and convert them to JSON with
error handling for malformed data. Include edge case tests.
File: buggy_sort.py
Task: Fix the sorting algorithm and add comprehensive tests
Create tasks that use git, pip, and shell commands:
{
"task": "Clone the FastAPI repo and create a hello world example",
"context_files": []
}The planner can include tool steps:
{
"steps": [
{
"agent": "tool",
"tool_name": "git_clone",
"tool_params": {
"url": "https://github.com/tiangolo/fastapi",
"dest": "fastapi_lib"
}
},
{
"agent": "coder",
"description": "Create hello world using FastAPI"
}
]
}For tasks with independent subtasks, the planner automatically groups them:
Create three microservices: user service, auth service, and notification service.
Each should have its own API endpoint and tests.
The planner creates parallel groups:
{
"steps": [
{"agent": "coder", "description": "User service", "parallel_group": 1},
{"agent": "coder", "description": "Auth service", "parallel_group": 1},
{"agent": "coder", "description": "Notification service", "parallel_group": 1},
{"agent": "tester", "description": "Integration tests", "parallel_group": 2}
]
}All three services are coded in parallel, then tested together!
# Edit .env
LLM_MODE=deepseek
DEEPSEEK_API_KEY=sk-your-deepseek-key
# Or set environment variables
export LLM_MODE=deepseek
export DEEPSEEK_API_KEY=sk-...# 1. Install and start Ollama
# Download from https://ollama.ai
# 2. Pull a model
ollama pull deepseek-coder
# 3. Configure AutoCodeAI
export LLM_MODE=local
export LOCAL_MODEL=deepseek-coder
export LOCAL_LLM_URL=http://localhost:11434/v1
# 4. Run!
uvicorn main:app --reloadUse different models for different agents:
# .env
LLM_MODE=litellm
PLANNER_MODEL=gpt-4o # Best for planning
CODER_MODEL=deepseek/deepseek-chat # Fast for coding
TESTER_MODEL=groq/llama-3.3-70b-versatile # Free, fast
DEBUGGER_MODEL=anthropic/claude-sonnet-4-5 # Best for debugging
CRITIC_MODEL=anthropic/claude-sonnet-4-5 # Best for reviewLLM_MODE=openai
OPENAI_API_KEY=sk-your-key-hereLLM_MODE=litellm
PLANNER_MODEL=gpt-4o-mini # Cheaper planner
CODER_MODEL=deepseek/deepseek-chat # Very cheap coding
TESTER_MODEL=groq/llama-3.3-70b-versatile # Free!
DEBUGGER_MODEL=deepseek/deepseek-chat
CRITIC_MODEL=gpt-4o-miniLLM_MODE=local
LOCAL_LLM_URL=http://localhost:11434/v1
LOCAL_MODEL=deepseek-coder
ENABLE_PARALLEL_EXECUTION=true- Check your
.envfile exists - Verify the API key variable matches your
LLM_MODE - Restart the server after changing
.env
- Install Docker Desktop
- Ensure Docker daemon is running
- Test:
docker ps
- Try using DeepSeek (
LLM_MODE=deepseek) - it's faster - Enable parallel execution in
.env - Use local models for maximum speed
- Check the server is running:
curl http://localhost:8000/health - Look for errors in the terminal
- Try clearing browser cache
- Read the full README.md for architecture details
- Check CHANGELOG.md for all v2.0 features
- Explore the API at
http://localhost:8000/docs - Join the community (link to Discord/GitHub Discussions)
- Contribute - see CONTRIBUTING.md
- Issues: GitHub Issues
- Discussions: GitHub Discussions
- Documentation: Full docs at
/docs
Happy Coding! 🚀 If AutoCodeAI helps you, please star the repo ⭐