DSH Plugins Marketplace

DSH Plugins

Plugins

/

nightshift

l

nightshift

Manifest valid

Run an agent unattended for hours and get a morning brief that is an audit, not a summary. Signs a manifest before the work, prices every step at the execution boundary, rolls back a failed verificati

hasBundlePatch

nightshift

Run an agent unattended for hours — and get a morning brief that is an audit, not a summary.

Sign a manifest before the work: what it is for, which commands prove it worked, what must never run, and what it is allowed to spend. Then wrap each mutating command in a checkpoint that rolls itself back when verification fails. In the morning, get a brief generated from the run's own journal — what changed, what was verified, what was not, and the exact command to undo the night.

dsh plugin --profile web add github:liyixuan201211/nightshift

No install needed to try it:

npx --yes github:liyixuan201211/nightshift --help

The problem this is for

The tools this belongs to each answer one question about one moment — ctx-budget what it will cost, blastradius what it would destroy, deadend whether this failed before, mcp-cap what a server can do, skillnotary what a skill may do, rewind how to get it back. All of them are point-in-time and stateless.

An unattended run is neither. Once the person leaves, nobody is standing at those checkpoints — and the failures that matter over hours are the quiet ones. Drift: the objective changing, the budget passing, a step failing silently, a loop spinning. No single-point tool is watching for those.

nightshift is the layer that watches. It is also the generalisation of something the family already does by hand — ctx-budget's own bundle notes that it reads a tools/list dump that mcp-cap already produced.

The one idea

The manifest is a contract you sign while you are still awake. The brief is the audit of that contract.

nightshift init --root ~/work \
  --objective "finish the auth refactor and get the suite green" \
  --deliverable "npm test passes" \
  --accept "tests=npm test" \
  --accept "types=npx tsc --noEmit" \
  --forbid "git push" \
  --command "npm run build"

nightshift preflight --root ~/work     # may I start?
nightshift step --root ~/work --verify "npm test" -- npm run build
nightshift acceptance --root ~/work
nightshift brief --root ~/work

Only two of the declared things are enforceable, and that is the point: acceptance[] is a list of shell commands, so "done" is an exit code rather than a claim; forbidden[] is matched before execution, so a rule is a gate rather than a post-mortem. An objective with no acceptance checks produces a brief that says unclear and means it.

What the brief contains

The brief is a rendering of the journal, never a summary written from memory. That direction is what makes it worth reading:

  • a claim with no event behind it cannot appear
  • a declared acceptance check that never ran is reported as not run, not omitted
  • a step whose success was never verified is reported as unverified — a different fact from "passed"
  • every action the gate refused is listed, because a report of what a run did cannot show whether the gate ever fired
  • tools that were unavailable are named, with the count (5/6 family tools)
  • the baseline snapshot id and the exact rewind undo line to reverse the night

Its bottom line is one word: verified, failed, incomplete, recovered, nothing-done, refused, or unclear.

The gate sits next to the action, not the session

preflight judges the commands a run declares. But a step can run anything, and an unattended run has hours in which to change its mind. So the same judgement runs again at every execution:

  1. forbidden patterns — a standing instruction, matched first and never routable-around
  2. irreversibility class — priced by blastradius, read from the exit code (lost → terminal, costly → recoverable, safe → two-way, anything else → unknown)
  3. curfew — after --curfew-minutes, no new one-way action may start (two-way actions stay allowed: refusing to save a file at 6am would be a worse failure than the one a curfew prevents)
  4. class policy — the manifest's own knobs

A refusal means the command did not run and nothing was changed.

A real disagreement between two of the tools

blastradius calls this lost:

{ "recoverability": "lost",
  "why": "not inside a git repository, so nothing can restore it",
  "samples": ["data.txt"], "verdict": "lost" }

It means git cannot restore it. But rewind exists precisely to restore files git never tracked, with or without git — so for a path inside the protected root, the checkpoint taken moments later does restore it.

Trusting either tool alone is wrong: believing blastradius refuses nearly every real refactor; believing the snapshot treats rm -rf ~/something-else as recoverable when the snapshot never covered it. So nightshift uses blastradius's own samples to decide:

at-risk pathsresult
all inside the protected rootdowngraded to one_way_recoverable — warned, allowed
any outside the rootstays one_way_terminal — refused
findings name no pathsstays one_way_terminal — refused

The last row is deliberate: being unable to tell is never an upgrade.

Refusing to start is a feature

