Introduction¶
After running a long series of conversations in DSH, going back to revisit a few of them requires toggling between windows and copy-pasting context back and forth. This kind of workflow shatters the conversation into fragments and makes it easy to miss important information. dsh-salon adds a chat entry point to the left activity bar. Clicking it opens a room where you can pull in existing sessions, chat within the room, and their replies automatically land back in the room.
What This Is¶
dsh-salon is a DSH plugin authored by maintainer Elysian1knight, designed to let existing sessions converse within the same panel—without creating new sessions or applying preset patches. The plugin uses the DSH host’s webServer, agents, sessionController, workspaceRegistry, and tools services, along with the front-end slot sidebar.panellist and @deepseek-ai/dsh-client-ui-primitives.
Core Features¶
The Room Only Seats Existing Sessions¶
The plugin only lists sessions that are “in a registered workspace and not archived.” Archived sessions must first be restored in DSH; unregistered workspaces won’t enter the room, and sub-agents don’t count either. The room’s own membership is tracked in state/room.json, storing only the sessionId. Names default to whatever the session itself is called.
The Room Keeps Its Own Records¶
The room’s name (default: “Group Chat”) is stored in the title field of state/room.json. You can change it in the settings panel; leaving it blank reverts to the default. Customized nicknames and avatar characters are stored in state/names.json (keyed by sessionId, with the host using owner); leaving them blank reverts to defaults. Two sessions with the same name each get a unique suffix; if that suffix happens to collide with a real name, it keeps incrementing until no one else is using it. If you rename yourself to someone else’s name, the request is rejected (400). Two same-named people in the room will cause to, from, and @ to all misidentify the target.
If It Doesn’t Deliver, It Says So¶
If you select someone from the sidebar who isn’t actually in the room, it explicitly says “nobody was called”—it doesn’t silently drop the message. Anyone who didn’t receive the message gets a system line appended to the ledger (#N Someone: Not woken (reason)). The small note on the sender’s side disappears on refresh, but the ledger entry persists. Only when the message actually reaches the session does it report “delivered.”
Security Boundaries¶
- All attachment playback responses include
X-Content-Type-Options: nosniff; SVG files are never served as pages—they’re served asapplication/octet-stream+Content-Disposition: attachment. The reason:/salon/files/shares the same origin as the GUI, so scripts inside an SVG would execute as page content. - Upload limit is 32 MB: exceeding it returns 413 directly, rather than buffering the entire request body into memory.
- Local-origin only: any request carrying an
Originheader that isn’t127.0.0.1/localhostgets a 403. The standalone port binds exclusively to127.0.0.1. This blocks other web pages in the browser from sneakily hitting the local port, but does not block local processes.
Privacy¶
Everything said in the room—messages, attachments, diagnostic logs—lives entirely under the local state/ directory. Nothing is transmitted externally or sent over the network; state/ is already in .gitignore. No external addresses exist: the host routes use the same-origin prefix /salon, and the fallback port only listens on 127.0.0.1. Session content will appear as context in whichever session is woken—that’s the feature itself, not a leak; but don’t pull a session into the room where its content shouldn’t be visible.
Installation & Activation¶
Install from npm (recommended):
dsh plugin add dsh-salon
Restart DSH after installation. The repo ships with a default cordis.patch.yml (containing only mode: room and port: 40765) that works out of the box; modify it only if you want to change the port or restrict workspaces.
Typical Usage¶
A “Group Chat” icon appears in the left activity bar. Click it to open the room. Gear icon in the top-right → pick a session → “Invite in.” No need to type a name—once it’s in the room, it goes by whatever name the session already has. Which workspaces qualify is defined in the workspaces: list in cordis.patch.yml (absolute paths, one per line); omitting the entire list means no workspace filtering, but archived sessions and sub-agents are still excluded.
A person’s name on the room roster is simply that session’s own name: if the session is called “Xi’s Conversation,” it shows as “Xi’s Conversation” in the sidebar. If you rename it in DSH, the room follows (no separate name is stored, and you can’t set an alternative in settings). Two sessions with the same name each get a unique suffix.
Before speaking, select a recipient in the “Send to” field above the input box—routing relies on this selector, not on @ mentions in the body. Choosing “Nobody” just leaves a note—no cost, no one gets woken. Writing @name in the body only takes effect when no one is selected (fallback). Clicking “Everyone” and then deselecting one person: it replaces the single “everyone” entry with an explicit list of the remaining people—it doesn’t keep “everyone” and subtract.
Two “Wake mode” options: Queue (it finishes its current turn before looking, non-interruptive) / Steer (interjects into its current step, mode:'steer'). Default is Queue—when someone arrives in the room, it shouldn’t blow away a long-running task.
Attachments: use the paperclip button, paste directly, or drag files into the panel. Files are first uploaded to state/files/, then logged with the message; when the other party is woken, they receive the absolute disk path and open it with their own file tools. Images display as thumbnails; everything else shows as a paperclip icon. Sending only an attachment with no text is also allowed.
Content column width is adjustable: one handle on each side, dragging adjusts the content column width (not the padding)—following the DSH conversation page pattern (WidthHandle from dsh-client-ui-conversation): the width lands on the CSS variable --salon-content-width, handle positions are computed via CSS calc(), and the JS function maintains a single number. The formula: minimum 640, side-margin budget 176, initial value clamp(680, column_width×0.64, 920); each 1px of pointer movement changes the content column width by 2px (split half left, half right); localStorage['salon.contentWidth'] is written only on mouse release; double-click resets to default (removes that preference). Text selection is suppressed across the entire panel during drag.
Nicknames and avatar characters: in settings, one row per person (the host gets a row too). Left side: nickname. Right side: the avatar character. Press Enter or click elsewhere to save. Blank = revert to default: name follows the session’s own name, avatar character is the first character of the name. Customized values are stored in state/names.json, keyed by session ID (host uses owner). They don’t appear in the ledger—the ledger is for what was said; the name is just the nameplate.
Routing (“Send to”): you can select multiple people at once—click to select, click again to deselect; “Everyone” is a separate button. Selecting “Everyone” = every person in the room (except the speaker themselves) receives a wake-up; the ledger records the actual names present at that moment, not a wildcard *. If you pick the wrong name or it’s not in the room, it explicitly says “nobody was called”—no silent dropping.
Group chat name: the top row in the settings panel. Blank = “Group Chat”, max 24 characters, Enter or click elsewhere to save. This changes the room’s nameplate, not anyone’s nickname; adding or removing people won’t overwrite it.
Messages in the room are not injected into the wake-up prompt: the woken session only receives the instruction “use salon_read to read context if you want; skip it if not.” That session decides for itself whether to read—how much to read is controlled by since/limit (default: last 20, cap: 200).
Delivery goes through the host’s session service (sessionController.prompt(request, signal)): the second parameter is an AbortSignal, not a message source—the very first line of that function is signal.throwIfAborted(); passing the wrong type throws signal.throwIfAborted is not a function (learned the hard way on Nov 14). The source is derived internally by requestId. This path handles both cold and warm sessions: internally it first calls resolveAgent(sessionId), then routes by mode to followup (queue) or steer (interjection). On failure it falls back to agents.get().followup → steer → agents.resume and retries; each failure step is logged to state/salon.log with the original message and the first four stack frames. If all attempts fail, it honestly reports “Not woken (reason)”—never “Delivered.”
Session replies are captured via session/event and written to the ledger; intermediate narration involving tool calls is not logged.
Rendering¶
Messages in the room use DSH’s own Markdown renderer (MarkdownText from @deepseek-ai/dsh-client-ui-primitives), so tables, footnotes, code-block toolbars, and images are the same components you see in DSH’s conversation panel—no custom markup needed. Two fallbacks are coded in client.js: if that module is unavailable, it falls back to a local Md renderer (bold / inline code / code blocks / headings / blockquotes / lists / links / images); if rendering throws mid-way, MdGuard catches it and switches to Md, so the panel won’t white-screen.
Image URLs are only recognized in two forms: http(s):// and in-room /salon/files/…; anything else is displayed as plain text—no broken images. HTML in the body is not executed (rendered as-is)—no injection vector into your own room.
API¶
| Method | Path | Purpose |
|---|---|---|
| GET | /salon/api/messages?since= |
Read the ledger |
| GET | /salon/api/status |
Host and room members |
| GET | /salon/api/config |
Room members + available sessions |
| POST | /salon/api/say |
{ text?, to?, from?, files?, mode? } (to is an array of names; * or “everyone” = all) (to is an array of names; omit it and it falls back to @ in the body; mode is queue/steer; files is the stored list returned by upload) |
| POST | /salon/api/upload?name= |
Raw bytes to storage; returns { ok, file:{ name, stored, size, type, url } } |
| GET | /salon/files/<stored> |
Retrieve an attachment (only accepts one-level names under files/; .. always gets 404) |
| POST | /salon/api/member/add |
{ sessionId } |
| POST | /salon/api/member/remove |
{ name } |
| POST | /salon/api/title |
{ title } (blank reverts to “Group Chat”, max 24 chars) |
| POST | /salon/api/name |
{ target, name?, initial? } (target is owner / session ID / current room name; blank reverts to default) |
Tests¶
node test-room.mjs
Fake host, real HTTP: listing sessions, inviting in, @ delivery, reply logging, delivery failure must report “not delivered,” removing members, reporting when no session service is available; attachment upload and retrieval (including .. traversal → 404, empty files rejected), steer/queue actually landing in mode, salon_read being mounted and able to read room messages, and wake-up prompts no longer stuffing old ledger content.
Use Cases & Cautions¶
Suitable for scenarios where you need to consolidate existing conversations into a single discussion space—for example, pulling multiple in-progress task sessions into the room for coordinated discussion or delegation. The plugin runs with the current DSH process’s permissions; review the source code and license before installing.
Closing¶
dsh-salon lets existing sessions converse within the same panel, eliminating the need to toggle between windows. The core principles are: “the room only seats existing sessions,” “the room keeps its own records,” and “if it doesn’t deliver, it says so”—and all data lives under the local state/ directory with no external transmission. Directory page and source code are linked below.
References¶
- https://www.skillhub.cn/plugins/Elysian1knight/Elysian-repository
- https://github.com/Elysian1knight/Elysian-repository