Preface

The search box in the left sidebar of the DeepSeek Harness (DSH) Web client can, by default, only match session titles and workspace names. This is because the official full-text index (@deepseek-ai/dsh-session-query-sqlite) is an optional capability in the Web setup and is disabled by default.

This plugin enables the SQLite FTS5 full-text index by overriding configuration entries in the profile’s cordis.patch.yml; it also rewrites the search filtering logic to support filtering results by time range and content source (user messages / DSH replies / project names).

What It Is

This is a DSH plugin for enhancing session search in the Web sidebar. It provides a local SQLite index, supports keyword search over historical session content, and has zero third-party dependencies.

  • Maintainer: CHIP-PHILO-GH
  • License: MIT

Core Capabilities

  • Custom search scope: Adjust the time range (all / 1 / 3 / 7 / 30 days) and content source (user messages / DSH replies / project names) in real time above the search results.
  • Persistent settings: User selections are written to the official settings document or localStorage and persist after restart.
  • Snippet display: Replace omitted single-line hit snippets with two lines of original text.
  • Local indexing: Uses SQLite FTS5 and supports creating the index only on the first search, avoiding startup blocking.
  • Index warm-up: Enabled by default; after startup, it runs a search in the background after a 45-second delay to ensure the index is ready.
  • Zero third-party dependencies: Depends only on official DSH modules.

Installation and Enablement

Installation requires modifying three files in the profile configuration directory (referenced as <DSH_HOME>, default %USERPROFILE%\.dsh); restart dsh web after changes.

  1. Mount the plugin directory
    Mount the plugin directory (referenced as <REPO>) under the profile’s node_modules. On Windows, use a junction to save space:
    $modules = Join-Path $env:USERPROFILE '.dsh' 'profiles\web\node_modules'
    New-Item -ItemType Directory -Force -Path $modules | Out-Null
    New-Item -ItemType Junction -Path (Join-Path $modules 'dsh-session-search') -Target '<REPO>'
  1. Update package.json
    Add the dependency and bundle reference to the profile’s package.json:
    {
      "dsh.profile.bundles": ["dsh-session-search"],
      "dependencies": {
        "dsh-session-search": "link:<REPO>"
      }
    }
  1. Enable full-text indexing
    Override the official index configuration in the profile’s cordis.patch.yml and set openAt: first-search:
    - id: session-query-sqlite
      config:
        path: '<DSH_HOME>\profiles\web\session-search.db'
        openAt: first-search

Configuration and Usage

After installation, the sidebar search box supports full-text search.

  1. Use the scope control
    Expand the sidebar search box and enter a keyword; a Scope control appears above the results. Click it to adjust:

    • Time range: all / 1 / 3 / 7 / 30 days.
    • Search content: check “User messages,” “DSH replies,” or “Project names.”
    • These changes take effect immediately and do not require a restart.
  2. Keep content matches only
    Uncheck “Project names,” and the sidebar will show only matches in session content, filtering out rows that match only names.

  3. Rebuild the index
    Delete the <DSH_HOME>\profiles\web\session-search.db file. The index is automatically rebuilt on the next search.

Testing and Verification

The plugin includes an offline verification harness that can check code and configuration consistency without running DSH or an internet connection:

node test.mjs

This command runs syntax checks, host and client verification harnesses, and verifies consistency between the README documentation and the configuration tables.

Notes

  • The plugin runs with the permissions of the current DSH process; review the source code and license before installing.
  • It depends on official DSH modules, not third-party libraries.
  • The official full-text index is optional in the Web setup; this plugin enables it by overriding openAt in cordis.patch.yml.

References

  • Catalog: https://www.skillhub.cn/plugins/CHIP-PHILO-GH/dsh-session-search
  • GitHub repository: https://github.com/CHIP-PHILO-GH/dsh-session-search