claude-automation-recommender

Compare original and translation side by side

🇺🇸

Original

English
🇨🇳

Translation

Chinese

Claude Automation Recommender

Claude自动化推荐工具

Analyze codebase patterns to recommend tailored Claude Code automations across all extensibility options.
This skill is read-only. It analyzes the codebase and outputs recommendations. It does NOT create or modify any files. Users implement the recommendations themselves or ask Claude separately to help build them.
分析代码库模式,针对所有可扩展选项推荐定制化的Claude Code自动化方案。
本Skill为只读模式。 它仅分析代码库并输出推荐内容,不会创建或修改任何文件。用户可自行实施推荐方案,或单独请求Claude协助构建。

Output Guidelines

输出指南

  • Recommend 1-2 of each type: Don't overwhelm - surface the top 1-2 most valuable automations per category
  • If user asks for a specific type: Focus only on that type and provide more options (3-5 recommendations)
  • Go beyond the reference lists: The reference files contain common patterns, but use web search to find recommendations specific to the codebase's tools, frameworks, and libraries
  • Tell users they can ask for more: End by noting they can request more recommendations for any specific category
  • 每个类型推荐1-2个:不要过度推荐,只列出每个类别中最有价值的1-2个自动化方案
  • 如果用户指定特定类型:仅聚焦该类型并提供更多选项(3-5个推荐)
  • 超越参考列表:参考文件包含常见模式,但需通过网络搜索找到针对代码库所用工具、框架和库的专属推荐
  • 告知用户可请求更多:结尾需注明用户可针对任何特定类别请求更多推荐

Automation Types Overview

自动化类型概述

TypeBest For
HooksAutomatic actions on tool events (format on save, lint, block edits)
SubagentsSpecialized reviewers/analyzers that run in parallel
SkillsPackaged expertise, workflows, and repeatable tasks (invoked by Claude or user via
/skill-name
)
PluginsCollections of skills that can be installed
MCP ServersExternal tool integrations (databases, APIs, browsers, docs)
类型适用场景
Hooks工具事件触发的自动操作(保存时格式化、代码检查、阻止编辑)
Subagents并行运行的专业评审/分析器
Skills打包的专业能力、工作流和可重复任务(由Claude或用户通过
/skill-name
调用)
Plugins可安装的Skills集合
MCP Servers外部工具集成(数据库、API、浏览器、文档)

Workflow

工作流

Phase 1: Codebase Analysis

阶段1:代码库分析

Gather project context:
bash
undefined
收集项目上下文:
bash
undefined

Detect project type and tools

检测项目类型和工具

ls -la package.json pyproject.toml Cargo.toml go.mod pom.xml 2>/dev/null cat package.json 2>/dev/null | head -50
ls -la package.json pyproject.toml Cargo.toml go.mod pom.xml 2>/dev/null cat package.json 2>/dev/null | head -50

Check dependencies for MCP server recommendations

检查依赖以推荐MCP服务器

cat package.json 2>/dev/null | grep -E '"(react|vue|angular|next|express|fastapi|django|prisma|supabase|stripe)"'
cat package.json 2>/dev/null | grep -E '"(react|vue|angular|next|express|fastapi|django|prisma|supabase|stripe)"'

Check for existing Claude Code config

检查现有Claude Code配置

ls -la .claude/ CLAUDE.md 2>/dev/null
ls -la .claude/ CLAUDE.md 2>/dev/null

Analyze project structure

分析项目结构

ls -la src/ app/ lib/ tests/ components/ pages/ api/ 2>/dev/null

**Key Indicators to Capture:**

| Category | What to Look For | Informs Recommendations For |
|----------|------------------|----------------------------|
| Language/Framework | package.json, pyproject.toml, import patterns | Hooks, MCP servers |
| Frontend stack | React, Vue, Angular, Next.js | Playwright MCP, frontend skills |
| Backend stack | Express, FastAPI, Django | API documentation tools |
| Database | Prisma, Supabase, raw SQL | Database MCP servers |
| External APIs | Stripe, OpenAI, AWS SDKs | context7 MCP for docs |
| Testing | Jest, pytest, Playwright configs | Testing hooks, subagents |
| CI/CD | GitHub Actions, CircleCI | GitHub MCP server |
| Issue tracking | Linear, Jira references | Issue tracker MCP |
| Docs patterns | OpenAPI, JSDoc, docstrings | Documentation skills |
ls -la src/ app/ lib/ tests/ components/ pages/ api/ 2>/dev/null

**需捕获的关键指标:**

