dsh-purge recovery: rollback, rules and backups
You delete dsh-purge's folder, restart, and the panel is gone while the policy still sits in its modified state — the classic accidental-deletion scene, because plugin files and policy state are two different things and deleting the former does not undo the latter. dsh-purge is a community red-team evaluation plugin that rewrites host policy and prompt configuration (plugin entry). Recovery follows priority: classify the change, run Restore, compare backups and rules, and only then reinstall. When reinstalling, the entry is DSH Plugin Hub.
First identify what dsh-purge changed: what DeepSeek Harness can roll back
Recovery does not start with action but with classification: plugin files, the policy default copy and the profile overlay each roll back differently. Misclassify and every step makes it messier.
| Change type | Rollback possible? | How |
|---|---|---|
| Host policy | Yes | Restore on the Clean page |
| Plugin files | Yes, by reinstalling | Reinstall the plugin |
| Profile overlay | Yes, from backup | Edit back or restore the backup |
| Session history | Not managed by dsh-purge | Handle through the session mechanism |
- Check whether the panel still exists; if it does, plugin files are probably intact and Restore comes first.
- If the panel is gone but the plugin list has an entry, restart once to rule out a loading problem.
- If the plugin list has no entry either, files were deleted or the profile manifest lost the entry; reinstall.
- Inspect the profile overlay for hand-written content so your own edits are not blamed on the plugin.
- Record one line per change type before deciding which to touch first.
Classification prevents "using a reinstall to solve a policy problem". While the policy remains modified, reinstalling only brings the panel back and leaves the altered default copy in place.
First priority: Restore the DeepSeek Harness official default copy
As long as the panel opens, run Restore before uninstalling or reinstalling. This step returns host policy to the official default copy and is the lowest-risk, most verifiable rollback available.
- Open the dsh-purge Clean page and copy the current state fields as a baseline for comparison.
- Run Restore and do not edit prompts or switch rule sets at the same time.
- Let it trigger the restart and do not interrupt it manually.
- Open a new session after the restart; old sessions do not reread the environment.
- Return to the Clean page and confirm the state says rolled back, not merely "looks normal".
Do not Apply immediately after Restore. Confirm the default behavior is back before deciding whether to re-apply rules; doing both at once makes it impossible to tell whether rollback failed or the new rules broke something. The full state machine is in how to use dsh-purge.
What Restore lets you judge immediately
- Panel state: it says rolled back, not unknown.
- New session: behavior returns to default.
- Old session: not valid evidence; a new session is mandatory.
- Overlay: no leftover references to the old rules.
Second priority: compare backups and rules to recover the DSH plugin policy you changed
Restore handles "return to official defaults"; backups handle "recover the rules you wrote yourself". They are not substitutes: return to defaults first, then restore only the part you need.
- Find the rule or prompt files you backed up earlier and confirm their version and date.
- Compare them with the current Clean page fields and list the differences between official default and what you want back.
- Restore only the rules you are sure you need; never overwrite the whole set.
- Re-apply after restoring, one rule group at a time.
- Open a new session to verify behavior and confirm you did not carry the bad pre-deletion configuration back with it.
Without a backup, do not rewrite everything from memory. Leave the environment at official defaults and add the minimum necessary rules one by one, verifying each. That beats restoring a remembered configuration in one shot. For rule grouping, see dsh-purge rule sets.
Third priority: reinstalling the DSH plugin and re-applying in order
Reinstall only when plugin files are gone, and after reinstalling run Restore before Apply; reverse the order and old policy may be written back. This is the easiest step to get wrong.
- Reinstall dsh-purge from the market or installed list in DSH Plugin Hub.
- Confirm it went into the correct profile; web and desktop use different profiles and must be handled separately.
- Restart the host, open the Clean page and check patch state first.
- If the state shows not rolled back, run Restore, then open a new session to verify default behavior.
- Apply rules from backup only when needed, one group at a time.
A reinstall does not roll policy back by itself; it only brings the panel back. Applying immediately after reinstall stacks rules on top of an unconfirmed default state, making later diagnosis harder.
Confirm the profile before reinstalling
- Install into the web profile on web and into each desktop profile on desktop.
- Reinstall only the side that broke; leave the other side alone.
- After reinstalling, read the state before deciding between Restore and Apply.
Verification after recovery: DeepSeek Harness rules and sessions
Recovery is complete only when three things agree: panel state, new-session behavior, and manifest plus residue. Old sessions are not evidence.
- Panel state: the Clean page clearly reports rolled back, not blank or unknown.
- New-session behavior: create a session and compare a fixed test input before and after recovery.
- Manifest: the installed list and profile manifest contain no duplicate entry or old package name.
- Overlay: the profile holds no leftover references to old rules.
- The other side: if both web and desktop are used, check each separately and never infer one from the other.
"Second contamination" usually comes from three places: an old session that never refreshed, an overlay that was never cleaned, or the other side that was never recovered. None of them lives at the "is the plugin back" layer, which is why verification cannot stop at the plugin list.
Keep a recovery record too: note the state before and after, which Restore or Apply ran, and the new-session result. Next time a deletion goes wrong, that record saves the whole classification step. For how dsh-purge differs from a normal uninstall, see dsh-purge versus uninstall; for where cleaning ends and rollback begins, see what dsh-purge is.
FAQ
DeepSeek Harness requires identifying what was deleted first: plugin files, the strategy's default copy, or a profile overlay. Reinstalling immediately overwrites the scene and may leave old policy active. The right order is classify the change, run Restore when possible, and only then discuss reinstalling.
DeepSeek Harness dsh-purge uses Restore to return host policy to the official default copy, undoing changes it wrote earlier. After Restore, restart and open a new session to verify, because an existing session does not reread the runtime environment automatically.
DeepSeek Harness usually has no panel once the plugin files are gone, so reinstall the plugin first and then run Restore on the Clean page. The order cannot be reversed, because no panel means no Restore entry. After reinstalling, do not Apply first; restore official defaults, then decide whether to re-apply.
DeepSeek Harness shows three checks: the panel reports rolled back, a new session behaves like the default, and neither the plugin list nor the profile manifest holds residue. Old sessions are not valid evidence and a new one is mandatory. Only when all three agree is recovery complete.
DeepSeek Harness web and desktop use different profiles, and plugin and policy state are maintained separately, so each side must be checked and recovered on its own. Recovering one side leaves the other with its previous policy, so never infer one side from the other.
Related Terms
- dsh-purge
- dsh-purge is a community red-team evaluation plugin for installed DeepSeek Harness that manages jailbreak or prompt-injection prompts and rewrites host policy. It is not a cache-cleaning tool and does not handle uninstalling.— https://dsh-plugin.org/plugins/yujunzhixue/dsh-purge
- Restore
- Restore is the dsh-purge operation that returns host policy to the official default copy, used for rollback and wrap-up. It is more verifiable than overwriting files by hand, and after it runs you must restart and open a new session.— https://dsh-plugin.org/plugins/yujunzhixue/dsh-purge
- Apply
- Apply is the dsh-purge action that writes rules and policy into the host and triggers a restart, and it is required after installation. Without a completed Apply, the panel exists but behavior does not change.— https://dsh-plugin.org/plugins/mmparko/dsh-purge
- official default copy
- The official default copy is the original version dsh-purge preserves before rewriting host policy, and it supports Restore rollback. It is neither the plugin installation package nor your own configuration file.— https://dsh-plugin.org/plugins/yujunzhixue/dsh-purge
Sources
- dsh-purge plugin entry (YuJunZhiXue)· dsh-plugin.org
- dsh-purge plugin entry (mmparko)· dsh-plugin.org
- DeepSeek Harness docs - plugins and lifecycle· deepseek-harness.github.io