Skip to main content

Inference runtime

Self-hosting Text Generation WebUI: five backends, one window — and the VRAM math behind it

oobabooga's text-generation-webui is on v4.9, with llama.cpp, ik_llama.cpp, ExLlamaV3, Transformers and TensorRT-LLM all hot-swappable in the same window. What decides how big a model you can run was never the UI — it's the tens of gigabytes on the card.

Text Generation WebUI is oobabooga's local LLM workbench, hosted at github.com/oobabooga/text-generation-webui under AGPL-3.0. It is not the same category of tool as Ollama or LM Studio, which each wrap a single backend: textgen puts five genuinely different inference paths — llama.cpp, ik_llama.cpp, ExLlamaV3, Transformers, TensorRT-LLM — behind one Model tab, and you can switch between them without restarting the process. Run a 32B GGUF Q4 in the afternoon, load a brand-new architecture through Transformers in the evening. The price of that flexibility is that you have to know what each path costs in VRAM.

Since v4.7.3 the portable builds bundle Electron, so you unzip, double-click textgen, and get a native window instead of a server plus a browser tab. Release assets follow the pattern textgen-portable-[ik-]4.9-[os]-[backend].zip, with cuda12.4, cuda13.1, vulkan, rocm7.2 and cpu variants for both Windows and Linux, an extra arm64-cuda13.1 Linux build for DGX Spark, and macOS arm64 / x86_64 (llama.cpp only). The backend versions inside v4.9 are pinned: llama.cpp at commit e947228, ik_llama.cpp at 40254a5, ExLlamaV3 at 0.0.34 — that pinning matters, and we come back to it below.

Feature-wise it long ago stopped being just a chat box: multimodal image input, txt/PDF/docx attachment parsing, message editing with conversation branching, a Notebook tab for raw continuation, an OpenAI- and Anthropic-compatible API with tool calling, MCP stdio servers, a web search tool, LoRA fine-tuning, and in v4.9 MTP speculative decoding that auto-enables for MTP GGUFs plus a live tokens/s readout. Zero telemetry, no outbound calls. All of it runs on your own card — and on NexGPU that card starts at RTX 3090 24GB for $0.193/GPU-hour, metered per second, with compute billing stopping the moment the instance stops.

01 —

Five loaders and their quant formats: who eats how much VRAM

The UI itself uses almost no VRAM. What uses VRAM is the weights plus a preallocated KV cache.

VersionParametersVRAMContextNotes
llama.cpp (GGUF)1B–70B, the single-card workhorseQ4_K_M ≈ params × 0.6GB: 8B ≈ 5GB / 32B ≈ 20GB / 70B ≈ 43GB; Q8_0 ≈ × 1.06--ctx-size defaults to 0, reading the native window from GGUF metadatav4.9 ships commit e947228. --gpu-layers defaults to -1 (auto) and spills to system RAM when the model doesn't fit; --cache-type accepts fp16, q8_0 and q4_0. The cache is preallocated, so whatever context you request is deducted up front.
ik_llama.cpp (separate ik- package)Large MoE models and CPU hybrid offloadSame order as the equivalent GGUF, but --cpu-moe / --n-cpu-moe move expert layers to system RAM and can cut VRAM to well under half the weight sizeSame as GGUFv4.9 ships commit 40254a5, packaged separately as textgen-portable-ik-4.9-* assets. For 100B+ sparse MoE models it is far more VRAM-frugal than mainline llama.cpp, at the cost of being bottlenecked by memory bandwidth.
ExLlamaV3 / ExLlamav3_HF (EXL3)8B–70B, pure-GPU inferenceStraight bpw math: 32B @ 4.0bpw ≈ 16GB, 70B @ 3.0bpw ≈ 26GB, plus KVCache supports fp16 and q2–q8, with separate K and V bit widthsv4.9 ships ExLlamaV3 0.0.34. Pure GPU — there is no CPU offload fallback, so if it doesn't fit, loading simply fails. The non-_HF ExLlamav3 variant additionally supports speculative decoding and multimodal models.
Transformers (bf16 / bitsandbytes)1B–13B at full precision, or 4-bit / 8-bitbf16 = params × 2GB (8B ≈ 16GB); load_in_4bit brings 8B down to ≈ 6GB, a bit lower with use_double_quantBounded by both --ctx-size and the model's native windowThe only path that supports LoRA training, and the one with the broadest architecture coverage. When llama.cpp hasn't merged support for a new architecture yet, Transformers is often the only thing that will load it at all.
TensorRT-LLMPrecompiled enginesDetermined by the precision and batch/seq limits chosen at compile time, then fixedBaked in when the engine is builtNVIDIA-only and the highest single-card throughput available here, but changing model or context length means recompiling the engine. Suited to a settled, long-running service — not to experimentation.

