QuotaCheap Playbook
Codex IDE Workflow: dùng open files, selection, diff và cloud delegation để code ít đoán hơn
Hướng dẫn Codex IDE workflow cho developer: open files, selected code, @file references, Chat/Agent modes, reasoning effort, image context, local UI loop,…
Trong IDE, Codex không cần bạn mô tả mọi thứ từ đầu. Open files, selected code, @file references, image context và diff preview giúp prompt ngắn hơn nhưng kết quả sát repo hơn.
Playbook tiếng Việt về Codex IDE workflow theo tài liệu OpenAI: VS Code/Cursor/Windsurf extension, open files context, selected code, @file references, model/reasoning, Chat vs Agent vs Full Access, image context, local planning, UI iteration, cloud delegation, follow-up cloud work, và verification.
Codex CLI mạnh khi bạn muốn transcript, shell commands và terminal control.
Codex Cloud mạnh khi bạn muốn giao việc nền.
Còn Codex IDE mạnh nhất ở khoảnh khắc bạn đang nhìn code.
Trong IDE, Codex có thứ mà prompt terminal thường thiếu: open files, selected code, editor context, diff preview, screenshot/mock, và vòng lặp rất nhanh giữa “sửa code → nhìn UI → chỉnh tiếp”.
Theo tài liệu OpenAI, Codex IDE extension gives access to Codex directly in VS Code, Cursor, Windsurf và các VS Code compatible editors.
Nó dùng cùng agent với CLI và shares same configuration.
Docs cũng nói: when Codex has context from open files and selected code, you can write shorter prompts and get faster, more relevant results.
Đây là điểm cốt lõi.
IDE workflow không phải là gõ prompt dài hơn.
Nó là đưa đúng context bằng hành động editor: mở file đúng, chọn đoạn đúng, attach ảnh đúng, preview diff đúng.
Bài này là playbook để dùng Codex IDE như một teammate trong editor: khi nào dùng Chat, khi nào dùng Agent, khi nào mở file, khi nào select code, khi nào delegate cloud, và cách verify để không accept diff theo cảm tính.
Codex IDE khác CLI ở đâu?
CLI buộc bạn mô tả context rõ hơn: file nào, path nào, command nào.
IDE có thể tự mang theo một phần context editor.
Theo docs workflows: IDE extension automatically includes your open files as context.
Trong CLI, bạn thường phải mention paths explicitly.
Điều này khiến IDE rất hợp với: đọc hiểu request flow khi bạn đã mở files liên quan; sửa một bug bạn đang nhìn trong editor; thêm test cho function selected; chỉnh UI dựa trên screenshot/mock; review diff trực tiếp trong editor; local planning trước khi delegate cloud; follow up cloud changes rồi apply local để test.
CLI vẫn hơn IDE khi: bạn cần transcript terminal dài; shell commands là trung tâm workflow; automation/non interactive exec; review working tree bằng slash command; chạy task trên remote terminal; xử lý repo qua SSH/headless.
Nói ngắn: IDE tốt cho context nhìn thấy.
CLI tốt cho command heavy workflow.
Open files là context, không phải trang trí Một trong những cách dùng IDE sai là mở 20 file rồi hỏi Codex “fix bug”.
Open files giúp Codex hiểu context, nhưng quá nhiều file cũng tạo noise.
Mở entrypoint liên quan.
Mở nearest caller/callee.