Autopilot is the most powerful skill in Claude Code, allowing you to describe a brief idea and let AI automatically complete the entire workflow: from requirements analysis, design, planning, implementation to testing and validation.
Autopilot là skill mạnh mẽ nhất trong Claude Code, cho phép bạn mô tả một ý tưởng ngắn gọn và để AI tự động hoàn thành toàn bộ quy trình: từ phân tích yêu cầu, thiết kế, lập kế hoạch, triển khai đến testing và validation.
Instead of guiding each step, you simply say 'autopilot build me a todo app' and Claude handles everything automatically.
Thay vì hướng dẫn từng bước, bạn chỉ cần nói 'autopilot build me a todo app' và Claude sẽ tự xử lý mọi thứ.
Your brief idea is expanded into a detailed spec. Analyst agent analyzes requirements, Architect agent creates technical design.
Ý tưởng ngắn gọn của bạn được mở rộng thành spec chi tiết. Analyst agent phân tích yêu cầu, Architect agent tạo thiết kế kỹ thuật.
1# Your input:2"autopilot create a blog with posts and comments"34# Phase 0 output (.omc/autopilot/spec.md):5## Requirements6- User authentication7- CRUD operations for posts8- Nested comments system9- Markdown support10...From the spec, Architect creates a detailed implementation plan with specific tasks. Critic agent reviews and validates the plan.
Từ spec, Architect tạo kế hoạch triển khai chi tiết với các task cụ thể. Critic agent review và validate kế hoạch.
1# Plan output (.omc/plans/autopilot-impl.md):2## Wave 1: Database Setup3- Task 1: Create Prisma schema4- Task 2: Setup database migrations56## Wave 2: API Layer7- Task 3: Posts CRUD endpoints8- Task 4: Comments endpoints9...Tasks are executed in parallel when possible. Simple tasks use Haiku, complex tasks use Opus. Ralph skill ensures each task completes before continuing.
Các task được thực thi song song khi có thể. Task đơn giản dùng Haiku, task phức tạp dùng Opus. Ralph skill đảm bảo mỗi task hoàn thành trước khi tiếp tục.
1# Execution progress:2✓ Task 1: Create Prisma schema (Haiku)3✓ Task 2: Database migrations (Haiku)4⟳ Task 3: Posts CRUD (Sonnet) - in progress5⟳ Task 4: Comments endpoints (Sonnet) - in progress6○ Task 5: Frontend pages (Opus) - waitingUltraQA mode runs build, lint, tests and automatically fixes failures. Repeats up to 5 times until everything passes.
UltraQA mode chạy build, lint, tests và tự động fix failures. Lặp lại đến 5 lần cho đến khi mọi thứ pass.
1# QA cycle:2Cycle 1:3 ✓ Build passed4 ✗ 3 lint errors → fixing...5 ✗ 2 test failures → fixing...67Cycle 2:8 ✓ Build passed9 ✓ Lint passed10 ✓ All tests passMulti-perspective review in parallel: Architect checks completeness, Security reviewer finds vulnerabilities, Code reviewer evaluates quality.
Review đa góc nhìn song song: Architect kiểm tra tính đầy đủ, Security reviewer tìm lỗ hổng, Code reviewer đánh giá chất lượng.
1# Basic usage2/autopilot create a REST API for inventory management34# With more details5/autopilot build a dashboard with:6- user authentication7- charts for sales data8- export to CSV9- dark mode support1011# Keyword trigger (without slash)12"autopilot create a CLI tool for file organization"- New projects requiring multiple files and related features.
Dự án mới cần nhiều file và tính năng liên quan.
- Complex features requiring planning, implementation, and testing.
Tính năng phức tạp cần planning, implementation và testing.
- When you want hands-off and let AI handle everything.
Khi bạn muốn hands-off và để AI xử lý toàn bộ.
- Simple bug fixes - use directly or /ralph instead.
Bug fix đơn giản - dùng trực tiếp hoặc /ralph thay vì.
- Questions or explanations - just ask normally.
Câu hỏi hoặc giải thích - chỉ cần hỏi bình thường.
- Small changes in one file - overkill for autopilot.
Thay đổi nhỏ trong một file - quá overkill cho autopilot.
Autopilot có thể chạy trong thời gian dài (10-30 phút cho dự án lớn). Sử dụng /cancel để dừng và tiếp tục sau.
1# Cancel current autopilot2/cancel34# Resume (run autopilot again with same task)5/autopilot6# Claude will detect previous state and offer to resumeKey Takeaways
Điểm Chính
- Autopilot handles entire projects from idea to working codeAutopilot xử lý toàn bộ dự án từ ý tưởng đến code hoạt động
- 5 phases: Expansion, Planning, Execution, QA, Validation5 giai đoạn: Expansion, Planning, Execution, QA, Validation
- Best for complex multi-file features and new projectsTốt nhất cho tính năng phức tạp nhiều file và dự án mới
- Use /cancel to stop, run /autopilot again to resumeDùng /cancel để dừng, chạy /autopilot lại để tiếp tục
Practice
Test your understanding of this chapter
What happens in Phase 0 (Expansion) of Autopilot?
Điều gì xảy ra trong Phase 0 (Expansion) của Autopilot?
Autopilot should be used for simple one-line bug fixes.
Autopilot nên được dùng cho bug fix đơn giản một dòng.
Complete the command to cancel a running autopilot
Hoàn thành lệnh để hủy autopilot đang chạy
/How many QA cycles does Autopilot run at maximum?
Autopilot chạy tối đa bao nhiêu QA cycles?