Serving tool calls from open models: vLLM parsers and llama.cpp templates
Answer: vLLM's quickstart starts the server with --enable-auto-tool-choice, --tool-call-parser llama3_json and a --chat-template from the vLLM examples directory. llama.cpp supports function calling for all models with native and generic handlers.
vLLM
vLLM supports auto, required (as of vLLM 0.8.3) and none for tool_choice. The client is OpenAI(base_url="http://localhost:8000/v1", api_key="dummy").
llama.cpp
Native formats are listed for Llama 3.x, Functionary, Hermes and Qwen 2.5; other templates use the generic handler. Use --chat-template-file to override the template when appropriate.
See also
- ao-tools-openai-function-calling
- ao-tools-ollama-tool-calling
- ao-tools-parallel-tool-calls
- ao-tools-tool-choice-across-providers
Claims
- id: C1 claim: vLLM uses a tool-call parser flag. source: S1 evidence: "--tool-call-parser llama3_json"
- id: C2 claim: vLLM lists required from 0.8.3. source: S1 evidence: "
required(as ofvllm>=0.8.3)"
- id: C3 claim: llama.cpp can override the template. source: S2 evidence: "Use
--chat-template-fileto override the template when appropriate"
Sources
- [S1] Tool calling (vLLM docs). vllm-project/vllm (GitHub). https://github.com/vllm-project/vllm/blob/main/docs/features/tool_calling.md . License: Apache-2.0. Accessed 2026-11-16.
- [S2] Function calling (llama.cpp docs). ggml-org/llama.cpp (GitHub). https://github.com/ggml-org/llama.cpp/blob/master/docs/function-calling.md . License: MIT. Accessed 2026-11-16.
License: this note is CC BY 4.0 (https://creativecommons.org/licenses/by/4.0/). Summary by iinventedlight (AI-assisted). Sources: vllm-project/vllm (GitHub), Tool calling (vLLM docs), Apache-2.0 (https://raw.githubusercontent.com/vllm-project/vllm/main/LICENSE); ggml-org/llama.cpp (GitHub), Function calling (llama.cpp docs), MIT (https://raw.githubusercontent.com/ggml-org/llama.cpp/master/LICENSE). Copyright (c) 2023-2026 The ggml authors. Text was condensed and changed from the originals.
License: CC-BY-4.0 · Summary by iinventedlight (AI-assisted). Sources: vllm-project/vllm (GitHub), Tool calling (vLLM docs), Apache-2.0 (https://raw.githubusercontent.com/vllm-project/vllm/main/LICENSE); ggml-org/llama.cpp (GitHub), Function calling (llama.cpp docs), MIT (https://raw.githubusercontent.com/ggml-org/llama.cpp/master/LICENSE). Copyright (c) 2023-2026 The ggml authors.
Cite this
iinventedlight. 2026. "Serving tool calls from open models: vLLM parsers and llama.cpp templates." iinventedlight Library, iil:note:9xhcqx0g, version of 2026-11-16. https://iinventedlight.com/library/notes/ao-tools-vllm-tool-parsers/. License: CC-BY-4.0.
@misc{iil_note_9xhcqx0g,
author = {{iinventedlight}},
title = {{Serving tool calls from open models: vLLM parsers and llama.cpp templates}},
howpublished = {iinventedlight Library},
year = {2026},
date = {2026-11-16},
url = {https://iinventedlight.com/library/notes/ao-tools-vllm-tool-parsers/},
note = {Permanent ID iil:note:9xhcqx0g. License: CC-BY-4.0.},
}
Spotted a mistake? Use the MCP feedback tool or email hello@iinventedlight.com. Or Report a correction (no account needed).
For language models and agents: start at /llms.txt | /agents.md | /.well-known/agent-library.json. This page in Markdown: /library/notes/ao-tools-vllm-tool-parsers.md.