How yujunzhixue/dsh-purge works
dsh-purge is a local DeepSeek Harness red-team plugin. The user opens its dock, chooses Clean or Drill, and applies changes to an official Web or desktop installation; changes can later be restored or uninstalled. Clean covers prompt/rule configuration and host patching, while Drill provides authorized asset, skill, and environment assessment with reports. The graph includes the documented update and startup reapply capabilities. Relationships are limited to README statements and shown source references; unsampled implementation details are not assumed.
Main entry points: index.js Plugin entry and dock · tools.js Drill tools · ui.js Drill interface · store-core.js Engagement and report store
Components 21
Plugin and lifecycle
- Plugin entry and dock
lib/index.js - Startup reapply
lib/reapply.js - Plugin update
lib/update.js
Host modification
- Host discovery
lib/core.js - Desktop support
lib/desktop.js - ASAR access and extraction
lib/extract-asar.js - Apply host patches
lib/core.js - Restore and uninstall
lib/uninstall.js
Prompt and policy
- Prompt rules and overrides
lib/rules.js - Prompt identity and injection
lib/identity.js - Network scope guard
lib/net-scope.js
Red-team drill
- Drill interface
lib/redteam/ui.js - Drill tools
lib/redteam/tools.js - Engagement and report store
lib/redteam/store-core.js - Platform and toolkit config
lib/redteam/platform-config.js - Skill availability and fixes
lib/redteam/skill-availability.js - Scoring rules
lib/redteam/score-rules.js - Report replay
lib/redteam/report-replay.js - Preset composition
lib/redteam/preset-composition.js
Other components
- Harness user
- Official Harness
Connections 26
- Harness user → Plugin entry and dock: opens dock
README.md - Plugin entry and dock → Official Harness: registers plugin
README.md - Plugin entry and dock → Host discovery: uses host state
lib/index.js - Plugin entry and dock → Prompt rules and overrides: routes rule operations
lib/index.js - Plugin entry and dock → Prompt identity and injection: builds prompt sections
lib/index.js - Plugin entry and dock → Drill interface: offers Drill page
README.md - Plugin entry and dock → Drill tools: exposes drill capability
README.md - Harness user → Apply host patches: applies Clean
README.md - Host discovery → Apply host patches: provides host targets
bin/dsh-purge.js - Host discovery → Desktop support: supports desktop
lib/core.js - Desktop support → ASAR access and extraction: uses ASAR access
lib/desktop.js - Apply host patches → Official Harness: writes host changes
README.md - Harness user → Restore and uninstall: restores or uninstalls
README.md - Plugin entry and dock → Startup reapply: supports startup reapply
lib/index.js - Plugin entry and dock → Plugin update: offers updates
lib/index.js - Prompt rules and overrides → Apply host patches: supplies prompt policy
lib/rules.js - Prompt identity and injection → Network scope guard: adds scope note
lib/identity.js - Drill interface → Engagement and report store: reads and updates engagements
lib/redteam/ui.js - Drill interface → Skill availability and fixes: checks skill availability
lib/redteam/ui.js - Drill interface → Platform and toolkit config: uses platform settings
lib/redteam/ui.js - Drill tools → Engagement and report store: reads and updates engagements
lib/redteam/tools.js - Drill tools → Skill availability and fixes: checks skill availability
lib/redteam/tools.js - Drill tools → Platform and toolkit config: uses platform settings
lib/redteam/tools.js - Engagement and report store → Scoring rules: loads scoring rules
lib/redteam/store-core.js - Engagement and report store → Report replay: uses report replay
lib/redteam/store-core.js - Drill tools → Preset composition: composes presets