Back to Skills

llama-cpp

Runs LLM inference on CPU, Apple Silicon, and consumer GPUs without NVIDIA hardware. Use for edge deployment, M1/M2/M3 Macs, AMD/Intel GPUs, or when CUDA is unavailable. Supports GGUF quantization (1.5-8 bit) for reduced memory and 4-10× speedup vs PyTorch on CPU.

3,579stars289forksUpdated 2/18/2026

Security Assessment

Safe(100/100)
Security Score100/100

About llama-cpp

The llama-cpp skill provides a lightweight solution for running large language model (LLM) inference on CPUs, Apple Silicon, and non-NVIDIA GPUs, offering a viable alternative for edge deployment and environments where CUDA is unavailable. It supports GGUF quantization formats to reduce memory usage while delivering significant speedups compared to PyTorch on CPU, with performance improvements of up to 10x. This skill is designed for users who need to deploy LLM inference on edge devices, such as Raspberry Pi or embedded systems, or on machines without NVIDIA hardware, including AMD or Intel GPUs and Apple Silicon-based Macs (M1/M2/M3). It enables high-performance model inference without requiring Docker or Python, making it highly suitable for resource-constrained environments where ease of deployment is critical.

Key features of llama-cpp include compatibility with various hardware platforms, including Apple Silicon, AMD/Intel GPUs, and CPUs. It provides multiple quantization options to balance performance and memory usage, allowing users to choose between faster speeds or higher quality based on their needs. With support for Metal (Apple Silicon), CUDA (NVIDIA), and ROCm (AMD), users can take advantage of hardware acceleration for improved inference speeds. The skill supports both interactive and batch processing modes, with the flexibility to offload layers of models to GPUs for even greater performance. It also includes a server mode for deploying inference APIs compatible with OpenAI’s API, enabling easy integration with other applications.

This skill is ideal for users deploying machine learning models in environments where GPU access is limited or unavailable, such as edge devices, embedded systems, and non-NVIDIA hardware configurations. It is also well-suited for developers looking for a straightforward, lightweight deployment option without the complexity of Docker or Python dependencies.

FAQ

What hardware does llama-cpp support?

llama-cpp supports CPU-only machines, Apple Silicon (M1/M2/M3), AMD and Intel GPUs, and edge deployment environments such as Raspberry Pi. It does not require NVIDIA hardware or CUDA.

How do I accelerate inference with llama-cpp?

Inference can be accelerated on supported hardware by using Metal for Apple Silicon, CUDA for NVIDIA GPUs, or ROCm for AMD GPUs. You can offload specific layers of the model to these accelerators to improve performance.

Can llama-cpp run on NVIDIA GPUs?

While llama-cpp is primarily designed for non-NVIDIA hardware, it does support NVIDIA GPUs using CUDA. However, for maximum throughput on NVIDIA GPUs, TensorRT-LLM may be a better choice.

What quantization formats does llama-cpp support?

llama-cpp supports multiple GGUF quantization formats, including Q4_K_M (default), Q4_K_S, Q5_K_M, Q6_K, Q8_0, and Q2_K, which allow for trade-offs between speed, quality, and memory usage.

Can I deploy llama-cpp on embedded systems?

Yes, llama-cpp is designed for edge and embedded systems. It is lightweight, does not require Docker or Python, and can run efficiently on devices like Raspberry Pi and other embedded hardware.

Install llama-cpp

Download and extract the skill files to your .claude/skills/ directory.

Quick Setup:

  1. Copy the skill folder to .claude/skills/
  2. Claude will automatically detect and use the skill