02 —

Pick the card by what you actually intend to run

Prices are NexGPU list rates per GPU per hour, metered per second and priced per hour, with no minimum and no setup fee.

  • 8B–14B GGUF, exercising the full UI, API, tool-calling and MCP path

    RTX 3090 24GB$0.193/GPU-hour

    A 14B Q4_K_M is only around 9GB, leaving enough of the 24GB to push --ctx-size to 32K while keeping an fp16 cache. It's the cheapest way to prove out a configuration.

  • 32B Q4_K_M resident with a 32K context

    RTX 5090 32GB$0.723/GPU-hour

    A 32B Q4_K_M spends about 20GB on weights alone; on a 24GB card the preallocated KV forces you to cut context. 32GB is what lets you keep --cache-type at q8_0 instead of dropping to q4_0.

  • 70B Q4_K_M on one card, without fighting tensor-split

    A100 PCIE 80GB$0.824/GPU-hour

    A 70B Q4_K_M is roughly 43GB — on an RTX A6000 48GB ($0.817/GPU-hour) that leaves almost nothing for KV. Paying $0.007 more per hour for 32GB extra is the best-value step on this price list.

  • LoRA fine-tuning, or running bf16 through Transformers

    H100 SXM 80GB$3.582/GPU-hour

    The Training tab runs the Transformers path, where gradients and optimiser state multiply the inference footprint several times over. bf16 training also requires the full install rather than the portable build — H100 memory and bandwidth get that pass done in one go.

03 —

Deploying Text Generation WebUI on NexGPU

Four steps from boot to a working OpenAI-compatible endpoint.

  1. 01

    Start a GPU instance

    Pick a card from the table above at console.nexgpu.net and choose a PyTorch or Ubuntu CLI image — both are among the 2,000+ prebuilt images. The network spans 1,175 verified rentable nodes, 2,498 GPUs and 75 GPU models, with up to 14 GPUs per node and a maximum node VRAM of 2,152GB. Get in via SSH, Jupyter or the web terminal.

    ssh -p <port> root@<node-ip>
  2. 02

    Install text-generation-webui

    The portable build is the least painful route: every dependency is bundled and it needs only Python 3.9+. If you want LoRA training, skip portable — it launches with --portable, which explicitly disables training — and use the repository's start_linux.sh one-click installer instead (conda, Python 3.13).

    wget https://github.com/oobabooga/text-generation-webui/releases/download/v4.9/textgen-portable-4.9-linux-cuda13.1.tar.gz && tar -xzf textgen-portable-4.9-linux-cuda13.1.tar.gz
  3. 03

    Drop the model into user_data/models/ and launch with the API on

    GGUF is a single file and goes straight into user_data/models/. Transformers and EXL3 models are multi-file and must each live in their own subfolder with the original structure intact. The compatible API only comes up if you pass --api; it listens on port 5000 under /v1. Always set --api-key.

    wget -P user_data/models/ https://huggingface.co/bartowski/Qwen2.5-32B-Instruct-GGUF/resolve/main/Qwen2.5-32B-Instruct-Q4_K_M.gguf && ./start_linux.sh --model Qwen2.5-32B-Instruct-Q4_K_M.gguf --gpu-layers -1 --ctx-size 32768 --cache-type q8_0 --api --api-key sk-your-own-key
  4. 04

    Reach it over an SSH tunnel, not --share

    As of v4.9 CORS is restricted to localhost by default, which is exactly right. Forward 7860 (web UI) and 5000 (API) back to your machine and open 127.0.0.1:7860 for the full interface. When you genuinely need to share with a team, use --listen together with --gradio-auth user:password rather than handing out a --share public link.

    ssh -N -L 7860:127.0.0.1:7860 -L 5000:127.0.0.1:5000 -p <port> root@<node-ip>

What a month actually costs, with the arithmetic

Say you keep a 32B Q4_K_M resident on an RTX 5090 32GB ($0.723/GPU-hour) to prototype an internal knowledge-base assistant, running it four real hours a day across 20 working days: 80 hours × $0.723 = $57.84. Add 60GB of storage for three or four different quantisations: 60 × $0.414 = $24.84. Export 20GB of results: 20 × $0.0081 = $0.16. Total about $82.84 for the month. The same 80 hours spent on an RTX 3090 24GB ($0.193/GPU-hour) tuning prompts and tool chains against an 8B Q4 costs just $15.44 in compute. The billing detail that matters: compute stops the instant you stop the instance, while storage keeps accruing until you destroy it — so delete the GGUFs you no longer need.