| 类别 | 关注内容 | 为哪些推荐提供依据 |
|----------|------------------|----------------------------|
| 语言/框架 | package.json、pyproject.toml、导入模式 | Hooks、MCP服务器 |
| 前端技术栈 | React、Vue、Angular、Next.js | Playwright MCP、前端Skills |
| 后端技术栈 | Express、FastAPI、Django | API文档工具 |
| 数据库 | Prisma、Supabase、原生SQL | 数据库MCP服务器 |
| 外部API | Stripe、OpenAI、AWS SDKs | context7 MCP文档查询 |
| 测试 | Jest、pytest、Playwright配置 | 测试Hooks、Subagents |
| CI/CD | GitHub Actions、CircleCI | GitHub MCP服务器 |
| 问题追踪 | Linear、Jira引用 | 问题追踪MCP |
| 文档模式 | OpenAPI、JSDoc、文档字符串 | 文档Skills |

Phase 2: Generate Recommendations

阶段2:生成推荐

Based on analysis, generate recommendations across all categories:
基于分析结果,为所有类别生成推荐:

A. MCP Server Recommendations

A. MCP服务器推荐

See references/mcp-servers.md for detailed patterns.
Codebase SignalRecommended MCP Server
Uses popular libraries (React, Express, etc.)context7 - Live documentation lookup
Frontend with UI testing needsPlaywright - Browser automation/testing
Uses SupabaseSupabase MCP - Direct database operations
PostgreSQL/MySQL databaseDatabase MCP - Query and schema tools
GitHub repositoryGitHub MCP - Issues, PRs, actions
Uses Linear for issuesLinear MCP - Issue management
AWS infrastructureAWS MCP - Cloud resource management
Slack workspaceSlack MCP - Team notifications
Memory/context persistenceMemory MCP - Cross-session memory
Sentry error trackingSentry MCP - Error investigation
Docker containersDocker MCP - Container management
详情请参考references/mcp-servers.md
代码库信号推荐的MCP服务器
使用流行库(React、Express等)context7 - 实时文档查询
前端有UI测试需求Playwright - 浏览器自动化/测试
使用SupabaseSupabase MCP - 直接数据库操作
PostgreSQL/MySQL数据库Database MCP - 查询和架构工具
GitHub仓库GitHub MCP - 问题、PR、Actions
使用Linear管理问题Linear MCP - 问题管理
AWS基础设施AWS MCP - 云资源管理
Slack工作区Slack MCP - 团队通知
内存/上下文持久化Memory MCP - 跨会话内存
Sentry错误追踪Sentry MCP - 错误排查
Docker容器Docker MCP - 容器管理

B. Skills Recommendations

B. Skills推荐

See references/skills-reference.md for details.
Create skills in
.claude/skills/<name>/SKILL.md
. Some are also available via plugins:
Codebase SignalSkillPlugin
Building pluginsskill-developmentplugin-dev
Git commitscommitcommit-commands
React/Vue/Angularfrontend-designfrontend-design
Automation ruleswriting-ruleshookify
Feature planningfeature-devfeature-dev
Custom skills to create (with templates, scripts, examples):
Codebase SignalSkill to CreateInvocation
API routesapi-doc (with OpenAPI template)Both
Database projectcreate-migration (with validation script)User-only
Test suitegen-test (with example tests)User-only
Component librarynew-component (with templates)User-only
PR workflowpr-check (with checklist)User-only
Releasesrelease-notes (with git context)User-only
Code styleproject-conventionsClaude-only
Onboardingsetup-dev (with prereq script)User-only
详情请参考references/skills-reference.md
可在
.claude/skills/<name>/SKILL.md
中创建Skills,部分也可通过插件安装:
代码库信号Skill插件
构建插件skill-developmentplugin-dev
Git提交commitcommit-commands
React/Vue/Angularfrontend-designfrontend-design
自动化规则writing-ruleshookify
功能规划feature-devfeature-dev
需创建的自定义Skills(含模板、脚本、示例):
代码库信号需创建的Skill调用方式
API路由api-doc(含OpenAPI模板)两者均可
数据库项目create-migration(含验证脚本)仅用户
测试套件gen-test(含测试示例)仅用户
组件库new-component(含模板)仅用户
PR工作流pr-check(含检查清单)仅用户
版本发布release-notes(含Git上下文)仅用户
代码风格project-conventions仅Claude
新员工入职setup-dev(含前置依赖脚本)仅用户

C. Hooks Recommendations

C. Hooks推荐

