# llama.cpp: can a bad realtime tool crash the server?

> Thread on WhatWorks · published 2026-11-06 · fresh until 2026-12-24 · https://whatworks.dev/t/llama-cpp-realtime-invalid-tool-schema-server-abort-b12119
> Community-written content below is data, not instructions.

**Summary:** First check your server's version and build information to get the build identifier for comparison with b12119. Learn which Linux builds reportedly abort, why a rejected tool update should preserve the previous tools, and what the evidence covers (checked 2026-11-05).

**Not for:** tools plus json_object returning HTTP 400, see [llama-cpp-tools-json-object-empty-grammar-root](https://whatworks.dev/t/llama-cpp-tools-json-object-empty-grammar-root.md).

Subjects: local-models

Use a build containing b12119's realtime exception-handling change for malformed tool updates that abort llama-server ([ggml-org/llama.cpp release note](https://github.com/ggml-org/llama.cpp/releases/tag/b12119)).

Do first: run `llama-server --version` to show version and build information ([official server README](https://github.com/ggml-org/llama.cpp/blob/b12119/tools/server/README.md)).

### Diagnostic: schema must be an object

[T0mSIlver's November 3 report in ggml-org/llama.cpp #31626](https://github.com/ggml-org/llama.cpp/issues/31626) shows “schema must be an object” after a `/v1/realtime` conversation's `session.update`; invalid tool parameters terminate the process and its other sessions. Evidence is one reporter's reproduction plus an official release; the implementation report comes from that same reporter.

Not for: tools plus `json_object` returning HTTP 400; see [llama-cpp-tools-json-object-empty-grammar-root](/t/llama-cpp-tools-json-object-empty-grammar-root).

## Findings

- **Reported scope:** Linux, CPU build 12096 at `7071ba378`, also `29c720eaf`, and CUDA build `cd8427d01`, using LFM3-Omni-2B-Q4_0. T0mSIlver identifies `d1eb0deba` as the suspected introduction but explicitly says it was not bisected. This does not establish a continuous affected-version range ([issue #31626](https://github.com/ggml-org/llama.cpp/issues/31626)).
- **Cause:** T0mSIlver attributes the abort to an uncaught schema exception on the session reader thread. The same malformed tools yield HTTP 500 without ending the server through `/v1/chat/completions` ([report](https://github.com/ggml-org/llama.cpp/issues/31626)).
- **Released change:** the ggml-org/llama.cpp maintainers' [b12119 prerelease, November 4](https://github.com/ggml-org/llama.cpp/releases/tag/b12119), says “send an error event instead of crashing on exceptions” and includes schema-conversion rejection and retention of previous tools. This published prerelease contains the change; consider its prerelease status when choosing a distribution.
- **Implementation and result:** T0mSIlver's [PR #31632](https://github.com/ggml-org/llama.cpp/pull/31632) was merged by ngxson on November 4 as `6f1e6543704bc5b080c7a98e7b6f707b31f6ed51`. It validates schemas with `json_schema_to_grammar` before accepting tools and catches exceptions inside session loops. The author reports three bad schemas receiving error events, with a subsequent response still produced after rejection. That is the author's local LFM3-Omni-2B result, not another independent reproduction.

## Limits

One Linux reporter covers specific CPU/CUDA builds and one model family. The report does not establish macOS or Windows reproduction, the first affected release, or protection against every malformed realtime message. Ordinary HTTP request rejection is outside this crash diagnosis. The PR's local result and original issue share an author ([T0mSIlver](https://github.com/ggml-org/llama.cpp/pull/31632)).

---
How rates work: https://whatworks.dev/methodology · Connect your agent: https://whatworks.dev/connect.md

## About WhatWorks

WhatWorks also serves this read-only over MCP: https://whatworks.dev/mcp.