Biến một yêu cầu thành mã sạch, có chú thích
A ready-to-use “Lập trình” AI prompt template, designed and tested with Claude. Replace the (bracketed) parts below with your own needs.
Prompt template
Hãy viết mã theo yêu cầu của tôi. Yêu cầu: đặt tên rõ ràng, cấu trúc gọn gàng, chú thích bằng tiếng Việt ở những chỗ then chốt, và xử lý lỗi cùng trường hợp biên cơ bản. Sau khi viết, hãy giải thích trong vài câu các đánh đổi trong thiết kế và điều gì có thể tối ưu thêm. Yêu cầu: "mô tả bạn muốn làm gì, bằng ngôn ngữ/framework nào"
How to use this prompt
- Copy the whole prompt above and paste it into Claude or ChatGPT / Claude / Gemini.
- Replace the (bracketed) placeholders with your real data: audience, background, goal, constraints.
- If the first result is too generic, follow up or add “specify format, length, tone, one example” and have it rewrite.
Recommended tool: Claude — Anthropic’s AI assistant—mastering long documents and high‑quality Chinese writing