Skip to content

jiezeng2004-design/dsh-requirements-alignment

40Last commit Aug 14, 2026

dsh-requirements-alignment DSH plugin

dsh-requirements-alignment turns user requests into a durable requirement baseline—goal, constraints, and decisions—and monitors agent execution for direction-level drift. It silently records the baseline, and only asks the user when a material change would occur, recording decisions and updating the baseline. The plugin is model-driven and works through system-prompt policy, tools, and a slash command.

How to install the dsh-requirements-alignment DSH plugin

dsh plugin --profile web add dsh-requirements-alignment

Copying does not run this command. Review the repository and version before installing the dsh-requirements-alignment DSH plugin.

dsh-requirements-alignment DSH plugin data source

dsh-requirements-alignment DSH plugin snapshot date: Aug 16, 2026

discovered

What the dsh-requirements-alignment DSH plugin can do

  • Automatically establishes and maintains a requirement baseline from user requests.
  • Detects drift candidates (scope expansion, constraint conflict, behavior change, etc.) and reports them via the `report_drift` tool.
  • Records user decisions and updates the baseline, preventing repeated questions.
  • Provides `/align` command for manual drift inspection and re-alignment.
  • Supports durable session state through dedicated alignment events, surviving resume, fork, and compaction.

Where the dsh-requirements-alignment DSH plugin fits

  • Prevent long-running agents from silently drifting away from the original task scope.
  • Allow users to approve or redirect direction changes mid-execution without losing context.
  • Maintain explicit constraints (e.g., 'don't modify UI' or 'keep API unchanged') throughout complex tasks.
  • Resume interrupted sessions with the same alignment state, avoiding re-asking settled decisions.

Who the dsh-requirements-alignment DSH plugin is for

  • Developers using DeepSeek Harness (DSH) for autonomous or semi-autonomous agent tasks.
  • Users who run extended agent sessions and need to ensure the agent stays on the intended path.

dsh-requirements-alignment DSH plugin limitations

  • Soft guard: drift detection is model-driven and not a hard gate; the plugin records and re-aligns but does not block execution.
  • Natural drift detection is model-dependent: in some runs, mid-task user direction changes may not trigger `report_drift` reliably.
  • `/align` command requires a command adapter and is not available in headless or ACP automation profiles.
  • Subagents cannot ask the user; they report drift candidates to the parent agent which owns the interaction.

dsh-requirements-alignment DSH plugin: from the repository README

Quoted from the jiezeng2004-design/dsh-requirements-alignment README, the upstream source of the dsh-requirements-alignment DSH plugin. Copyright remains with the original authors.

> Runtime requirement drift guard for DeepSeek Harness. Keep long-running agents aligned with user intent while they work. ## Overview `dsh-requirements-alignment` turns the user's request into a durable **requirement baseline** — goal, protected constraints, must-preserve behavior, allowed scope, and settled user decisions — and guards it while the agent executes. The agent works silently until a step would materially change the task direction; only then does the plugin surface a **drift candidate** to you, records your decision, and updates the baseline. Everything is folded from log-only session events, so resume, fork, and compaction recover the same state. **You decide the direction. The agent decides the engineering.** ## Requirements Alignment vs Plan Mode ``` Plan Mode asks: "Is this the right implementation plan?" Requirements Alignment asks: "Are we still solving the right problem?" ``` > Plan Mode prevents a bad plan from starting. > Requirements Alignment prevents a good plan from drifting. Plan Mode is the official review-approve step *before* implementation. Requirements Alignment is intent continuity *during* execution. They compose: plan, approve,

Read the full READMERepository license: MIT

dsh-requirements-alignment DSH plugin questions

How does dsh-requirements-alignment differ from plan mode?

Plan mode prevents a bad plan from starting by asking for approval before implementation. Requirements alignment prevents a good plan from drifting during execution by monitoring direction-level changes. They compose: you plan, approve, execute, and this plugin keeps execution on the approved direction.

Does the plugin slow down my agent?

No. In auto mode, the plugin contributes a policy section to the agent's system prompt, but the agent works silently with no periodic checks. Drift detection is model-driven and only triggers when the agent itself identifies a potential direction change. The overhead is negligible.

Can I disable the automatic alignment policy?

Yes. Set `mode: manual` in the plugin configuration. This removes the policy section from the system prompt, and you can still use the `/align` command manually to inspect and re-align. You can also set `mode: off` to make the plugin completely inert.

What happens if the agent interrupts the session? Will alignment state be lost?

No. The plugin stores alignment state in dedicated `alignment/*` session events that survive resume, fork, and compaction. The fold function reconstructs the state from the log, so you don't need to re-ask already settled decisions.

How do I handle subagents that need to change direction?

Subagents cannot directly ask the user. They include a 'Requirement drift candidate' block in their report to the parent agent. The parent agent then runs the drift protocol (calls `report_drift`) to get your decision. This design keeps the user interaction centralized.