Introduction¶
In DeepSeek Harness (DSH) development practice, the ask_user_question tool typically handles only flat 1–3 questions. When it is necessary to collect expectations, acceptance criteria, or scope definitions across multiple interaction dimensions, simple linear questioning is insufficient. What we need is a system capable of path branching, deep options, and fast decision-making.
The dsh-rich-questions plugin provides this capability. It extends the ask_survey tool in the DSH Web GUI, allowing agents to build surveys in real time from conversation context and render and answer them directly in the chat interface.
What This Is¶
This is a DSH client plugin maintained by svgop. It is an open-source project under the MIT license with zero runtime dependencies. The plugin adds a rich branching survey system to the Web GUI, supporting graph-based branching logic, lazy hover insights, Mermaid diagrams, quick mode, and actions such as reroll/push/discuss.
Core Features¶
The plugin provides the following capabilities:
- Branching Paths: Graph-based branching logic, where each option defines the next question (
next); selecting option C triggers different follow-up questions than option A. - Per-Option Intelligence: Each option carries insights, sources, and citations, as well as a compact Mermaid diagram. Information is revealed through click-to-expand disclosures (
?text, branch-icon diagrams), avoiding hover popups. - Inline Rationale: After selecting an option, a pencil icon is available, allowing the user to explain the reason for the choice in one line before submitting (Justify). These rationales are passed to the agent along with the answers.
- Quick Mode: Provides six whole-survey decision templates labeled a-f; clicking one applies a complete, coherent answer mapping and submits it. For example, “Deliver like Vercel/Railway: prioritize polish + DX.”
- Bank & Continue: Supports per-step submission. In long surveys, current answers are automatically saved on the host side, survive refresh, and can be continued in any browser.
- Persistent Progress: Survey drafts are saved automatically. After refreshing the page or switching tabs and returning, the progress, questions, and answers remain unchanged.
- Preflight Guidance: Before the first question, provides Reroll (rewrite and upgrade), Push (generate reusable research artifacts), and Discuss (switch to discussion mode) actions.
- Language Following: The survey language automatically switches based on the chat language (English/Chinese).
- Host Authority: Pending survey state is stored on the host side; closing the browser or tab does not lose state, and state is automatically restored upon reconnection.
Installation and Enablement¶
Install using the DSH CLI:
dsh plugin --profile web add dsh-rich-questions
After installation, restart the dsh web process and refresh the browser tab. The ask_survey tool will appear in all agent presets.
If installing via a fork:
dsh plugin --profile web add file:/path/to/dsh-rich-questions
Typical Usage¶
The agent can dynamically generate surveys based on conversation context. The survey is rendered in the composer seat, displaying one question per page and showing progress along the current path. The agent may define the survey structure with JSON, for example:
{
"survey": {
"title": "Expectation alignment",
"intro": "Short markdown preamble — the first page.",
"entry": "q1",
"questions": {
"q1": {
"prompt": "Which direction fits this release?",
"options": {
"a": { "label": "Stability", "next": "q2" },
"b": { "label": "Speed", "next": "q3" }
}
}
}
}
}
After the agent responds, the user answers directly in the chat input area. Multi-select, free text, skip logic, and other interactions are supported.
Applicable Scenarios and Notes¶
This plugin is suitable for complex workflows that require branching logic, deep options, and fast decision-making, such as scope definition and acceptance criteria collection.
Notes:
* DSH >= 0.1.2-alpha.1 is required.
* Node >= 20 is required.
* The plugin runs with the permissions of the current DSH process.
* Review the source code and license before installation.
Conclusion¶
dsh-rich-questions integrates a survey system seamlessly into DSH’s conversation flow, reducing the fragmented feel of traditional form tools in agent interactions. Through host-authoritative state management and the banking feature, it ensures usability for long, multi-stage surveys.
Learn more or view the source code:
* Plugin Directory
* GitHub Repository