Skip to content

In development. Expect rough edges and changes. The source code is not public yet.

Docker 7 min read How-to mediumAdept

Run, Test, and Evaluate Models and MCP Locally with Docker + Promptfoo

Promptfoo, Docker Model Runner and Docker MCP Toolkit can be combined to evaluate LLM apps entirely on a dev machine. Three worked configs are shown. The first compares local Gemma3 against Claude Opus 4.1 using llm-rubric and similarity assertions, graded by local smollm3 and mxbai embeddings instead of OpenAI. The second tests MCP tools directly (GitHub, Fetch, Playwright, YouTube transcript) through the MCP gateway. The third red-teams a GitHub-summarizer agent with MCP, PII, BOLA and BFLA plugins plus jailbreak and prompt-injection strategies, which exposed a tool-discovery vulnerability that was fixed with a prompt guideline.

Assumes: Docker DesktopLLM prompting basicsModel Context Protocol

Related posts

  • Tool Calling with Local LLMs: A Practical Evaluation

    Docker mediumAdept

    Docker benchmarked 21 local and hosted LLMs on tool calling using model-test, a harness that runs shopping-cart scenarios with multiple acceptable tool-call sequences inside a 5-round agent loop and scores invocation, tool selection and parameter accuracy as an F1 score. Over 3,570 tests on an M4 Max MacBook Pro, GPT-4 led at 0.974. Qwen3 14B was the best local model at 0.971 but took about 142 seconds per interaction, and Qwen3 8B reached 0.933 at roughly half that latency. Tool-tuned models such as watt-tool 8B and xLAM 8B scored poorly, and quantized variants performed no worse than full-precision ones.

  • We got local models to triage the OpenClaw repo for FREE!*

    Hugging Face mediumAdept

    Local open-weight models running in an agent harness on an NVIDIA GB10 (DGX Spark) can triage OpenClaw's GitHub issues and PRs in real time, routing only relevant topics to a maintainer via Discord. The localpager pipeline mirrors the repo with gitcrawl into SQLite, queues classification jobs, and runs a pi-based agent that can inspect code through a read-only, injection-resistant 'reposhell' before emitting schema-constrained labels; notification routing stays deterministic. On a 330-item consensus-labeled eval set, gemma-4-26b-a4b gave the highest recall (0.905) at 1.41 s/row with vLLM NVFP4 serving, while qwen3.6-35b-a3b gave better precision (0.831) and F1 (0.824) at ~10x the latency. A GPT-5.5 OpenClaw cron job re-labels every 2 hours to track false positives and negatives in production.

  • Getting Started with the Labs AI Tools for Devs Docker Desktop Extension

    Docker mediumAdept

    The Labs AI Tools for Devs Docker Desktop extension runs LLM prompts against local projects. Prompts are referenced by git ref or URL, or loaded as local files. A prompt is a markdown file with system and user sections, and project context such as languages and files is injected through mustache templates. Tools the LLM can call are defined as Docker images that get bind-mounted into the project and receive a JSON payload as their first argument. Sample prompts cover Dockerfile generation, runbooks, ESLint and Pylint fixes.

  • Breaking Free From AI Vendor Lock-in: Integrating GitHub Models with Docker cagent

    Docker mediumAdept

    Docker cagent, an open-source multi-agent runtime driven by declarative YAML, can use GitHub Models as a custom OpenAI-compatible provider. You point base_url at https://models.github.ai/inference and pass a GitHub personal access token as the API key, so one credential reaches models from OpenAI, Meta, Microsoft, Anthropic and DeepSeek. The walkthrough builds a podcast-generator agent whose root agent delegates to researcher and scriptwriter sub-agents that use DuckDuckGo and filesystem MCP servers through the Docker MCP gateway. The agent is then shared through Docker Hub with cagent push, pull and run.

  • Run Gemma 3 with Docker Model Runner: Fully Local GenAI Developer Experience

    Docker mediumAdept

    Docker Model Runner (in Docker Desktop for macOS 4.40.0+) exposes an OpenAI-compatible API on localhost, so Gemma 3 can be pulled with `docker model pull ai/gemma3` and called through the standard OpenAI SDK by pointing baseURL at http://localhost:12434/engines/v1. A sample Comment Processing System uses it to generate synthetic user feedback, categorize sentiment, cluster comments with mxbai-embed-large embeddings, extract feature ideas as JSON and draft support replies, all with no external API calls. Per-task temperature and token limits can be tuned freely because local inference carries no per-token cost or rate limit.

The quest for software engineering knowledge.

Look:
Layout: