Production-Grade ML Environment Provisioning Platform
EnvForge is an intelligent environment provisioning platform that automates one of the most frustrating parts of machine learning development: creating reliable and compatible development environments.
By combining hardware diagnostics, compatibility-aware version resolution, template-driven script generation, and built-in safety validation, EnvForge enables developers to generate deterministic setup scripts for PyTorch, TensorFlow, CUDA, YOLO, and other ML ecosystems across Windows, WSL, and Linux.
No more CUDA mismatches. No more dependency conflicts. No more hours spent debugging installation issues.
Generate. Verify. Deploy. Build AI with confidence.
A massive thank you to all the developers who have contributed code, resolved issues, and helped shape EnvForge into a production-grade ML environment provisioning platform!
Made with contrib.rocks.
- Project Overview
- Contributors
- Features
- Architecture
- Project Structure
- Quick Start
- Documentation Links
- Contributing
- Roadmap
- License
Deterministic logic > AI generation. Because scripts affect real systems, EnvForge relies on a strictly deterministic Compatibility Engine to resolve versions. It never guesses package versions or writes destructive shell commands.
EnvForge helps users:
- Generate environment setup scripts (
setup.sh,setup.ps1,Dockerfile) - Install compatible ML frameworks (TensorFlow, PyTorch, YOLO, etc.)
- Verify existing environments
- Diagnose setup issues across OS, GPU, and Python boundaries
- Environment Profiles: Out-of-the-box configurations for
pytorch-cuda,tf-gpu,yolov8, and more. - Hardware Introspection: A standalone CLI agent (
envforge-agent) that detects OS, RAM, GPU, VRAM, and CUDA details without an internet connection. - Safety First: Every generated script passes through a regex-based
SafetyFilterthat strictly blocks dangerous commands (e.g.,rm -rf /,mkfs). - Idempotent Setup: Scripts verify prerequisites before installing anything.
- RESTful API: Fast, async backend built on FastAPI and PostgreSQL.
EnvForge is built with a modular, scalable architecture.
- CLI Diagnostic Agent: Inspects local hardware and emits a structured JSON
DiagnosticReport. - API Layer: FastAPI handles incoming requests and orchestrates logic.
- Compatibility Engine: A pure-Python module holding the "Engineering Moat" β the CUDA and Framework compatibility matrices.
- Template Engine: Renders Jinja2 templates (
.sh,.ps1,Dockerfile) based on the resolved environment. - Safety Filter: Scans rendered output to block destructive actions.
For more details, see ARCHITECTURE.md.
EnvForage/
βββ .github/ # GitHub templates, workflows, and automation
β βββ ISSUE_TEMPLATE/
β βββ workflows/
β βββ CODEOWNERS
β βββ dependabot.yml
β βββ PULL_REQUEST_TEMPLATE.md
β
βββ backend/ # FastAPI backend and compatibility engine
β βββ alembic/ # Database migrations
β βββ app/
β β βββ ai/ # AI troubleshooting logic
β β βββ api/ # API routes
β β βββ compatibility/ # CUDA/Framework compatibility engine
β β βββ core/ # Core application logic
β β βββ middleware/ # Custom middleware
β β βββ models/ # Database models
β β βββ schemas/ # Pydantic schemas
β β βββ services/ # Business services
β β βββ templates/ # Script generation templates
β β
β βββ scripts/ # Utility scripts
β βββ seeds/ # Compatibility matrices and profiles
β βββ tests/ # Unit, integration, and API tests
β βββ Dockerfile
β βββ pyproject.toml
β
βββ frontend/ # Next.js web application
β βββ public/
β βββ src/
β β βββ app/
β β β βββ diagnose/ # Environment diagnostics UI
β β β βββ generate/ # Script generation UI
β β β βββ profiles/ # Environment profiles
β β β βββ troubleshoot/ # AI troubleshooting interface
β β β
β β βββ components/ # Reusable React components
β β βββ services/ # API communication layer
β β βββ types/ # TypeScript types
β β
β βββ Dockerfile
β βββ package.json
β
βββ cli/ # Standalone diagnostic CLI agent
βββ docs/ # Project documentation
β
βββ docker-compose.yml # Development environment
βββ docker-compose.prod.yml # Production deployment
βββ CONTRIBUTING.md # Contribution guidelines
βββ CODE_OF_CONDUCT.md # Community standards
βββ SECURITY.md # Security policy
βββ TROUBLESHOOTING.md # Common issues & fixes
βββ CHANGELOG.md # Release history
βββ LICENSE
βββ README.md
Inspect your environment without needing the backend!
pip install envforge-agent
envforge diagnosegit clone https://github.com/rishabh0510rishabh/EnvForage.git
cd EnvForage
docker-compose up -dPrerequisites:
- Helm 3+
- A running Kubernetes cluster (Docker Desktop, minikube, or cloud)
- NGINX Ingress Controller (only if
ingress.enabled=true):
kubectl apply -f https://raw.githubusercontent.com/kubernetes/ingress-nginx/controller-v1.10.0/deploy/static/provider/cloud/deploy.yamlhelm install envforge ./helm/envforge
# Enable ingress (optional)
helm install envforge ./helm/envforge \
--set ingress.enabled=true \
--set ingress.host=api.yourdomain.com
kubectl port-forward svc/envforge 8000:8000
kubectl port-forward svc/envforge-frontend 3000:3000The API is now running at http://localhost:8000.
Generate a PyTorch CUDA setup script for Linux:
curl -X POST http://localhost:8000/api/v1/scripts/generate \
-H "Content-Type: application/json" \
-d '{"profile_id": "pytorch-cuda", "target_os": "LINUX", "output_formats": ["setup.sh"]}'| Document | Purpose |
|---|---|
| ARCHITECTURE.md | High-level system overview and component boundaries |
| COMPATIBILITY_ENGINE.md | Core logic: CUDA mappings and framework rules |
| WORKFLOW.md | Script generation, diagnosis, and repair flows |
| AI_USAGE_POLICY.md | Where AI is allowed vs where deterministic logic is required |
| SCRIPT_SAFETY.md | Prohibited commands and rollback philosophy |
| CLI_REFERENCE.md | Commands for envforge diagnose, verify, and fix |
| API_DESIGN.md | REST endpoints, schemas, and validation rules |
| PROFILE_SPEC.md | How to build and define new ML profiles |
| TASKS.md | The master implementation blueprint |
We love open source! Contributions of all sizes are welcome β whether it's fixing bugs, improving documentation, adding new environment profiles, enhancing the compatibility engine, or proposing new features.
Please read our Contributing Guide before getting started. You'll find detailed instructions for:
- Local development setup (Docker & non-Docker workflows)
- Backend, frontend, and CLI development
- Branching and commit message conventions
- Adding new profiles and script templates
- Testing requirements and quality standards
- Pull request guidelines and code review expectations
Before submitting a contribution, please ensure that all tests pass and relevant documentation is updated.
Thank you for helping make EnvForge more reliable, safe, and developer-friendly!
- Phase 1: Core Backend (Compatibility Engine, Template Engine) β
- Phase 2: CLI Diagnostic Agent (
envforge-agent) β - Phase 3: Next.js Frontend Web App β
- Phase 4: AI Troubleshooting Layer β
- Phase 5: Environment Verification β
- Phase 6: Polish & Production Readiness β
See the full ROADMAP.md for details.
This project is licensed under the MIT License - see the LICENSE file for details.