Preface¶
When acting as an assistant for note repositories, document libraries, or code repositories in DeepSeek Harness (DSH), agents often need to “guess paths by file name” or “search body text by snippet.” If every retrieval launches an external process, latency and context switching will slow down the conversation. For Chinese notes, common typos (e.g., typing “自动同部” instead of “自动同步”) can also cause pure literal grep to fail completely. The following introduces the community plugin dsh-hot-search (maintainer caishzh), which maintains an index within the host process and provides five tools covering filename fuzzy search, precise/regex content retrieval, Chinese typo-tolerant content retrieval, and hit aggregation before batch reading.
What is this¶
dsh-hot-search is a resident hot search plugin for DSH: the index lives in the host process, so queries no longer spawn subprocesses for every call. In one sentence: it hits even with Chinese typos (README example: 自动同部 → 自动同步), achieving millisecond-level responses in the author’s self-test scenarios. This complements FFF’s grep fuzzy, which resulted in 0 hits for Chinese in actual testing (even for correct words). This plugin uses a self-developed line index to fill the gap in CJK typo-tolerant content retrieval.
- Current version (package.json): 0.1.3
- License: MIT
- Environment: Node >= 22; DSH >= 0.2.0-rc.1 < 0.3.0 (Tested by the author on
0.2.0-rc.2) - Community Directory: SkillHub Plugin Page (Classified as “Network Tools”; the plugin itself does not initiate network requests, see “Permissions & Privacy” below)
- Source Code: github.com/caishzh/dsh-hot-search
Core Features: Five Tools¶
| Tool | Purpose | Engine |
|---|---|---|
hot_find |
Filename/path fuzzy search (subsequence + frecency + git status). e.g., obsidain → obsidian; works for Chinese as well |
FFF native; degrades to built-in subsequence matching when unavailable |
hot_fuzzy |
Content retrieval with Chinese typo tolerance. mode=fuzzy (default) / literal / regex; multi-word defaults to AND, any=true is OR |
Resident line index (self-developed) |
hot_grep |
Exact literal / regex content retrieval | FFF native (requires availability) |
hot_plan |
Aggregates hits by file, outputs hit count, size, best similarity, and hit line numbers to help decide which articles to read first and in how many batches | Resident line index |
hot_stats |
Index scale, build time, staleness, FFF availability, and degradation reasons | — |
How to choose (from README): Remember a vague word → hot_fuzzy; remember filename → hot_find; remember exact words for regex → hot_grep; want to batch read a bunch of files → hot_plan.
Extensions included in the line index by default are .md, .txt, .markdown; single file and total index budgets per root can be adjusted in the configuration (see the next section).
Installation & Activation¶
Installation commands follow the README, choose one:
# Method 1: npm / registry
dsh plugin add dsh-hot-search
# Method 2: Local directory (for development; must be absolute path)
dsh plugin add D:\path\to\dsh-hot-search
# Method 3: tarball (pre-built artifact, also no allowBuilds authorization needed)
dsh plugin add D:\path\to\dsh-hot-search-0.1.0.tgz
# Verify this layer is loaded after installation
dsh --dump-config | Select-String hot-search
Ready to use immediately after installation: If roots is not configured, it indexes the DSH workspace (or process cwd). To index your own note library, override the plugin configuration in the profile’s cordis.patch.yml (Note: config is a full replacement, not a deep merge):
- id: hot-search
config:
roots:
- path: D:\path\to\your-vault
label: main
- path: D:\path\to\another\notes
label: work
Common configuration items (default values are based on the README table; refreshIntervalMs is explicitly set to 60000 within the bundle, so --dump-config might show 60 seconds instead of the documented default 120000):
| Key | Default | Description |
|---|---|---|
enabled |
true |
If off, no tools are registered |
roots |
[] |
Index roots; if empty, falls back to DSH_WORKSPACE → process cwd |
extensions |
.md .txt .markdown |
Extensions entering the line index |
maxFileSize |
2 MiB |
Files larger than this are not indexed |
maxIndexedBytes |
64 MiB |
Total budget per root |
refreshIntervalMs |
120000 (often 60000 in bundle) |
Auto-rebuild interval after staleness; 0 means no auto-rebuild |
fuzzyMaxErrors |
0 |
Fuzzy tolerance error count; 0 means automatic based on word length |
watch |
true |
Whether FFF finder watches files |
stateDir |
"" |
Root directory for frecency/history database |
maxResults |
50 |
Single return limit |
promptSection |
true |
Whether to inject usage instructions into the system prompt |
When verifying CLI, the README reminds: Do not use --profile desktop (DSH CLI rejects this built-in profile), use --profile demo instead.
Typical Usage & Self-Test Data¶
The agent calls these five tools exposed by DSH during the conversation; specific parameters follow the plugin schema and README. The author tested on an Obsidian library with 198 notes (Windows / Node 24.21 / independent workspace), taking the average of 8 rounds with mode=fuzzy, resulting in:
| Item | Actual Test |
|---|---|
| Index Scale | 198 files / 4485 lines / 278 KB |
| Index Build | 31–36 ms (Resident, built only once in-process) |
hot_fuzzy Chinese typo 自动同部 |
0.80 ms (Hits 自动同步) |
hot_fuzzy literal 同步 |
1.03 ms (15 results) |
hot_find obsidain |
2.36 ms (3 results) |
Algorithm self-tests that do not enter the host repository:
node dsh-hot-search\dev\hot-search-smoke.mjs
Use Cases & Notes¶
Who is it for: Developers who work long-term with local Markdown/text libraries (e.g., Obsidian vaults) in DSH, need fast filename fuzzy search, literal/regex grep, and want body text to be searchable even with Chinese input typos.
Permissions & Operation: The plugin reads text matching extensions under roots with the permissions of the current DSH host process to build an in-memory index; it does not transmit content to the network, the plugin itself makes zero network requests. Writes only occur in runtime state (frecency, FFF history, etc.), paths are resolved by stateDir or $DSH_HOME/system cache; it will not write into the indexed repository. Before installation, it is recommended to review the source code and MIT license yourself to ensure the index scope and state directory meet your compliance requirements.
Native Dependencies & Degradation: hot_find / hot_grep depend on the Rust native library @ff-labs/fff-node. If loading fails, the plugin does not crash entirely: hot_find degrades to built-in subsequence matching, hot_grep reports an error and suggests using hot_fuzzy; hot_fuzzy / hot_plan / hot_stats do not depend on FFF. The README is tested on Windows x64; other platforms need the corresponding @ff-labs/fff-bin-<platform>, otherwise they follow the degradation path. When developing with pnpm, pnpm install --node-linker=hoisted is required, otherwise FFF may silently degrade.
Conclusion¶
dsh-hot-search consolidates “filename fuzzy + precise grep + Chinese typo-tolerant content search + batch reading planning” into the DSH host process, reducing the cost of per-query process startup and explicitly emphasizing capability supplementation for CJK typos in the README. Directories and Documentation:
- SkillHub: caishzh/dsh-hot-search
- GitHub: github.com/caishzh/dsh-hot-search
The DSH ecosystem emphasizes “everything is a plugin”; SkillHub is an independent community directory and has no official affiliation with DeepSeek / High-Flyer. Before choosing any plugin, verify versions and configurations based on the repository README and local --dump-config.