npx skills add https://github.com/a2f0/tearleads --skill preen-review-instructions审核 REVIEW.md 和 .gemini/INSTRUCTIONS.md 中的审查说明,确保其完整性、准确性,并与代码库模式保持同步。更新说明以反映当前的约定。
在以下情况下运行此技能:
| 文件 | 用途 |
|---|---|
REVIEW.md | 主审查说明(仓库根目录) |
.gemini/INSTRUCTIONS.md | Gemini Code Assist 特定说明 |
CLAUDE.md | Claude 代码约定(事实来源) |
Audit the review instructions in REVIEW.md and .gemini/INSTRUCTIONS.md for completeness, accuracy, and sync with codebase patterns. Update instructions to reflect current conventions.
Run this skill when:
| File | Purpose |
|---|---|
REVIEW.md | Master review instructions (repo root) |
.gemini/INSTRUCTIONS.md | Gemini Code Assist specific instructions |
广告位招租
在这里展示您的产品或服务
触达数万 AI 开发者,精准高效
AGENTS.md| Codex 约定(事实来源) |
compliance/ | 合规文档(安全控制) |
compliance/infrastructure-controls.md | 跨框架哨兵索引 |
echo "=== REVIEW.md sections ==="
rg '^##' REVIEW.md | head -20
echo "=== Last modified ==="
git log -1 --format="%ci" -- REVIEW.md
# 未提及的新路由文件
echo "=== Recent route additions ==="
git log --since="30 days ago" --name-only --pretty=format: -- 'packages/api/src/routes/**/*.ts' | sort -u | head -10
# 未提及的新共享组件
echo "=== Recent component additions ==="
git log --since="30 days ago" --name-only --pretty=format: -- 'packages/*/src/components/**/*.tsx' | sort -u | head -10
# 新包目录
echo "=== Package structure ==="
ls -d packages/*/ 2>/dev/null | head -10
# TypeScript 规则
echo "=== CLAUDE.md TypeScript mentions ==="
rg -i 'typescript|any|cast|@ts-' CLAUDE.md | head -10
# 安全规则
echo "=== CLAUDE.md security mentions ==="
rg -i 'security|auth|permission|injection' CLAUDE.md | head -10
echo "=== Gemini INSTRUCTIONS sections ==="
rg '^##' .gemini/INSTRUCTIONS.md | head -20
# 比较部分数量
echo "=== Section comparison ==="
echo "REVIEW.md sections: $(rg '^##' REVIEW.md | wc -l)"
echo "Gemini sections: $(rg '^##' .gemini/INSTRUCTIONS.md | wc -l)"
echo "=== Review script prompt analysis ==="
rg -A5 'PROMPT=' scripts/solicitClaudeCodeReview.sh | head -15
rg -A5 'PROMPT=' scripts/solicitCodexReview.sh 2>/dev/null | head -15 || true
# 检查 REVIEW.md 是否有安全部分
echo "=== REVIEW.md security coverage ==="
rg -c 'Security|OWASP|injection|auth' REVIEW.md
# 检查合规文档引用
echo "=== Compliance references in REVIEW.md ==="
rg -c 'compliance/|sentinel|TL-' REVIEW.md
# 检查 infrastructure-controls.md 是否存在并包含哨兵
echo "=== Infrastructure controls sentinel count ==="
rg -c 'TL-[A-Z]+-[0-9]+' compliance/infrastructure-controls.md
# 检查框架对等性
echo "=== Framework document counts ==="
for fw in HIPAA NIST.SP.800-53 SOC2; do
echo "$fw policies: $(ls compliance/$fw/policies/*.md 2>/dev/null | wc -l | tr -d ' ')"
done
# 检查 REVIEW.md 是否提及哨兵工作流
echo "=== Sentinel workflow in REVIEW.md ==="
rg 'Adding New Sentinel|COMPLIANCE_SENTINEL' REVIEW.md | head -5
| 类别 | 严重性 | 操作 |
|---|---|---|
| 缺少新模式部分 | 中等 | 向 REVIEW.md 添加部分,同步到 Gemini |
| 包结构过时 | 低 | 更新 REVIEW.md 中的包列表 |
| Gemini 说明出现偏差 | 中等 | 将 .gemini/INSTRUCTIONS.md 与 REVIEW.md 同步 |
| 缺少安全规则 | 高 | 从 CLAUDE.md 添加安全指导 |
| 审查脚本未使用说明 | 中等 | 更新脚本以包含 REVIEW.md 内容 |
| 缺少合规性部分 | 高 | 添加合规文档指导 |
| 缺少哨兵工作流 | 高 | 添加添加新哨兵的说明 |
| 合规性框架对等性差距 | 中等 | 确保所有框架具有同等覆盖范围 |
REVIEW.md 添加部分.gemini/INSTRUCTIONS.md 添加精简版本REVIEW.md 底部的版本历史# 比较部分标题
diff <(rg '^##' REVIEW.md | sort) <(rg '^##' .gemini/INSTRUCTIONS.md | sort)
确保 REVIEW.md 中的关键部分在 .gemini/INSTRUCTIONS.md 中有对应的条目。
如果 solicitClaudeCodeReview.sh 未引用 REVIEW.md:
# 读取并包含说明
INSTRUCTIONS=$(cat REVIEW.md | head -100)
PROMPT="Review using these guidelines:
$INSTRUCTIONS
[Rest of prompt...]"
当审查说明中缺少安全或合规性指导时:
/preen-api-security 技能以获取要记录的安全模式compliance/infrastructure-controls.md 以获取哨兵模式安全部分所需内容:
合规性部分所需内容:
TL-<类别>-<编号>)infrastructure-controls.md 添加新哨兵当新的安全控制需要合规文档时:
compliance/infrastructure-controls.md 添加哨兵,包含:
compliance/<FW>/policies/NN-topic-policy.mdcompliance/<FW>/procedures/NN-topic-procedure.mdcompliance/<FW>/technical-controls/NN-topic-control-map.mdPOLICY_INDEX.md<!-- COMPLIANCE_SENTINEL: TL-NEW-001 | policy=path | procedure=path | control=description -->
git checkout -b docs/review-instructions-<date>/commit-and-push,然后运行 /enter-merge-queue如果在发现过程中未发现问题,请不要创建分支。
.gemini/INSTRUCTIONS.md 简洁(Gemini 有令牌限制)REVIEW.md 和 .gemini/INSTRUCTIONS.md 之间的同步REVIEW.md 中记录了所有主要的代码库模式.gemini/INSTRUCTIONS.md 涵盖与 REVIEW.md 相同的主题(精简版)compliance/infrastructure-controls.md 和 /preen-compliance-docs 的交叉引用质量指标是缺失或过时部分的数量:
# 计算潜在差距
GAPS=0
# 检查缺失部分
[ -z "$(rg 'TypeScript Standards' REVIEW.md)" ] && GAPS=$((GAPS + 1))
[ -z "$(rg 'API Security' REVIEW.md)" ] && GAPS=$((GAPS + 1))
[ -z "$(rg 'React Standards' REVIEW.md)" ] && GAPS=$((GAPS + 1))
[ -z "$(rg 'Database Performance' REVIEW.md)" ] && GAPS=$((GAPS + 1))
[ -z "$(rg 'Testing Standards' REVIEW.md)" ] && GAPS=$((GAPS + 1))
# 检查安全和合规性覆盖范围
[ -z "$(rg 'Security and Compliance' REVIEW.md)" ] && GAPS=$((GAPS + 1))
[ -z "$(rg 'OWASP' REVIEW.md)" ] && GAPS=$((GAPS + 1))
[ -z "$(rg 'Adding New Sentinel' REVIEW.md)" ] && GAPS=$((GAPS + 1))
[ -z "$(rg 'COMPLIANCE_SENTINEL' REVIEW.md)" ] && GAPS=$((GAPS + 1))
[ -z "$(rg 'infrastructure-controls.md' REVIEW.md)" ] && GAPS=$((GAPS + 1))
# 检查 gemini 安全覆盖范围
[ -z "$(rg 'Security' .gemini/INSTRUCTIONS.md)" ] && GAPS=$((GAPS + 1))
[ -z "$(rg 'compliance/' .gemini/INSTRUCTIONS.md)" ] && GAPS=$((GAPS + 1))
# 检查 gemini 同步情况
REVIEW_SECTIONS=$(rg '^## ' REVIEW.md | wc -l)
GEMINI_SECTIONS=$(rg '^## ' .gemini/INSTRUCTIONS.md | wc -l)
[ "$GEMINI_SECTIONS" -lt $((REVIEW_SECTIONS / 2)) ] && GAPS=$((GAPS + 1))
echo "$GAPS"
# 限制发现输出
git log --since="30 days ago" --name-only --pretty=format: | head -30
# 抑制验证输出
git commit -S -m "message" >/dev/null
git push >/dev/null
失败时,重新运行而不进行抑制以查看错误。
每周安装次数
1
仓库
首次出现
1 天前
安全审计
安装于
zencoder1
amp1
cline1
openclaw1
opencode1
cursor1
CLAUDE.md |
| Claude Code conventions (source of truth) |
AGENTS.md | Codex conventions (source of truth) |
compliance/ | Compliance documentation (security controls) |
compliance/infrastructure-controls.md | Cross-framework sentinel index |
echo "=== REVIEW.md sections ==="
rg '^##' REVIEW.md | head -20
echo "=== Last modified ==="
git log -1 --format="%ci" -- REVIEW.md
# New route files not mentioned
echo "=== Recent route additions ==="
git log --since="30 days ago" --name-only --pretty=format: -- 'packages/api/src/routes/**/*.ts' | sort -u | head -10
# New shared components not mentioned
echo "=== Recent component additions ==="
git log --since="30 days ago" --name-only --pretty=format: -- 'packages/*/src/components/**/*.tsx' | sort -u | head -10
# New package directories
echo "=== Package structure ==="
ls -d packages/*/ 2>/dev/null | head -10
# TypeScript rules
echo "=== CLAUDE.md TypeScript mentions ==="
rg -i 'typescript|any|cast|@ts-' CLAUDE.md | head -10
# Security rules
echo "=== CLAUDE.md security mentions ==="
rg -i 'security|auth|permission|injection' CLAUDE.md | head -10
echo "=== Gemini INSTRUCTIONS sections ==="
rg '^##' .gemini/INSTRUCTIONS.md | head -20
# Compare section counts
echo "=== Section comparison ==="
echo "REVIEW.md sections: $(rg '^##' REVIEW.md | wc -l)"
echo "Gemini sections: $(rg '^##' .gemini/INSTRUCTIONS.md | wc -l)"
echo "=== Review script prompt analysis ==="
rg -A5 'PROMPT=' scripts/solicitClaudeCodeReview.sh | head -15
rg -A5 'PROMPT=' scripts/solicitCodexReview.sh 2>/dev/null | head -15 || true
# Check REVIEW.md has security section
echo "=== REVIEW.md security coverage ==="
rg -c 'Security|OWASP|injection|auth' REVIEW.md
# Check for compliance documentation references
echo "=== Compliance references in REVIEW.md ==="
rg -c 'compliance/|sentinel|TL-' REVIEW.md
# Check infrastructure-controls.md exists and has sentinels
echo "=== Infrastructure controls sentinel count ==="
rg -c 'TL-[A-Z]+-[0-9]+' compliance/infrastructure-controls.md
# Check for framework parity
echo "=== Framework document counts ==="
for fw in HIPAA NIST.SP.800-53 SOC2; do
echo "$fw policies: $(ls compliance/$fw/policies/*.md 2>/dev/null | wc -l | tr -d ' ')"
done
# Check REVIEW.md mentions sentinel workflow
echo "=== Sentinel workflow in REVIEW.md ==="
rg 'Adding New Sentinel|COMPLIANCE_SENTINEL' REVIEW.md | head -5
| Category | Severity | Action |
|---|---|---|
| Missing section for new pattern | Medium | Add section to REVIEW.md, sync to Gemini |
| Outdated package structure | Low | Update package list in REVIEW.md |
| Gemini instructions drift | Medium | Sync .gemini/INSTRUCTIONS.md with REVIEW.md |
| Security rule missing | High | Add security guidance from CLAUDE.md |
| Review script not using instruct. | Medium | Update script to include REVIEW.md content |
| Missing compliance section | High | Add compliance documentation guidance |
| Missing sentinel workflow | High | Add instructions for adding new sentinels |
| Compliance framework parity gap | Medium | Ensure all frameworks have equal coverage |
REVIEW.md under appropriate heading.gemini/INSTRUCTIONS.mdREVIEW.md# Compare section headers
diff <(rg '^##' REVIEW.md | sort) <(rg '^##' .gemini/INSTRUCTIONS.md | sort)
Ensure key sections from REVIEW.md have corresponding entries in .gemini/INSTRUCTIONS.md.
If solicitClaudeCodeReview.sh doesn't reference REVIEW.md:
# Read and include instructions
INSTRUCTIONS=$(cat REVIEW.md | head -100)
PROMPT="Review using these guidelines:
$INSTRUCTIONS
[Rest of prompt...]"
When security or compliance guidance is missing from review instructions:
/preen-api-security skill for security patterns to documentcompliance/infrastructure-controls.md for sentinel patternsRequired content for security section:
Required content for compliance section:
TL-<CATEGORY>-<NUMBER>)infrastructure-controls.mdWhen new security controls need compliance documentation:
Add sentinel to compliance/infrastructure-controls.md with:
Create/update document triad in each framework:
compliance/<FW>/policies/NN-topic-policy.mdcompliance/<FW>/procedures/NN-topic-procedure.mdcompliance/<FW>/technical-controls/NN-topic-control-map.mdUpdate POLICY_INDEX.md in each framework directory
Add COMPLIANCE_SENTINEL comments in policy documents:
<!-- COMPLIANCE_SENTINEL: TL-NEW-001 | policy=path | procedure=path | control=description -->
git checkout -b docs/review-instructions-<date>/commit-and-push, then /enter-merge-queueIf no issues found during discovery, do not create a branch.
.gemini/INSTRUCTIONS.md concise (Gemini has token limits)REVIEW.md and .gemini/INSTRUCTIONS.mdREVIEW.md.gemini/INSTRUCTIONS.md covers same topics as REVIEW.md (condensed)compliance/infrastructure-controls.md and /preen-compliance-docsThe quality metric is the count of missing or stale sections:
# Count potential gaps
GAPS=0
# Check for missing sections
[ -z "$(rg 'TypeScript Standards' REVIEW.md)" ] && GAPS=$((GAPS + 1))
[ -z "$(rg 'API Security' REVIEW.md)" ] && GAPS=$((GAPS + 1))
[ -z "$(rg 'React Standards' REVIEW.md)" ] && GAPS=$((GAPS + 1))
[ -z "$(rg 'Database Performance' REVIEW.md)" ] && GAPS=$((GAPS + 1))
[ -z "$(rg 'Testing Standards' REVIEW.md)" ] && GAPS=$((GAPS + 1))
# Check for security and compliance coverage
[ -z "$(rg 'Security and Compliance' REVIEW.md)" ] && GAPS=$((GAPS + 1))
[ -z "$(rg 'OWASP' REVIEW.md)" ] && GAPS=$((GAPS + 1))
[ -z "$(rg 'Adding New Sentinel' REVIEW.md)" ] && GAPS=$((GAPS + 1))
[ -z "$(rg 'COMPLIANCE_SENTINEL' REVIEW.md)" ] && GAPS=$((GAPS + 1))
[ -z "$(rg 'infrastructure-controls.md' REVIEW.md)" ] && GAPS=$((GAPS + 1))
# Check gemini security coverage
[ -z "$(rg 'Security' .gemini/INSTRUCTIONS.md)" ] && GAPS=$((GAPS + 1))
[ -z "$(rg 'compliance/' .gemini/INSTRUCTIONS.md)" ] && GAPS=$((GAPS + 1))
# Check gemini sync
REVIEW_SECTIONS=$(rg '^## ' REVIEW.md | wc -l)
GEMINI_SECTIONS=$(rg '^## ' .gemini/INSTRUCTIONS.md | wc -l)
[ "$GEMINI_SECTIONS" -lt $((REVIEW_SECTIONS / 2)) ] && GAPS=$((GAPS + 1))
echo "$GAPS"
# Limit discovery output
git log --since="30 days ago" --name-only --pretty=format: | head -30
# Suppress validation output
git commit -S -m "message" >/dev/null
git push >/dev/null
On failure, re-run without suppression to see errors.
Weekly Installs
1
Repository
First Seen
1 day ago
Security Audits
Installed on
zencoder1
amp1
cline1
openclaw1
opencode1
cursor1
Python PDF处理教程:合并拆分、提取文本表格、创建PDF文件
59,800 周安装
browser-use CLI 浏览器自动化工具:快速持久会话,支持多步骤工作流
60,300 周安装
新闻内容提取工具 - 支持12个主流平台,自动输出JSON和Markdown格式
205 周安装
AI Elements:基于shadcn/ui的AI原生应用组件库,快速构建对话界面
62,200 周安装
专业SEO审计工具:全面网站诊断、技术SEO优化与页面分析指南
63,800 周安装
Azure GitHub Copilot SDK 部署指南:从零构建、集成到现有项目与模型配置
75,700 周安装