-
-
Notifications
You must be signed in to change notification settings - Fork 1.1k
Model prompt still being truncated #1593
Copy link
Copy link
Open
Labels
bugSomething isn't workingSomething isn't workingstatus/untriagedThis issue needs triaging to confirm itThis issue needs triaging to confirm it
Description
Describe the Bug
The patch notes for v0.25.0 mention that now a proper tokenizer is used, which prevents the system prompt from being truncated. Even after updating, I have observed that the prompt is still being truncated by ollama:
Jun 10 21:22:18 ollama-host ollama[159]: time=2025-06-10T21:22:18.314Z level=WARN source=runner.go:128 msg="truncating input prompt" limit=512 prompt=617 keep=4 new=512
Jun 10 22:46:49 ollama-host ollama[159]: [GIN] 2025/06/10 - 22:46:49 | 200 | 1h24m39s | 10.99.99.105 | POST "/api/chat"
Jun 11 08:07:59 ollama-host ollama[159]: time=2025-06-11T08:07:59.286Z level=WARN source=runner.go:128 msg="truncating input prompt" limit=512 prompt=617 keep=4 new=512
Jun 11 08:10:38 ollama-host ollama[159]: [GIN] 2025/06/11 - 08:10:38 | 200 | 2m39s | 10.99.99.105 | POST "/api/chat"
Jun 11 08:13:42 ollama-host ollama[159]: time=2025-06-11T08:13:42.858Z level=WARN source=runner.go:128 msg="truncating input prompt" limit=512 prompt=529 keep=4 new=512
Jun 11 08:18:51 ollama-host ollama[159]: [GIN] 2025/06/11 - 08:18:51 | 200 | 5m8s | 10.99.99.105 | POST "/api/chat"
Jun 11 08:20:08 ollama-host ollama[159]: time=2025-06-11T08:20:08.539Z level=WARN source=runner.go:128 msg="truncating input prompt" limit=512 prompt=587 keep=4 new=512
Steps to Reproduce
- Set a token limit that is smaller than the length of the page contents
- Start an AI tagging job
- Observe Ollama logs
Expected Behaviour
The entire prompt should be crafted on Karakeep's side to not exceed the set amount of tokens.
Screenshots or Additional Context
No response
Device Details
No response
Exact Karakeep Version
v0.25.0
Have you checked the troubleshooting guide?
- I have checked the troubleshooting guide and I haven't found a solution to my problem
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't workingstatus/untriagedThis issue needs triaging to confirm itThis issue needs triaging to confirm it