code-review-quality by proffesor-for-testing/agentic-qe
npx skills add https://github.com/proffesor-for-testing/agentic-qe --skill code-review-quality<default_to_action> 在审查代码或建立审查实践时:
快速审查清单:
关键成功因素:
| 等级 |
|---|
广告位招租
在这里展示您的产品或服务
触达数万 AI 开发者,精准高效
| 图标 |
|---|
| 含义 |
|---|
| 操作 |
|---|
| 阻塞性问题 | 🔴 | 缺陷/安全性/崩溃 | 合并前必须修复 |
| 主要问题 | 🟡 | 逻辑问题/测试缺失 | 合并前应修复 |
| 次要问题 | 🟢 | 风格/命名 | 最好修复 |
| 建议 | 💡 | 替代方案 | 未来可考虑 |
| 变更行数 | 建议 |
|---|---|
| < 200 | 单次审查会话 |
| 200-400 | 分块审查 |
400 | 请求拆分 PR
| ✅ 审查 | ❌ 跳过 |
|---|---|
| 逻辑正确性 | 格式化(使用 linter) |
| 安全风险 | 命名偏好 |
| 测试覆盖率 | 架构争论 |
| 性能问题 | 风格意见 |
| 错误处理 | 微小变更 |
🔴 **阻塞性问题:SQL 注入风险**
此查询存在 SQL 注入漏洞:
```javascript
db.query(`SELECT * FROM users WHERE id = ${userId}`)
修复方案: 使用参数化查询:
db.query('SELECT * FROM users WHERE id = ?', [userId])
原因: 用户输入直接嵌入 SQL 语句,允许攻击者执行任意查询。
### 主要问题(应修复)
```markdown
🟡 **主要问题:缺少错误处理**
如果 `fetchUser()` 抛出异常会怎样?错误会未处理地向上传播。
**建议:** 添加 try/catch 并提供适当的错误响应:
```javascript
try {
const user = await fetchUser(id);
return user;
} catch (error) {
logger.error('Failed to fetch user', { id, error });
throw new NotFoundError('User not found');
}
### 次要问题(最好修复)
```markdown
🟢 **次要问题:变量名可以更清晰**
`d` 没有表达含义。考虑使用 `daysSinceLastLogin`。
💡 **建议:考虑将其提取为辅助函数**
此验证逻辑出现在 3 个地方。一个 `validateEmail()` 辅助函数可以减少重复。非阻塞性问题,但可能值得后续 PR 处理。
审查必须达到最低加权发现分数 3.0(CRITICAL=3, HIGH=2, MEDIUM=1, LOW=0.5, INFORMATIONAL=0.25)。如果初始审查未达标,请运行 qe-devils-advocate 代理作为元审查者以查找更多观察结果。每次审查应至少包含 3 个可操作的观察结果。
// 全面代码审查
await Task("Code Review", {
prNumber: 123,
checks: ['security', 'performance', 'testability', 'maintainability'],
feedbackLevels: ['blocker', 'major', 'minor'],
autoApprove: { maxBlockers: 0, maxMajor: 2 }
}, "qe-quality-analyzer");
// 安全专项审查
await Task("Security Review", {
prFiles: changedFiles,
scanTypes: ['injection', 'auth', 'secrets', 'dependencies']
}, "qe-security-scanner");
// 测试覆盖率审查
await Task("Coverage Review", {
prNumber: 123,
requireNewTests: true,
minCoverageDelta: 0
}, "qe-coverage-analyzer");
aqe/code-review/
├── review-history/* - 过往审查决策
├── patterns/* - 按团队/仓库分类的常见问题
├── feedback-templates/* - 可复用的反馈模板
└── metrics/* - 审查周转时间
const reviewFleet = await FleetManager.coordinate({
strategy: 'code-review',
agents: [
'qe-quality-analyzer', // 逻辑,可维护性
'qe-security-scanner', // 安全风险
'qe-performance-tester', // 性能问题
'qe-coverage-analyzer' // 测试覆盖率
],
topology: 'parallel'
});
| ✅ 应该做 | ❌ 不应该做 |
|---|---|
| "你是否考虑过...?" | "这是错的" |
| 解释为何重要 | 只说"修复这个" |
| 肯定好的代码 | 只指出负面问题 |
| 建议,而非要求 | 居高临下 |
| 审查 < 400 行 | 一次性审查 2000 行 |
优先处理反馈: 🔴 阻塞性问题 → 🟡 主要问题 → 🟢 次要问题 → 💡 建议。聚焦于缺陷和安全性,而非风格。多提问,而非命令。每次审查 < 400 行代码。快速反馈(< 24小时)胜过详尽反馈。
使用代理时: 代理自动化安全、性能和覆盖率检查,使人工审查者能专注于逻辑和设计。使用代理进行一致、快速的初步审查。
/security-testing 进行安全专项审查/qe-coverage-analysis/qe-quality-assessment每周安装数
715
仓库
GitHub 星标数
271
首次出现
2026年1月24日
安全审计
安装于
codex703
opencode702
gemini-cli700
github-copilot699
cursor696
amp691
<default_to_action> When reviewing code or establishing review practices:
Quick Review Checklist:
Critical Success Factors:
| Level | Icon | Meaning | Action |
|---|---|---|---|
| Blocker | 🔴 | Bug/security/crash | Must fix before merge |
| Major | 🟡 | Logic issue/test gap | Should fix before merge |
| Minor | 🟢 | Style/naming | Nice to fix |
| Suggestion | 💡 | Alternative approach | Consider for future |
| Lines Changed | Recommendation |
|---|---|
| < 200 | Single review session |
| 200-400 | Review in chunks |
400 | Request PR split
| ✅ Review | ❌ Skip |
|---|---|
| Logic correctness | Formatting (use linter) |
| Security risks | Naming preferences |
| Test coverage | Architecture debates |
| Performance issues | Style opinions |
| Error handling | Trivial changes |
🔴 **BLOCKER: SQL Injection Risk**
This query is vulnerable to SQL injection:
```javascript
db.query(`SELECT * FROM users WHERE id = ${userId}`)
Fix: Use parameterized queries:
db.query('SELECT * FROM users WHERE id = ?', [userId])
Why: User input directly in SQL allows attackers to execute arbitrary queries.
### Major (Should Fix)
```markdown
🟡 **MAJOR: Missing Error Handling**
What happens if `fetchUser()` throws? The error bubbles up unhandled.
**Suggestion:** Add try/catch with appropriate error response:
```javascript
try {
const user = await fetchUser(id);
return user;
} catch (error) {
logger.error('Failed to fetch user', { id, error });
throw new NotFoundError('User not found');
}
### Minor (Nice to Fix)
```markdown
🟢 **minor:** Variable name could be clearer
`d` doesn't convey meaning. Consider `daysSinceLastLogin`.
💡 **suggestion:** Consider extracting this to a helper
This validation logic appears in 3 places. A `validateEmail()` helper would reduce duplication. Not blocking, but might be worth a follow-up PR.
Reviews must meet a minimum weighted finding score of 3.0 (CRITICAL=3, HIGH=2, MEDIUM=1, LOW=0.5, INFORMATIONAL=0.25). If the initial review falls short, run the qe-devils-advocate agent as a meta-reviewer to find additional observations. Every review should have at least 3 actionable observations.
// Comprehensive code review
await Task("Code Review", {
prNumber: 123,
checks: ['security', 'performance', 'testability', 'maintainability'],
feedbackLevels: ['blocker', 'major', 'minor'],
autoApprove: { maxBlockers: 0, maxMajor: 2 }
}, "qe-quality-analyzer");
// Security-focused review
await Task("Security Review", {
prFiles: changedFiles,
scanTypes: ['injection', 'auth', 'secrets', 'dependencies']
}, "qe-security-scanner");
// Test coverage review
await Task("Coverage Review", {
prNumber: 123,
requireNewTests: true,
minCoverageDelta: 0
}, "qe-coverage-analyzer");
aqe/code-review/
├── review-history/* - Past review decisions
├── patterns/* - Common issues by team/repo
├── feedback-templates/* - Reusable feedback
└── metrics/* - Review turnaround time
const reviewFleet = await FleetManager.coordinate({
strategy: 'code-review',
agents: [
'qe-quality-analyzer', // Logic, maintainability
'qe-security-scanner', // Security risks
'qe-performance-tester', // Performance issues
'qe-coverage-analyzer' // Test coverage
],
topology: 'parallel'
});
| ✅ Do | ❌ Don't |
|---|---|
| "Have you considered...?" | "This is wrong" |
| Explain why it matters | Just say "fix this" |
| Acknowledge good code | Only point out negatives |
| Suggest, don't demand | Be condescending |
| Review < 400 lines | Review 2000 lines at once |
Prioritize feedback: 🔴 Blocker → 🟡 Major → 🟢 Minor → 💡 Suggestion. Focus on bugs and security, not style. Ask questions, don't command. Review < 400 lines at a time. Fast feedback (< 24h) beats thorough feedback.
With Agents: Agents automate security, performance, and coverage checks, freeing human reviewers to focus on logic and design. Use agents for consistent, fast initial review.
/security-testing for security-focused review/qe-coverage-analysis on changed files/qe-quality-assessmentWeekly Installs
715
Repository
GitHub Stars
271
First Seen
Jan 24, 2026
Security Audits
Gen Agent Trust HubPassSocketPassSnykPass
Installed on
codex703
opencode702
gemini-cli700
github-copilot699
cursor696
amp691
agent-browser 浏览器自动化工具 - Vercel Labs 命令行网页操作与测试
136,300 周安装