← Back to Leaderboard
Toobabooga

oobabooga/textgen

Local LLM desktop app with switchable inference backends and compatible APIs

View on GitHub ↗
Engineering Health (Methodology)
B · 60/100
Maintenance Activity
● Updated 3mo ago
Latest Release
v4.9
Commercial License Check
AGPL-3.0 · Copyleft Warning

Automated SPDX check for reference only — not legal advice. Disclaimer

Maintenance12/35
Fork Adoption23/25
Release Cadence14/20
License Clarity11/20
Self-HostedLocal AIAPIGPU1 README badge views (30d)
Total Stars
★ 47,757
24h Growth
+0
7d Growth
+22
Forks
5,983

GitHub Star History

Full-history star trajectory from GitHub official history. Switch ranges or hover any point for exact counts.

oobabooga/textgen Star History (2022-12-20 - 2026-12-04) ALL-TIME STAR HISTORY (2022-12 – 2026-12) +47.8k in 1445d · avg +33/day 50.4k 25.2k 0 2022-12-20: ★ 12023-03-18: ★ 3,1222023-06-17: ★ 14,3332023-09-16: ★ 22,1882023-12-16: ★ 27,4512024-03-16: ★ 32,5292024-06-15: ★ 35,9442024-09-14: ★ 37,8622024-12-14: ★ 39,5182025-03-15: ★ 41,4512025-06-14: ★ 42,6452025-09-13: ★ 43,8162025-12-13: ★ 44,6682026-03-14: ★ 45,5132026-06-13: ★ 46,8692026-09-12: ★ 47,4312026-12-04: ★ 47,757 ★ 47.8k 2022-12 2024-12 2026-12

Evidence-Backed Technical Brief

AI Deep Review

Architecture & Core Mechanics

TextGen brings a desktop chat client, browser UI, and API together around a Python application launched through server.py. Portable releases bundle Electron for the desktop window; their inference path uses llama.cpp with GGUF weights discovered in user_data/models. The full installation adds loader choices such as Transformers and ExLlamaV3; the manual full-install path uses Conda and hardware-specific PyTorch and loader dependencies. Models and loaders can be switched without restarting the application.

The conversation layer formats prompts with Jinja2 templates for instruction-following or character chat. With --api enabled, external clients can use OpenAI-compatible Chat and Completions endpoints or an Anthropic-compatible Messages endpoint against local inference. Tool calling can invoke built-in tools, custom functions packaged as individual Python files, or MCP servers, making tool execution a separate trust decision from loading model weights.

Key Capabilities & Differentiators

TextGen supports instruction and character chat, editable messages with version navigation, conversation branching, and a free-form Notebook. Compatible vision models can interpret attached images, while text, PDF, and DOCX attachments let users discuss document contents. Chat and API workflows can use tool calling; available tools include web search, page fetching, and math.

The loader lineup includes llama.cpp, ik_llama.cpp, Transformers, ExLlamaV3, and TensorRT-LLM. GGUF models can be placed directly in user_data/models; multi-file Transformers and EXL3 models go in individual subdirectories and require the full installation. The full path also supports resumable LoRA fine-tuning on multi-turn chats or raw text and a separate diffusers image-generation tab with 4-bit and 8-bit quantization and a persistent gallery.

Trade-offs & Limitations

Compared with ChatGPT and the OpenAI API, TextGen gives operators control over weights, quantization, context, and where inference runs, but shifts capacity planning and maintenance onto the host. Size against the selected quantization, target context and concurrency, not just the weight file. KV cache and runtime overhead need headroom; GPU offload and cache quantization can change the fit, but their performance impact should be tested on the intended hardware.

The portable GGUF path is the simplest to maintain; the full install adds training, image generation, and loaders at the cost of PyTorch and more hardware-specific dependencies. Local inference can run offline without telemetry, but web search and page fetching make outbound requests, and MCP servers and extensions should be reviewed before use. API compatibility helps with client migration but does not guarantee hosted-service feature parity. AGPL-3.0 obligations also matter when modifying or redistributing the application.

Hardware & Deployment Guide

For desktop use, pick a portable build for Linux, Windows, or macOS and the appropriate hardware option: CUDA, Vulkan, ROCm, or CPU-only, as available for the platform. Unpack it, put a GGUF in user_data/models, and launch textgen or textgen.bat. Add --model to user_data/CMD_FLAGS.txt to load a model at startup. The full one-click installer uses Miniforge and Conda under installer_files/ and serves the browser UI at http://127.0.0.1:7860.

For service deployments, --listen or --nowebui skips the Electron window in portable releases, and --api enables API access. Docker Compose 2.17+ configurations are provided under docker/ for NVIDIA, AMD, Intel, and CPU-only targets. Keep local use on loopback and control access before exposing the service. Release v4.7.3 introduced bundled Electron, v4.8 revised the chat composer, and v4.9 introduced draft-mtp, automatically enabled for MTP GGUFs.

