← 返回
未分类 中文

Nm Pensive Blast Radius

Analyze the blast radius of code changes with risk scoring. Shows affected nodes, untested functions, and review priorities using the code knowledge graph
分析代码变更的影响范围,通过风险评分和受影响节点映射,帮助在合并前了解变更涉及的内容及测试覆盖缺失情况。
athola athola 来源
未分类 clawhub v1.9.14 5 版本 100000 Key: 无需
★ 0
Stars
📥 437
下载
💾 1
安装
5
版本
#latest

概述

> Night Market Skill — ported from claude-night-market/pensive. For the full experience with agents, hooks, and commands, install the Claude Code plugin.

Blast Radius Analysis

Analyze the impact of current code changes using the

code knowledge graph.

Prerequisites

This skill requires the gauntlet plugin for graph

data. Check if it's available:

GRAPH_QUERY=$(find ~/.claude/plugins -name "graph_query.py" -path "*/gauntlet/*" 2>/dev/null | head -1)

If gauntlet is not installed (GRAPH_QUERY is empty):

Fall back to a manual impact analysis using git diff

and grep to trace imports and call sites. Skip graph

steps and go directly to step 3 (manual mode).

If gauntlet is installed but no graph.db exists:

Tell the user: "Run /gauntlet-graph build first."

Steps

  1. Show current changes: Run git diff --stat to

show the user what files changed.

  1. Run impact analysis (requires gauntlet):

```bash

python3 "$GRAPH_QUERY" \

--action impact --base-ref HEAD --depth 2

```

Fallback tier 1 (sem available, no gauntlet):

Use sem for cross-file dependency tracing:

```bash

if command -v sem &>/dev/null; then

sem impact --json

fi

```

This traces real function-level dependencies instead

of filename matching. See leyline:sem-integration

for detection patterns.

Fallback tier 2 (no sem, no gauntlet): Trace

callers of changed functions with rg (or grep):

```bash

# Prefer rg for speed; fall back to grep

if command -v rg &>/dev/null; then

git diff --name-only HEAD | while read f; do

stem="${f%.}"; stem="${stem##/}"

[ -z "$stem" ] && continue # skip dotfiles (.gitignore etc.)

rg -l "$stem" . 2>/dev/null

done | sort -u

else

git diff --name-only HEAD | while read f; do

stem="${f%.}"; stem="${stem##/}"

[ -z "$stem" ] && continue # skip dotfiles (.gitignore etc.)

grep -rl "$stem" . 2>/dev/null

done | sort -u

fi

```

Note: this searches all file types. For Python-only

projects, add --type py to rg or --include="*.py"

to grep to reduce false positives.

  1. Display results in priority order:

Format the output as a table:

```

Risk | Node | File | Reason

0.85 | auth.py::verify_token | auth.py:45 | untested, security

0.62 | db.py::execute_query | db.py:112 | high fan-in

0.41 | api.py::handle_request | api.py:78 | flow participant

```

  1. Highlight untested functions: List any affected

functions that lack test coverage (no TESTED_BY edge).

  1. Show overall risk: Display the overall risk level

(low/medium/high) based on the maximum risk score.

  1. Suggest actions:
    • For high-risk nodes: "Consider adding tests before

merging"

  • For security-sensitive nodes: "Review authentication

and authorization logic carefully"

  • For high-fan-in nodes: "Changes here affect many

callers; verify backward compatibility"

Risk Scoring Model

Five weighted factors (sum capped at 1.0):

FactorWeightMeaning
-------------------------
Test gap0.30No test coverage
Security0.20Auth/crypto/SQL keywords
Flow participation0.25Part of execution flows
Cross-community0.15Called from other modules
Caller count0.10High fan-in function

版本历史

共 5 个版本

  • v1.9.14 当前
    2026-07-02 08:48
  • v1.9.13
    2026-06-30 16:53 安全 安全
  • v1.9.12
    2026-06-19 19:57 安全 安全
  • v1.0.2
    2026-05-09 16:40 安全 安全
  • v1.0.1
    2026-05-07 17:07 安全 安全

安全检测

腾讯云安全 (Keen)

队列中

腾讯云安全 (Sanbu)

队列中

🔗 相关推荐

dev-programming

Github

steipete
使用 `gh` CLI 与 GitHub 交互,通过 `gh issue`、`gh pr`、`gh run` 和 `gh api` 管理议题、PR、CI 运行及高级查询。
★ 689 📥 332,671
dev-programming

Mcporter

steipete
使用 mcporter CLI 直接列出、配置、认证及调用 MCP 服务器/工具(支持 HTTP 或 stdio),涵盖临时服务器、配置编辑及 CLI/类型生成功能。
★ 200 📥 68,565
dev-programming

YouTube

byungkyu
使用托管OAuth集成YouTube Data API,支持搜索视频、管理播放列表、获取频道数据及评论互动,适用于用户需要时使用此技能。
★ 142 📥 42,393