English | 中文
Select a word or phrase in a DSH chat, get a short gloss in context, hear it, and keep a local glossary.
The card uses the passage around the selection. Here CRAQ is explained as the
replication protocol 3FS uses, and the model adds a short Chinese line because
the term is technical.
Status: early prototype, usable. Tested with DeepSeek V4.1 Flash on DSH
0.2.2-rc.5. The UI and the lookup prompt may change. See
KNOWN-ISSUES.md for limitations and the roadmap.
A gloss is a short explanation of a word as it is used in a sentence — not a full dictionary entry. That is what this plugin adds to the conversation.
- Select text in any assistant or user message. A small Explain / Quote pill appears where the built-in quote button used to be.
- Explain asks the model currently selected in DSH for one contextual gloss: IPA, part of speech, a short meaning, an example, and an optional usage note. It sends a short passage around the selection, so the model sees the sentence the word belongs to. The plugin uses the model's lowest reasoning effort to keep the wait short. For a technical or abstract sense, the model may add a short Chinese explanation; for a simple word it stays English only.
- Speak reads the word, the meaning, and the example. IPA stays on the card; it is not spoken.
- Copy puts the word, IPA, meaning, example, note, and any Chinese explanation on the clipboard with one click.
- Save writes the gloss to a local JSON glossary. A short passage around the selection is sent to your configured model provider; nothing else leaves the machine.
- Glossary opens as a right-sidebar page. Cards are ordered by the last time you looked the word up or saved it, so the words you touch most stay near the top. Click a card to reveal the example; the speaker reads word + meaning.
- The DSH Web GUI. The client half is a Web client module.
- The built-in
@deepseek-ai/dsh-message-quotesplugin. The card renders in its selection slot; the quote handler opens it. - A configured model route. The plugin uses the session's current default model.
- A browser with at least one English voice for the speaker button. Without one, the button stays silent.
dsh plugin --profile web add github:wyhgoodjob/dsh-glossReplace web with your profile name. The command installs the package into
that profile and adds its bundle. Restart dsh, then refresh the Web page.
From a local checkout, point at the directory instead:
dsh plugin --profile web add /path/to/dsh-glossYou can also add a local directory from Settings → Plugins → Add plugin.
- Select a word or a short phrase in a message.
- Click Explain.
- Click the speaker, or Save.
- Open the glossary from the card, or from the right sidebar's + menu.
The gloss follows the sentence. For example, selecting take off in a sentence
about a plane gives the “leave the ground” sense, not “remove clothes”.
The glossary is plain JSON at:
~/.dsh/gloss/glossary.json
The first run imports a glossary from an earlier build when the new file does
not exist. Set DSH_HOME to move the DSH home; the glossary follows it. The
stored fields may change between versions.
- The host half registers one authenticated route and calls the current model for a short contextual gloss. It selects the model's lowest reasoning effort for each lookup and remembers the source passage with each saved entry.
- The client half renders the selection pill, the result card, and the right-sidebar glossary.
- Saved entries are written atomically to the local JSON file.
Lookups are usable but still a little slow: the card waits for the whole JSON reply instead of streaming the meaning first. Streaming and a dedicated fast model are on the roadmap. See KNOWN-ISSUES.md.
MIT © 2026 Yihao Wang. See LICENSE.