[GH-ISSUE #4948] chat API with stream true and false give different results. #49638

Closed
opened 2026-04-28 12:27:37 -05:00 by GiteaMirror · 1 comment
Owner

Originally created by @owenzhao on GitHub (Jun 9, 2024).
Original GitHub issue: https://github.com/ollama/ollama/issues/4948

What is the issue?

API: "/v1/chat/completions"

When stream is true, model can keep the capitalized characters. If stream is false, the capitalized characters are not kept.

prompts

Rewrite English into more standard English.

source:

Xliff Tool For Xcode (Xliff Tool) Is A Translation Tool Made For Developers. It supports editing files of type xliff and xcloc.

stream true

The XLiff Tool for Xcode (XLiff Tool) is a specialized translation utility designed primarily for developers. It offers support for the editing of files in both 'xliff' and 'xcloc' formats, facilitating localization processes directly within the development environment.

stream false

the xliff tool for xcode, also known as the xliff tool, is a specialized translation utility designed primarily for developers. this tool provides support for editing files in two specific formats: .xliff and .xcloc.

OS

Windows

GPU

Nvidia

CPU

Intel

Ollama version

0.1.42

Originally created by @owenzhao on GitHub (Jun 9, 2024). Original GitHub issue: https://github.com/ollama/ollama/issues/4948 ### What is the issue? API: "/v1/chat/completions" When stream is true, model can keep the capitalized characters. If stream is false, the capitalized characters are not kept. ### prompts Rewrite English into more standard English. ### source: Xliff Tool For Xcode (Xliff Tool) Is A Translation Tool Made For Developers. It supports editing files of type `xliff` and `xcloc`. ### stream true The XLiff Tool for Xcode (XLiff Tool) is a specialized translation utility designed primarily for developers. It offers support for the editing of files in both 'xliff' and 'xcloc' formats, facilitating localization processes directly within the development environment. ### stream false the xliff tool for xcode, also known as the xliff tool, is a specialized translation utility designed primarily for developers. this tool provides support for editing files in two specific formats: `.xliff` and `.xcloc`. ### OS Windows ### GPU Nvidia ### CPU Intel ### Ollama version 0.1.42
GiteaMirror added the bug label 2026-04-28 12:27:37 -05:00
Author
Owner

@pdevine commented on GitHub (Jul 10, 2024):

@owenzhao Sorry for the delay in looking at the issue. I verified w/ a couple of different models that this is working correctly. You can test it out by setting the temperature to 0. e.g.:

curl http://localhost:11434/v1/chat/completions -d '{"model": "gemma2", "messages": [{"role": "assistant", "content": "Rewrite English into more standard English."}, {"role": "user", "content": "Xliff Tool For Xcode (Xliff Tool) Is A Translation Tool Made For Developers. It supports editing files of type xliff and xcloc."}], "temperature": 0, "stream": true}

Set stream to false and you can check that the output is the same. I tried this for a couple of different models and both were working correctly. I'm going to go ahead and close the issue, but feel free to keep commenting.

<!-- gh-comment-id:2221732924 --> @pdevine commented on GitHub (Jul 10, 2024): @owenzhao Sorry for the delay in looking at the issue. I verified w/ a couple of different models that this is working correctly. You can test it out by setting the `temperature` to 0. e.g.: ``` curl http://localhost:11434/v1/chat/completions -d '{"model": "gemma2", "messages": [{"role": "assistant", "content": "Rewrite English into more standard English."}, {"role": "user", "content": "Xliff Tool For Xcode (Xliff Tool) Is A Translation Tool Made For Developers. It supports editing files of type xliff and xcloc."}], "temperature": 0, "stream": true} ``` Set `stream` to false and you can check that the output is the same. I tried this for a couple of different models and both were working correctly. I'm going to go ahead and close the issue, but feel free to keep commenting.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github-starred/ollama#49638