Summary
A Dictionary / Thesaurus tool window — look up the definition, part of
speech, and synonyms/antonyms for the word under the cursor (or a typed
query) without leaving the editor. Sits in the tool-window system alongside
Rhyme Search.
Motivation
Poets reach for meaning and near-synonyms constantly. Today the only
word-tool is Rhyme Search (src/rhyme/search.rs, Datamuse-backed). A
dictionary/thesaurus is the obvious companion panel.
Scope (v1)
- Bottom or right tool window, toggled from the tool-window stripe.
- Input: current selection / word at caret, plus a search box.
- Output: headword, pronunciation (reuse CMUdict / the pronunciation
resolver), definitions grouped by part of speech, synonyms, antonyms.
- Double-click a synonym to insert it; copy-from any entry.
Offline-first (non-negotiable #4)
- Local first: bundle a permissively-licensed English dictionary +
thesaurus dataset (e.g. WordNet 3.0, or wiktionary-derived) under
assets/, compiled via build.rs, queried with zero network.
- Datamuse (
ml=, syn, ant, md=d) is enhancement only — short
timeout, falls back to the bundled data, has an off switch. English only.
Files (sketch)
- new
src/tools/dictionary.rs (or src/rhyme/ sibling) — panel + lookup.
assets/dictionary/… + build.rs entry for the bundled dataset.
- tool-window registration in
app/chrome.rs + app/layout.rs.
- a
show_dictionary_panel / enable-online-lookup setting via the existing
settings pattern.
Summary
A Dictionary / Thesaurus tool window — look up the definition, part of
speech, and synonyms/antonyms for the word under the cursor (or a typed
query) without leaving the editor. Sits in the tool-window system alongside
Rhyme Search.
Motivation
Poets reach for meaning and near-synonyms constantly. Today the only
word-tool is Rhyme Search (
src/rhyme/search.rs, Datamuse-backed). Adictionary/thesaurus is the obvious companion panel.
Scope (v1)
resolver), definitions grouped by part of speech, synonyms, antonyms.
Offline-first (non-negotiable #4)
thesaurus dataset (e.g. WordNet 3.0, or wiktionary-derived) under
assets/, compiled viabuild.rs, queried with zero network.ml=,syn,ant,md=d) is enhancement only — shorttimeout, falls back to the bundled data, has an off switch. English only.
Files (sketch)
src/tools/dictionary.rs(orsrc/rhyme/sibling) — panel + lookup.assets/dictionary/…+build.rsentry for the bundled dataset.app/chrome.rs+app/layout.rs.show_dictionary_panel/ enable-online-lookup setting via the existingsettings pattern.