Skip to main content
skill

inference-serving-llama-cpp — Claude Code skill: inference

This skill guides local LLM inference with llama.cpp on CPUs, Apple Silicon, and AMD or Intel GPUs. It fits setups where CUDA is unavailable.

Install into Claude Code · claude-code-templates All methods and platforms ↓
npx claude-code-templates@latest --skill ai-research/inference-serving-llama-cpp
Open on GitHub

What inference-serving-llama-cpp does

The skill covers a llama.cpp workflow for GGUF models: build the runtime, obtain a model, run llama-cli, or expose it through llama-server. It also shows how to send requests to the OpenAI-compatible endpoint with curl.

Its examples include Metal, CUDA, and ROCm builds, GGUF quantization from 1.5 to 8 bits, batch input, grammar-constrained JSON, and context-size changes. Models can come from huggingface-cli or be converted from a Hugging Face directory. The listed dependency is llama-cpp-python, so that package is a prerequisite for the setup guidance.

What it helps with

  • run an LLM on a CPU-only machine
  • compile llama.cpp for Metal, CUDA, or ROCm
  • fetch a model in GGUF format
  • serve completions through an OpenAI-compatible API
  • constrain output to valid JSON

Example prompts for the agent

  • Set up llama-cli for models/llama-2-7b-chat.Q4_K_M.gguf with an interactive session.
  • Prepare a Metal build of llama.cpp for an Apple Silicon machine.
  • Start llama-server on port 8080 and show a curl request to its API.

How to install inference-serving-llama-cpp

1claude-code-templates

npx claude-code-templates@latest --skill ai-research/inference-serving-llama-cpp

2Skills CLI (Vercel)

npx skills add davila7/claude-code-templates --skill inference-serving-llama-cpp -a claude-code

3Manually: put the files in place

~/.claude/skills/inference-serving-llama-cpp/SKILL.md

Copy the whole skill folder; for one project use .claude/skills/inference-serving-llama-cpp/

Step by step, with commands for each platform: How to install skills in Claude Code: five ways

Questions about inference-serving-llama-cpp

How do I install inference-serving-llama-cpp in Claude Code?

Run npx claude-code-templates@latest --skill ai-research/inference-serving-llama-cpp, then run npx skills add davila7/claude-code-templates --skill inference-serving-llama-cpp -a claude-code. Use ~/.claude/skills/inference-serving-llama-cpp/SKILL.md afterward.

What does inference-serving-llama-cpp do?

It gives Claude Code guidance for running LLMs with llama.cpp on CPUs and non-NVIDIA hardware. The material covers GGUF models, quantization, command-line inference, and an OpenAI-compatible server.

Which hardware can inference-serving-llama-cpp use?

The covered setups include CPUs, Apple Silicon M1/M2/M3/M4, and AMD or Intel GPUs. Metal, CUDA, and ROCm builds are described, so NVIDIA hardware is not required when CUDA is unavailable.

Similar skills

All skills for AI and ML →

From the same set804

The whole set →

Project sponsors

Companies that keep this analytics open
Gold sponsor

Impressions, clicks and code copies — open statistics. We keep the numbers public for the same reason NeBlask itself is public. Become a sponsor