prompt-writing
Skill này làm gì
Skill này hướng dẫn việc viết và tinh chỉnh các prompt lưu trong YAML, chẳng hạn system prompt và prompt cho agent. Skill dành cho người xây dựng trợ lý AI và muốn có prompt rõ ràng, có cấu trúc.
Khi nào nên dùng
- ✓Khi bạn đang viết system prompt cho một trợ lý AI.
- ✓Khi bạn muốn cải thiện một mẫu prompt YAML chưa hoạt động tốt.
- ✓Khi bạn cần thêm biến và các phần rõ ràng vào một prompt.
Liên kết skill
https://github.com/ModelEngine-Group/nexent/blob/develop/.claude/skills/prompts-writing/SKILL.mdSao chép rồi dán vào AI của bạn (Claude, ChatGPT hoặc Cursor) và nhờ nó làm theo hướng dẫn.
Cách dùng
Cách dễ nhất: sao chép tin nhắn và dán vào AI của bạn. AI sẽ đọc skill và làm theo hướng dẫn.
Tin nhắn có sẵn để dán
Dành cho Claude Code, Codex hoặc Cursor: chạy lệnh trong thư mục dự án của bạn và skill sẽ được cài đặt.
Tải tệp SKILL.md về và thả vào thư mục skill của agent.
Ví dụ cách nhờ AI
“Viết lại system prompt YAML cho agent hỗ trợ khách hàng của chúng tôi, có các phần rõ ràng, chỗ giữ chỗ cho tên khách hàng và một danh sách kiểm tra.”
5 skill mới mỗi tuần. Đọc chỉ 1 phút.
Cách hoạt động
Skill cung cấp cho agent một bố cục YAML chuẩn, quy tắc về tiêu đề, danh sách và chỗ giữ chỗ, cùng một danh sách kiểm tra chất lượng. Agent dùng những thứ này để tạo hoặc chỉnh prompt và kiểm tra trước khi trả lại.
Nội dung kỹ thuật (SKILL.md gốc)
Lấy nguyên văn từ GitHub, do tác giả viết bằng tiếng Anh.
Prompt Writing
Create and optimize YAML-based prompts for AI assistants following industry best practices.
Quick Start
Standard YAML Prompt Structure
system_prompt: |-
# Section with ### header
## Subsection with ## header
Content with clear structure.
**Bold key concepts**
- Bullet points for requirements
- Consistent indentation (2 spaces)
1. Numbered lists for sequences
2. Use when order matters
user_prompt: |
Direct instructions with {{ variable placeholders }}
Key Principles
- Structure: Use
|-for multi-line system prompts,|for user prompts - Templating: Use
{{ variable }}for dynamic content - Separators: Use
---sparingly, only between major sections - Language: Keep prompts in consistent language (English recommended for templates)
Quality Checklist
Before finalizing any prompt, verify:
- No unclosed braces
{{without}} - No excessive separators (
---,***) - Consistent heading hierarchy (
###→##) - Clear variable placeholders with descriptive names
- Proper YAML indentation preserved
- No HTML tags in Markdown content
- Lists have parallel structure
Common Patterns
System Prompt with Sections
system_prompt: |-
### Role Definition
You are a professional [role name]. Your task is to [core responsibility].
### Requirements
1. First requirement
2. Second requirement
3. Third requirement
### Guidelines
- Do this
- Don't do that
- Always do this
### Output Format
Respond in plain text without separators.
Jinja2 Template Variables
user_prompt: |
Please analyze the following {{ document_type }}:
Name: {{ filename }}
Content: {{ content }}
Summary ({{ max_words }} words):
References
- Best Practices: See best-practices.md for detailed guidelines
- Templates: See templates.md for reusable patterns
- Examples: See examples.md for real-world samples
Related Tools
When working with prompts, also consider:
- YAML validation tools
- Jinja2 syntax checkers
- Markdown linters
Câu hỏi thường gặp
Skill dùng định dạng nào?
Skill dùng YAML với một khối system prompt và một khối user prompt.
Biến được viết như thế nào?
Nội dung động được viết trong hai cặp dấu ngoặc nhọn, ví dụ tên của một biến.
Skill có kiểm tra kết quả không?
Có. Skill có danh sách kiểm tra để xác minh prompt trước khi hoàn tất.
Chi tiết
Mô tả gốc của tác giả
Create, refine, and optimize high-quality YAML prompts for AI assistants. Use when working with prompt templates, system prompts, agent prompts, or any prompt engineering tasks. Provides structure guidelines, template patterns, and quality standards for YAML-based prompts.
repo: ModelEngine-Group/nexent
Độ phổ biến
- Sao GitHub
- 6.1k
- Vị trí xếp hạng
- #14426
- Giấy phép
- MIT
- Cập nhật
- 2/11/2026
Bình luận
- …
Skill tương tự
writing-skills
311kDạy agent của bạn viết skill mới và kiểm thử từng skill trước, kiểm tra xem skill có thực sự thay đổi cách agent hành xử hay không.
writing-for-agents
310kGiải thích cách viết hướng dẫn rõ ràng cho agent AI, gồm skill, tệp AGENTS.md và CLAUDE.md, để agent cư xử nhất quán.
bengali-nlp
280kGiúp agent của bạn xử lý văn bản tiếng Bengali, hỗ trợ hiểu ngôn ngữ này, chuẩn hóa văn bản và xử lý các đặc điểm riêng của nó.