llama-cpp
Skill172 starsChanged 4 months agoMITView on GitHub
Operate, configure, benchmark, and troubleshoot llama.cpp across CPU, Metal, CUDA, HIP/ROCm, Vulkan, SYCL, and hybrid or multi-GPU systems. Use when installing or building llama.cpp, selecting or inspecting GGUF models, running llama-cli or bounded llama-completion, serving an OpenAI-compatible API with llama-server, tuning memory and performance, or diagnosing backend, context, template, and API failures. Do not use for model training or fine-tuning, general inference-framework selection, llama-cpp-python or other bindings, LlamaIndex, Ollama, or LM Studio operation.
11 other projects use a version of this.
Adopted by
Most recently taken up by
- ashleysbrain/skillstheir own version, first seen Nov 8, 2026
- delorenj/skillstheir own version, first seen Nov 7, 2026
- pedroiff0/awesome-skillstheir own version, first seen Sep 29, 2026
- mhiskall282/Securing-the-Digital-Mine-UNESCO-Projecttheir own version, first seen Sep 20, 2026
- Samin12/skillstheir own version, first seen Aug 14, 2026
- wm2313/my-skillstheir own version, first seen Jul 2, 2026
Used with
Projects with it also use llm-wiki, caveman and 1 more.
Other files people use alongside this one.
Files found in the same public projects as a version of this one, more often than they turn up anywhere else. Each project counts once, large collections count for less, and this file's own repository is left out.
devstefanchoSkillllm-wiki
Maintains an LLM-powered personal wiki (capture → raw → wiki → schema) that self-organizes from memos, AI conversations, and research. Use when user mentions wiki init, wiki capture, wiki ingest, wiki distill, wiki query, wiki lint, wiki update, 위키 초기화, 위키에 적어줘/메모, 이 대화 위키에 정리, 위키 추가, 위키 정리, 위키 질문, 위키 검사, 위키 업데이트, or wants to build/maintain a knowledge base.
Also in 3 projects that use this
MicrosoftSkillcaveman
Ultra-compressed response style that reduces output token count while preserving technical accuracy, with intensity levels and auto-clarity safety rules
Also in 3 projects that use this
GoogleSkillgrill-me
A relentless interview to sharpen a plan or design.
Also in 3 projects that use this
Other versions11 projects use a version of this.
Word for word · 0
None found.
Edited · 0
None found.
Wrote their own version · 11
- tdimino/claude-code-minoan★ 41same name
- maystudios/claude-skills★ 21same name
- delorenj/skills★ 17same name
- Samin12/skills★ 8same name
- julweber/ai_agent_skills★ 2same name
- Kubementat/ai_agent_skills★ 2same name
- ashleysbrain/skills★ 1same name
- Clay-HHK/claude-skills★ 1same name
- mhiskall282/Securing-the-Digital-Mine-UNESCO-Project★ 1same name
- pedroiff0/awesome-skills★ 1same name
1 more not listed
How matches are found. Word for word: the exact same text. Edited: shares passages with this file (“99% same” means 99% of its five-word phrases also appear here; 10% or more counts). Their own version: similar meaning, or, weakest, the same name. We can’t tell which project had it first. Projects are counted among the 200 most-starred candidates, and mentions are links to the repository we found, up to 50 per site, so both counts are a floor.
In this repository192 other files it gives its agents.
- agent-production-operations/AGENTS.mdAGENTS.md
- AGENTS.mdAGENTS.md
- forward-deployed-engineering/AGENTS.mdAGENTS.md
- production-excellence/AGENTS.mdAGENTS.md
- product-lifecycle/AGENTS.mdAGENTS.md
- tailscale/AGENTS.mdAGENTS.md
- workflow-architect/AGENTS.mdAGENTS.md
- llms.txtllms.txt
- actuarial-risk-modelingSkill
- adr-authoringSkill
- agent-councilSkill
- agent-evals-and-observabilitySkill
- agent-production-operationsSkill
- agent-skillsSkill
- ai-governanceSkill
- ai-operating-economicsSkill
- amazon-memoSkill
- analog-occultismSkill
- anydocSkill
- api-design-and-evolutionSkill
- artifact-pyramidsSkill
- ascii-city-engineSkill
- autogenSkill
- backend-engineeringSkill
- binary-analysisSkill
- bmadSkill
- brand-designerSkill
- c4-diagrammingSkill
- camera-hackingSkill
- capacity-and-cost-engineeringSkill
- chief-of-staff-methodologySkill
- cli-builderSkill
- cncf-landscapeSkill
- code-reviewSkill
- color-managementSkill
- community-guidesSkill
- conditional-customer-successSkill
- confluence-cliSkill
- constrained-optimizationSkill
- crewaiSkill
- crmSkill
- crowdsecSkill
- cryptpadSkill
- cyberpunkSkill
- daily-life-discoverySkill
- data-architectSkill
- data-cleaningSkill
- data-engineeringSkill
- data-scientistSkill
- de-spinSkill
- digital-twinSkill
- docker-composeSkill
- documentsSkill
- dsm5Skill
- dspySkill
- electronicsSkill
- emailSkill
- enterprise-architectureSkill
- epubSkill
- esp32-developmentSkill
- The first 60 shown.
The file
Show its rules and text
We split this skill into the rules it gives an agent
16 rules. 0 are common, 10 are distinctive, and 6 are very specific to this project.
0
Common
Most of the 8 edited versions we read keep these.
10
Distinctive
This author's own choices. Worth a look.
6
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Distinctive: line 16
Treat every launch recipe as a hypothesis about a specific build, model, host, and workload.
- Very specific: line 21
Read the installed command's --help before using a flag from documentation.
- Very specific: line 23
Verify the backend from --list-devices and model-load logs.
- Distinctive: line 24
Start with a bounded CLI smoke test on loopback or local input.
- Distinctive: line 25
Call work complete only at the requested boundary: binary, model load, generated output, API response, benchmark comparison, or diagnosed …
- Very specific: line 29
Use ml-engineering for model training, fine-tuning, broad quantization methodology, evaluation design, or choosing among llama.cpp, vLLM, …
- Distinctive: line 33
Run only commands that exist in the installed build:
- Very specific: line 59
Use llama-completion for unattended raw completions on builds that separate that frontend from interactive llama-cli.
- Distinctive: line 86
Do not call one quantization universally best.
- Distinctive: line 102
Do not infer accelerator use from the command line alone.
- Distinctive: line 103
Do not expose an unauthenticated server beyond loopback by accident.
- Very specific: line 105
Do not enable llama-server built-in filesystem or shell tools in an untrusted environment.
- Distinctive: line 106
Do not override a chat template until model metadata, the original model card, and rendered behavior have been inspected.
- Distinctive: line 108
Do not compare benchmark numbers from different models, quants, commits, backends, contexts, batches, thermal states, or workloads as if …
- Very specific: line 109
Do not treat llama-bench tokens per second as TTFT.
- Distinctive: line 110
Do not claim a larger configured context preserves quality unless the model and scaling behavior support it and the workload was evaluated.
“Common” is measured: kept by at least 6 in 10 of the 8 edited versions of this file we could read. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
llama.cpp Operations
Treat every launch recipe as a hypothesis about a specific build, model, host, and workload. Discover capabilities from the installed binary, inspect the model and startup logs, then measure the requested boundary.
Operating contract
- Record the exact llama.cpp version or commit, installation method, OS and architecture, CPU and RAM, accelerator and memory, driver/toolkit, available devices, model provenance and quantization, intended context, concurrency, and workload.
- Read the installed command's
--helpbefore using a flag from documentation. llama.cpp flags, defaults, binary names, and REST behavior change frequently. - Confirm the target, scope, and rollback path before acting. Read-only discovery may proceed without confirmation.
- Verify the backend from
--list-devicesand model-load logs. A successful build or an accepted GPU flag does not prove acceleration is active. - Start with a bounded CLI smoke test on loopback or local input. Establish a measured baseline before changing threads, batches, context, cache types, offload, or split mode.
- Call work complete only at the requested boundary: binary, model load, generated output, API response, benchmark comparison, or diagnosed failure with evidence.
When not to use
Use ml-engineering for model training, fine-tuning, broad quantization methodology, evaluation design, or choosing among llama.cpp, vLLM, TGI, and other engines. Use the relevant product skill for Ollama, LM Studio, or LlamaIndex. Use binding-specific documentation for llama-cpp-python, node-llama-cpp, or other language wrappers.
Read-only preflight
Run only commands that exist in the installed build:
llama-cli --version
llama-cli --help
llama-cli --list-devices
llama-server --version
llama-server --help
llama-bench --helpAlso inspect host memory and accelerator state with native OS/vendor tools. Record results in the operation record. If no binary exists, choose an installation path only after reading installation and backends.
Route the task
| Need | Read first |
| Install, build, choose CPU/Metal/CUDA/HIP/Vulkan/SYCL, Docker, or prove backend use | installation and backends |
| Acquire, convert, inspect, license-check, quantize, or fit a GGUF model | models, GGUF, and memory |
Run llama-cli, expose llama-server, call compatible APIs, use templates, structured output, embeddings, reranking, or tools | inference and serving |
| Tune threads, batches, context, cache, offload, concurrency, or multi-GPU and compare results | performance and benchmarking |
| Diagnose load, backend, OOM, speed, context, template, output, or API failures | troubleshooting |
| Check the evidence, research date, upstream revision, or refresh rule behind a claim | source index |
Batch inference versus interactive chat
Use llama-completion for unattended raw completions on builds that separate
that frontend from interactive llama-cli. The installed CLI may advertise a
shared flag in help and still reject it at runtime; presence of
--no-conversation alone is not proof of batch support. Never fall back to an
interactive frontend when the completion target is missing. Read
bounded batch inference before using
scripts/llama_batch.py. Its plan command performs bounded read-only capability
checks; run writes a new private output directory and consumes GPU resources.
The helper currently supports POSIX CUDA0 with full model offload; other backends
use separately verified workflows.
Bound process wall time and combined stdout/stderr bytes, pass EOF stdin, retain
failed logs, and stop only the process group you launched. A token budget alone
does not bound an interactive prompt loop. Do not accumulate runtime output in
an unbounded capture_output=True buffer. Never hide a GPU fallback or call a
prepared plan an executed inference pass.
Safe workflow
1. Select and verify the installation
Prefer a supported package or release binary when its compiled backend matches the target. Build from a pinned revision when backend options, portability, or reproducibility require it. Use Docker when host isolation is useful and device passthrough is understood. After installation, capture version, help, device listing, and a model-load log before claiming success.
2. Select and inspect the model
Accept a user-specified local GGUF path or Hugging Face repository. Before downloading, record the repository, revision, file, size, model card, license, base-model lineage, and quantizer when available. Inspect GGUF metadata and model-load output for architecture, quantization, context, tokenizer, chat template, and sidecars. Plan capacity from actual file size plus KV cache, context, batch/concurrency, compute buffers, and backend overhead; parameter count alone is insufficient.
Do not call one quantization universally best. Start from workload quality and capacity constraints, avoid requantizing an already quantized model when a higher-precision source is available, and compare candidate quants with the same task-quality and performance workload.
3. Prove local inference
Use a short, fixed prompt and bounded token count. Record the exact command, seed or sampling settings, startup log, output, timings, and whether the expected backend loaded. If the model has a chat template, test the template path required by the intended workload rather than treating plain completion as chat proof.
4. Prove serving
Bind to 127.0.0.1 for the first launch. Wait for /health to report ready, query /v1/models, then make a representative request using a reported model identifier. A listening process or HTTP 200 from a shallow endpoint is not inference proof. External exposure requires an explicit decision about bind address, API keys, TLS or reverse proxy, firewall, CORS, rate limits, logging, and whether experimental built-in tools are disabled.
5. Tune one dimension at a time
Preserve a baseline before changing context size, generation and batch threads, logical or physical batch size, GPU layers, KV cache type/offload, Flash Attention, parallel slots, or multi-GPU split. Use llama-bench for prompt-processing and token-generation comparisons, and an end-to-end client or server benchmark for TTFT and request latency. Record each comparison in the benchmark template.
Hard boundaries
- Do not infer accelerator use from the command line alone; require device and load-log evidence.
- Do not expose an unauthenticated server beyond loopback by accident. Authentication is not a substitute for network and TLS controls.
- Do not print or
teeunredacted unit definitions, process environments, environment-file contents, API keys, or other credential-bearing configuration. Prefer redacted metadata; never retain secrets merely as evidence. If exact rollback requires a secret-bearing backup, keep it temporarily outside the repository with mode0600, minimum retention, and explicit cleanup. Do not publish raw or low-entropy secret hashes. - Do not enable
llama-serverbuilt-in filesystem or shell tools in an untrusted environment. - Do not override a chat template until model metadata, the original model card, and rendered behavior have been inspected.
- For
finish_reason: "length"with populatedreasoning_contentand emptycontent, inspect the access-controlled raw response but report only sanitized field state, lengths,finish_reason, andusage. From the same baseline, run separate one-variable probes: a bounded output-budget increase and, when the exact template supports it,chat_template_kwargs.enable_thinking: false. In streaming, inspect the documented schema forchoices[].delta.reasoning_content,choices[].delta.content, and terminalchoices[].finish_reason; record each as absent, null, empty, or populated rather than assuming presence. Treatreasoning_effort: "none"and server-side reasoning flags as version-sensitive, source-verified alternatives, not portable defaults. - Do not compare benchmark numbers from different models, quants, commits, backends, contexts, batches, thermal states, or workloads as if only one variable changed.
- Do not treat
llama-benchtokens per second as TTFT; its measurements exclude tokenization and sampling. - Do not claim a larger configured context preserves quality unless the model and scaling behavior support it and the workload was evaluated.
Exit criteria
The task is complete when the requested boundary is evidenced: the expected binary and backend are observed; the selected model's provenance and fit are recorded; a bounded prompt returns usable output; a server reaches readiness and completes a representative API request; a tuning change beats or preserves the declared metrics under matched conditions; or a failure is reduced to a supported cause with a safe next action. List any stronger boundary that was not tested.
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