04 —

Frequently asked questions

How much VRAM does text-generation-webui actually need?

The interface itself uses almost none. What consumes VRAM is the weights plus a preallocated KV cache. The GGUF rule of thumb holds up well: Q4_K_M ≈ params × 0.6GB, Q8_0 ≈ × 1.06, bf16 = × 2. So 8B Q4_K_M ≈ 5GB, 32B ≈ 20GB, 70B ≈ 43GB. Don't forget the cache — the docs state plainly that it is preallocated, so whatever --ctx-size you ask for is deducted immediately, and switching --cache-type from fp16 to q8_0 halves it outright. Do that math, then pick the card: NexGPU offers 75 GPU models from 24GB to 141GB — RTX 3090 at $0.193, RTX 5090 32GB at $0.723, A100 80GB at $0.824, H200 141GB at $6.660 — all billed per second, so guessing wrong just means stopping and switching.

When should I use text-generation-webui instead of vLLM or Ollama?

The division of labour is clear. vLLM is built for high-concurrency production serving — PagedAttention, continuous batching, one backend taken to its limit. Ollama wins on simplicity. Text Generation WebUI's edge is having five backends coexist with no restart between them, plus Notebook-style continuation, conversation branching, every sampler parameter exposed, and LoRA training in the same window. It is a single-operator workbench, ideal for the model-selection and parameter-tuning phase. NexGPU's 2,000+ prebuilt images include both PyTorch and vLLM, so you can settle on a model and quant level in textgen, then move to a vLLM instance for load testing.

What do I do when loading fails with 'unknown model architecture'?

This is one of the most common categories in the issue tracker — users have reported things like 'unknown model architecture: minimax-m3'. The cause is that each release pins llama.cpp to a fixed commit; v4.9 sits at e947228, so an architecture merged upstream afterwards won't work until the next textgen release. Three ways out: wait for the release, swap the llama.cpp binary yourself, or switch to the Transformers loader, which tracks the transformers library and usually gains new architectures first (re-estimate VRAM for bf16 or 4-bit if you do). That last route jumps you a tier in memory — spinning up an A100 PCIE 80GB at $0.824/GPU-hour on NexGPU for one evening is far faster than rebuilding your environment.

Can I train LoRAs in it, and what card do I need?

Yes — the Training tab handles both multi-turn chat datasets and raw text, running through the Transformers path. One caveat: portable builds launch with --portable, which explicitly disables training, so you need the full start_linux.sh install (conda, Python 3.13). On memory, training has to hold weights, gradients and optimiser state at once, typically three to four times the inference footprint, so a 7B-class LoRA belongs on an 80GB card. NexGPU's H100 SXM 80GB is $3.582/GPU-hour and A100 SXM4 80GB is $1.088/GPU-hour — stop when the run finishes, with no quota request for a few hours of fine-tuning.

Why can't I find the ExLlamaV2 or AutoGPTQ loaders my tutorial mentions?

Because they are no longer in the loader list. The v4.9 Model tab offers exactly five: llama.cpp, ik_llama.cpp, Transformers, ExLlamav3_HF / ExLlamav3, and TensorRT-LLM. The wave of 2024-era GPTQ tutorials is out of date, and EXL3 is ExLlamaV3's new format — it is not interchangeable with EXL2 weights. If your library is all older quantisations, converting to GGUF and running llama.cpp is the safest migration. This is exactly the kind of trial-and-error that belongs on per-second billing: a NexGPU Tesla T4 16GB is $0.298/GPU-hour, enough to work through format compatibility one file at a time.

How do I safely reach the web UI and API when it's deployed in the cloud?

v4.9 already tightened CORS to localhost by default and fixed a path-traversal issue in character-name handling, so the right posture is simply not to expose it publicly. An SSH port forward for 7860 and 5000 gives you zero configuration and zero attack surface. For team access, pair --listen with --gradio-auth user:password and set --api-key on the API side — don't skip either layer. NexGPU instances ship with SSH, Jupyter, a web terminal and a REST API by default, and with 51 countries and regions to choose from you can put the node close to your users. If something won't connect, reach us on Telegram in English or Chinese — no ticket queue.

Start building on NexGPU

Enterprise R&D team or solo developer — either way, your first job can be running in minutes.

Sign up to browse live network pricing. No payment method required.