Ongiei451 downloadsLocal-first dictionary toolkit with offline definitions, online enrichment, and wordbook sync.
Local-first dictionary tools for Obsidian, with offline English-Chinese definitions, optional online enrichment, safe vocabulary-note linking, wordbook synchronization, and one-way Anki export.
LexiBridge is currently in
0.xdevelopment. Features and stored data structures may still change.
LexiBridge supports Obsidian 1.8.7 and later. Dictionary lookup, note, and reading features work on desktop and mobile. The current whole-file ECDICT installer and Anki export require desktop Obsidian.
ECDICT is the default definition source. LexiBridge downloads ecdict.csv from skywind3000/ECDICT, converts it locally, and imports the entries into IndexedDB. Dictionary data is not written into the vault.
The settings page can test and select GitHub, ghproxy.net, gh-proxy.com, jsDelivr, or Statically download endpoints. Installation and updates use a pinned upstream commit and validate the downloaded file, imported entry count, and representative entries before replacing the active local database. A failed update leaves the existing database available.
Batch migration only processes notes marked with dict_source: eudic or a legacy Eudic synchronization callout. It runs entirely against the local ECDICT database. LexiBridge does not add hidden management comments or synchronization callouts to vocabulary notes.
Youdao is an optional, user-initiated online source. It can supply phonetics, definitions, forms, web translations, and examples when requested for a single word. It is never used for automatic batch processing.
Requests are serialized, use randomized spacing and limited retries, and pause after HTTP 403 or 429 responses. You can disable online fallback and use ECDICT only. The dictionary panel can switch between ECDICT and Youdao; the default source for editor selection lookup is configurable.
LexiBridge writes vocabulary notes under the configured folder. Templates control frontmatter and body structure. Existing content below protected headings such as ## Notes is retained by heading level during an update.
Automatic linking previews every proposed change before writing. Links use the shortest unambiguous Obsidian target, preserve the displayed source text as an alias when needed, and avoid code, links, frontmatter, configured headings, and other excluded Markdown regions.
Virtual links do not modify Markdown and inherit the surrounding text color. They are rendered only in the foreground Obsidian window and only inside the note body in Reading view or Live Preview; Markdown-rendered TOC/outline side panels and background windows are excluded. A short hover delay prevents previews from opening while the pointer merely passes over a word. Their click action is configurable, and the compact preview can still open the note or convert all matching occurrences in the current document to real short WikiLinks so backlinks remain useful even if LexiBridge is later disabled.
Eudic is an optional wordbook connector, not a general definition source. After an official Open API token is configured, each selected remote wordbook maps to a separate subfolder inside the vocabulary-note folder. The same word may belong to more than one wordbook.
Remote wordbook renames update their mapped local folders. Renaming a mapped local wordbook folder can update the corresponding remote wordbook.
Deletion, a missing synchronization baseline, or substantial divergence after a long inactive period pauses automatic synchronization. Manual synchronization displays the complete difference list and offers three alignment strategies:
Destructive plans remain subject to the configured deletion limit. LexiBridge stores a bounded synchronization history and can restore recorded local deletions. Successful checkpoints are saved during long operations, so interrupted synchronization can continue later.
Anki is an optional one-way export target. Obsidian remains the source of card content; Anki owns review scheduling, history, suspension state, and optional AnkiWeb synchronization.
LexiBridge creates or updates the LexiBridge Vocabulary note type and identifies managed notes through a stable LexiBridgeId field. Updates use AnkiConnect field updates instead of deleting and recreating notes, preserving note IDs, card IDs, and review history. Card front, back, and CSS templates are editable in settings.
Full export begins with a read-only preview. Missing Markdown sources leave Anki notes unchanged by default. From the preview, users may explicitly tag missing-source notes, suspend their cards, or permanently delete them after confirmation. A zero-source scan refuses destructive actions. LexiBridge does not write Anki IDs or synchronization markers into Markdown.
Ongiei/obsidian-lexibridge as a beta plugin.main.js, manifest.json, and styles.css from the latest release.<vault>/.obsidian/plugins/lexibridge/.Optional Youdao lookup, Eudic wordbook synchronization, remote AnkiConnect endpoints, and AnkiWeb synchronization remain inactive until explicitly configured.
| Command | Purpose |
|---|---|
| Open dictionary view | Open the local-first dictionary side panel. |
| Create a lemma note for selected or cursor word | Create or update a vocabulary note. |
| Query selected or cursor word | Look up the selected word or the word at the cursor. |
| Enrich current or selected word with Youdao | Explicitly refresh one vocabulary note from Youdao. |
| Automatically link current document | Preview vocabulary links for the whole document. |
| Link vocabulary words in current section | Limit link preview to the current heading section. |
| Link vocabulary words in selection | Limit link preview to selected text. |
| Inspect and remove vocabulary links | Preview real vocabulary WikiLinks that can be converted back to display text. |
| Discover missing vocabulary notes | List unlinked words that do not yet have vocabulary notes. |
| Migrate Eudic notes with ECDICT | Refresh eligible legacy notes entirely offline. |
| Synchronize Eudic wordbooks | Review differences and run the selected alignment plan. |
| Test AnkiConnect connection | Request only the AnkiConnect API version. |
| Synchronize vocabulary notes to Anki | Preview and send the full configured vocabulary-note scope. |
| Synchronize current vocabulary note to Anki | Add or update only the current vocabulary note. |
| Feature | Endpoint | Data sent |
|---|---|---|
| ECDICT installation or update | skywind3000/ECDICT or selected mirror | No vault content. |
| ECDICT lookup and migration | None | Nothing. |
| Youdao enrichment | dict.youdao.com/jsonapi |
The word explicitly queried by the user. |
| Eudic synchronization | Official Eudic Open API | Words and wordbook operations in the selected scope. |
| AnkiConnect connection test | http://127.0.0.1:8765 by default |
No vault content. |
| Anki export | Configured AnkiConnect endpoint | Selected vocabulary-note content, tags, and source links. |
| AnkiWeb trigger | Performed by Anki Desktop | LexiBridge never receives AnkiWeb credentials. |
LexiBridge contains no telemetry. The Eudic token is stored as plain text in the plugin's data.json; do not publish or share that file.
Vault access is limited to the configured vocabulary-note folder, the active note or selected text, and files explicitly selected by the user. LexiBridge does not enumerate unrelated vault notes.
npm ci
npm test
npm run lint
npm run check:community
For the real AnkiConnect acceptance test, start Anki Desktop with AnkiConnect enabled, then run:
npm run test:anki-manual
ECDICT is provided by skywind3000/ECDICT under the MIT License. LexiBridge downloads the upstream CSV and processes it only on the local device.
The project structure is based on the Obsidian Sample Plugin. Lemmatization uses the MIT-licensed wink-lemmatizer. Names and trademarks remain the property of their respective owners.