Skill Overview
Skill Name: wechat-red-envelope-cover-designer
Core Function: Generate cover design images that comply with the specifications of the WeChat Red Envelope Cover Open Platform, including cover images, cover pendants, bubble pendants, and cover story materials.
Applicable Scenarios:
- Festival-themed red envelope cover design for Spring Festival, Mid-Autumn Festival, Valentine's Day, Qixi Festival, Christmas, Birthday, Lantern Festival, Dragon Boat Festival, New Year's Day, National Day, etc.
- Custom brand event-themed red envelope cover design
- Enterprise or personal custom red envelope cover needs
Complete Workflow
plaintext
Requirement Confirmation → Design Formulation → Cover Image Generation → Delivery & Review Reminder
Phase 1: Requirement Confirmation
Before starting the design, the following key information must be confirmed with the user:
1. Basic Information Confirmation
Cover Theme:
- Festival type selection: Spring Festival, Mid-Autumn Festival, Valentine's Day, Qixi Festival, Christmas, Birthday, Lantern Festival, Dragon Boat Festival, New Year's Day, National Day
- Or brand event theme
Cover Abbreviation:
- Maximum 8 characters
- Displayed on the red envelope cover
- Can be: enterprise name abbreviation, official account name, video account name, registered trademark
Need Brand Logo:
- Yes/No
- If yes, provide the logo file (200×200px, ≤100KB)
Target Audience:
- General users
- Enterprise clients
- Specific groups
2. Design Style Confirmation
Overall Style Selection:
- Chinese Chic (traditional elements + modern design)
- Minimalist
- Illustration
- 3D Stereoscopic
- Flat Design
- Hand-drawn
- Cute/Q-style
- Retro
- Other custom styles
Main Color Preference:
- Red and Gold Series (suitable for festive festivals like Spring Festival, National Day)
- Pink and Purple Series (suitable for Valentine's Day, Qixi Festival)
- Blue and White Series (suitable for Mid-Autumn Festival, ice and snow themes)
- Green Series (suitable for Dragon Boat Festival, environmental protection themes)
- Custom color description
Element Preference:
- Traditional elements (auspicious clouds, patterns, window grilles, etc.)
- Modern elements (geometric shapes, abstract designs, etc.)
- Mascots
- Abstract patterns
- Specific IP images
3. Material Requirement Confirmation
Materials the user needs to generate:
- ☑️ Cover Image (Required)
- ☐ Cover Pendant (Optional)
- ☐ Bubble Pendant (Optional)
- ☐ Cover Story Images (Optional, maximum 5 images)
4. Special Requirement Confirmation
Include Portrait:
- If yes, provide portrait authorization letter (authorization validity period ≥ 6 months after submission for review)
Use Registered Trademark:
- If yes, provide trademark registration certificate
Include Copyrighted Materials:
- If yes, provide copyright authorization letter (authorization validity period ≥ 6 months after submission for review)
Phase 2: Design Formulation
Based on the confirmed requirements, present the complete design proposal to the user:
Proposal Display Format
plaintext
【Design Proposal】
━━━━━━━━━━━━━━━━━━━━━━━━
🎨 Theme: [Theme Name]
📝 Cover Abbreviation: [Abbreviation] (≤8 characters)
🎯 Design Style: [Style Description]
🎨 Main Color Scheme: [Color Scheme]
📦 Material List:
1. ☑️ Cover Image (Required) - 957×1278 pixels
2. ☐ Cover Pendant (Optional) - 1053×1746 pixels
3. ☐ Bubble Pendant (Optional) - 480×384 pixels
4. ☐ Cover Story Images (Optional) - 750×1250 pixels × [Quantity]
━━━━━━━━━━━━━━━━━━━━━━━━
Proposal Confirmation
- After the user confirms the design proposal is correct, proceed to the next phase
- If there are modification needs, adjust and confirm again
- Start generating images only after confirmation
Phase 3: Cover Image Generation
Generate various materials in strict accordance with the following order and specifications:
Generation Order
- Cover Image (Required) - 957×1278px
- Cover Pendant (Optional) - 1053×1746px
- Bubble Pendant (Optional) - 480×384px
- Cover Story Images (Optional) - 750×1250px
Image Generation Steps
Step 1: Select Prompt Template
If it's a festival theme:
- Use the festival-specific prompts in
references/festival-prompts.md
- Ensure elements and color schemes match the festival
If it's a custom theme:
- Use the general templates in
references/prompt-templates.md
- Replace variables and supplement details according to user needs
Step 2: Build Complete Prompt
Replace the following variables according to the selected template:
- : Replace with the specific style confirmed by the user
- : Replace with the color scheme confirmed by the user
- : Replace with the specific theme name
[Core Visual Element Description]
: Replace with the core elements confirmed by the user (such as zodiac images, animals, etc.)
- : Replace with the specific background description
- : Replace with the decorative elements confirmed by the user
Step 3: Emphasize Key Composition Rules
- Use the detailed instructions in the dimension specification file
references/dimension-specs.md
The prompt must include relevant rules from the dimension specification file, such as the following instructions:
Cover Image Composition Rules:
- Main visual elements are concentrated in the middle and lower parts of the image
- Avoid complex patterns in the upper area to ensure white text is clearly readable
- The bottom 15% of the image may be blocked, so avoid placing key elements there
Cover Pendant Composition Rules:
- Description: The pendant should be a pattern or icon with certain shapes and decorative patterns, not a single line or wireframe. The cover pendant will be displayed together with the cover image on the red envelope opening page.
- Size: 1053×1746 pixels, aspect ratio approximately 3:5
- Editable Area: Only the top approximately 324px area is editable (the rest is non-editable)
- Design elements must be 100% located within the top 324px area (including details such as shadows, halos, particles, etc.)
- The area below the top 324px must be completely blank/transparent (no opaque pixels allowed)
- The pendant should be a pattern or icon with certain shapes and decorative patterns, not a single line or wireframe.
Bubble Pendant Composition Rules:
- Description: The bubble pendant should be a pattern or icon with certain shapes and decorative patterns, not a single line or wireframe. The bubble pendant will be displayed together with the cover image on the red envelope bubble.
- Size: 480×384 pixels, aspect ratio 5:4
- Editable Area (according to platform editor schematic):
- Top 96px is editable area (elements can be placed)
- Middle 216px is non-editable area (must be completely transparent and blank, no opaque pixels allowed)
- Bottom 72px is editable area (elements can be placed)
- Elements must not cross boundaries: including shadows, strokes, glows, particles, etc., must not enter the middle 216px non-editable area
Cover Story Image Composition Rules:
- Description: The cover story will be displayed on the red envelope details page, used to tell the story behind the brand, team, and cover creation, allowing brand culture to be better conveyed.
- Size: 750×1250 pixels, aspect ratio 3:5
- The top and bottom 10% of the image may be cropped on some devices
- Key elements are concentrated in the central 80% area of the image
- Reserve space at the bottom for optional story description text overlay
Step 4: Emphasize Prohibited Elements
The prompt must include the following prohibited content:
- No text, watermarks or logos
- No QR codes, barcodes or contact information
- No real person photos or portraits
- No brand product images or advertising elements
- No political, religious or controversial symbols
- Content suitable for all age groups
Step 5: Call Image Generation Tool
-
Use the
tool to generate initial images, with the following command example:
node scripts/generate_image.js -p "Sunset mountain landscape" -f "sunset.png" -a 1:1 -r 2K
Command explanation:
| Parameter | Required | Description |
|---|
| / | Yes | Image description (text-to-image) or editing instruction (image-to-image). Keep the user's original complete input. |
| / | No | Output image path/filename; if not provided, a PNG filename with timestamp will be automatically generated and saved in the current directory. |
| / | No | Image aspect ratio: , , , , , , , , , |
| / | No | Image resolution: / / (must be uppercase). If not provided, it will not be specified in the request, determined by the API side. |
| / | No | Input image path for image-to-image; multiple images (up to 14) can be passed. Passing this parameter enters edit mode. |
-
Set appropriate descriptions according to material types
-
Generate multiple images each time to improve quality
Step 6: Adjust Image Size and Auto-Compress
- Use the instructions in to understand image size specifications and intelligent compression strategies
Use the
script for precise cropping, size adjustment and intelligent compression of generated images:
Script Functions:
- Auto center cropping to maintain target aspect ratio
- Intelligent Compression: Automatically adjust quality until meeting WeChat size limits
- Support batch generation of all sizes
- Auto check file size limits
- Auto force safety area transparency for pendants
- Display safety area prompts
- Note: This script does not handle background removal. Please use remove_bg_enhanced.js for background removal
WeChat Size Limits:
- Cover Image: ≤500KB
- Cover Pendant: ≤300KB (PNG transparent)
- Bubble Pendant: ≤300KB (PNG transparent)
- Cover Story: ≤300KB per image
Usage:
-
Install Dependencies
-
Single Type Cropping (Auto Compression)
bash
# Generate cover image (auto compress to ≤500KB)
node resize_cover.js <input-image> cover
# Generate cover pendant (auto crop to standard size, only retain top 324px editable area)
node resize_cover.js <input-image> hang
# Generate bubble pendant (auto crop to standard size, retain top 96px and bottom 72px editable areas)
node resize_cover.js <input-image> bubble
# Generate cover story (auto compress to ≤300KB)
node resize_cover.js <input-image> story
-
Batch Generate All Sizes
bash
node resize_cover.js <input-image> all [output-directory]
-
Specify Output Path
bash
node resize_cover.js <input-image> <type> <output-path>
Supported Sizes:
- Cover Image: 957×1278px (3:4)
- Cover Pendant: 1053×1746px (3:5, only top 324px editable, PNG transparent)
- Bubble Pendant: 480×384px (5:4, top 96px + bottom 72px editable, middle 216px transparent blank, PNG transparent)
- Cover Story: 750×1250px (3:5)
Intelligent Compression Strategy:
The script will automatically try multiple compression strategies until meeting the limit:
-
Non-transparent Images (cover images, story images):
- JPEG quality adjustment: 90% → 85% → ... → 55%
- Optimize encoding with mozjpeg
- Reduce resolution if necessary
-
Transparent Images (pendants):
- 8-bit palette PNG
- Reduce palette quality
- Limit color count (128 colors)
- Maximum compression level
- Reduce resolution if necessary
Output Example:
📸 Cover Image
Original: 1920×1080px, 2450.50KB
Target: 957×1278px, ≤500KB
Cropped: 1438×1080px → 957×1278px
✅ Saved to: ./output/cover.jpg
Size: 485.32KB / 500KB
Compression: jpeg, quality 75%
Step 7: Handle Transparent Background (Pendants Only)
For cover pendants and bubble pendants, ensure the background is transparent (PNG format) and elements are located within the specified safety areas.
Use remove_bg_enhanced.js (AI-generated Image Special)
Suitable for AI-generated images with complex backgrounds, featuring intelligent background detection algorithms:
Script Features:
- Intelligent background detection (supports white/gray/auto modes)
- Dual detection algorithm based on brightness and color distance
- Edge feathering and anti-aliasing processing
- Noise filtering (auto remove small impurities)
- Optimized for AI-generated images
Usage:
-
Generate White Background Image First
bash
# Generate cover pendant (prompt includes "PURE WHITE BACKGROUND")
node generate_image.js -p "... PURE WHITE BACKGROUND ..." -i "cover.png" -f "cover-pendant-white-bg.png" -a "2:3"
# Generate bubble pendant
node generate_image.js -p "... PURE WHITE BACKGROUND ..." -i "cover.png" -f "bubble-pendant-white-bg.png" -a "5:4"
-
Use Enhanced Script to Remove Background
bash
# Process cover pendant
node remove_bg_enhanced.js cover-pendant-white-bg.png cover-pendant.png --mode white --tolerance 35 --feather 4
# Process bubble pendant
node remove_bg_enhanced.js bubble-pendant-white-bg.png bubble-pendant.png --mode white --tolerance 35 --feather 3
-
Adjust Size to Specification Requirements
bash
# Adjust cover pendant to standard size (already transparent, just crop)
node resize_cover.js cover-pendant.png hang cover-pendant.png
# Adjust bubble pendant to standard size (already transparent, just crop)
node resize_cover.js bubble-pendant.png bubble bubble-pendant.png
Parameter Explanation:
| Parameter | Description | Default Value | Recommended Value |
|---|
| Background detection mode: // | auto | white (white background images) |
| Background tolerance (0-100), larger values are more aggressive | 30 | 35-50 |
| Edge feathering pixels (0-20) | 3 | 3-5 |
| Edge smoothness (0-10) | 2 | 2-4 |
| Minimum reserved area pixel count | 100 | 100-200 |
Complete Workflow Example:
bash
# 1. Generate white background pendant image
node generate_image.js \
-p "A decorative pendant design on PURE WHITE BACKGROUND..." \
-i "cover.png" \
-f "cover-pendant-white-bg.png" \
-a "2:3"
# 2. Remove background
node remove_bg_enhanced.js \
cover-pendant-white-bg.png \
cover-pendant-transparent.png \
--mode white \
--tolerance 35 \
--feather 4 \
--min-area 200
# 3. Adjust size to WeChat specifications
node resize_cover.js \
cover-pendant-transparent.png \
hang \
cover-pendant.png \
--no-remove-bg
Notes:
- Be sure to add to the prompt when generating images
- Adjust tolerance value according to actual effect, can appropriately increase for complex backgrounds
- Larger feather values result in softer edges but may lose details
- Must use to adjust to standard size after processing
Phase 4: Delivery & Review Reminder
After completing all material generation, provide the user with a complete delivery list and review reminders:
Delivery List Format
plaintext
【Delivery List】
━━━━━━━━━━━━━━━━━━━━━━━━
✅ Cover Image (957×1278px), File Name
└─ Format: PNG/JPG, ≤500KB
☐ Cover Pendant (1053×1746px), File Name
└─ Format: PNG transparent background, ≤300KB
☐ Bubble Pendant (480×384px), File Name
└─ Format: PNG transparent background, ≤300KB
☐ Cover Story Images (750×1250px) × [Quantity], File Name
└─ Format: PNG/JPG, ≤300KB per image
📋 Submission & Review Reminders:
- [ ] Prepare cover abbreviation (≤8 characters)
- [ ] Prepare brand logo (if needed, 200×200px, ≤100KB)
- [ ] Prepare supporting documents (if involving trademarks/portraits/copyrights)
- [ ] Authorization validity period ≥ 6 months after submission for review
━━━━━━━━━━━━━━━━━━━━━━━━
Pre-Review Self-Check Reminders
Remind the user to perform the following checks before submitting for review:
- Content Compliance Check
- No legally prohibited content
- No politically sensitive content
- No contact information or traffic-diversion information
- No commercial promotion content
- No infringement of others' copyrights, trademarks, portrait rights
- Design Quality Check
- Clear and sharp image, no blurriness or jagged edges
- Harmonious and unified color matching
- Balanced composition, clear focus
- File size meets requirements
- Exact size
- Safety Area Check
- The top 25% area of the cover image is simple and clean
- No key elements in the bottom 15% of the cover image
- Cover pendant elements are only within the top 324px editable area (the rest is transparent blank)
- The middle 216px non-editable area of the bubble pendant is completely transparent (elements only appear in the top 96px and bottom 72px)
- Format Requirement Check
- Cover Image: PNG/JPG, ≤500KB, 957×1278px
- Cover Pendant: PNG transparent, ≤300KB, 1053×1746px
- Bubble Pendant: PNG transparent, ≤300KB, 480×384px
- Cover Story: PNG/JPG, ≤300KB per image, 750×1250px
Key Principles of Workflow
1. Step-by-Step
- Proceed to the next phase only after completing the current one
- Start generating images only after the user confirms the design proposal
- Ensure each step complies with specifications
2. Follow Specifications
- Strictly follow the size specifications in
references/dimension-specs.md
- Strictly follow the prompt templates in
references/prompt-templates.md
and references/festival-prompts.md
- Strictly follow the review standards in
references/audit-standards.md
3. Style Consistency
- All materials (cover images, pendants, story images) must use a unified design language
- Colors, styles, and element selections must be coordinated
- Form a complete visual system
4. Safety First
- Always prioritize review pass rate
- Do not use any uncertain content
- Keep content positive, healthy and uplifting
5. User Confirmation
- User confirmation is required at each key phase
- User satisfaction is the ultimate goal
- Adjust promptly based on user feedback
Common Scenario Handling
Scenario 1: User Selects Festival Theme
- Select the corresponding festival template from
references/festival-prompts.md
- Use festival-specific elements and color schemes
- Generate materials according to the design requirements of the festival theme
Scenario 2: User Has Custom Brand Needs
- Use the general templates in
references/prompt-templates.md
- Integrate the user's brand elements (logo, brand colors, etc.)
- Remind the user to prepare supporting documents such as trademark registration certificates
Scenario 3: User Needs All Materials
- Generate in order: Cover Image → Cover Pendant → Bubble Pendant → Cover Story Images
- Ensure each image complies with the corresponding size specifications
- Maintain style consistency across all materials
Scenario 4: User Only Needs Cover Image
- Generate only the cover image (957×1278px)
- Ensure the composition meets safety area requirements
- Focus on optimizing the visual effect of the cover image
Skill Directory File Structure
Core Function: Store reference documents, templates and specification files required for skill operation, providing standardized guidance for WeChat red envelope cover design.
├── SKILL.md # Main skill file, including complete workflow and usage instructions
└── scripts/ # Script folder
├── generate_image.js # Image generation script (text-to-image/image-to-image)
├── resize_cover.js # Image size cropping and compression script
├── remove_bg_enhanced.js # Enhanced background removal script (for AI-generated images)
├── package.json # Dependency configuration
└── README.md # Script usage instructions
└── references/ # Reference document folder
├── dimension-specs.md # Dimension specification document
├── prompt-templates.md # General prompt templates
├── festival-prompts.md # Festival-specific prompts
└── audit-standards.md # Review standards document
References File List and Usage Instructions
1. dimension-specs.md (Dimension Specification Document)
Document Function: Define precise size specifications and design requirements for various materials of WeChat red envelope covers
2. prompt-templates.md (General Prompt Templates)
Document Function: Provide general prompt templates for various materials to ensure generated images comply with WeChat red envelope cover specifications
3. festival-prompts.md (Festival-Specific Prompts)
Document Function: Provide festival-specific prompt templates for different festivals, including festival-specific elements, color schemes and design requirements
4. audit-standards.md (Review Standards Document)
Document Function: Detail the review standards and prohibited content for WeChat red envelope covers, ensuring generated materials can pass platform review
Scripts List and Usage Instructions
1. generate_image.js (Image Generation Script)
File Function: Call AI interface to generate images, supporting text-to-image and image-to-image
Core Functions:
- Text-to-image: Generate new images based on prompts
- Image-to-image: Edit and optimize based on existing images
- Support multiple aspect ratios and resolutions
Usage Scenarios:
- Generate cover images, pendants, story images and other materials
- Generate supporting materials based on existing images (maintain style consistency)
2. resize_cover.js (Size Cropping Script)
File Function: Adjust image size to WeChat red envelope cover specifications and perform intelligent compression
Core Functions:
- Auto center cropping to maintain target aspect ratio
- Intelligent compression to meet size limits
- Auto force safety area transparency for pendants (only retain content in editable areas)
Usage Scenarios:
- Adjust images to the standard size of WeChat red envelope covers
- Compress files to meet WeChat size limits
- Force safety areas for pendant images (auto crop non-editable areas)
Notes:
- This script does not handle background removal, only size and compression
- For background removal, please use remove_bg_enhanced.js first
3. remove_bg_enhanced.js (Enhanced Background Removal Script) ⭐ Recommended
File Function: Intelligent background removal tool designed specifically for AI-generated images
Core Functions:
- Intelligent background detection (white/gray/auto modes)
- Dual detection algorithm based on brightness and color distance
- Edge feathering and anti-aliasing processing
- Noise filtering, retain subject details
Usage Scenarios:
- Background removal for AI-generated pendant images
- Professional keying for complex backgrounds
- Scenarios requiring fine edge processing
Script Division of Labor:
| Function | resize_cover.js | remove_bg_enhanced.js |
|---|
| Main Responsibility | Size cropping and compression | Background removal and transparency processing |
| Applicable Scenarios | Size standardization for all images | Background removal for AI-generated images |
| Core Capabilities | Center cropping, intelligent compression, safety area restriction | Intelligent background detection, edge feathering, noise filtering |
| Usage Timing | Final step of size standardization | After background removal, before resize_cover.js |
| Typical Workflow | Execute last | Generate white background image first → remove background → adjust size with resize_cover.js |
References File Usage Principles
- Prioritize Festival-Specific Templates
- When the user selects a festival theme, prioritize using the corresponding template in festival-prompts.md
- Ensure festival elements and color schemes match festival characteristics
- General Templates as Supplement
- When the user has custom needs or the festival-specific template does not fully match, use the general templates in prompt-templates.md
- Replace variables and supplement details according to user needs
- Strictly Follow Size Specifications
- All materials must be generated strictly in accordance with the size requirements in dimension-specs.md
- Pay special attention to composition safety areas to ensure text readability
- Always Follow Review Standards
- All designs must comply with the requirements in audit-standards.md
- Avoid using any prohibited content
- Ensure content is suitable for all age groups
- Maintain Style Consistency
- All materials (cover images, pendants, story images) must use a unified design language
- Colors, styles, and element selections must be coordinated