Desktop runtime: Electron packages the portable interface around a local inference stack; server.py is the direct server entry point.
Loader choice: Switch among llama.cpp, ik_llama.cpp, Transformers, ExLlamaV3, and TensorRT-LLM without restarting the application.
Memory controls: GGUF deployments can tune context length, KV-cache type, and GPU layer offload.
Integration: OpenAI- and Anthropic-compatible endpoints support tool calling, with single-file Python tools and MCP servers.
Conversation workflow: Edit messages, navigate versions, branch chats, or move to a free-form Notebook.
Decoding: v4.9 adds draft-mtp and enables it automatically for MTP GGUFs.
Best For

Individuals and teams that want local chat or API inference, control over model weights, and the option to start with GGUF before adding other loaders or training.

Skip If

You want managed inference without maintaining hardware or model files, require exact hosted-API parity, or cannot meet AGPL-3.0 obligations for your deployment.

Reviewed on 2026-12-03 · Grounded in GitHub README, root file tree & releasesMethodology

Quick Start & Installation

Self-HostedLocal AIAPIGPU
# Clone repository
git clone https://github.com/oobabooga/textgen
cd textgen

# Create virtual environment
python -m venv venv

# Activate virtual environment
# On Windows:
venv\Scripts\activate
# On macOS/Linux:
source venv/bin/activate

# Install dependencies (choose appropriate file under requirements/portable for your hardware)
pip install -r requirements/portable/requirements.txt --upgrade

# Launch server (basic command)
python server.py --portable --api --auto-launch

# When done working, deactivate
deactivate

Comparison vs. Top Chat UI & AI Apps Alternatives

Full comparison →
RepositoryStars7d TrendStackLicenseCore Positioning
textgen ★47.8k+22PythonAGPL-3.0Local LLM desktop app with switchable inference backends and compatible APIs
ODS8k+88PythonApache-2.0A Docker Compose stack for private AI chat and inference on your own hardware
cherry-studio54.1k+204TypeScriptAGPL-3.0Electron AI workspace for comparing cloud and local models, running agents, and
jan46.4k+139Rust—Tauri desktop chat with local LLM inference and an OpenAI-compatible API

AI Context Briefing (for Claude / Cursor / Windsurf)

Standardized architecture summary & quickstart commands ready to paste into coding agents.

Raw .md ↗
curl -sL https://repoforai.com/repo/oobabooga/textgen.md

Embed Star History Chart & Badges in README.md

Full-history Star History SVGs and velocity cards on GitHub Camo: drop-in replacement for OSSInsight and Star History widgets.

oobabooga/textgen Star History on RepoForAI

Active README embeds unlock Hot-Tier 6h Telemetry Refresh automatically (zero pay-to-rank).

Frequently Asked Questions about textgen

How do I connect an existing OpenAI or Anthropic client?

Enable the API with --api and point the client at your TextGen instance. Chat, Completions, and Messages are supported, including tool calling. Check that your client can override its base URL, and test the endpoint and tool-call format you actually use. Compatibility does not mean that every hosted SDK feature or model behavior carries over.

How should I size VRAM, RAM, and disk for a local deployment?

Start by estimating memory for the exact GGUF quantization, then budget for the KV cache at your intended context length and test at your expected concurrency. For GGUF, --gpu-layers, --ctx-size, and --cache-type expose the main placement and cache decisions. A 16 GB GPU is a sizing constraint, not a blanket compatibility guarantee; the full PyTorch installation also needs roughly 10 GB of disk before budgeting for model files.

Can a company use TextGen internally or expose it as a service?

AGPL-3.0 permits commercial use. If you modify the covered program and let users interact with that modified version over a network, you generally must offer those users its Corresponding Source. Distribution can trigger separate obligations. Review the license of each model and extension independently; the application's license does not grant rights to the weights.

When is TextGen a better fit than ChatGPT or the OpenAI API?

Choose TextGen when you want local inference, direct control over weights and runtime settings, and both a chat UI and an API. Choose ChatGPT when you primarily want a managed chat experience, or the OpenAI API when you want managed inference for an application without maintaining GPU drivers, loaders, and model files.

Upstream README & Documentation

This profile focuses on independent engineering analysis and live telemetry. Read the full upstream README, changelog, and examples directly on GitHub.

Maintaining oobabooga/textgen? Pin to Homepage + competitor /alternatives pages with a custom Cloud/Demo CTA.Feature oobabooga/textgen on Homepage & Alternatives ($19)
WEEKLY BREAKOUT DIGEST

Top 10 Breakout Open-Source AI Repos, Every Thursday

Signal-only digest of fast-growing AI repos, SPDX license alerts, and architecture picks. Zero spam.

Zero spam · 1-click unsubscribe · Privacy Policy

Saved in your browser · Export Markdown RFC tables or jump into /vs compare