Agent Skillsdeepseek-ai/deepseek-harness › dsh-code-review

dsh-code-review

GitHub

用于审查 deepseek-harness 仓库的 PR,提供代码库规范、防御性模式及质量门禁等指导,确保正确性与安全性。

.agents/skills/dsh-code-review/SKILL.md deepseek-ai/deepseek-harness

Trigger Scenarios

需要审查 Pull Request 验证代码符合项目规范与质量标准

Install

npx skills add deepseek-ai/deepseek-harness --skill dsh-code-review -g -y
More Options

Non-standard path

npx skills add https://github.com/deepseek-ai/deepseek-harness/tree/master/.agents/skills/dsh-code-review -g -y

Use without installing

npx skills use deepseek-ai/deepseek-harness@dsh-code-review

指定 Agent (Claude Code)

npx skills add deepseek-ai/deepseek-harness --skill dsh-code-review -a claude-code -g -y

安装 repo 全部 skill

npx skills add deepseek-ai/deepseek-harness --all -g -y

预览 repo 内 skill

npx skills add deepseek-ai/deepseek-harness --list

SKILL.md

Frontmatter
{
    "name": "dsh-code-review",
    "description": "Use when reviewing a pull request in the deepseek-harness repo — orients the reviewer to this codebase's standards (AGENTS.md conventions, defensive patterns, ADRs, quality gates) and the review-specific checks that code alone can't show"
}

Reviewing a DeepSeek-Harness PR

This skill is guidance, not a complete checklist. Verify and fetch the PR's live base and exact head, then run pnpm --silent run change-scope --base <verified-base-ref> --head <verified-head-ref> before reading the diff and enough surrounding code to understand the design. The report identifies paths and dirty layers but does not replace semantic review. Re-establish the base and rerun it after a retarget or merge. Prioritize correctness, lifecycle, security, and broken required behavior over style; a short review with one substantiated blocker is better than a list of nits.

Sources of truth

Blocking requirements

  1. New prose receives semantic review. Use dsh-prose-standard to critically review every added or changed Markdown passage, JSDoc, comment, prompt, description, diagnostic, and visible string. Verify required coverage, accuracy, placement, and editorial quality against the owning code or behavior; automated checks do not establish those properties.
  2. Docs match the code. Config, defaults, errors, wire fields, events, and public behavior update the package README and JSDoc in the same diff. Comments state non-obvious contracts; flag implementation narration, test walkthroughs, review history, and duplicated rationale for deletion or a link to their one home.
  3. Core type docs match. Changes to spine or seam vocabulary update the appropriate subsystems page and any type-equiv entry. Internal types need no catalog entry.
  4. Registrations clean up. Verify each new registry contribution passes the disposal tests required by packages/AGENTS.md.
  5. Invariant companions are semantic. For every touched ./invariant, require an owner event-stream or mutable-data relationship at the point where that package can observe it; service or method presence, plugin metadata or effects, and fixed pure examples belong in type, load, or unit tests. Accept an empty installer when its package-specific reason establishes that no plausible runtime relationship exists; do not demand an invented check merely to eliminate emptiness (repository rule; package invariant rules).
  6. Required evidence exists. Verify the author ran the relevant local checks for the diff and that CI covers the exhaustive matrix; review the semantic gaps neither can detect.

Manual checks

  • Intent and interface contracts: trace both sides of every changed interface. Confirm the implementation matches the PR and any Agent Note, including errors, cancellation, ownership, and disposal.
  • Lifecycle and concurrency: for async setup, callbacks, processes, or teardown, apply defensive-patterns.md. Check races before publication, cancellation during awaits, independent error reporting, callback containment, ownership before reentry, complete detach cleanup, and quiescent disposal.
  • Capability and consumer fit: trace every current consumer, then flag consumer-specific behavior leaking into the interface under the package rules. Flag the inverse too: a new public method on a generic service (registry, session, agent) whose only caller is one internal consumer is an unnecessary API expansion — require a private capability closure handed to that consumer at construction instead.
  • Scope, ownership, and necessity: map each abstraction, state machine, option, defensive copy, and compatibility path to its current contract, production consumer, and owning plugin or service. Challenge unrelated features and speculative generality, then test the PR against the root rules.
  • Configuration and public choices: ask what current-consumer evidence or prior art supports each default, public operation set, format, or imported external concept. Require an explicit choice or deferral when that evidence is absent.
  • Model perspective: inspect the exact prompts, tool schemas, results, and diagnostics the model receives across affected modes. Flag concepts outside the model's task, then verify stable text verbatim and dynamic behavior through snapshots or end-to-end coverage.
  • Enforcement: follow every denial path to the operation that executes it; exercise direct and alternate callers that can bypass schemas, prompts, facades, wrappers, or listener ordering.
  • Borrowed and derived state: determine whether each retained value is borrowed or owned under the package contract, then trace notifications and every cache, prompt, UI echo, replay, and query view to the documented success point and authoritative source.
  • Bounds cover the final operation: locate the owner of the complete emitted or retained result, including wrappers and metadata. Probe tiny and exact limits, oversized single chunks, and multibyte text for byte limits.
  • Real entry path: tests exercise the shipped Loader, bin, worker, ACP bridge, or subprocess where relevant. A hand-mounted plugin does not catch invalid Loader exports; a function plugin must named-export its namespace and have no default export.
  • Test strength: assertions fail on the intended regression and verify external state, logs, events, or disposal rather than restating the implementation or trusting an agent's report. Coverage is necessary but not evidence that the scenario is correct.
  • Invariant lifecycle and negative controls: verify candidate observations are rejected before publication where possible, session-backed checks reconstruct durable history after late loading or HMR, and a deliberately invalid case fails through the real runner for the intended rule.
  • Implemented Agent Notes match shipped reality: when a PR implements a proposed Agent Note, move and rewrite it as present-tense shipped state in the same diff, then verify paths, names, and mechanisms against the implementation.
  • Transcript changes: editor-visible or model-visible changes update snapshots or explain why no snapshot applies. Review expected-output diffs as behavior changes, not formatting noise.
  • Bilingual changes: compare meaning and terminology on both sides; a green pairing hash does not prove translation quality.

Reporting findings

State the defect, location, impact, and evidence. Place a localized defect inline on the tightest relevant diff range; use a PR-level comment for cross-cutting architecture, scope, or review-wide synthesis. Separate blockers from suggestions and omit issues already enforced by a green gate. Use the existing GitHub review thread for replies. When receiving review, verify each claim and fix or rebut it on technical grounds without performative agreement.

Version History

  • 47f9438 Current 2026-08-16 15:43

Same Skill Collection

.agents/skills/dsh-archive-agent-notes/SKILL.md
.agents/skills/dsh-doc-site-sync/SKILL.md
.agents/skills/dsh-doc-standards/SKILL.md
.agents/skills/dsh-find-simplifications/SKILL.md
.agents/skills/dsh-merging-stacked-prs/SKILL.md
.agents/skills/dsh-pre-push-checks/SKILL.md
.agents/skills/dsh-prose-standard/SKILL.md
.agents/skills/dsh-translate-docs/SKILL.md
.agents/skills/dsh-trim-cot-leakage/SKILL.md
.agents/skills/record-browser-gif/SKILL.md

Metadata

Files
0
Version
47f9438
Hash
59df05ce
Indexed
2026-08-16 15:43

inicio - Wiki
Copyright © 2011-2026 iteam. Current version is 2.155.2. UTC+08:00, 2026-08-16 19:19
浙ICP备14020137号-1 $mapa de visitantes$