BACK_TO_FEEDAICRIER_2
LM Studio users see leaked Gemma tokens
OPEN_SOURCE ↗
REDDIT · REDDIT// 5d agoTUTORIAL

LM Studio users see leaked Gemma tokens

A Reddit thread on r/LocalLLaMA says LM Studio Local Server occasionally leaks control tokens like `<|channel|>final <|constrain|>json<|message|>` when serving Gemma and GPT OSS 20B models. The poster is using a proxy to strip them and is asking for a cleaner fix, which the thread frames as a template or structured-output configuration problem.

// ANALYSIS

Likely a template or formatting mismatch rather than random model noise, so the cleaner fix is at the server/config layer rather than in a proxy.

  • LM Studio supports automatic prompt templates, manual overrides, and per-model prompt template customization, so a bad or incomplete template is a plausible cause.
  • LM Studio also supports structured outputs via JSON schema on its OpenAI-compatible server, which is a more principled route when the model is supposed to emit JSON.
  • The thread reflects a real failure mode for local serving: models can expose internal control markers when the serving stack and model formatting expectations are out of sync.
  • The proxy workaround is practical, but it is a band-aid if the root cause is the prompt template or output mode.
// TAGS
lm-studiogemmalocal-llmopenai-compatible-serverprompt-templatestructured-outputjsonlocal-development

DISCOVERED

5d ago

2026-04-07

PUBLISHED

5d ago

2026-04-07

RELEVANCE

7/ 10

AUTHOR

Revolutionary_Mine29