Skip to main content

llama-wrangler

PyPI GitHub Release Docker

Lightweight web admin panel for llama.cpp server management.

Features

  • Model Browser — Scan local directory for .gguf files, view name/size/modified
  • Model Download — Search HuggingFace for GGUF models, download with progress tracking
  • Server Lifecycle — Start/stop/restart llama-server subprocess from the browser
  • Parameter Config — Visual editor for llama-server flags (context size, GPU layers, batch size, flash attention, etc.)
  • System Monitoring — Real-time GPU (VRAM, temp, utilization, power), CPU, RAM, and disk usage
  • Log Viewer — Stream llama-server stdout/stderr via Server-Sent Events
  • Health Monitoring — Poll /health endpoint, show status badge
  • i18n — English and Chinese interface, switchable at runtime

Install

pip install llama-wrangler

Prerequisites

llama-wrangler manages a llama-server process on the host machine. Make sure you have:

  • llama.cpp compiled with llama-server binary (build instructions)
  • NVIDIA GPU driver installed (for GPU inference and monitoring)

Quick Start

# Start the admin panel
llama-wrangler --host 0.0.0.0 --port 7860

# With custom config
llama-wrangler --config /path/to/config.json

Then open http://localhost:7860 in your browser.

Configuration

Config is stored at ~/.config/llama-wrangler/config.json:

{
  "llama_server_path": "/path/to/llama-server",
  "models_dir": "/path/to/models",
  "default_args": {
    "host": "0.0.0.0",
    "port": 8080,
    "n_gpu_layers": 99,
    "ctx_size": 8192,
    "flash_attn": true,
    "batch_size": 2048,
    "ubatch_size": 512,
    "threads": 0,
    "parallel": 1,
    "cont_batching": true,
    "metrics": true
  }
}

Docker

Host prerequisites

The following must be set up on the host machine before running the container:

  1. NVIDIA GPU driver — install from NVIDIA or your distro's package manager
  2. NVIDIA Container Toolkit — required for --gpus flag to work:
    # Ubuntu/Debian
    curl -fsSL https://nvidia.github.io/libnvidia-container/gpgkey | \
      sudo gpg --dearmor -o /usr/share/keyrings/nvidia-container-toolkit-keyring.gpg
    curl -s -L https://nvidia.github.io/libnvidia-container/stable/deb/nvidia-container-toolkit.list | \
      sed 's#deb https://#deb [signed-by=/usr/share/keyrings/nvidia-container-toolkit-keyring.gpg] https://#g' | \
      sudo tee /etc/apt/sources.list.d/nvidia-container-toolkit.list
    sudo apt-get update && sudo apt-get install -y nvidia-container-toolkit
    sudo nvidia-ctk runtime configure --runtime=docker
    sudo systemctl restart docker
    
    See the official install guide for other distros.
  3. llama.cpp compiled on the host with llama-server binary
  4. Verify everything works: docker run --rm --gpus all ubuntu nvidia-smi

Build and run

# Build
docker build -t llama-wrangler .

# Run
docker run --gpus all -p 7860:7860 \
  -v /path/to/models:/mnt/data/models \
  -v /path/to/llama-server:/opt/llama-server:ro \
  -v /sys:/sys:ro \
  -v ~/.config/llama-wrangler:/root/.config/llama-wrangler \
  llama-wrangler

Volume mounts explained:

Mount Purpose
-v /path/to/models:/mnt/data/models GGUF model files (read/write for downloads)
-v /path/to/llama-server:/opt/llama-server:ro llama-server binary from host
-v /sys:/sys:ro Sensor data (disk/NVMe temperatures via psutil)
-v ~/.config/llama-wrangler:... Persist configuration across restarts
--gpus all GPU access (nvidia-smi, CUDA for llama-server)

Note: CPU and RAM metrics work out of the box in Docker — psutil reads /proc which is shared from the host. GPU monitoring requires --gpus all via nvidia-container-toolkit.

Without GPU

llama-wrangler works without a GPU (CPU-only inference). Simply omit --gpus all:

docker run -p 7860:7860 \
  -v /path/to/models:/mnt/data/models \
  -v /path/to/llama-server:/opt/llama-server:ro \
  llama-wrangler

The GPU section on the dashboard will be hidden automatically.

Tech Stack

  • Backend: Python asyncio (zero-framework, vendored HTTP server)
  • Frontend: Single-file vanilla HTML/CSS/JS
  • Dependencies: huggingface-hub, psutil only
  • No: Flask, FastAPI, React, npm, database

License

MIT

Metadata

Release files for llama-wrangler 0.1.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for llama-wrangler 0.1.0
File Size Uploaded
llama_wrangler-0.1.0.tar.gz 46.9 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for llama-wrangler 0.1.0
File Interpreter ABI Platform
llama_wrangler-0.1.0-py3-none-any.whl Python 3 none any Details

Total release size: 95.2 kB

Release files / llama_wrangler-0.1.0.tar.gz

Download URL llama_wrangler-0.1.0.tar.gz
Size 46.9 kB
Tags Source
SHA-256 checksum
How to use checksums
98a575b6c63a151f6a655d26e2f3a13630176e744047c34a24212fa62e295eae
BLAKE2b-256 checksum
How to use checksums
aed64db01d030315141be027eb687d992d76c4886d2f44b5d64a9bf4780cc715
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/6.1.0 CPython/3.13.12

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Jul 4, 2026.

Transparency log

Release files / llama_wrangler-0.1.0-py3-none-any.whl

Download URL llama_wrangler-0.1.0-py3-none-any.whl
Size 48.4 kB
Tags Python 3
SHA-256 checksum
How to use checksums
7bc3a625df2029f0d165edb32286aad7cf9a75cd2962256f30b6c531d7b1c9e6
BLAKE2b-256 checksum
How to use checksums
0b54dfe8ea13295face4af1236221f19f3ad605f701500050fff8bc3193af695
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/6.1.0 CPython/3.13.12

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Jul 4, 2026.

Transparency log

Release history Release notifications | RSS feed

This release

0.1.0 This release

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page