LazyCoder is an advanced autonomous AI agent with "God Mode" capabilities designed specifically for Cursor IDE. The system offers intelligent automation of programming tasks with full integration of the OpenAI API, GitHub, and an advanced file processing system.
- 4 control levels: Manual, Semi-Auto, Full-Auto, Dry-Run
- Dynamic switching of autonomy levels in real time
- Emergency Stop - immediate halt of all operations
- Rollback - revert changes in case of errors
- Images: OCR, UI analysis, object detection (OpenAI Vision)
- Documents: PDF, DOCX, TXT, MD - text extraction and content analysis
- Audio: Whisper transcription, audio feature analysis
- Code: Function analysis, complexity, imports, refactoring
- AI-powered insights for development context
- Automatic repository management
- Creating issues, PRs, commits
- Integration with CI/CD workflows
- Project synchronization
- GUI control via Playwright
- Integration with chat system
- Automatic file opening and code editing
- Workspace synchronization
- Python 3.8+
- Cursor IDE
- API keys: OpenAI, GitHub (optional: Anthropic, Google)
# Clone the repository
git clone https://github.com/lazycoder/lazycoder.git
cd lazycoder
# Install dependencies
pip install -r requirements.txt
# Install the package
pip install -e .
# Configure environment variables
cp .env.example .env
# Edit .env and add your API keys
- Copy and edit the configuration file:
cp .env.example .env
- Add your API keys in the
.env
file:
OPENAI_API_KEY=sk-your-openai-api-key-here
GITHUB_TOKEN=ghp_your-github-token-here
CURSOR_WORKSPACE_PATH=/path/to/your/cursor/workspace
- Optionally adjust settings in
config/settings.yaml
# Start with default configuration
lazycoder start
# Start with a specific autonomy level
lazycoder start --autonomy semi_auto
# Start with a custom configuration
lazycoder start --config /path/to/config.yaml
# Analyze a single file
lazycoder process-file document.pdf
# Analysis with context
lazycoder process-file image.png --context "UI mockup for login page"
# Code analysis
lazycoder process-file app.py --context "Main application file"
# Change autonomy level
lazycoder set-autonomy full_auto
# Emergency stop
lazycoder emergency-stop
# System status
lazycoder status
- User confirms every action
- Full control over all operations
- Ideal for learning and testing
- Automatic execution of safe actions
- Confirmation required for risky operations
- Balance between automation and control
- Full autonomy with safety checks
- Automatic execution of all actions
- Maximum productivity
- Simulates actions without execution
- Ideal for testing and debugging
- Safe experimentation
# The agent automatically:
# 1. Detects UI elements in the image
# 2. Extracts text via OCR
# 3. Generates HTML/CSS code based on the mockup
# 4. Creates React/Vue components
# The agent automatically:
# 1. Extracts requirements from PDF
# 2. Creates issues on GitHub
# 3. Generates code based on the specification
# 4. Updates documentation
# The agent automatically:
# 1. Transcribes meeting recordings
# 2. Extracts action items
# 3. Creates project tasks
# 4. Generates summaries
graph TD
A[Agent Orchestrator] --> B[Autonomy Controller]
A --> C[File Processing Agent]
A --> D[GitHub Agent]
A --> E[Cursor Agent]
A --> F[Memory System]
C --> G[OpenAI Vision]
C --> H[Whisper STT]
C --> I[Document Parser]
C --> J[Code Analyzer]
F --> K[ChromaDB]
F --> L[Vector Embeddings]
B --> M[Safety Monitor]
B --> N[Emergency Stop]
autonomy:
levels:
custom_level:
description: "Custom autonomy level"
auto_execute: true
require_confirmation_for: ["git_push", "file_deletion"]
safety_checks: true
file_processing:
analysis:
use_openai_vision: true
use_whisper: true
generate_summaries: true
extract_entities: true
code_complexity_analysis: true
security:
whitelist:
domains: ["github.com", "api.openai.com"]
file_extensions: [".py", ".js", ".md"]
blacklist:
commands: ["rm -rf", "sudo"]
paths: ["/etc", "/usr"]
# Run tests
pytest tests/
# Integration tests
pytest tests/integration/
# Tests with coverage
pytest --cov=src tests/
from lazycoder import AgentOrchestrator
orchestrator = AgentOrchestrator(config)
await orchestrator.initialize()
# Create a task
task_id = orchestrator.create_task(
name="Process file",
agent_type="file_processing",
action="process_file",
parameters={"file_path": "document.pdf"}
)
from lazycoder.agents import FileProcessingAgent
agent = FileProcessingAgent(config)
result = await agent.process_file("image.png", context="UI mockup")
print(f"Insights: {result.content_analysis.insights}")
print(f"Summary: {result.content_analysis.summary}")
- Fork the repository
- Create a branch for your new feature (
git checkout -b feature/amazing-feature
) - Commit your changes (
git commit -m 'Add amazing feature'
) - Push to the branch (
git push origin feature/amazing-feature
) - Open a Pull Request
This project is licensed under the MIT License - see the LICENSE file for details.
- 📖 Documentation
- 🐛 Report bugs
- 💬 Discussions
- OpenAI for the GPT-4 and Whisper APIs
- Cursor for the amazing IDE
- LangChain for the AI framework
- The open source community for inspiration
Built with ❤️ for developers by developers
🌟 If LazyCoder helped you at work, leave a star on GitHub! 🌟