AI Agent Hub
Back to plugins
dsh-plugin-context-trim preview

dsh-plugin-context-trim

Workflow Updated 2026.09.06

Run the following command in DeepSeek Harness:

dsh plugin install Pasumao/dsh-plugin-context-trim

Paste the following prompt into your AI chat to install this plugin:

Run dsh plugin install Pasumao/dsh-plugin-context-trim in DeepSeek Harness to install; source: https://github.com/Pasumao/dsh-plugin-context-trim

About this plugin

Running several dsh plugins at once means every request carries skills, tools, and prompt-section text that the current conversation does not need, needlessly consuming a precious token budget. dsh-plugin-context-trim lets you decide, per session, which plugins' skills, tools, and system-prompt paragraphs are visible to the model; suppressed items simply do not appear in that conversation's context, while every other session keeps full injection without any cross-talk.

The plugin uses a shadow-entry mechanism: cancelled items are overlaid with same-name entries at the agent-scope layer (modelInvocable:false for skills, tools.restrict deny-lists for tools/MCP, empty-text sections for prompt paragraphs), so the global registry is never mutated and everything unwinds cleanly when the agent is destroyed. A funnel button opens a plugin-grouped, three-state tree panel where you batch-toggle entries, see a live character-savings estimate at the bottom, and optionally save the selection as the workspace default so every new session inherits it. Once a session has produced at least one model step it locks automatically, and a confirm-guarded force-edit unlocks it with hot effect on the next step. Zero configuration, zero runtime dependencies, loopback-only HTTP.

Built for everyday users and plugin developers who stack multiple dsh plugins and want precise per-scene control over what the model sees, without touching the core package, registering any account, or exposing a public endpoint.

Screenshots

Use Cases

  • Code-writing sessions that do not need bot-kb skills, or chat sessions that do not need image tools
  • Multiple stacked plugins inflating every request with irrelevant schema that should be hidden
  • Saving a trim profile as the workspace default so every new session inherits it automatically

Best For

  • Daily users stacking multiple dsh plugins who want per-scene precision over what the model sees
  • Plugin developers who need to hide specific skills or tools during debugging or demos
  • Token-cost-sensitive power users who want to minimize irrelevant schema in every request