The DeepSeek Harness (DSH) ecosystem already has many tools for tracking token usage and estimating costs, but it lacks statistics for “wall-clock time.” dsh-timesheet is a client-side plugin that fills this gap. It extracts turn-level data from session logs and calculates total duration along with aggregate statistics by day, project, provider, and source.
Core Features¶
This plugin provides turn-based time tracking. Key features include:
- Data Source: Reads turn-level timing data from standard DSH session logs.
- Aggregation Dimensions: Supports rollups by day, by project, by model provider, and by source (desktop / CLI / VS Code, etc.).
- Metrics: Provides total time spent, number of tool calls, failure rate, and time to first token.
- Output Formats: Supports Markdown reports and machine-readable JSON reports (
dsh-timesheet/v1format). - Usage Modes: Provides a command-line tool and also supports invocation through an agent inside Harness.
Installation and Enablement¶
Use the official installation command to add the plugin to your local DSH environment:
dsh plugin add dsh-timesheet
Typical Usage¶
Command-Line Usage¶
Run it in a directory that contains *.jsonl session logs:
dsh-timesheet <dir> [--json]
dir: Specifies the session log directory (e.g.,~/.codex/sessions).--json: Outputs a machine-readabledsh-timesheet/v1report.
Examples:
npx dsh-timesheet ~/.codex/sessions
npx dsh-timesheet ~/.codex/sessions --json
In-Agent Invocation¶
Invoke the tool directly in a DSH conversation:
Generate a timesheet report:
timesheet, pointing the directory to the session logs directory.
The tool returns a structured statistical report.
Use Cases and Notes¶
This plugin is suitable for developers who need to analyze the actual runtime duration of agents and optimize workflow efficiency.
- Read-Only Design: The plugin is inherently read-only and does not modify session log files.
- Runtime Environment: Requires Node.js version >= 18 installed in the local environment.
- Log Format: Supports parsing plain-text
.jsonllogs only. For compressed.l.zstdlogs, decompress or export them before analysis.
Summary¶
dsh-timesheet provides the scarce “wall-clock time” statistics capability in the DSH ecosystem. Through CLI or agent invocation, it quickly surfaces session duration distributions and tool-call behavior, providing data-driven support for time management.