[GH-ISSUE #1508] [BUG]: Only first letter or word is shown as response from LLM #967

Closed
opened 2026-02-22 18:22:27 -05:00 by yindo · 1 comment
Owner

Originally created by @diegodambra on GitHub (May 23, 2024).
Original GitHub issue: https://github.com/Mintplex-Labs/anything-llm/issues/1508

How are you running AnythingLLM?

Docker (remote machine)

What happened?

LLM returns full response, but AnythingLLM interface only shows first letter or word. The interface may display the full response, but only until I navigate away, when I return to the chat, the response is now first letter/word. Workspace Chat always list responses with first letter/word.

The Sqllite DB table workspace_chats also reflects the issue, example:
36|2|what llm are you?|{"text":"I","sources":[],"type":"chat"}|1|2|1716385031805|1716385031805||

Response from endpoint chats also shows only first letter/word is returned to interface:
{ "type": "chat", "role": "assistant", "content": "I", "sources": [], "chatId": 35, "sentAt": 1716384827, "feedbackScore": null }
where endpoint stream-chat did return the same response given by LLM:
data: {"uuid":"d3d88381-1a39-4558-bf20-9776da45be63","sources":[],"type":"textResponseChunk","textResponse":"I","close":false,"error":false} data: {"uuid":"d3d88381-1a39-4558-bf20-9776da45be63","sources":[],"type":"textResponseChunk","textResponse":"","close":true,"error":false} data: {"uuid":"d3d88381-1a39-4558-bf20-9776da45be63","sources":[],"type":"textResponseChunk","textResponse":" am a large language model, trained by Google. \n","close":false,"error":false} data: {"uuid":"d3d88381-1a39-4558-bf20-9776da45be63","sources":[],"type":"textResponseChunk","textResponse":"","close":true,"error":false} data: {"uuid":"d3d88381-1a39-4558-bf20-9776da45be63","sources":[],"type":"textResponseChunk","textResponse":"","close":true,"error":false} data: {"uuid":"d3d88381-1a39-4558-bf20-9776da45be63","type":"finalizeResponseStream","close":true,"error":false,"chatId":36}

App .env:
# Auto-dump ENV from system call on 14:08:31 GMT+0000 (Coordinated Universal Time) LLM_PROVIDER='generic-openai' GENERIC_OPEN_AI_BASE_PATH='http://litellm-proxy:4000' GENERIC_OPEN_AI_MODEL_PREF='vertex_ai/gemini-1.5-pro-preview-0409' GENERIC_OPEN_AI_MODEL_TOKEN_LIMIT='4096' GENERIC_OPEN_AI_API_KEY='sk-xxxx-xxxx-xxxx' EMBEDDING_ENGINE='native' VECTOR_DB='lancedb' JWT_SECRET='xxxx-xxxx-xxxx' DISABLE_TELEMETRY='true' STORAGE_DIR='/app/server/storage' SERVER_PORT='3001'

AnythingLLM-Your-personal-LLM-trained-on-anything

Are there known steps to reproduce?

No response

Originally created by @diegodambra on GitHub (May 23, 2024). Original GitHub issue: https://github.com/Mintplex-Labs/anything-llm/issues/1508 ### How are you running AnythingLLM? Docker (remote machine) ### What happened? LLM returns full response, but AnythingLLM interface only shows first letter or word. The interface may display the full response, but only until I navigate away, when I return to the chat, the response is now first letter/word. Workspace Chat always list responses with first letter/word. The Sqllite DB table `workspace_chats` also reflects the issue, example: `36|2|what llm are you?|{"text":"I","sources":[],"type":"chat"}|1|2|1716385031805|1716385031805||` Response from endpoint `chats` also shows only first letter/word is returned to interface: `{ "type": "chat", "role": "assistant", "content": "I", "sources": [], "chatId": 35, "sentAt": 1716384827, "feedbackScore": null }` where endpoint `stream-chat` did return the same response given by LLM: `data: {"uuid":"d3d88381-1a39-4558-bf20-9776da45be63","sources":[],"type":"textResponseChunk","textResponse":"I","close":false,"error":false} data: {"uuid":"d3d88381-1a39-4558-bf20-9776da45be63","sources":[],"type":"textResponseChunk","textResponse":"","close":true,"error":false} data: {"uuid":"d3d88381-1a39-4558-bf20-9776da45be63","sources":[],"type":"textResponseChunk","textResponse":" am a large language model, trained by Google. \n","close":false,"error":false} data: {"uuid":"d3d88381-1a39-4558-bf20-9776da45be63","sources":[],"type":"textResponseChunk","textResponse":"","close":true,"error":false} data: {"uuid":"d3d88381-1a39-4558-bf20-9776da45be63","sources":[],"type":"textResponseChunk","textResponse":"","close":true,"error":false} data: {"uuid":"d3d88381-1a39-4558-bf20-9776da45be63","type":"finalizeResponseStream","close":true,"error":false,"chatId":36}` App `.env`: `# Auto-dump ENV from system call on 14:08:31 GMT+0000 (Coordinated Universal Time) LLM_PROVIDER='generic-openai' GENERIC_OPEN_AI_BASE_PATH='http://litellm-proxy:4000' GENERIC_OPEN_AI_MODEL_PREF='vertex_ai/gemini-1.5-pro-preview-0409' GENERIC_OPEN_AI_MODEL_TOKEN_LIMIT='4096' GENERIC_OPEN_AI_API_KEY='sk-xxxx-xxxx-xxxx' EMBEDDING_ENGINE='native' VECTOR_DB='lancedb' JWT_SECRET='xxxx-xxxx-xxxx' DISABLE_TELEMETRY='true' STORAGE_DIR='/app/server/storage' SERVER_PORT='3001'` ![AnythingLLM-Your-personal-LLM-trained-on-anything](https://github.com/Mintplex-Labs/anything-llm/assets/39560678/6e235ed7-4354-483e-b46e-f638e1302b11) ### Are there known steps to reproduce? _No response_
yindo added the possible bug label 2026-02-22 18:22:27 -05:00
yindo closed this issue 2026-02-22 18:22:27 -05:00
Author
Owner

@diegodambra commented on GitHub (May 23, 2024):

I can confirm patch fixes the issue, giga thanks!

@diegodambra commented on GitHub (May 23, 2024): I can confirm patch fixes the issue, giga thanks!
yindo changed title from [BUG]: Only first letter or word is shown as response from LLM to [GH-ISSUE #1508] [BUG]: Only first letter or word is shown as response from LLM 2026-06-05 14:38:12 -04:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: Mintplex-Labs/anything-llm#967