AI Slop Code Risk Monitor

YuJunZhiXue/dsh-purge

SlopCodeMonitor badge for YuJunZhiXue/dsh-purge Adjusted legacy signal; badge bands: 25 / 50 / 75 (different from dashboard bands).
2.6 Low pattern signal View on GitHub

Open-Source Code Quality, Security and Technical Debt Review

This report summarizes scanner evidence for YuJunZhiXue/dsh-purge. SynthScan examined 56,984 lines of code across 87 source files, recording 113 pattern matches distributed across 6 syntactic categories. The legacy adjusted pattern signal is 2.6 (Low pattern signal); it is not an authorship estimate.

Use the findings to ask whether maintainers can explain intent, verify dependencies, simplify unnecessary scaffolding, and focus review effort. Risk Payload v1 adds ownership, supply-chain, over-engineering, and review-effort vectors when available. These are prompts for human verification, not probabilities, security findings, or measured maintenance costs.

2.6
Adjusted Signal
2.6
Raw Pattern Score
100%
Time Factor
—
Last Push
—
Stars
—
Language
57.0K
Lines of Code
87
Files
113
Pattern Hits
2026-10-31
Scan Date
0.00
HC Hit Rate

Risk Review · Payload v1

Use each vector to guide manual verification of the underlying findings.

Payload schema: 1.0.0 · Engine: 2.0.0 · Scoring: heuristic-density-v1 · Scan date: 2026-10-31.

Cognitive Ownership Risk 6.6/100 · LOW

Can maintainers explain intent, assumptions, and trade-offs? 86 finding(s).

Hallucinated Dependency & Supply Chain Risk 0.5/100 · LOW

Are imports declared and package/API names verified? 5 finding(s).

Agent Over-Engineering Ratio 10.9/100 · LOW

Are wrappers, guards, and repeated structures necessary? 102 finding(s).

PR Review Velocity Impact 12.7/100 · LOW

Which changes need focused human review? 113 finding(s).

What These Metrics Mean

Adjusted Signal
Legacy pattern score normalized per 1,000 scanned lines and multiplied by the repository-level time factor. It is not an estimate of AI authorship.
Raw Pattern Score
Sum of severity- and context-weighted pattern findings before applying the time factor.
Time Factor
A coarse multiplier based on repository last-push metadata. It does not identify when individual code was written.
Pattern Hits
Count of configured pattern findings. Review each location and surrounding code before acting.
HC Hit Rate
High- and critical-severity findings per scanned file. Severity is a configured detector weight, not proof of a vulnerability or authorship.
Lines / Files
Scan coverage denominators used by the legacy normalized score.

Pattern-Signal History

Run additional scans to build a history of the legacy pattern signal. Score changes are not a measure of AI adoption or code quality.

No multi-scan history yet — run the scanner again to build trend data.

Severity Breakdown

Groups findings by configured severity weight. Severity is not a confidence estimate, security rating, or proof that a package is missing. Verify imports against the project's manifests and inspect each finding in its local design context.

CRITICAL 0HIGH 0MEDIUM 21LOW 92

Directory Score Breakdown

This horizontal bar chart shows where configured pattern scores accumulate across directories. Treat the bars as locations to inspect, not as evidence of authorship or code quality. Use the file-level findings to decide whether a directory needs a focused ownership, dependency, complexity, or review check.

Pattern Findings

The scanner identified 113 distinct pattern matches across 6 syntactic categories. Each entry below represents a discrete location in the source code where the engine recorded a detector match to inspect in context. Expand any category row to inspect the individual file paths, line numbers, code snippets, and the lexical context (CODE, COMMENT, or STRING) in which each match was detected.

Reading the findings table: The Severity column indicates the configured finding weight (CRITICAL / HIGH / MEDIUM / LOW). The Context column identifies whether the match occurred inside executable code, an inline comment, or a string literal — legacy comment-context matches receive a ×1.5 score weight. The ⚡ bolt icon marks clustered matches: three or more patterns within a 10-line window, each receiving an additional ×1.5 density multiplier under the legacy scoring model.