preflight exits 4 and starts nothing when a run would be unrecoverable. The usual cause is that rewind is unavailable — an unattended run with no way back is the one thing this refuses outright. Fix the cause; there is no flag that gets past it.

Exit codes are the contract

ExitMeaning
0ok
1error
2usage error
3attention — a preflight warning, or a step that failed and was rolled back
4refused — nothing was done, on purpose
5degraded — it ran, but some checks could not be performed
6nothing — there was nothing to do

-q suppresses output and never the exit code.

Notes on the seams with its siblings

  • --exclude .nightshift is not optional. nightshift keeps its journal inside the directory rewind protects, so every rewind call passes the exclude. Without it the journal would dirty its own snapshots and rewind status would never be clean. (Tested.)
  • Exit codes are translated, not trusted. 3 means OVER_BUDGET in ctx-budget, LOST in blastradius, DRIFT in deadend, CHANGED in mcp-cap, and "the tree differs" in rewind. Each tool's dialect is data in src/tools.js, overridable per run, and nightshift tools prints the table.
  • unverifiable is not ok. blastradius exits 5 for any command outside its vocabulary, and its JSON says "verdict": "none" when it means "I have no analysis for you". Reading that string as "no risk" waves through curl … | sh, so nightshift maps on the exit code and treats the verdict as corroboration only.
  • "Not priced" is recorded as info, never as a pass. blastradius only understands destructive commands, so pricing touch legitimately returns "I cannot tell you". Escalating that to a warning every time would train the operator to ignore warnings — so it is visible in the brief without raising the verdict. (onUnpriced, default ignore.)

Honest limits

  • It does not decide what to do. It holds a run to what was already decided.
  • It is not a scheduler. It does not wake up; something drives it.
  • It is not a sandbox. It predicts with blastradius and recovers with rewind; it does not isolate.
  • It fetches nothing. There is no npx fallback unless --allow-npx is passed. Resolution is local: --tools-dir, $NIGHTSHIFT_TOOLS_DIR, the configured search path, or PATH.
  • The brief is only as good as the acceptance checks. No oracle, no verification — and the brief will say so rather than implying otherwise.

Design

See DESIGN.md for the architecture, the exit-code normalisation table, and the reasoning behind the ordering rule that a refused run must not leave a snapshot behind.

License

MIT

Comments

Loading…

Similar plugins

dsh-advisor-plugin

by leeyoung1

Pairs the running executor with a stronger reviewer model through zero-parameter advisor() calls and step-based patrol checks, returning plan, correction, or stop guidance.

Development & InfrastructureManifest valid

★ 3

↓ 318/wk

MIT

TypeScript

Sep 11, 2026

dsh plugin --profile web add dsh-advisor-plugin

by bpc-oss

DeepSeek Harness plugin: subagent_routed — run a one-shot subagent fully mounted on ANY agent preset from ANY session, with per-call model/provider override and a model-availability pre-check.

Tools & CapabilitiesWorkflow & AutomationManifest valid

★ 3

MIT

JavaScript

Sep 12, 2026

dsh plugin --profile web add dsh-routed-subagent

by Jesse-njx

Scheduled agents on a cron: run a prompt on a schedule and get the digest where you already are, with overlap/missed-run/timeout safety defaults.

Workflow & AutomationManifest valid

★ 0

MIT

TypeScript

Aug 28, 2026

dsh plugin --profile web add @dsh-routines/bundle

by KelaoHu

Time-shifting task delegation for DeepSeek Harness (dsh): plan tasks at leisure, they run unattended off-peak, come back to a report. Human-adjudicated, desktop + web.

Workflow & AutomationManifest valid

★ 170

↓ 364/wk

MIT

TypeScript

Oct 11, 2026

dsh plugin --profile web add dsh-lowtide

by alpacachen

Runs one-time and RFC 5545 recurring Agent tasks in fresh DSH sessions, with visual schedule editing and session-linked history.

Workflow & AutomationDevelopment & InfrastructureManifest valid

★ 4

↓ 1.4k/wk

MIT

TypeScript

Oct 8, 2026

dsh plugin --profile web add @alpacachen/dsh-automation

by bwndlct

Session execution analytics and audit reports for DeepSeek Harness — see how your agent actually worked

Tools & CapabilitiesModels & ProvidersManifest valid

★ 3

MIT

JavaScript

Aug 14, 2026

dsh plugin --profile web add dsh-session-audit