Skip to content

Anionex/dsh-suggested-replies

30Last commit Aug 14, 2026

dsh-suggested-replies DSH plugin

This plugin creates an internal agent session after each AI completion to generate candidate user replies. The candidates are shown as clickable bubbles in the `conversation.input.dock` area, filling the draft without auto-sending. It supports configurable count, context size, and failover handling.

How to install the dsh-suggested-replies DSH plugin

dsh plugin --profile web add @anionex/dsh-suggested-replies

Copying does not run this command. Review the repository and version before installing the dsh-suggested-replies DSH plugin.

dsh-suggested-replies DSH plugin data source

dsh-suggested-replies DSH plugin snapshot date: Aug 16, 2026

discovered

What the dsh-suggested-replies DSH plugin can do

  • Generates 2-4 suggested reply candidates after each AI response using an internal agent
  • Displays candidates in a single horizontal line above the chat input box
  • Clicking a candidate fills the draft text without sending the message automatically
  • Configurable suggestion count, context message count, max character length, and timeout
  • Failover: generates conservative candidates even if the internal agent fails to return valid JSON
  • Expiration protection: cancels ongoing generation on new user input, settings toggle, or plugin unload
  • State persistence across page refresh or host restart via sidecar storage keyed by session ID

Where the dsh-suggested-replies DSH plugin fits

  • Quickly follow up with common actions or questions after an AI response
  • Provide verification or clarification prompts for the user to select
  • Offer decision-making choices (e.g., 'Yes', 'No', 'More details') without typing
  • Reduce repetitive typing in customer support or Q&A scenarios
  • Enable faster iteration in conversational workflows by pre-filling drafts

Who the dsh-suggested-replies DSH plugin is for

  • DSH Web users who want to streamline chat interactions
  • Developers building conversational interfaces that need quick reply suggestions

dsh-suggested-replies DSH plugin limitations

  • Requires an additional model call per AI response, increasing cost and latency
  • Only supported in DSH Web (uses `conversation.input.dock` which is Web-only)
  • Candidate generation may fail if the internal agent times out or returns invalid data, though fallback is provided
  • Maximum suggestion count is limited to 4, and per-candidate character limit is 300

dsh-suggested-replies DSH plugin: from the repository README

Quoted from the Anionex/dsh-suggested-replies README, the upstream source of the dsh-suggested-replies DSH plugin. Copyright remains with the original authors.

DSH Web 的“预测回复”插件:AI 回复结束后,生成几条用户下一步可能会发送的消息候选,并将它们显示在**聊天输入框上方**。点击候选只会将文本填入输入框,**不会自动发送**。 ![候选气泡位于输入框上方](docs/suggested-replies-layout.svg) ## 行为 ```text AI 完成本轮回复 -> 插件创建一个只使用官方事件的内部 Agent Session -> 内部 Agent 以零工具、完整 persona 根据近期对话生成候选 -> flush 并归档内部 Session,把 UI 状态写入插件自有 storage-domain sidecar -> Web 在 conversation.input.dock(输入框上方)显示气泡 -> 点击候选:inputActions.setDraft(text) -> 用户自行编辑或点击发送 ``` - **正确位置**:注册 `conversation.input.dock`,位于 DSH 的消息输入卡片上方;不会放到输入框下方的 `conversation.composer.dock`。 - **单行展示**:候选始终保持在一条横线上;宽度不足时横向滚动查看,不换到第二行。 - **只填入草稿**:点击候选会替换当前草稿为该候选,不会调用发送动作。 - **候选内容**:优先覆盖合理的下一步执行、验证/追问、或决策/选择;候选跟随最近对话语言,彼此去重且可直接发送。 - **失败兜底**:辅助模型没有返回规定 JSON 时,插件仍按最近对话语言生成配置数量的保守候选,不再把空数组当成成功结果隐藏整行。 - **上下文范围**:辅助提示词只截取直接用户消息和 AI 回复;AGENTS、运行时快照和 Skill 目录等注入上下文不会挤占最近对话窗口。 - **过期保护**:新用户输入、设置关闭、辅助调用超时或插件卸载都会取消当前生成,避免旧结果在下一轮对话中回流。 - **模型调用与成本**:每个可生成候选的完成轮次额外运行一个短文本内部 Agent。默认复用 Session 最新 `request/header` 中实际使用的 provider/model,再回退到 Agent 默认路由;也可通过 `suggestionProvider` + `suggestionModel` 显式覆盖。关闭开关后不再运行该 Agent。 - **Core 零修改**:父 Session 不追加插件自定义事件,也不修改 `KNOWN_SESSION_EVENT_TYPES`。生成过程完整记录在内部官方 Agent Session;候选的 loading/ready/cleared 状态保存在插件拥有的 `suggested_replies_state`

Read the full READMERepository license: MIT

dsh-suggested-replies DSH plugin questions

How do I install the suggested replies plugin?

Run `dsh plugin --profile web add @anionex/dsh-suggested-replies` in your terminal. After installation, restart the DSH web service and hard-refresh your browser. The plugin will be active for new conversations.

How can I change the number of suggested replies?

Edit your DSH configuration (e.g., via `cordis.patch.yml` or profile overlay) and set the `suggestionCount` field. The value can range from 2 to 4. For example: `suggestionCount: 4`. The change takes effect immediately for the next AI response.

Why are no suggested replies showing up?

Check that the plugin is enabled in Web settings (`enabled` toggle). Also verify that the internal agent model is available. If the timeout is too short, the generation may fail. You can increase `timeoutMs` (up to 30000). If the model returns invalid JSON, the plugin will fallback to conservative candidates, but if all candidates are empty, the row may be hidden.

Does clicking a suggested reply automatically send the message?

No, clicking a candidate only fills the draft text in the input box. It does not trigger sending. You can edit the text before pressing Enter or clicking the send button.

Can I use a different model for generating suggestions?

Yes, you can specify `suggestionProvider` and `suggestionModel` in the plugin configuration. They must be provided together. If omitted, the plugin uses the same provider/model as the current session.