Free Intensive Nov 21–22Free 2-day hands-on Vibecoding Intensive on Nov 21–22 at 16:00 MSK (Sat–Sun) · Live Cohort 3 starts Nov 23Join Free →Cohort 3 (Nov 23)
ReleaseInsight · On RadarHabr AI→ original

A Habr developer decoded llama.cpp flags: a 4-part reference, with one part out so far

llama.cpp is a program for running neural networks on your own computer, but the built-in --help output for its flags is too terse. A Habr author spent a week working through the parameters of llama-cli, llama-completion, and llama-server, checking them against the source code. The reference is split into 4 parts: common flags, sampling, speculative decoding, and settings for individual utilities. Only one part is ready so far, so the rest will have to wait.

AI-processed from Habr AI; edited by Hamidun News
A Habr developer decoded llama.cpp flags: a 4-part reference, with one part out so far
Source: Habr AI. Collage: Hamidun News.
Listen to article
Article Fact Sheet & Key Figures
ParameterDetails
Primary sourceHabr AI ↗
Editor-in-Chief
Part 1 — Common Paramsgeneral flags shared by all three utilities
Key metric #2The reference is duplicated on GitHub in Russian and English, one page each
Key metric #3Descriptions the author is unsure of are marked with a note about possible inaccuracy

llama.cpp is a popular program for running neural networks directly on your own computer or server, without the cloud. It has dozens of flags, and the built-in --help output describes each one in a single dry line. As a result, many people copy a set of parameters from someone else's guide without fully understanding what they have actually turned on. A Habr author decided to close that gap: over a week, he went through all the arguments and compiled a reference in Russian. It is split into 4 parts by flag category, and so far only the first has been published.

What the reference covers

The focus is on three utilities for inference, that is, for running an already-trained model:

  • llama-cli — working with the model in the terminal in a dialogue format;
  • llama-completion — generating a continuation of text from a given beginning;
  • llama-server — running the model as a server that other programs connect to.

The author followed the output of "llama-cli --help" and "llama-server --help" and kept the same order. For each parameter, he lists the name, the template, and a short description from the built-in help, followed by an extended comment in his own words. You can keep the terminal open alongside and check each flag against its explanation.

The four parts of the reference

Common Params — general parameters. They largely match across all three utilities, and this is the biggest part. The series starts with it, and the article is already out and serves as a table of contents for the rest.

Sampling Params — sampling parameters, that is, the rules by which the model chooses the next word from among the candidates. These include temperature, top-p, top-k, min-p, and more. The author admits he was quite surprised by how many ways llama.cpp offers to tune the model's behavior. This material is still in progress.

Speculative Params — settings for speculative decoding. The idea is that a small, fast draft model guesses several next tokens, and the large main model verifies them all at once. If the guesses are confirmed, the large model accepts them without generating step by step, and the text appears faster. This part is also in progress.

Example-Specific Params — parameters for specific utilities. For example, llama-server has its own server-side settings that llama-cli and llama-completion do not have. The author warns that "specific" does not mean "rare." Some of these flags are needed for regular use, especially with the server. This part has not been published yet.

The author tentatively plans 4 articles, but acknowledges there may be more.

How the author worked and what to trust

The author honestly writes that he does not personally use everything in llama.cpp, and that he worked through many of the parameters together with AI. He did not copy the models' answers: he tried to understand how each parameter works and what it affects, read the source code where necessary, and only then wrote the comment. Where he lacked confidence, the description is marked with a note that it may be inaccurate.

He used AI to translate the English version but proofread it by hand, since models often pick overly literary phrasing for technical text. The reference is also duplicated on GitHub as two pages, Russian and English, following the order of the built-in help. Corrections are accepted in the comments on the articles, as pull requests on GitHub, by email, and on the author's Telegram.

What to do with this

If you run local models for development, chatbots, or internal services, bookmark the first part and use it as a reference rather than reading it cover to cover. But keep the limitations in mind: one part out of roughly four is ready, the author does not claim complete coverage or full accuracy, and some descriptions may contain errors. Check parameter values against your own build of llama.cpp, since the set of flags changes from version to version. Judging by the description, the most useful sections will be those on sampling and speculative decoding, but you will have to wait for them. Watch for updates to the table of contents in the first article.

Story

Key Questions Answered

What the reference covers?

The focus is on three utilities for inference, that is, for running an already-trained model: llama-cli — working with the model in the terminal in a dialogue format; llama-completion — generating a continuation of text from a given beginning; llama-server — running the model as a server that other programs connect to. The author followed the output of "llama-cli --help" and "llama-server --help" and kept the same order.

What are the key details on The four parts of the reference?

Common Params — general parameters. They largely match across all three utilities, and this is the biggest part. The series starts with it, and the article is already out and serves as a table of contents for the rest. Sampling Params — sampling parameters, that is, the rules by which the model chooses the next word from among the candidates. These include temperature, top-p, top-k, min-p, and more. The author admits he was quite surprised by how many ways llama.cpp offers to tune the model's behavior.

How the author worked and what to trust?

The author honestly writes that he does not personally use everything in llama.cpp, and that he worked through many of the parameters together with AI. He did not copy the models' answers: he tried to understand how each parameter works and what it affects, read the source code where necessary, and only then wrote the comment. Where he lacked confidence, the description is marked with a note that it may be inaccurate.

ZK
Zhemal Khamidun — CPO at Alpina Digital, product manager of AlpinaGPT. Building AI products since 2019. Hamidun News is a pet project that grew into a production aggregator with 6,000+ readers.
✦ Unified AI Workspace · Nomad

Test Frontier LLMs & Autonomous Agents in One Workspace

Run Claude Opus 5.5, GPT-6, Gemini 3.1, and DeepSeek side-by-side in Nomad AI (nomadnet.ai) — unified model routing, deep research, and multimodal workflows under one subscription.

Try Nomad AI →Launch Nomad Agent
What do you think?
Loading comments…