Head to head · Local inference · October 2026 research run

MLX LM vs TextGen

MLX LM scores 52.2 (D) on agent readiness against TextGen's 45.1 (E), and leads in 4 of 7 scored categories. TextGen leads on schema & documentation and security & auth. Both do local inference.

Which one, for what

MLX LM D

Good for An owner with an Apple silicon Mac who wants MLX-format models, local fine-tuning and quantisation from Python or the command line, with a simple local chat completions server.

Ahead on

  • Reliability, 66 against 51
  • Maintenance & community, 61 against 24
  • Transparency & trust, 66 against 49

Also in its favour

  • No key needed to call it
  • No incidents deducted, where TextGen loses 4 points for them

Watch for

mlx_lm.server has no API key or other credential option, and --allowed-origins defaults to *

TextGen E

Good for A person who wants one app for several backends (llama.cpp, ExLlamaV3, Transformers) with an OpenAI and Anthropic-compatible endpoint, LoRA training and image generation.

Ahead on

  • Schema & documentation, 61 against 37
  • Security & auth, 40 against 32

Watch for

No release since v4.9 on 20 May 2026 and no code commit on main or dev since 31 May 2026

Score by category

CategoryWeight this runMLX LMTextGenEdge
Reliability16%206651MLX LM +15
Performance10%pendingpendingpendingnot scored in this run
Schema & documentation13%16.23761TextGen +24
Agent ergonomics13%16.25450MLX LM +4
Security & auth14%17.53240TextGen +8
Payments & pricing10%12.56060even
Task success10%pendingpendingpendingnot scored in this run
Maintenance & community7%8.86124MLX LM +37
Transparency & trust7%8.86649MLX LM +17
Negative events≤150-4
Total52.2 · D45.1 · E

Facts side by side

FactMLX LMTextGen
KindHTTP APIModel platform
VendorApple Inc.oobabooga
Hosted endpointno (local only)no (local only)
TransportsHTTPHTTP
AuthNoneAPI key
PricingFreeFree
x402nono
LicenceMITAGPL-3.0
Read-only variant documentednono
llms.txtnono
Last release2026-10-012026-05-20
Terms last updatedno document linkedno document linked
Privacy policy last updatedno document linkedno document linked
Customer content may train models
Terms restrict automated access
Terms restrict benchmarking
Terms or service can change without notice
Arbitration or class-action waiver
Popularity7.3k stars, 140k PyPI/wk48k stars

Verdicts

MLX LM

MIT, with no telemetry found in the source, and the tests passed on the last eight pushes to main. mlx_lm.server has no API key option, answers any origin by default and loads whichever model a request names, and its own docs say it is not recommended for production.

TextGen

AGPL-3.0 with no telemetry, and a local API on 127.0.0.1:5000 that checks the Host header, limits CORS to localhost and separates an admin key from the caller's key. No release since v4.9 on 20 May 2026, no code commits since 31 May, no test suite, and ten security advisories in the year, all fixed.

Before you call either

MLX LM

  1. Keep mlx_lm.server on 127.0.0.1 and pass --allowed-origins with the origins you trust. There is no API key, and the default answers every origin
  2. Treat any caller as able to load any model. The model and adapters request fields accept any Hugging Face repository or local path
  3. Send max_tokens or max_completion_tokens when you need more than 512 tokens, the server default
  4. Read errors as {"error": "<text>"} with 400 for a bad field and 404 for a model that failed to load. They are not OpenAI error objects
  5. Poll GET /health before the first request. It answers 503 with unavailable when the generation thread has stopped

TextGen

  1. Ask the owner to launch with --api. Nothing listens on port 5000 without it, and a model must be loaded first
  2. Call http://127.0.0.1:5000/v1. Any Host header other than localhost or 127.0.0.1 gets 400 Invalid host header unless --listen is set
  3. Send the key as Authorization: Bearer on OpenAI routes and as x-api-key on /v1/messages. Model loading needs the admin key
  4. Read http://127.0.0.1:5000/docs or modules/api/typing.py for parameters. max_tokens defaults to 512 on chat completions
  5. Run tool calls yourself. The API returns finish_reason: "tool_calls" and executes nothing on the server
  6. Use the repository name oobabooga/textgen. The old text-generation-webui URL redirects

Questions

Which is better for AI agents, MLX LM or TextGen?

MLX LM scores 52.2 (D) on agent readiness against TextGen's 45.1 (E), and leads in 4 of 7 scored categories. TextGen leads on schema & documentation and security & auth.

Can an agent call MLX LM and TextGen without installing anything?

No hosted endpoint is listed for MLX LM. No hosted endpoint is listed for TextGen.

Are MLX LM and TextGen open source?

Yes. MLX LM is open source (MIT). TextGen is open source (AGPL-3.0).

Other comparisons with MLX LM or TextGen

Machine-readable

For companies

Do agents find, use and choose your tools?

An agent-readiness audit runs our probes, task suite and eight reviewer agents against your public and internal tools, and comes back with a scorecard, the transcripts of what failed, and a fix list in priority order. From $2,500, re-run included. We never take payment to move a rank. We do help companies earn one.