Agent-Clinic: Diagnosing Agent User Experience Issues with Reviewable Evidence

Preface

When running Agents in DeepSeek Harness (DSH), session logs accumulate over time: where tokens are being spent, whether tools are stuck in loops, whether approvals are slowing things down—summary numbers alone often fail to reveal “what needs to be changed.” The common approach is to dig through raw jsonl files or adjust profiles by feel, which is costly and hard to reproduce.

agent-clinic (Agent health clinic) addresses this exact class of problem: it read-only scans local Agent sessions, flags experience-related anomalies using evidence that can be reviewed item by item, and provides actionable prescriptions for each issue. It is maintained by GitHub user 1687210989, classified as a workflow plugin in the DSH community directory; the repository is licensed under MIT, the current package version is 0.2.0, and it requires Node >= 22.15.

The following sections describe its positioning, capabilities, installation methods, and typical usage. Facts are based on the repository README and package.json.

What is this

In one sentence: a “health report” generator for local Agents—beyond statistics, it emphasizes evidence localization (including session.v4.jsonl.zstd#L… and ./run.sh show verification commands) and prescriptions (YAML snippets, slash commands, plugin installation entries, or clear statements that no solution exists).

What it does not do is also clearly stated in the README: it does not proactively push notifications, does not install things for you, does not modify configurations, does not diagnose code quality, and does not send conversations to external services.

Core Features

Evidence + prescriptions, not vague suggestions

  • Problem descriptions are tied to specific sessions and time windows. For example, a loop will state “same tool + same parameters + same error ≥3 times” and provide log line numbers.
  • Prescriptions read local real configurations and write out “current value → recommended value”; if the current value is already no weaker than the recommendation, the withdrawal reason is explained in the “evaluated but not given prescriptions” section.
  • Dimensions that were never implemented or had insufficient samples are listed separately in the report to avoid being confused with “no anomalies detected.”

22 diagnostic dimensions (all implemented)

The README categorizes metrics into token/context (C series), execution and tools (E/N series), assets and patterns (A series), cross-session (K1/K2), etc. A selection is shown below:

Type Example ID Meaning (brief)
High severity C1 Output per request exceeds the baseline of other main sessions by 2x, and the total is ≥20,000
High severity E1 Same tool, same parameters, same error repeated ≥3 times (infinite loop)
High severity N2 Command-type tools hitting high-risk patterns (e.g., rm -rf, reset --hard)
Medium severity C5 Single session compression ≥3 times, with DSH-measured freed tokens (shadowedTokenCount)
Medium severity N3 Approval requests ≥5 times, with separate columns for rejected / result unidentifiable / no corresponding decision record
Cross-session K1/K2 Based on local salted fingerprint snapshots ~/.agent-clinic/text-fingerprints.json (body text not persisted; can be disabled with fingerprints --clear or AGENT_CLINIC_NO_FINGERPRINT_STORE=1)

When the same type of problem hits across multiple sessions, it is merged into a single card marked “N occurrences,” but expanding it still preserves each session and evidence. For complete thresholds and judgment criteria, see the repository docs/diagnostics.md.

Prescriptions and plugin recommendations

Prescription types include: behavioral suggestions, profile patch modifications, installation/enabling of community plugins, etc.; it searches the plugin directory and matches by capability tags and keywords, labels the source (manual verification / npm / GitHub), and does not recommend already-installed plugins.

DSH plugin form

When installed as a DSH plugin, the sidebar has a “Health check” entry and a full-page panel, with support for near-real-time badges. The CLI side supports scan, report, show, and prescription feedback (e.g., ./run.sh rx reject <target ID>). Local smoke self-checks score 345/345 (the README badge description indicates that CI badges reflect the actual status of GitHub Actions).

Installation and Activation

DSH community directory page: https://www.skillhub.cn/plugins/1687210989/agent-clinic
Source repository: https://github.com/1687210989/agent-clinic

Install as a DSH plugin

Open Plugins → Add Plugin in the Harness sidebar and paste the repository URL:

https://github.com/1687210989/agent-clinic.git

After installation, you must completely exit and restart Harness—plugins are only loaded at startup.

Install as a Skill (optional)

Install with a single command, no repository cloning needed:

curl -fsSL https://raw.githubusercontent.com/1687210989/agent-clinic/main/install.sh | bash

Typical Usage

In the plugin directory or Skill installation path, you can use the repository-provided ./run.sh (or npm run report which corresponds to node src/cli.mjs report) to generate reports.

Generate a health check report:

./run.sh report

The report includes a scan overview, problem categories sorted by severity (each with conclusion, impact estimate, confidence, evidence localization, and verification commands), a prescription list, as well as sections like “undetected dimensions” and “not yet implemented dimensions.” To verify a single piece of evidence, for example:

./run.sh show "…/session.v4.jsonl.zstd#L3"

The local patch path targeted by configuration-type prescriptions in the README example is ~/.dsh/profiles/desktop/cordis.patch.yml (the tool is read-only and does not modify it for you).

Applicable scenarios and notes

Who it’s for: Developers who use Agents on DSH long-term and need to systematically troubleshoot experience issues such as token waste, tool infinite loops, approval friction, unused skills/MCPs, and repeated questions across sessions, and are willing to modify configurations or behaviors themselves based on evidence.

Permissions and security: The plugin read-only accesses local sessions and configurations with the current DSH process permissions; please read the repository source code and MIT license before installation. K1/K2 involve local fingerprint snapshots; if you do not accept local storage of user text hashes, you can disable fingerprint storage.

Platform scope: The README states that DSH session parsing, reporting, and plugin UI are in a usable state; the WorkBuddy platform is pending implementation.

Ecosystem notes: DSH follows the principle that “everything is a plugin”; the plugin directory on skillhub.cn is a community site and has no official affiliation with DeepSeek / High-Flyer.

Conclusion

agent-clinic moves Agent usage analysis from “a pile of numbers” to “verifiable evidence + actionable prescriptions,” and honestly labels unimplemented dimensions and insufficient sample situations. If you are already using DSH, you can add the plugin as described above and restart Harness, then run ./run.sh report to do a health check against your local sessions.

羽毛球分组比赛记分
小程序二维码

欢迎使用《羽毛球分组比赛记分》微信小程序

Xiaoye