DeepSeek Harness Plugin

PerryLink/dsh-legal-clause

Stars ★ 0 Downloads (30d) 1,437 Category Workflow & Automation Added 2026-11-02 npm dsh-legal-clause

Contract clause work: build the clause tree, map it against a 12-key playbook, register the playbook and export the unresolved report — 5 `legal.*` tools.

Install

# from npm (prebuilt)

dsh plugin --profile web add dsh-legal-clause

# from GitHub (first run asks for allowBuilds approval — follow the hint, retry)

dsh plugin --profile web add github:PerryLink/dsh-legal-clause

Any plugin you install runs third-party code with your own permissions — it can read your files, use your credentials, and reach the network, and tool approvals don’t sandbox it. GitHub-sourced plugins also run build scripts at install time — pnpm blocks those until you allow them, so an install can stop with ERR_PNPM_GIT_DEP_PREPARE_NOT_ALLOWED or ERR_PNPM_IGNORED_BUILDS; dsh prints the exact key to add under allowBuilds in your profile’s pnpm-workspace.yaml, and the install works on the next run. Allowing a build is a trust decision: only install sources you trust, and pin a commit (github:owner/repo#sha).

README

dsh-legal-clause

Official repository. The only official repository of this package, maintained by PerryLink. Same-name repositories under other accounts are not affiliated. Apache-2.0.

CI DSH Market

Legal clause tree, 12-key playbook mapping and unresolved report.

Status: alpha / public-synthetic / partial / not counted / not GA. No customer evidence, customer data, or production-readiness claim.

English · 简体中文 · Español · Português · हिन्दी

dsh plugin --profile <profile> add dsh-legal-clause

⭐ If this helps, a star makes it easier for the next person to find it. Nothing is gated behind it.

Workflow diagram for dsh-legal-clause: local input, plugin, local output.

Workflow: local input → plugin → local output. No model call is required.

Real dsh-legal-clause terminal output

Real local test run; no model or network call.

Install

Install and verify:

dsh plugin --profile <profile> add dsh-legal-clause
dsh --profile <profile> --dump-config | grep dsh-legal-clause

Uninstall:

dsh plugin --profile <profile> remove dsh-legal-clause

Install channels

npm is the recommended channel; the others are for pinning or offline use.

  • npm (recommended): dsh plugin --profile <profile> add dsh-legal-clause
  • git channel: dsh plugin --profile <profile> add github:PerryLink/dsh-legal-clause
  • tarball: pnpm pack then dsh plugin --profile <profile> add ./dsh-legal-clause-<version>.tgz
  • 1024 store: npm i -g dsh1024 then dsh1024 plugin --profile <profile> add dsh-legal-clause

What it does

Legal clause tree, 12-key playbook mapping and unresolved report. Runs locally on DeepSeek Harness. The table below is the exact tool surface; the examples use the real command surface.

Input and output stay local; nothing is uploaded.

Tools

Tool names and descriptions are kept in English to match the runtime output.

Tool Purpose Risk
legal.playbook Load the default 12-key playbook R0
legal.clause_tree Build a clause tree from legal text R1 local write
legal.playbook_register Register versioned custom playbook keys R1 local write
legal.playbook_check Compare a stored tree with a playbook and report missing/extra keys R0
legal.export_tree Export the clause tree as JSON R1 local write

Quick start

dsh plugin --profile <profile> add dsh-legal-clause
dsh --profile <profile> --dump-config | grep dsh-legal-clause

Examples

Fixture-backed example

Input: fixtures/public/mit/sample_nda.txt

Command: pnpm test

Acceptance row:

req_id metric threshold actual pass source counted
SKU-10-A01 合同条款树(20) 20/20 20 true public/synthetic false

This is a fixture-backed acceptance row, not a customer run; no output is invented.

Limits

  • Public/synthetic only; no customer data or customer evidence.
  • Alpha/partial, not counted, no GA or production-readiness claim.
  • No model or network call unless a tool explicitly says so.
  • The exact per-tool boundaries are in the table and ACCEPTANCE.csv.

Public sample

Public/synthetic fixtures live in fixtures/; ACCEPTANCE.csv records the public checks with counted=false.

Development

pnpm install --frozen-lockfile
pnpm build && pnpm lint && pnpm typecheck && pnpm test

Compatibility

Surface Status
Harness dsh >=0.2.1-rc.3 <0.3.0
Node >=24.9.0 <25
Platforms All; local files only
Data No network, no model call, no upload

Permissions & data

  • Runs locally; no network, no model call, no upload.
  • Public/synthetic fixtures only; no customer data, no customer evidence.
  • Alpha/partial; not counted, no GA or production-readiness claim.

Related work

Sibling packages and family indexes: dsh-legal-intake · dsh-docx-redline · dsh-contract-suite

Related checkers

Each entry is a separate package with its own rule pack and version; install only the ones you need.

Package Why it is relevant
dsh-contract-stance Clause stance register for negotiation positions and risk levels.
dsh-lawcite-adapter Citation and legal-document element verification.
dsh-evidence-check Evidence-list completeness for the same matter.

Family

Package npm
dsh-einvoice npm
dsh-docx-redline npm
dsh-policy-ledger npm
dsh-ghg npm
dsh-bankrec npm
dsh-ap-three-way npm
dsh-ifc-qto npm
dsh-qms-capa npm
dsh-legal-intake npm
dsh-legal-clause npm
dsh-freight-audit npm
dsh-hs-candidate npm
dsh-travel-recon npm
dsh-pim-lint npm
dsh-eval-pack npm
dsh-finops-suite npm
dsh-contract-suite npm
Package npm
dsh-aqua-input-check npm
dsh-archive-check npm
dsh-bid-ca-precheck npm
dsh-bid-qual-check npm
dsh-contract-stance npm
dsh-customs-doc-check npm
dsh-demurrage-ledger npm
dsh-drill-script-check npm
dsh-eia-guide-check npm
dsh-emergency-plan npm
dsh-essay-rubric-check npm
dsh-evidence-check npm
dsh-export-ctl-check npm
dsh-fmea-table-check npm
dsh-forecast-penalty npm
dsh-gongwen-flow-check npm
dsh-gongwen-word-check npm
dsh-guard-plan-qc npm
dsh-hazchem-check npm
dsh-hazplan-check npm
dsh-hidden-risk-map npm
dsh-hs-classify npm
dsh-icd-rule-check npm
dsh-lawcite-adapter npm
dsh-lc-doc-check npm
dsh-learning-gap-check npm
dsh-medrec-qc npm
dsh-nsfc-form-check npm
dsh-nurse-record-check npm
dsh-origin-rvc-check npm
dsh-ota-review-check npm
dsh-paper-doc-adapter npm
dsh-permit-report-check npm
dsh-pipeline-check npm
dsh-pleading-draft npm
dsh-policy-brief-draft npm
dsh-power-loss-split npm
dsh-power-ticket-check npm
dsh-ppap-check npm
dsh-protest-deadline npm
dsh-railway-window npm
dsh-repair-order-qc npm
dsh-review-reply-check npm
dsh-rulefile-check npm
dsh-safety-brief-check npm
dsh-site-log-check npm
dsh-soe-decision-check npm
dsh-soilwater-check npm
dsh-sop-sync-check npm
dsh-spc-gbt-adapter npm
dsh-tender-extract npm
dsh-tender-matrix npm
dsh-warranty-calc npm
dsh-auto-review npm
dsh-autotier npm
dsh-budget npm
dsh-cert-mcp npm
dsh-checkpoint-rewind npm
dsh-claude-move npm
dsh-click npm
dsh-composer-history npm
dsh-data-quality npm
dsh-defend npm
dsh-doublecheck npm
dsh-draw npm
dsh-fast npm
dsh-fund-research npm
dsh-industry-research npm
dsh-laya npm
dsh-library npm
dsh-local-ai npm
dsh-lsp-actions npm
dsh-mask npm
dsh-mcp-panel npm
dsh-memento npm
dsh-observe npm
dsh-output-styles npm
dsh-permission-rules npm
dsh-plugin-guide npm
dsh-plugin-upgrade npm
dsh-reach npm
dsh-research-report npm
dsh-score npm
dsh-session-sync npm
dsh-talk npm
dsh-test-drive npm
dsh-translate npm
npm
npm
npm
npm
npm

License

Apache-2.0. See LICENSE, NOTICE, THIRD-PARTY-NOTICES.

Content from the project README on GitHub ↗

Links

More in this category

View the whole category →

Comments are public GitHub Discussions. Loading them connects to GitHub and Giscus; a GitHub account is required to post.