Index of every page on this site: llms.txt
All skills
deepseek-ai avatar

/dsh-code-review

@2e39e70
by DeepSeekdeepseek-ai/deepseek-harness285k stars
35,399
Run it yourself

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

Use this Skill: https://skilld.dev/gh/deepseek-ai/deepseek-harness/dsh-code-review

Nothing lands on disk. Nothing to clean up.

Fork this Skill

Edit a local copy. It keeps the author and licence.

SKILL.md

≈64 tokens for metadata: the name and description. ≈3k when used: this file.

Description uses 3.2% of example budget

Before choosing a Skill, your Agent reads its name and description. All available Skills share that space.

  • A shorter description leaves more room for other Skills. This entry exceeds our 1% size suggestion.

In our Claude Code example, all Skill names and descriptions share 8,000 characters. This Skill uses ≈255 characters, or 3.2%.

The 1% threshold is a size suggestion. Longer descriptions can still fit.

Your model, settings, and other Skills decide how much text your Agent can read.

Example settings and source

The example uses a 200k-token context and default Claude Code settings. The count includes the name, description, separators, and when_to_use when present. Codex also counts local file paths.

Skit's source and limits: Codex 0.160.1, Claude Code 2.1.292.

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.

Read the requirements before judging the diff. Map the changed paths to the artifacts below, open each owning page from Sources of truth, and only then read the diff against those requirements. Judging a diff against memory of the rules is how a violation passes review.

Sources of truth

  • AGENTS.md and packages/AGENTS.md: standing repository and package authoring rules.
  • docs/defensive-patterns/: the architecture requirements a change must satisfy and the habits behind them. Each page owns one artifact; read every page the diff touches:
    • general.md — timing, async state, value representation, shared ownership, decentralization, refactors, migrations, performance evidence, disposal, callbacks, subprocesses.
    • package-surface.md — exports, package shape, build faces, dependency declarations, resolve hooks.
    • remote-and-api.md — remote services, @Remote methods, API dispatch, business ownership in packages/api.
    • client-components.md — client components, slots, stores, hooks, effects, shared base packages.
    • conversation-and-session.md — projection reads, Session retention, conversation nodes, renderers.
  • docs/AGENTS.md: documentation placement and prose discipline.
  • dsh-prose-standard: required coverage and editorial judgment for comments, docs, prompts, and visible strings.
  • dsh-ci-test-reliability: isolation and regression-proof rules for resource-owning, asynchronous, or flaky tests and fixtures.
  • dsh-client-ui-ux: feedback-surface choice, overlay safety, platform window adaptation, and visual token discipline for product-user-visible GUI changes.
  • dsh-error-handling: failure classification, error classes and codes, tool failures, handling ownership, containment, state guarantees, and actionable reports.
  • dsh-session-projection: projection ownership, state size, historical reads, and migrations.
  • docs/testing.md and the quality-gates reference: required test tiers and gates.
  • Agent Notes: design rationale. Treat disagreement with an Agent Note as a design discussion, not an automatic veto.
  • For bilingual changes, read translation-rules.md and terminology.md; the extended translation skill is outside automatic review and runs only on explicit user invocation.

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. Cordis ownership and cleanup. When reviewing Cordis plugin code or helpers reachable from its entrypoints, load and apply cordis-styling-nitpicking to the changed behavior and affected consumers. Check its three P0 rules: singleton state, unreversed effects, and cleanup dependencies released before consumers finish. Verify each new registry contribution passes the disposal tests required by packages/AGENTS.md.
  5. 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.
  6. Client UI copy is locale-owned. Reject product text embedded in JSX, templates, helper returns, accessibility attributes, or primitive defaults. Require typed dictionary keys, the standard t seat or explicit localized props, verify-client-ui-i18n, and behavior evidence in each affected locale; preserve user/model/wire data and code tokens verbatim.

Manual checks

  • UI review coverage: apply the UI change workflow to the cumulative visible diff. Verify its minimum checks for the changed properties and consumers. Missing required inspection remains a gap; missing optional reports does not. Do not demand full-audit records for ordinary changes. Recheck only new interactions or invalidated evidence. Existing tests, GUI GIFs and designer/product approval remain required under their original triggers.
  • 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.
  • Error handling: apply dsh-error-handling to changed failure paths, including their state guarantees and final user-visible reports. Flag an expected tool failure that would reach tool/result without error.name/error.code. Reject catch-and-continue unless the state owner establishes that subsequent work's preconditions hold, including after recovery.
  • Lifecycle and concurrency: for async setup, callbacks, processes, or teardown, apply defensive-patterns/general.md. Check races before publication, cancellation during awaits, independent error reporting, callback containment, ownership before reentry, complete detach cleanup, and quiescent disposal.
  • Scope, ownership, and necessity: first identify the required behavior behind each new distinction, field, adapter, state machine, option, defensive copy, and compatibility path. A requirement, check, or Agent Note introduced by the PR is a design choice to assess, not independent evidence of necessity. Compare existing source fields, discriminants, and their consumers before accepting another representation; distinguish deleting a concept from relocating its declaration. Moving an unnecessary concept closer to its owner is not a simplification. Challenge unrelated features and speculative generality against the root rules.
  • Capability and consumer fit: trace every current consumer, then flag consumer-specific behavior leaking into the interface under the package rules. For required behavior, prefer an existing extension point near its producer or consumer when the local implementation adds little complexity, following the ownership rule; compare producer-owned declaration merging with changes to distant core or shared type declarations. 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.
  • Configuration and public choices: trace authoritative reads and precedence before accepting another CLI or configuration pass-through; a forwarded value may be shadowed before use. 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.
  • Test reliability: for a resource-owning, asynchronous, platform-sensitive, or flaky test, apply dsh-ci-test-reliability to the real worker/job topology, resource allocation, global-state restoration, synchronization, timeout budget, and quiescent teardown.
  • Negative controls: verify a deliberately invalid case fails through the real runner for each changed acceptance 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.

Source: SKILL.md on GitHub

No rule matched.

skilld matched fixed text patterns in SKILL.md and file names. Patterns miss obfuscated code.

skilld run checks every file with the same patterns. It asks for approval before it loads a Skill with a behavior marked Needs approval.

1 warning4d3 checks · Risk SAFE
  • Gen Agent Trust Hub8d

    This skill provides a comprehensive framework for AI agents to conduct code reviews within the deepseek-harness repository. It emphasizes adherence to internal architectural standards, defensive programming patterns, and manual verification of PR evidence. While it involves running a local project script and ingesting external code diffs, these are standard operations for a developer-oriented tool and no malicious patterns were identified.

  • Socket4d

    No alerts

  • Snyk8d

    Risk: MEDIUM · 1 issue

Signed by skilld at 2e39e70. This ties the file your Agent reads to that commit on GitHub. It does not review the instructions.

Last checked against GitHub 3 days ago.

Activeupdated 2 weeks ago

README badge

README badge for deepseek-ai/deepseek-harness/dsh-code-review