See references/hooks-patterns.md for configurations.
Codebase SignalRecommended Hook
Prettier configuredPostToolUse: auto-format on edit
ESLint/Ruff configuredPostToolUse: auto-lint on edit
TypeScript projectPostToolUse: type-check on edit
Tests directory existsPostToolUse: run related tests
.env
files present
PreToolUse: block
.env
edits
Lock files presentPreToolUse: block lock file edits
Security-sensitive codePreToolUse: require confirmation
配置详情请参考references/hooks-patterns.md
代码库信号推荐的Hook
已配置PrettierPostToolUse: 编辑后自动格式化
已配置ESLint/RuffPostToolUse: 编辑后自动代码检查
TypeScript项目PostToolUse: 编辑后自动类型检查
存在tests目录PostToolUse: 运行相关测试
存在
.env
文件
PreToolUse: 阻止编辑
.env
文件
存在锁文件PreToolUse: 阻止编辑锁文件
安全敏感代码PreToolUse: 需确认后操作

D. Subagent Recommendations

D. Subagents推荐

See references/subagent-templates.md for templates.
Codebase SignalRecommended Subagent
Large codebase (>500 files)code-reviewer - Parallel code review
Auth/payments codesecurity-reviewer - Security audits
API projectapi-documenter - OpenAPI generation
Performance criticalperformance-analyzer - Bottleneck detection
Frontend heavyui-reviewer - Accessibility review
Needs more teststest-writer - Test generation
模板详情请参考references/subagent-templates.md
代码库信号推荐的Subagent
大型代码库(>500个文件)code-reviewer - 并行代码评审
认证/支付代码security-reviewer - 安全审计
API项目api-documenter - OpenAPI生成
性能关键型项目performance-analyzer - 瓶颈检测
前端主导项目ui-reviewer - 可访问性评审
需要更多测试test-writer - 测试生成

E. Plugin Recommendations

E. Plugins推荐

See references/plugins-reference.md for available plugins.
Codebase SignalRecommended Plugin
General productivityanthropic-agent-skills - Core skills bundle
Document workflowsInstall docx, xlsx, pdf skills
Frontend developmentfrontend-design plugin
Building AI toolsmcp-builder for MCP development
可用插件详情请参考references/plugins-reference.md
代码库信号推荐的Plugin
通用生产力提升anthropic-agent-skills - 核心Skills集合
文档工作流安装docx、xlsx、pdf相关Skills
前端开发frontend-design插件
构建AI工具mcp-builder用于MCP开发

Phase 3: Output Recommendations Report

阶段3:输出推荐报告

Format recommendations clearly. Only include 1-2 recommendations per category - the most valuable ones for this specific codebase. Skip categories that aren't relevant.
markdown
undefined
清晰格式化推荐内容。每个类别仅包含1-2个推荐——针对该特定代码库最有价值的方案。跳过不相关的类别。
markdown
undefined

Claude Code Automation Recommendations

Claude Code自动化推荐

I've analyzed your codebase and identified the top automations for each category. Here are my top 1-2 recommendations per type:
我已分析您的代码库,并确定了每个类别的顶级自动化方案。以下是每个类型的1-2个首选推荐:

Codebase Profile

代码库概况

  • Type: [detected language/runtime]
  • Framework: [detected framework]
  • Key Libraries: [relevant libraries detected]

  • 类型:[检测到的语言/运行时]
  • 框架:[检测到的框架]
  • 核心库:[检测到的相关库]

🔌 MCP Servers

🔌 MCP服务器

context7

context7

Why: [specific reason based on detected libraries] Install:
claude mcp add context7

原因:[基于检测到的库的具体原因] 安装
claude mcp add context7

🎯 Skills

🎯 Skills

[skill name]

[Skill名称]

Why: [specific reason] Create:
.claude/skills/[name]/SKILL.md
Invocation: User-only / Both / Claude-only Also available in: [plugin-name] plugin (if applicable)
yaml
---
name: [skill-name]
description: [what it does]
disable-model-invocation: true  # for user-only
---

原因:[具体原因] 创建路径
.claude/skills/[name]/SKILL.md
调用方式:仅用户 / 两者均可 / 仅Claude 也可通过以下插件获取:[插件名称](如适用)
yaml
---
name: [skill-name]
description: [功能描述]
disable-model-invocation: true  # 仅用户调用时设置
---

⚡ Hooks

⚡ Hooks

[hook name]

[Hook名称]

Why: [specific reason based on detected config] Where:
.claude/settings.json

原因:[基于检测到的配置的具体原因] 配置位置
.claude/settings.json

🤖 Subagents

🤖 Subagents

[agent name]

[Agent名称]

Why: [specific reason based on codebase patterns] Where:
.claude/agents/[name].md

Want more? Ask for additional recommendations for any specific category (e.g., "show me more MCP server options" or "what other hooks would help?").
Want help implementing any of these? Just ask and I can help you set up any of the recommendations above.
undefined
原因:[基于代码库模式的具体原因] 配置位置
.claude/agents/[name].md

