YuanyuanMa03/dsh-funnel
Ingestion-time tool-output curation: keeps error and warning lines plus head and tail, spills the full text to disk with a pointer the model can read back; covers every text tool, small results pass through untouched.
dsh-funnel curates tool output before it enters the model's context: it wraps the tools/execute extension point (the seam the official timeout guard uses) and re-projects the canonical value of successful results — long string fields inside value (stdout, stderr, fetched pages, file contents) are replaced in place with head/tail plus every error/warning line, spilling the full text to .dsh-funnel/ with the path in a notice the model can read back on demand. A measured headless session cut a 2001-line (8,893-byte) bash result to 370 characters for the model while keeping the full text on disk — curation is pagination, not deletion, and the spool doubles as an audit trail of what the agent actually saw. Because the curated view replaces the result at the tool seam, the session log records exactly what the model saw. Boundaries: error results are never touched (short and load-bearing), and it complements compaction-time pruning rather than replacing it.
Install
dsh plugin add github:YuanyuanMa03/dsh-funnelREADME EN primary with zh edition verified 2026-09-02 (repo YuanyuanMa03/dsh-funnel; npm dsh-funnel 0.1.0 exists with repository field → this repo, but the README documents the git form as primary). Install per README: dsh plugin add github:YuanyuanMa03/dsh-funnel. Zero configuration; the plugin covers every tool that returns text (bash, file reads, web fetch, search) and results under the threshold pass through byte-identical.
Compatibility
DSH profiles with the tools/execute seam; config optional (maxChars default 4000, keepHead/keepTail, keyword patterns, per-tool aggressiveness, spill on/off).
Details
- Repo: YuanyuanMa03/dsh-funnel
- Category: Tools & Capabilities
- Stars: 1
- Version: git github:YuanyuanMa03/dsh-funnel (npm dsh-funnel 0.1.0)
- Last push: 2026-08-15
- First seen: 2026-08-15
Recent updates
Ingestion-time tool-output curation at the tools/execute seam; head/tail + error/warning lines kept; full text spilled to .dsh-funnel/ with a read-back path; error results untouched; configurable thresholds.
FAQ
- What does the model see?
- A curated view — head and tail lines plus every error/warning line, with a notice pointing to the full text spilled to .dsh-funnel/; the model can re-read the original on demand.
- Is anything lost?
- No — lossless at the disk level; the spool doubles as an audit trail, and since curation happens at the tool seam, the session log records exactly what the model saw.
- How does it differ from compaction pruning?
- Compaction-time pruning cleans up after the budget is already blown; dsh-funnel keeps it from being blown at ingestion — every result, immediately. They compose.
Alternatives
KitDoesIt/dsh-compaction-instant · JohnXu22786/context-pruner · EvilIrving/dsh-context-proxy