darknecrocities/skillbuilder/local-llm

Claude Code and agent skill by darknecrocities/skillbuilder

Trust tier 2
  • community
LLM review pending
Source check pending

Checking that the SKILL.md file is still in the repository.

Local LLM architecture, quantized inference (GGUF Q4_K_M/Q8_0), Ollama, llama.cpp, Apple Silicon MLX, vLLM, SGLang, WebLLM/Transformers.js, KV-cache tuning, GBNF structured grammars, in-process local RAG, and 3-tier hybrid routing.

Install

npx vskill@latest install darknecrocities/skillbuilder/local-llm

SKILL.md

The same SKILL.md was published earlier as darknecrocities/skillbuilder/local-llm.

Local LLM & Edge Inference (/local-llm)

Philosophy: Compute exact VRAM + KV-cache budgets before loading weights, enforce GBNF/schema grammars at logit sampling, keep RAG in-process, and never silently leak local prompts to cloud APIs.

1. Progressive Disclosure References

ResourcePurpose
references/quantized-inference-and-gguf.mdQ4_K_M/Q5_K_M/Q8_0 sizing math, Apple MLX, Ollama SSE cancellation & health probes.
references/serving-engines-and-kv-cache.mdvLLM / SGLang PagedAttention, Transformers.js WebGPU, q8_0 KV-cache, prefix caching, speculative decoding.
references/gbnf-grammars-and-local-rag.mdGBNF logit-level JSON schemas, sqlite-vec & DuckDB vss in-process hybrid RAG.
scripts/verify_local_llm_hygiene.pyAudits degraded Q2/Q3 quantizations, missing timeouts, -ngl 0, unconstrained JSON prompts, and unbounded num_ctx.

2. Heterogeneous Inference Runtime Matrix

RuntimeFormatsBest TargetKey Capabilities
`llama.cpp` (`llama-server`)GGUF (Q4_K_M+)Linux / Docker / CUDAContinuous batching (-cb), -ngl 999, GBNF grammars, -fa.
`Ollama`GGUFWorkstations / Local DevDeclarative Modelfile, OpenAI /v1, format JSON schema.
Apple Silicon `MLX`MLX 4-bit / 8-bitmacOS M1–M4 UMAZero-PCIe-copy Metal execution (80–130+ tok/s).
`vLLM` / `SGLang`FP8 / AWQ / GPTQMulti-user GPU serversPagedAttention, RadixAttention prefix reuse, high concurrency.
`WebLLM` / `Transformers.js`Wasm + WebGPUClient Browsers100% private in-browser execution inside Web Workers.

3. Core Quantization, RAG & Hybrid Routing Invariants

  1. VRAM Budget Formula: $\text{VRAM}_{\text{req}} = (\text{Params} \times \text{Bpw} / 8) + \text{KV Cache} + \text{Scratch (0.4–1.0 GB)}$. Default to Q4_K_M (chat/routing), Q5_K_M (code/logic), or Q8_0 (embeddings); reject Q2/Q3 collapse. Pin num_ctx (8192 default) and enable -fa + q8_0 KV cache for long contexts.
  2. Deterministic GBNF / Schema Grammars: Constrain local 3B–8B JSON output at token logit sampling (grammar in llama.cpp, format in Ollama) so markdown fences and malformed JSON cannot be sampled.
  3. In-Process Local RAG: Use sqlite-vec or DuckDB vss (doc_hash + embedding_model version tracking, top_k <= 6) instead of heavyweight external vector DB containers.
  4. 3-Tier Hybrid Cascade: Route Tier 1 (3B edge <150ms) -> Tier 2 (32B–70B local) -> Tier 3 (Gemini Frontier) ONLY with 3s/15s timeouts and explicit AI_PRIVACY_MODE=hybrid_consent (/ai-integration).

4. Automated Local LLM Hygiene Audit

bash
python3 skills/local-llm/scripts/verify_local_llm_hygiene.py --path .

Security

  • Security scanPassed, 100 of 100Pattern checks on the skill's files.
  • Model reviewNot runA model review is scheduled for the next rescan.

Quality evaluation

  • Task evaluationNot runNo evaluation yet. Run one in Skill Studio.

Source

Popularity

7-day trend score
0

Not refreshed yet.

Works with

Any agent vskill installs to: 56 targets in all. These 39 have a page on this site.

  • Claude Code
  • Cursor
  • GitHub Copilot
  • Windsurf
  • Codex
  • Gemini CLI
  • Cline
  • Amp
  • Roo Code
  • Goose
  • Continue
  • Kilo Code
  • Junie
  • Trae
  • OpenHands
  • Qwen Code
  • AI Agent
  • Tabnine Chat
  • Sourcegraph Cody
  • Amazon Q
  • Firebase Genkit
  • Sweep
  • Devin
  • Phind
  • Mentat
  • Claude Desktop
  • Aider
  • GPT Pilot
  • Plandex
  • bolt.new
  • v0
  • Replit Agent
  • Anse
  • TypingMind
  • BetterChatGPT
  • LibreChat
  • Warp AI
  • Pieces
  • Fig AI
Embed badge
vskill VERIFIED badge
[![vskill VERIFIED](https://verified-skill.com/api/v1/skills/darknecrocities/skillbuilder/local-llm/badge)](https://verified-skill.com/skills/darknecrocities/skillbuilder/local-llm)

Something wrong with this skill or its page? Tell us.