UI Enhancements

dsh-task-lens

apoclota/dsh-task-lens · ★ 1

apoclota

Always-on draggable task lens for DeepSeek Harness: context-reconstructed steps with 7-phase coding plans, in-phase progress, a focused done/doing/next panel with full steps in detail…

License
MIT
Added
2026-10-30
Maintenance
active
Install kind
github
Manifest details
Manifest status
Declared
Manifest path
package.json#dsh
Manifest checked
2026-10-30T09:38:39.434Z
Lifecycle scripts
None found

Static manifest checks report declarations only; they are not compatibility or security review.

安装

dsh plugin --profile web add 'github:apoclota/dsh-task-lens#074a59f7b6fb06446e8214b539fe238b57f0ff94'

GitHub 源码安装:首次需按提示配置 allowBuilds 构建授权后重试

For install and environment setup, plus plugin development tutorials, see DSH community docs ↗

README

Source README · body: en · Read Chinese README

Table of contents
  1. What you get
  2. Install
  3. Configuration
  4. How the memory works
  5. Privacy and security
  6. Development
  7. License

English | 中文

A "task lens" plugin for DeepSeek Harness: it reconstructs steps from your request, the model's plan, tool calls and errors, translates what the agent is doing into plain Chinese, shows status lights and one honest progress bar, and remembers the mistakes of past runs for the next one. No model calls, no extra token spend.

dsh-task-lens

What you get

  • Steps that follow the task — it first classifies the request as drawing, coding, document, data, research or setup, then shows the matching steps. A drawing request walks through "plan composition and palette → draw frame and outline → lay down base colours → paint → adjust light and detail → export"; a coding request walks through "locate the problem → read code → edit → add tests → run tests → check the build → wrap up". Coding, setup and general tasks also reconstruct steps from actual tool calls: frontend and backend are split, consecutive writes in one area are merged, and verification steps that have not happened yet are added. It also reads the model's reasoning and numbered plan to advance the active step — no extra model calls.
  • Tool calls in plain language — pwsh, read, grep, edit, web_fetch and friends become "running tests", "editing login.tsx", "searching for «submitting»", with the command, file or query kept in view.
  • One honest progress bar, with a little cosmos — driven by the todo list when the model writes one; otherwise by the active step's position in the plan. Reaches 100% on a normal finish and never fakes completion after an abort. The thick filled section glows and streams tiny stars left to right, while a gently swaying DeepSeek mascot image rides the current position and turns green when done.
  • One status light, right by the bar — blue for reads, searches and analysis; amber for writes, edits and installs; teal for runs and tests; green when done; red for errors or a lost connection. Step rows use text and check marks instead of extra lamps.
  • Three focused rows on the main panel — the panel always shows "done / doing / next" instead of a long list you have to scan. Concise mode keeps those rows too. A single changing "thinking" line below them summarizes the current intent. Each row carries the concrete action ("writing frame.svg", "editing petals.svg") plus the first line of code, command or target file. ops_bash also shows its command, script, cwd and timeout. Hover for the full content; secrets are redacted automatically.
  • The detail page shows every step — click "详情" for a longer thinking summary of the current judgement and next move, then all steps, their status and detailed actions. Raw reasoning is not exposed. For full-stack work you can see which files were read, which layer changed, and whether tests and build steps have been added.
  • Progress keeps moving — coding uses 7 phases; document, data, research and setup use 6–7. The active phase advances with tool-call count and elapsed time, so long-running commands do not freeze at one percentage. A new instruction during a running turn triggers a fresh estimate: progress dips for the added work, then climbs again with the next tool calls.
  • Always-on panel — once enabled it stays visible. With no active task it drops into a ready state instead of disappearing. It starts above the composer; drag the title bar anywhere and the position is remembered, or double-click the title bar to reset. Narrow or multi-thread windows get a smaller panel capped at 55% of the viewport height, and duplicate panel hosts are cleaned up.
  • Detail page and settings — the "详情" button shows the task translation, current tool, a longer thinking summary, every step and recent actions. "设置" adjusts panel size, custom width/height (320–900 × 220–900), information density (concise / normal / detailed) and one of five background colours, and shows the current lessons. Preferences save automatically. The detail page reuses local context — it never makes an extra model call or network request.
  • Collapsed view keeps the essentials — status light, starry progress bar, percentage and a one-line task report. Expand it whenever you want the rest.
  • Automatic error memory — failures are classified in Chinese (missing file, permissions, port in use, missing dependency, timeout, rate limit, …), duplicates are merged with a counter, and a successful retry marks the entry fixed.
  • Next run avoids them for free — lessons land in a managed block inside ~/.dsh/AGENTS.md, which the host already loads (10 entries / 1200 chars by default).
  • Zero token cost — translation, planning, progress and lesson handling are pure local rules. No model calls, no network requests.

Install

Desktop: Settings → Plugins, search for dsh-task-lens, install, reload.

CLI:

dsh plugin --profile web add dsh-task-lens

Use your own profile name instead of web (a desktop profile is owned by the app — install it from the app's plugin page instead).

The panel appears above the composer once installed. Drag its title bar to move it; double-click the title bar to reset. To preview the hover detail on its own, open assets/demo.html?hover=1; to see the no-task ready state, open assets/demo.html?idle=1:

Hover detail

Task detail page

Settings, backgrounds and current lessons

Configuration

In the profile's cordis.patch.yml:

- id: dsh-task-lens
  name: dsh-task-lens
  config:
    showPanel: true
    showThinking: false
    lessonsEnabled: true
    lessonsMax: 10
    lessonsMaxChars: 1200
Key Default Meaning
showPanel true Inject the floating panel above the composer (lessons are still recorded when off)
showThinking false Also show a line while the model is thinking without tool calls
lessonsEnabled true Record errors and write them to AGENTS.md
lessonsMax 10 Max entries written to AGENTS.md
lessonsMaxChars 1200 Char budget of the managed block
pollMs 400 Panel polling interval (local read only, no token spend)
keepDoneMs 120000 How long finished task data stays before the panel returns to its ready state (the panel itself stays visible)
instructionsFile $DSH_HOME/AGENTS.md Instruction file receiving the managed block
lessonFile $DSH_HOME/dsh-task-lens/lessons.json Lesson store

How the memory works

  1. Tool errors are classified from error.code plus the message.
  2. Same tool + same target + same error merge into one entry with a repeat counter.
  3. Entries are ranked and written into the managed block in ~/.dsh/AGENTS.md (<!-- dsh-task-lens:begin --> … <!-- dsh-task-lens:end -->); nothing outside the block is touched.
  4. A later success for the same tool on the same target marks the entry fixed; once only fixed entries remain, the block is removed entirely.
  5. Raw records stay in ~/.dsh/dsh-task-lens/lessons.json for manual inspection.

Privacy and security

  • Everything runs locally; the plugin makes no network requests and uploads nothing.
  • Paths in lessons are masked: $DSH_HOME and the user home become $DSH_HOME and ~.
  • The local HTTP endpoint only accepts GET and requires a loopback host, a same-origin request and a non-cross-site Sec-Fetch-Site.

Development

npm test

Syntax-checks lib/ and runs the dependency-free smoke test (fake host composition, simulated session events, task classification, step plans, progress, translation with redacted previews, lesson persistence, the managed block, and endpoint security).

Preview the UI by opening assets/demo.html in a browser — it ships with demo data and needs no host. Add ?hover=1 to auto-open the hover detail.

License

MIT