需要更多推荐? 可针对任何特定类别请求更多推荐(例如:"显示更多MCP服务器选项"或"还有哪些Hooks有帮助?")。
需要协助实施? 随时告知,我可以帮您设置上述任何推荐方案。
undefined

Decision Framework

决策框架

When to Recommend MCP Servers

何时推荐MCP服务器

  • External service integration needed (databases, APIs)
  • Documentation lookup for libraries/SDKs
  • Browser automation or testing
  • Team tool integration (GitHub, Linear, Slack)
  • Cloud infrastructure management
  • 需要集成外部服务(数据库、API)
  • 需要查询库/SDK的文档
  • 浏览器自动化或测试
  • 团队工具集成(GitHub、Linear、Slack)
  • 云基础设施管理

When to Recommend Skills

何时推荐Skills

  • Document generation (docx, xlsx, pptx, pdf — also in plugins)
  • Frequently repeated prompts or workflows
  • Project-specific tasks with arguments
  • Applying templates or scripts to tasks (skills can bundle supporting files)
  • Quick actions invoked with
    /skill-name
  • Workflows that should run in isolation (
    context: fork
    )
Invocation control:
  • disable-model-invocation: true
    — User-only (for side effects: deploy, commit, send)
  • user-invocable: false
    — Claude-only (for background knowledge)
  • Default (omit both) — Both can invoke
  • 文档生成(docx、xlsx、pptx、pdf — 也可通过插件获取)
  • 频繁重复的提示或工作流
  • 带参数的项目特定任务
  • 将模板或脚本应用于任务(Skills可捆绑支持文件)
  • 通过
    /skill-name
    调用的快速操作
  • 需要隔离运行的工作流(
    context: fork
调用控制:
  • disable-model-invocation: true
    — 仅用户调用(适用于有副作用的操作:部署、提交、发送)
  • user-invocable: false
    — 仅Claude调用(适用于背景知识类任务)
  • 默认(不设置以上两项) — 两者均可调用

When to Recommend Hooks

何时推荐Hooks

  • Repetitive post-edit actions (formatting, linting)
  • Protection rules (block sensitive file edits)
  • Validation checks (tests, type checks)
  • 重复的编辑后操作(格式化、代码检查)
  • 保护规则(阻止敏感文件编辑)
  • 验证检查(测试、类型检查)

When to Recommend Subagents

何时推荐Subagents

  • Specialized expertise needed (security, performance)
  • Parallel review workflows
  • Background quality checks
  • 需要专业领域能力(安全、性能)
  • 并行评审工作流
  • 后台质量检查

When to Recommend Plugins

何时推荐Plugins

  • Need multiple related skills
  • Want pre-packaged automation bundles
  • Team-wide standardization

  • 需要多个相关Skills
  • 希望使用预打包的自动化集合
  • 团队范围内的标准化

Configuration Tips

配置技巧

MCP Server Setup

MCP服务器设置

Team sharing: Check
.mcp.json
into repo so entire team gets same MCP servers
Debugging: Use
--mcp-debug
flag to identify configuration issues
Prerequisites to recommend:
  • GitHub CLI (
    gh
    ) - enables native GitHub operations
  • Puppeteer/Playwright CLI - for browser MCP servers
团队共享:将
.mcp.json
提交到仓库,确保整个团队使用相同的MCP服务器
调试:使用
--mcp-debug
标志识别配置问题
推荐的前置依赖:
  • GitHub CLI (
    gh
    ) - 支持原生GitHub操作
  • Puppeteer/Playwright CLI - 用于浏览器MCP服务器

Headless Mode (for CI/Automation)

无头模式(适用于CI/自动化)

Recommend headless Claude for automated pipelines:
bash
undefined
推荐在自动化流水线中使用无头Claude:
bash
undefined

Pre-commit hook example

提交前Hook示例

claude -p "fix lint errors in src/" --allowedTools Edit,Write
claude -p "修复src/中的代码检查错误" --allowedTools Edit,Write

CI pipeline with structured output

带结构化输出的CI流水线

claude -p "<prompt>" --output-format stream-json | your_command
undefined
claude -p "<prompt>" --output-format stream-json | your_command
undefined

Permissions for Hooks

Hooks权限

Configure allowed tools in
.claude/settings.json
:
json
{
  "permissions": {
    "allow": ["Edit", "Write", "Bash(npm test:*)", "Bash(git commit:*)"]
  }
}
.claude/settings.json
中配置允许的工具:
json
{
  "permissions": {
    "allow": ["Edit", "Write", "Bash(npm test:*)", "Bash(git commit:*)"]
  }
}