An open-source, self-hosted MLOps workspace for computer-vision training, evaluation, model management, and inference workflows. YOLO object detection is the initial reference workload.
This repository contains two runnable applications:
- A Next.js frontend with live inference and persistent run history integration, alongside prototype screens for dataset and model management.
- A FastAPI inference backend that loads local Ultralytics YOLO models, accepts JPEG or PNG uploads, returns annotated images with structured detections, and persists execution history into a database (SQLite default via SQLModel).
Both the Inference workspace (/inference) and the Run history & details
screens (/runs, /runs/details) are connected live to the backend API.
mlops/
├── backend/ # FastAPI YOLO inference & run persistence service
│ ├── app/ # Routes, database, domain models, and YOLO inference
│ ├── models/ # Local YOLO model weights
│ ├── README.md # Backend setup and API reference
│ └── pyproject.toml
├── frontend/ # Next.js product shell & connected UI
│ ├── src/
│ ├── README.md # Frontend routes and behavior
│ └── package.json
├── docs/ # Product plan and design documentation
└── AI_USE.md # Project AI-use disclosure
- Python 3.12 or newer
uv- Sufficient CPU/GPU memory to load the included YOLO weights
Run frontend and backend as separate applications. Start each in its own terminal.
cd backend
uv sync
uv run uvicorn app.main:app --reloadThe backend is available at:
- API:
http://127.0.0.1:8000 - Swagger UI:
http://127.0.0.1:8000/docs - Health check:
http://127.0.0.1:8000/health
See the backend README for request examples, supported models, validation behavior, and database configuration.
cd frontend
bun install
bun devOpen http://localhost:3000. The frontend proxies /infer and /inference_runs directly to the FastAPI backend. See the frontend README for available routes and behavior.
Run backend checks from backend/ :
uv run ruff check app
uv run ruff format --check app
uv run pytestRun frontend checks from frontend/ :
bun lint
bun run build| Method | Path | Purpose |
|---|---|---|
GET |
/health |
Report that the API process is running |
POST |
/infer |
Run YOLO inference on an uploaded image & log run to DB |
GET |
/inference_runs |
List all persisted inference runs |
GET |
/inference_runs/{run_id} |
Retrieve details for a specific inference run |