huxin7735-collab/dsh-maintainer-doc-guard
dsh-maintainer-doc-guard keeps long-term project memory outside the context window: it maintains per-session maintainer documents (plan, conventions, stack, state, README), registers a standing system-prompt section that re-hydrates them every turn, and gates new infrastructure writes until a working same-basename precedent has been read.
dsh-maintainer-doc-guard keeps long-term project memory outside the context window and keeps a long turn answerable to the request that started it. It maintains a per-session set of maintainer documents - plan.md, conventions.md, stack.md, state.md and maintainer/README.md - under .dsh-maintainer-doc-guard/<session-id>/, creating the session folder and a blank file for each document on first open so two sessions in one workspace never share or mix a file. A standing system-prompt section lists the documents present and instructs the model to read the relevant one before every operation or thinking round, re-evaluated each turn and never accumulating in the history. A pre-write precedent gate denies a write or edit into a guarded infrastructure area until the session has read at least one working same-basename precedent, with a model-visible denial listing concrete candidate files to read first.
Install
dsh plugin --profile web add github:huxin7735-collab/dsh-maintainer-doc-guardCopied verbatim from the README's install line.
Compatibility
A dsh bundle with a monotonic pre-write guard: the tools/pre-execute listener delegates downstream first and only then applies its own deny, so it can never force an allow another guard refused, and after gate.maxDeniesPerTarget denials for one target it lets the call through and logs, so a stubborn model cannot deadlock. It complements dsh-fs-observation-policy's FS_NOT_OBSERVED check (which covers the file being replaced but not the contract it must obey) by gating writes to guarded infrastructure areas. The parent document directory is overridable with the docsDir knob, and each conversation gets its own isolated document set.
Details
- Repo: huxin7735-collab/dsh-maintainer-doc-guard
- Category: Coding & Development
- Stars: 2
- Version: GitHub repo huxin7735-collab/dsh-maintainer-doc-guard (2*); installed from GitHub (no npm package documented). Ships as a dsh bundle; the README documents the approach as measured on DeepSeek V4 Flash. English README.
Alternatives
030611/dsh-context-provenance · 030611/qiushi-dsh-evidence-audit · 0x3fffff/dsh-desktop-launcher