dsh-hindsight-bank-router: Unifying Hindsight Memory Bank Identity for DeepSeek Harness

j62268781-alt/dsh-hindsight-bank-router

Memory & ContextVerified
Listed on 2026-10-12
Page last updated 2026-10-12

A DSH plugin that routes Hindsight memory banks by remote repository name instead of local directory name, so every clone of the same repo shares one team memory bank.

dsh-hindsight-bank-router is a memory bank routing plugin for DeepSeek Harness that addresses a subtle hazard in the Hindsight coding plugin, whose bank name is derived from the local directory name. When the same repository is cloned into differently named folders, memory silently splits into separate banks that never converge; this plugin re-anchors identity to the remote repository name so every clone lands on one git-prefixed bank. It leaves Hindsight untouched and only feeds it a dynamically generated path-to-bank mapping, following a priority chain of user-level config, in-repo config, git remote name, and directory name, while any exception is merely logged and never blocks startup.

How to Install

install
npmdsh plugin --profile web add @j62268781-alt/dsh-hindsight-bank-router
Category
Memory & Context
Platform
DSH Plugin
Author
j62268781-alt
Distribution
Plugin

dsh-hindsight-bank-router Key Features

Anchors banks to remote repo nameDeclarative priority routing chainRequires two explicit opt-in switchesNo git spawn, reads config onlyFail-open, never blocks startup
Listed on dsh-plugin.org

dsh-hindsight-bank-router Repo Summary

What Does It Do?

It is a DSH plugin for DeepSeek Harness that anchors Hindsight coding-agent memory banks to the remote repository name instead of the local directory name. It solves the silent forking problem where the same repository, cloned into differently named local folders, ends up with memory banks that never converge. Rather than modifying Hindsight itself, the plugin feeds it a dynamically generated path-to-bank mapping so team memory actually merges. It is maintained by j62268781-alt under the MIT license and written in JavaScript.

Core Features

  • Remote-name anchoring: both the local folder name and the remote repository name resolve to the same git-prefixed bank name, so every clone of a repository shares one memory bank.
  • Declarative priority chain: user-level workspace file, in-repo config file, git remote name, then directory name, with the first match winning and explicit configuration always taking precedence.
  • Two locks required: the user-level switch must be explicitly set to true alongside the deployment-level switch; if either is false, your configuration is left completely untouched.
  • Never overwrites hand-written mappings: a sidecar state file records which paths it managed, and removal only touches entries it wrote itself.
  • No git subprocess: it reads .git/config directly, so there is no child process, no timeout, and no failure under machine load.
  • Fail-open behavior: any exception is only logged and never blocks DSH startup or sessions, and Chinese repository names resolve correctly.

How to Use This Plugin?

After enabling it in DSH, the plugin scans the configured root directories at load time, locates .git, resolves the remote URL, and safely merges the mapping into Hindsight's configuration file; Hindsight resolves the bank lazily on the first session, so it reads the correct mapping. To adjust behavior, write a bankId in the user-level workspace file or the in-repo config file, with the user-level entry taking precedence over the repository one; if you do not want repositories to carry configuration at all, disable repo-level lookup in the deployment config. Routing is off by default and only activates when both the user-level and deployment-level switches are true.

How to Troubleshoot This Plugin?

Memory still forks and never converges: first confirm the user-level switch is explicitly set to true, then confirm the deployment-level switch is on; if either is false the plugin will not touch your configuration. Repo-level configuration has no effect: check whether repo-level lookup was disabled in the deployment config, or whether a higher-priority bankId in the user-level workspace file already overrides it. A Chinese repository name resolves to garbled text: make sure you are using this plugin rather than hand-rolled mapping logic, since the correct order is to decode first and then sanitize. The plugin does not write a mapping as expected: non-git directories and git repositories without an origin produce no mapping and fall back to default behavior, which is intended.

This page is an independent rewrite of the plugin's official README — for authoritative documentation and the latest changes, refer to the source: j62268781-alt/dsh-hindsight-bank-router. The plugin is third-party code that runs on your machine once installed; inclusion does not imply endorsement — please review the source before installing.

Install, update, and uninstall this plugin in the Plugin Market of DeepSeek Harness's DSH Plugin Hub

DSH Plugin FAQ