AI Agent Hub
Back to plugins
🧠

dsh-context-proxy

Memory Updated 2026.08.25

Run the following command in DeepSeek Harness:

dsh plugin install EvilIrving/dsh-context-proxy

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

Run dsh plugin install EvilIrving/dsh-context-proxy in your terminal, or clone from https://github.com/EvilIrving/dsh-context-proxy for a local install, to enable the on-demand context-retrieval plugin in DeepSeek Harness.

About this plugin

In the DeepSeek Harness pipeline, output-retention, spill-policy, compaction-basic, and session-query already handle truncation, spill-to-disk, compaction, and token metering. What is missing is a clean, model-facing read-back path for earlier turns. dsh-context-proxy fills exactly that gap with a thin, non-destructive layer: it registers three on-demand retrieval tools into the agent tool set so the model can pull context from already-persisted logs whenever needed, with zero extra token cost until a tool is actually invoked.

The three tools are purpose-built and complementary. context_query filters by sequence number, event type, surface, or text and returns a lightweight list of matches. context_slice reads a single event together with a bounded before/after window, ideal for inspecting the immediate context around one message. context_grep performs line-level ripgrep search against spill files, falling back to a literal, case-insensitive, whitespace-flexible scan via sessionQuery when no spill path is available. Every result carries a replay-safe citation (session: rebuildable from the canonical log, or path:line pointing to a local spill file), so the model can locate content precisely instead of guessing ids. Both sessionQuery and subprocess are optional backends read via ctx.get; a missing backend degrades the tool to a clean isError result rather than blocking indefinitely. The ripgrep binary ships from @vscode/ripgrep, so no system rg install is required and no shell layer sits between the argv vector and the search engine.

If your workflows involve long conversations where the model must repeatedly revisit early instructions or tool outputs, dsh-context-proxy is a low-intrusion add-on. It does not alter existing spill or compaction policies; it simply appends three tool schemas and returns results as compact JSON that appends to the surface without rewriting earlier tokens, keeping KV-cache behavior clean. It is well suited for long-horizon agents, multi-turn debugging sessions, or multi-agent coordination where precise retrieval is essential for maintaining contextual continuity.

Use Cases

  • Precisely recalling early instructions or tool outputs in long conversations
  • Inspecting a bounded before/after window around a specific message during multi-turn debugging
  • Retrieving persisted history on demand in multi-agent coordination instead of relying on model memory

Best For

  • Developers building long-horizon agent applications
  • DeepSeek Harness users who need contextual continuity across multi-turn conversations
  • Teams in multi-agent systems that require precise retrieval of session history