shanraisshan / claude-code-best-practice

shanraisshan / claude-code-best-practice

claude-code-best-practice from vibe coding to agentic engineering - practice makes claude perfect claude-code-best-practice 从“感觉编程”(vibe coding)到智能体工程——熟能生巧

= Agents · = Commands · = Skills = 智能体 · = 命令 · = 技能

Boris Cherny on X (tweet 1 · tweet 2 · tweet 3) Boris Cherny 在 X 上的分享(推文 1 · 推文 2 · 推文 3)

Tip: Visit the How to Use section to take full advantage of this repo. 提示:请访问“如何使用”(How to Use)部分,以充分利用本仓库。

🧠 CONCEPTS (概念)

FeatureLocationDescription
Subagents.claude/agents/.md子智能体
Commands.claude/commands/.md命令
Skills.claude/skills//SKILL.md技能(官方技能 · Mono-repo 专用技能)
Workflows.claude/commands/weather-orchestrator.md工作流
Hooks.claude/hooks/钩子
MCP Servers.claude/settings.json, .mcp.jsonMCP 服务器
Pluginsdistributable packages插件(可分发包)
MarketplacesCreate Marketplaces市场
Settings.claude/settings.json设置(权限 · 模型配置 · 输出样式 · 沙盒 · 快捷键 · 自动模式配置)
Status Line.claude/settings.json状态栏
MemoryCLAUDE.md, .claude/rules/, ~/.claude/rules/, ~/.claude/projects//memory/记忆(自动记忆 · 深度解析 · 规则)
Checkpointingautomatic (file-edit tracking)检查点(自动,文件编辑追踪)
CLI Startup Flagsclaude [flags]CLI 启动标志
Interactive ModeEnv Vars交互模式 · 环境变量
AI TermsBest PracticesAI 术语 · 最佳实践
Prompt EngineeringExtend Claude Code提示词工程 · 扩展 Claude Code

🔥 Hot (热门功能)

FeatureLocationDescription
Ultrareview/code-review ultra, claude ultrareview [target]超级审查
Tasks trackingDevcontainers .devcontainer/任务追踪
Channels—channels, plugin-based频道
ReferenceUltraplan /ultraplan参考
No Flicker Mode/tui fullscreen, CLAUDE_CODE_NO_FLICKER=1无闪烁模式
Auto Mode—permission-mode auto, Shift+Tab自动模式
BlogPower-ups /powerup博客 · 增强功能
Fast Mode/fast, “fastMode”: true快速模式
Advisor/advisor, advisorModel, —advisor顾问
Computer Usecomputer-use MCP server计算机使用
Desktop Agent SDKnpm / pip package桌面智能体 SDK
QuickstartExamples快速入门 · 示例
Ralph Wiggum LooppluginRalph Wiggum 循环
Chrome—chrome, extensionChrome 扩展
Claude Code Webclaude.ai/codeClaude Code 网页版
RoutinesSlack @Claude in Slack例程
Code ReviewGitHub App (managed)代码审查
Local/code-review GitHub Actions .github/workflows/本地代码审查
GitLab CI/CDRemote Control /remote-control, /rcGitLab CI/CD · 远程控制
Headless ModeDeep Links claude-cli://open?repo=…&q=…无头模式 · 深层链接
Dynamic Workflows/workflows, ultracode keyword, /effort ultracode, .claude/workflows/动态工作流
Deep ResearchAgent Teams built-in (env var)深度研究 · 智能体团队
Agent Viewclaude agents, —bg, /bg智能体视图
Scheduled Tasks/loop, /schedule, cron tools定时任务
Desktop scheduled tasksAnnouncement桌面定时任务 · 公告
Routinesclaude.ai/code/routines, /schedule例程
Desktop TasksTasks /tasks, ~/.claude/tasks/桌面任务
Ultrareview trackingGoal /goal , /goal clearUltrareview 追踪 · 目标
Voice Dictation/voice语音听写
Bundled Skills/code-review, /batch捆绑技能
Git Worktrees—worktree/-w, .worktreeinclude, EnterWorktree/ExitWorktree, isolation: “worktree”, WorktreeCreate/WorktreeRemove hooksGit 工作树

See orchestration-workflow for implementation details of Command → Agent → Skill pattern. 请参阅 orchestration-workflow 以了解“命令 → 智能体 → 技能”模式的实现细节。

claude /weather-orchestrator claude /weather-orchestrator

⚙️ DEVELOPMENT WORKFLOWS (开发工作流)

All major workflows converge on the same architectural pattern: Research → Plan → Execute → Review → Ship 所有主要工作流都汇聚于同一架构模式:研究 → 计划 → 执行 → 审查 → 发布

(Table data omitted for brevity) (表格数据因篇幅省略)

Note: yellow tags are sub-loops — steps that repeat inside a parent step (e.g. per task, per story, or until a verify condition passes). 注意:黄色标签为子循环——即在父步骤中重复的步骤(例如:每个任务、每个故事,或直到验证条件通过为止)。

🔀 CROSS-MODEL WORKFLOWS (跨模型工作流)

Use Claude Code together with other models — Codex, Gemini, GPT, Kimi, DeepSeek, local — via three mechanisms: 通过以下三种机制,将 Claude Code 与其他模型(Codex、Gemini、GPT、Kimi、DeepSeek、本地模型)结合使用:

  • Plugin — another model’s CLI runs inside Claude Code (slash commands like /codex:review) 插件 — 其他模型的 CLI 在 Claude Code 内部运行(如 /codex:review 等斜杠命令)
  • MCP — Claude Code calls another model as a tool through Model Context Protocol MCP — Claude Code 通过模型上下文协议(MCP)将其他模型作为工具调用
  • Router — Claude Code’s API endpoint is swapped to a different provider 路由 — 将 Claude Code 的 API 端点切换到不同的提供商

Methodology: Cross-Model (Claude Code + Codex) Workflow — manual two-terminal flow with Plan in Claude, QA-Review in Codex. 方法论:跨模型(Claude Code + Codex)工作流——手动双终端流程,在 Claude 中进行计划,在 Codex 中进行 QA 审查。

🧰 SKILL COLLECTIONS (技能合集)

Repos primarily known as curated libraries of SKILL.md files (distinct from full workflow methodologies above). Sorted by stars descending. 主要以精选的 SKILL.md 文件库而闻名的仓库(区别于上述完整的工作流方法论)。按星标降序排列。

🤖 AGENT COLLECTIONS (智能体合集)

Repos primarily known as curated libraries of subagent definitions (.claude/agents/.md). Sorted by stars descending. 主要以精选的子智能体定义库(.claude/agents/.md)而闻名的仓库。按星标降序排列。

💡 TIPS AND TRICKS (83) (技巧与窍门)

🚫👶 = do not babysit 🚫👶 = 不要事无巨细地监管(放手让 AI 执行)

Prompting · Planning · Context · Session · CLAUDE.md + .claude/rules · Agents · Commands · Skills · Hooks · Workflows · Advanced · Git / PR · Debugging · Utilities · Daily 提示词 · 计划 · 上下文 · 会话 · CLAUDE.md + .claude/rules · 智能体 · 命令 · 技能 · 钩子 · 工作流 · 进阶 · Git / PR · 调试 · 工具 · 日常

■ Prompting (3) ■ 提示词 (3)

Tip: Claude — “grill me on these changes and don’t make a PR until I pass your test.” or “prove to me this works” 提示:Claude — “针对这些更改对我进行盘问,在我通过你的测试之前不要提交 PR。” 或者 “向我证明这段代码有效”。