会话支持隔离吗?因为好像不同的人跟同一个agent对话,是可以干扰他去删除其他人的对话内容的
Thanks for raising this concern. We reviewed the codebase and here is our analysis:
Chat sessions ARE isolated per user
The current implementation already enforces user-level isolation on chat sessions:
- WebSocket connection: If a session belongs to user A, user B cannot connect to it (rejected with code 4003).
- Session listing: Each user only sees their own sessions (
scope=minefilters byuser_id). - Session deletion: Only the session owner (or admin) can delete a session (403 for others).
- Message viewing: Same ownership check — non-owners get 403.
So one user cannot directly read, modify, or delete another user's chat messages.
What might feel like "interference"
That said, there are shared resources across users when talking to the same agent:
| Resource | Shared? | Impact |
|---|---|---|
| Chat sessions & messages | No — per-user isolated | Safe |
| Agent workspace (files) | Yes — shared across all users | User A can ask the agent to create a file, user B can ask the agent to delete it |
| Agent memory & agenda | Yes — global per agent | User A's conversation may update the agent's memory, affecting how it responds to user B |
| Agent configuration | Yes — managed by admin/creator | N/A |
Could you help us understand?
To better address your concern, could you describe the specific scenario you encountered?
- Which content was affected? Was it chat messages that disappeared, or files/data that the agent was working on?
- What roles do the users have? (Admin users can view/delete all sessions by design — this is intentional for management purposes.)
- Were multiple users chatting with the same agent at the same time?
This will help us determine whether this is a genuine isolation bug or expected behavior from shared agent resources. If it turns out to be about workspace/memory isolation, that's a valid feature request we can discuss separately.
| 资源 | 共享? | 影响 |
|---|---|---|
| 代理工作区(文件) | 是 — 在所有用户间共享 | 用户 A 可以请求代理创建文件,用户 B 可以请求代理删除它 |
| 代理内存与议程 | 是 — 每个代理的全局范围 | 用户 A 的对话可能会更新代理的内存,从而影响其如何回应用户 B |
这2点目前是解决不了的吗?
It's not a matter of whether it can be solved — this is just our current design. Having said that, the requirement you mentioned is something we can consider. For example, the agent could have its own public memory and workspace, and also maintain per-user memory and per-user workspace that are isolated from each other.
谢谢,非常期待更多的特性展示