Skip to content

Local UI to run and train LLMs and diffusion models. Supports GGUF, MLX, Qwen3.8, DeepSeek-V4.1, MiniMax-H3, Gemma 4, FLUX and more.

README.md draft

Roland Tannous0bada7e758a4
diff --git a/README.md b/README.md
index 5270b9aaf63..4d2092b3a98 100644
--- a/README.md
+++ b/README.md
@@ -1 +1,144 @@
-# new-ui-prototype
+<p align="center">
+ <img src="https://raw.githubusercontent.com/unslothai/unsloth/main/images/unsloth%20logo%20white%20text.png" alt="Unsloth Studio" width="400"/>
+</p>
+
+<h3 align="center">πŸ¦₯ Unsloth Studio</h3>
+
+<p align="center">
+ A modern, full-stack web interface for fine-tuning, managing, and chatting with large language models β€” locally or in the cloud.
+</p>
+
+<p align="center">
+ <a href="#features">Features</a> β€’
+ <a href="#quick-start">Quick Start</a> β€’
+ <a href="#api-reference">API Reference</a> β€’
+ <a href="#project-structure">Project Structure</a>
+</p>
+
+---
+
+## Features
+
+| Area | Capabilities |
+|---|---|
+| **Training** | Configure and launch LoRA / QLoRA fine-tuning jobs with real-time SSE progress streaming, live loss charts, and one-click stop / resume |
+| **Model Management** | Browse, load, and manage Hugging Face hub models and local checkpoints |
+| **Inference** | Interactive chat playground for testing fine-tuned models |
+| **Dataset Tools** | Upload, preview, and prepare datasets (JSON, CSV, Parquet, PDF, DOCX) |
+| **Export** | Export & push trained adapters to the Hugging Face Hub |
+| **Auth** | Token-based authentication with JWT access / refresh flow and first-time setup token |
+
+## Quick Start
+
+### One-command setup
+
+```bash
+bash setup.sh
+```
+
+This script will:
+1. Install **Node.js β‰₯ 20** via nvm (if needed)
+2. Build the frontend to `studio/frontend/dist`
+3. Create a Python virtual environment and install all dependencies (including `unsloth`)
+4. Register a convenient `unsloth-ui` shell alias
+
+### Launch the studio
+
+```bash
+# After setup, open a new terminal (or source ~/.bashrc), then:
+unsloth-ui -H 0.0.0.0 -p 8000
+```
+
+On **first launch**, a one-time setup token is printed to the console. Use it in the browser to create your admin account.
+
+## API Reference
+
+All endpoints require a valid JWT `Authorization: Bearer <token>` header (except `/api/auth/*` and `/api/health`).
+
+| Method | Endpoint | Description |
+|---|---|---|
+| `GET` | `/api/health` | Health check |
+| `GET` | `/api/system` | System info (GPU, CPU, memory) |
+| `POST` | `/api/auth/signup` | Create account (requires setup token on first run) |
+| `POST` | `/api/auth/login` | Login and receive JWT tokens |
+| `POST` | `/api/auth/refresh` | Refresh an expired access token |
+| `GET` | `/api/auth/status` | Check if auth is initialized |
+| `POST` | `/api/train/start` | Start a training job |
+| `POST` | `/api/train/stop` | Stop a running training job |
+| `POST` | `/api/train/reset` | Reset training state |
+| `GET` | `/api/train/status` | Get current training status |
+| `GET` | `/api/train/metrics` | Get training metrics (loss, LR, steps) |
+| `GET` | `/api/train/stream` | SSE stream of real-time training progress |
+| `GET` | `/api/models/` | List available models |
+| `POST` | `/api/inference/chat` | Send a chat message for inference |
+| `GET` | `/api/datasets/` | List / manage datasets |
+
+> Full interactive docs are available at `/docs` (Swagger UI) and `/redoc` when the server is running.
+
+## CLI Commands
+
+The Unsloth CLI (`cli.py`) provides the following commands:
+
+```
+Usage: cli.py [COMMAND]
+
+Commands:
+ train Fine-tune a model
+ inference Run inference on a trained model
+ export Export a trained adapter
+ list-checkpoints List saved checkpoints
+ ui Launch the Unsloth Studio web UI
+ studio Launch the studio (alias)
+```
+
+## Project Structure
+
+```
+new-ui-prototype/
+β”œβ”€β”€ cli.py # CLI entry point
+β”œβ”€β”€ cli/ # Typer CLI commands
+β”‚ └── commands/
+β”‚ β”œβ”€β”€ train.py
+β”‚ β”œβ”€β”€ inference.py
+β”‚ β”œβ”€β”€ export.py
+β”‚ β”œβ”€β”€ ui.py
+β”‚ └── studio.py
+β”œβ”€β”€ setup.sh # One-command bootstrap script
+└── studio/
+ β”œβ”€β”€ backend/
+ β”‚ β”œβ”€β”€ main.py # FastAPI app & middleware
+ β”‚ β”œβ”€β”€ run.py # Server launcher (uvicorn)
+ β”‚ β”œβ”€β”€ auth/ # Auth storage & JWT logic
+ β”‚ β”œβ”€β”€ routes/ # API route handlers
+ β”‚ β”‚ β”œβ”€β”€ training.py
+ β”‚ β”‚ β”œβ”€β”€ models.py
+ β”‚ β”‚ β”œβ”€β”€ inference.py
+ β”‚ β”‚ β”œβ”€β”€ datasets.py
+ β”‚ β”‚ └── auth.py
+ β”‚ β”œβ”€β”€ models/ # Pydantic request/response schemas
+ β”‚ β”œβ”€β”€ core/ # Training engine & config
+ β”‚ β”œβ”€β”€ utils/ # Hardware detection, helpers
+ β”‚ └── requirements.txt
+ β”œβ”€β”€ frontend/
+ β”‚ β”œβ”€β”€ src/
+ β”‚ β”‚ β”œβ”€β”€ features/ # Feature modules
+ β”‚ β”‚ β”‚ β”œβ”€β”€ auth/ # Login / signup flow
+ β”‚ β”‚ β”‚ β”œβ”€β”€ training/ # Training config & monitoring
+ β”‚ β”‚ β”‚ β”œβ”€β”€ studio/ # Main studio workspace
+ β”‚ β”‚ β”‚ β”œβ”€β”€ chat/ # Inference chat UI
+ β”‚ β”‚ β”‚ β”œβ”€β”€ export/ # Model export flow
+ β”‚ β”‚ β”‚ └── onboarding/# Onboarding wizard
+ β”‚ β”‚ β”œβ”€β”€ components/ # Shared UI components (shadcn)
+ β”‚ β”‚ β”œβ”€β”€ hooks/ # Custom React hooks
+ β”‚ β”‚ β”œβ”€β”€ stores/ # Zustand state stores
+ β”‚ β”‚ └── types/ # TypeScript type definitions
+ β”‚ β”œβ”€β”€ package.json
+ β”‚ └── vite.config.ts
+ └── tests/ # Backend test suite
+```
+
+## License
+
+This project is licensed under the [GNU Affero General Public License v3.0 (AGPL-3.0)](https://www.gnu.org/licenses/agpl-3.0.html).
+
+Copyright Β© 2026 Unsloth AI.