Hyper-Verbose Identifiers80 hits · 70 pts
SeverityFileLineSnippetContext
LOWlib/profile-insert.js28export function profileHasPurgeBodyInsert(text) {CODE
LOWlib/profile-insert.js226export function validateAllowBuildRewrite(text) {CODE
LOWlib/profile-insert.js352export function ensureAllProfileBodyInserts(dshHome) {CODE
LOWlib/core.js313function findAiBaseFromRunningProcess() {CODE
LOWlib/core.js360export function isDesktopCommandRuntimeDir(dir) {CODE
LOWlib/core.js364export function listDesktopCommandRuntimeDirs() {CODE
LOWlib/core.js605export function silenceSubprocessLocalFlash(dshHome = findDshHome()) {CODE
LOWlib/core.js708export function silenceLiangshenCustomBashFlash(dshHome = findDshHome()) {CODE
LOWlib/core.js755function listLiangshenCustomBashFiles(dshHome) {CODE
LOWlib/core.js943export function liangshenPromptFilterText(text) {CODE
LOWlib/core.js952function listLiangshenMinimalPromptFiles(dshHome) {CODE
LOWlib/core.js979export function keepLiangshenOperatorPrompt(dshHome = findDshHome()) {CODE
LOWlib/core.js1056function listLiangshenBootstrapFiles(dshHome) {CODE
LOWlib/core.js1375export function silenceDshmarketRestartFlash(dshHome = findDshHome()) {CODE
LOWlib/core.js1462function listDshmarketRestartFiles(dshHome) {CODE
LOWlib/core.js2227export function repairOfficialCliAfterUnpack(exe) {CODE
LOWlib/core.js2240export function scheduleSealedDesktopRestart(handoff) {CODE
LOWlib/core.js2346export function restartSealedDesktopIfNeeded(input = {}) {CODE
LOWlib/core.js2368export function rememberDesktopInstallForHandoff(handoff) {CODE
LOWlib/core.js2458export function committedOverrideRevision() {CODE
LOWlib/core.js2463export function rememberCommittedOverride(dshHome, text) {CODE
LOWlib/core.js2593function replacementPrecedenceRewrites(name) {CODE
LOWlib/core.js4286 "function dshPurgeHandoffDesktopUpdate(owner) {\n" +CODE
LOWlib/core.js4338 pattern: "function dshPurgeHandoffDesktopUpdate(owner) {",CODE
LOWlib/core.js4345 "function dshPurgeHandoffDesktopUpdate(owner) {",CODE
LOWlib/core.js6169export async function dropStaleUserProfilePatchBackups(dshHome = findDshHome()) {CODE
LOWlib/core.js6218export function restoreMissingOriginalsFromBak(aiBase) {CODE
LOWlib/core.js6255export function restoreMissingOriginalsAllHosts(options = {}) {CODE
LOWlib/core.js6281export function refreshStaleBaksForUpgrade(aiBase) {CODE
LOWlib/core.js6839function isDisposableYamlFoldParagraph(para) {CODE
LOWlib/core.js6880function yamlStripDisposableFoldParas(bodyLines) {CODE
LOWlib/core.js6896function yamlHasDisposableFoldParagraph(bodyLines) {CODE
LOWlib/core.js6904function emptyDisposableFoldedYaml(text) {CODE
LOWlib/core.js6936function stripOrphanYamlAfterEmptyScalars(text) {CODE
LOWlib/core.js6951export function sanitizeYamlPersonaScalars(text) {CODE
LOWlib/core.js6988export function collapseDuplicateLegacyApplyPath(text) {CODE
LOWlib/core.js7020function rewriteStaleLegacyApplyCall(text) {CODE
LOWlib/core.js7520export function patchWatchedClientBundlesSync(aiBase = findAiBase()) {CODE
LOWlib/core.js7872export function sanitizeDesktopCommandRuntimes() {CODE
LOWlib/core.js7931function officialBinJsNearLauncher(fp) {CODE
LOWlib/core.js8239export function isUserCustomizedOverrideSync(dshHome) {CODE
LOWlib/core.js8283export function syncPromptInjectOnDiskSync(dshHome) {CODE
LOWlib/core.js8578export function healOfficeSkillsRuntimeOnDisk(extraSources) {CODE
LOWlib/reapply.js64function refreshStaleApplyPlaceholder(sha) {CODE
LOWlib/reapply.js116export function hostStillHasAppliedPatches() {CODE
LOWlib/reapply.js160export async function patchesMatchInstallStrict() {CODE
LOWlib/reapply.js183export function patchesLostAfterHostReset() {CODE
LOWlib/preset-default.js50function repairSelectedDefaultInYaml(text, fallback = FALLBACK_PRESET) {CODE
LOWlib/preset-default.js152export function clearOwnedSelectedDefault({ ctx = null, dshHome = "" } = {}) {CODE
LOWlib/preset-default.js175export function scheduleClearOwnedSelectedDefault(opts = {}) {CODE
LOWlib/preset-default.js188export function cancelClearOwnedSelectedDefault() {CODE
LOWlib/preset-default.js194export function removeStaleAgentPresetDir(dshHome, id = "redteam") {CODE
LOWlib/skills.js91function assertImportSourceOutsideSkills(dshHome, srcPath) {CODE
LOWlib/index.js533function installMnemonMessageStrip(ctx, config = {}) {CODE
LOWlib/index.js725function shouldKeepFreshFullAccess(session, svc) {CODE
LOWlib/index.js735function upgradeFreshSessionAccess(ctx, session) {CODE
LOWlib/index.js814function installRewindDeriveFilter(ctx) {CODE
LOWlib/hide-console.js75export function installChildProcessImportHook() {CODE
LOWlib/hide-console.js235export function installHideConsoleIntoBin(aiBase, { fs, path: nodePath } = {}) {CODE
LOWlib/restart-desktop.js263function killOtherDesktopProcesses(keepPid, exe = info.execPath) {CODE
20 more matches not shown…
Decorative Section Separators20 hits · 60 pts
SeverityFileLineSnippetContext
MEDIUMscripts/redteam-setup.sh2# ─────────────────────────────────────────────────────────────────────────────COMMENT
MEDIUMscripts/redteam-setup.sh20# ─────────────────────────────────────────────────────────────────────────────COMMENT
MEDIUMscripts/redteam-setup.sh44# ── 输出工具 ────────────────────────────────────────────────────────────────COMMENT
MEDIUMscripts/redteam-setup.sh84# ── 工具函数 ────────────────────────────────────────────────────────────────COMMENT
MEDIUMscripts/redteam-setup.sh181# ─────────────────────────────────────────────────────────────────────────────COMMENT
MEDIUMscripts/redteam-setup.sh186# ═══ ① 工具安装 ════════════════════════════════════════════════════════════COMMENT
MEDIUMscripts/redteam-setup.sh302# ═══ ② nuclei 模板 ═════════════════════════════════════════════════════════COMMENT
MEDIUMscripts/redteam-setup.sh320# ═══ ③ 配置:FOFA_KEY 与 VPS ══════════════════════════════════════════════COMMENT
MEDIUMscripts/redteam-setup.sh435# ═══ ④ 体检表 ══════════════════════════════════════════════════════════════COMMENT
MEDIUMscripts/redteam-setup.sh456# ═══ ⑤ 完成标记 ════════════════════════════════════════════════════════════COMMENT
MEDIUMpresets/redteam/agent.cordis.yml25# ── identity ────────────────────────────────────────────────────────────────COMMENT
MEDIUMpresets/redteam/agent.cordis.yml140# ── shell ───────────────────────────────────────────────────────────────────COMMENT
MEDIUMpresets/redteam/agent.cordis.yml157# ── filesystem ──────────────────────────────────────────────────────────────COMMENT
MEDIUMpresets/redteam/agent.cordis.yml169# ── background jobs ────────────────────────────────────────────────────────COMMENT
MEDIUMpresets/redteam/agent.cordis.yml181# ── skills ──────────────────────────────────────────────────────────────────COMMENT
MEDIUMpresets/redteam/agent.cordis.yml210# ── goals ───────────────────────────────────────────────────────────────────COMMENT
MEDIUMpresets/redteam/agent.cordis.yml221# ── plan mode ───────────────────────────────────────────────────────────────COMMENT
MEDIUMpresets/redteam/agent.cordis.yml247# ── compaction ──────────────────────────────────────────────────────────────COMMENT
MEDIUMpresets/redteam/agent.cordis.yml278# ── delegation and workflows ────────────────────────────────────────────────COMMENT
MEDIUMpresets/redteam/agent.cordis.yml376# ── remaining model-facing rows ─────────────────────────────────────────────COMMENT
Fake / Example Data5 hits · 6 pts
SeverityFileLineSnippetContext
LOWlib/redteam/skill-availability.js316 addIssue('placeholder', p + '还是占位符(技能里写的是占位符,说明本机/本环境还没配)', { placeholder: p })CODE
LOWlib/redteam/skill-fixes.js458 * `kind` ∈ `'file-missing' | 'content-missing' | 'env-missing' | 'path-missing' | 'placeholder' | 'shadowed'`。COMMENT
LOWlib/redteam/skill-fixes.js504 } else if (kind === 'placeholder') {CODE
LOWlib/redteam/index.js118 return { text: text.split(SKILLS_PLACEHOLDER).join(BUNDLED_SKILLS_EXPR), changed: true, reason: 'placeholder' }CODE
LOWlib/redteam/index.js410 ? (rendered.reason === 'placeholder'CODE
Over-Commented Block5 hits · 5 pts
SeverityFileLineSnippetContext
LOWscripts/redteam-setup.sh1#!/usr/bin/env bashCOMMENT
LOWlib/web-reclaim.js1// #197:Web「应用 → 自动重启」用 detached 子进程接管 server,父进程 250ms 后退出,COMMENT
LOWlib/index.js261function installHungPromptGlobal() {COMMENT
LOWpresets/redteam/agent.cordis.yml1# The `redteam` agent preset: 攻防演练红队指挥智能体(由 standard 复制改造)。COMMENT
LOWpresets/redteam/agent.cordis.yml181# ── skills ──────────────────────────────────────────────────────────────────COMMENT
Self-Referential Comments1 hit · 3 pts
SeverityFileLineSnippetContext
MEDIUMpresets/redteam/agent.cordis.yml3# This file is an AGENT-PLANE composition. The roster mounts it ONCE under aCOMMENT
Excessive Try-Catch Wrapping2 hits · 2 pts
SeverityFileLineSnippetContext
LOWscripts/redteam-setup.sh106except Exception: sys.exit(1)CODE
LOWscripts/redteam-setup.sh118except Exception: sys.exit(0)CODE