mirror of
https://github.com/Niko1221/Strata.git
synced 2026-12-03 19:03:30 +07:00
[GH-ISSUE #5008] [GUI] Parallel chats in the same folder mix up each other's messages and files #2313
Labels
No labels
needs-format
pull-request
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
Niko1221/Strata#2313
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @streamcfd on GitHub (Nov 2, 2026).
Original GitHub issue: https://github.com/Niko1221/Strata/issues/5008
When two chats run at the same time and both were opened in the same working
folder, their messages and their working files get mixed up. Everything about
both chats is keyed to the folder, not to the chat: the session records, the
scratch files on disk, and (at the model level) the conversation cache. So while
one chat is mid-turn, the other chat writes into the same directory tree, waits
on the same single model slot, and borrows/evicts conversation state from the
same parked cache as the first chat.
This is not a display glitch: the files on disk really are shared, and the model
side really is swapping conversation state between chats.
Environment
ai.strata.desktop), Windows 11.0.1.55-windows-x86_64-cuda-cuda13, runningone local quantized model ("one request at a time", 1 request in flight).
How to reproduce
time.
W. Start a long task that creates manyfiles inside
W(scratch folder, scripts, background shell jobs).folder
W. Start a second task that also writes files insideW.What actually happens
1. All chats opened in the same folder are stored in one per-folder session bucket
Every chat opened in the same folder is persisted under one directory keyed by
that folder path, not per chat:
and the same per-folder mapping is in
~\.strata\data\agent\sessions.json, whereevery entry has the identical
cwdand only thesessionIddiffers. So fourdifferent chats from the last hour share one storage bucket.
2. The working files are genuinely shared between the two chats
Both chats wrote into the same folder tree: one chat created its own scratch
subfolder and scripts, the other created a different scratch subfolder and its
own scripts, and a tool launched from one chat dropped an unrelated third‑party
crash-report folder into the shared root. Each chat's
pwsh/glob/readcalls operate on the shared root, so each chat sees the other's intermediate
files and can read, edit or clean up the other's work. In the logs of the last
hour the shared root path appears 42 times in one chat and 44 times in the other.
There is no per-chat scratch namespace and no ownership marker on files, so a
"cleanup my temp files" step in one chat is a hazard for the other chat.
3. A chat stalls mid-turn because the other chat owns the model slot
Both chats were assembling prompts of roughly 70k tokens each against one
131k context window served one-request-at-a-time. Chat A's turn was interrupted
by a ~40 s wait for a shell request while Chat B's request was in flight; a new
chat opened at 16:12 while Chat A was mid-turn, and Chat A's next model step
only continued after the new chat's request had run.
4. The engine parks, restores, borrows and evicts conversation state across chats
Engine log (
<install>\<engine>.log) while both chats were running:conversation cache: dropped … superseded copy of this conversationconversation cache: restored …conversation cache: parked …conversation cache: borrowed <N> tokens from a parked conversation, which stays parkedconversation cache: no room beside the parked conversation this request starts with; taking it instead of borrowingcancelled request keeps its conversation: <N> tokens liveWARNINGThree or four conversations are parked in the cache at the same time, a request
borrows up to ~71k tokens from a conversation that is not the one it starts
with, and three times the engine says there was no room and it took the parked
conversation instead of borrowing from it. Those are exactly the moments where a
chat's reply starts looking like it belongs to a different chat.
5. The text reaching the model gets garbled under this load
One chat's transcript contains a stray combining diacritic (U+036D) inserted
into the workspace path, twice, 38 seconds apart:
The persisted tool-call arguments and tool-result text in the same session store
are clean, so the corrupted path is not coming from disk or from the tool layer —
it appears only in the text the model was working with and produced, during a turn
that ran interleaved with another chat. The visible effect was real: edits failed
with
old_string was not found/FS_EDIT_NOT_FOUNDon a file thatreadopened normally, and the chat burned several steps re-checking a path that was
never wrong.
6. Setting changes made in one chat appear in another chat's transcript
A change of the approval policy (
ask→never) made while working in one chatshows up in the other chats as an injected user-role message:
in each chat's own history, at the moment that chat's next turn started — although
the user only made that change in one of the chats. A user-role line describing an
action the user did not take in that chat is indistinguishable from something the
user actually typed there.
What should happen instead
per-chat ownership of files created during that chat, so listing/cleaning files
in one chat cannot touch another chat's work.
that belongs to the same conversation (shared static prefix aside), and "no room"
should evict the requesting chat's own superseded copy rather than take over a
parked conversation belonging to a different chat.
and how long the current chat is queued, instead of a silent mid-turn stall.
the other chats, not injected as a user-role message.
Impact
Mid-turn context corruption plus shared file namespace. On the affected chats this
cost several wasted tool steps, produced failed edits against files that existed,
and left two chats' output files interleaved in one folder where either chat could
overwrite or delete the other's work.
Notes
or message text from one chat appears in another chat's session file. The mixing
is in the shared on-disk workspace, the shared per-folder session bucket, and the
shared conversation/model cache.
with placeholders; no user name, machine name, document names or hardware
identifiers are included.
Read
Source
@github-actions[bot] commented on GitHub (Nov 2, 2026):
Thanks for the issue. To keep the tracker readable, every item needs an area prefix in the title and the parts of the issue form filled in. This one is missing:
Edit the issue (title and description) and this note goes away on its own. If it is still missing parts in 5 days it will be closed, which is not a rejection: fix it and comment
/reopen.Details: CONTRIBUTING.md
@github-actions[bot] commented on GitHub (Nov 2, 2026):
Thanks, this follows the format now.
@Niko1221 commented on GitHub (Nov 5, 2026):
Hello streamcfd,
Thank you for the clear description. We reproduced it: one chat's end-of-turn sweep listed the other chat's file as its own. In Strata 0.2.11 a turn reports only the files its own tools wrote, and when turns overlap, files nobody claimed are withheld. In a real-app test two parallel chats in one folder gave four clean rounds, each with its own file. The things that are not ours (the agent's per-folder bucket and its approval-policy notice) are unchanged. If chats still mix up on 0.2.11, please send which tool wrote the file.
The Strata project