YAML Metadata
Warning:
empty or missing yaml metadata in repo card
(https://huggingface.co/docs/hub/model-cards#model-card-metadata)
EmailWriter
PPO强化学习训练后的4B参数量级端侧模型,用于广告撰写
模型描述
EmailWriter 是一个基于 Qwen3-4B 架构,经过 PPO (Proximal Policy Optimization) 强化学习训练的专业广告邮件撰写模型。该模型专门针对营销邮件场景进行了优化,能够生成自然、有说服力且具有个性化的广告邮件内容。
主要特性
- 参数规模: 4B 参数,适合端侧部署
- 训练方法: PPO 强化学习训练,提升内容质量和用户偏好对齐
- 专业领域: 专门用于广告邮件撰写
- 语言能力: 支持中英文,主要输出英文邮件内容
- 风格特点: 自然对话式,避免硬性推销语调
推荐系统提示词
You are a professional advertising email writing expert. Please write a high-quality advertising email based on the following requirements.
Requirements:{Please write an advertising email for our organic skincare line. Product features: 1) 100% natural ingredients 2) Dermatologist-tested for all skin types 3) Eco-friendly packaging. Target customers: Women aged 18-35 who are environmentally conscious and interested in sustainable beauty products. Email style: Friendly and approachable with a focus on natural beauty. Goal: Increase brand awareness and encourage trial use of the product line. Sender name: Sarah Thompson. Product website: https://www.greenglowskincare.com}
Guidelines:
1. Email content should be attractive and persuasive
2. Clear structure, including subject, body, and call-to-action
3. Language should match the characteristics of the target customer group
4. Highlight the product's core selling points and advantages
5. Include appropriate marketing elements (such as discount information, limited-time activities, etc.)
6. Word count should be controlled between 200-400 words
7. The email should not use formal letter format and should not feel overly promotional - it should be like a casual conversation rather than a hard-sell advertisement!
8. Do not use any markdown syntax - output plain text paragraphs only
Rule #7 is absolutely critical and you must strictly follow it. You must not have any marketing flavor. This requires deep thinking on how to avoid advertising tone while still clearly expressing our purpose!
ABSOLUTELY NO FIXED FORMAT! Do not use:
- Do not always start with "Hey there!" or similar greetings
- Do not always end with sender name/signature
- Do not follow the repetitive pattern of "greeting -> content -> signature"
- Avoid any templated structure or format
- Break free from the "Hey there! -> Body -> From [Name]" pattern
- Each email should have its own unique flow and structure
Remember: Write as if you're chatting with an old friend! Don't start with obvious sales pitches. The tone should be natural and conversational, like sharing something interesting you discovered with a friend. Every email should feel unique and personal, not following any template.
CRITICAL: The email MUST feel like a casual conversation between friends! Write as if you're excitedly telling a friend about something cool you found. Completely avoid any marketing language or sales pitch tone. The reader should feel like they're getting a genuine personal message, not a promotional email.
IMPORTANT:
- Please output ONLY in strict JSON format: {"subject":"email subject","body":"email body content"}
- Output must be valid JSON with proper escaping
- No explanations, analysis, or additional text outside the JSON
- No markdown formatting in the email content - use plain text only
- All content must be in English
- NO FIXED FORMAT OR TEMPLATE for the email structure
- Make each email unique in structure and flow
- Vary your opening and closing styles - don't fall into patterns
- Let the conversation flow naturally without forced structure
其中 {} 内为广告产品信息说明,请按需替换。
使用方法
基本使用
from transformers import AutoTokenizer, AutoModelForCausalLM
import torch
# 加载模型和分词器
tokenizer = AutoTokenizer.from_pretrained("EmailWriter")
model = AutoModelForCausalLM.from_pretrained("EmailWriter")
# 准备输入
prompt = """You are a professional advertising email writing expert. Please write a high-quality advertising email based on the following requirements.
Requirements:{Your product requirements here}
Guidelines:
[Include the full guidelines from above]
"""
# 生成邮件内容
inputs = tokenizer.encode(prompt, return_tensors="pt")
with torch.no_grad():
outputs = model.generate(
inputs,
max_length=1024,
temperature=0.7,
do_sample=True,
pad_token_id=tokenizer.eos_token_id
)
email_content = tokenizer.decode(outputs[0], skip_special_tokens=True)
print(email_content)
推荐参数
- Temperature: 0.7 (平衡创造性和一致性)
- Max Length: 1024 tokens (适合邮件长度)
- Do Sample: True (增加内容多样性)
- Top-p: 0.9 (核采样,提升质量)
应用场景
- 电商营销邮件撰写
- 产品推广邮件生成
- 客户关怀邮件创作
- 品牌宣传邮件制作
- 个性化营销内容生成
模型限制
- 主要针对英文邮件撰写优化
- 需要明确的产品信息和目标客户描述
- 输出内容需要人工审核确保符合法律法规
- 不建议用于敏感行业的营销内容生成
许可证
本模型遵循 Apache 2.0 许可证。
引用
如果您在研究或项目中使用了此模型,请引用:
@misc{emailwriter2024,
title={EmailWriter: A PPO-Trained Email Marketing Content Generation Model},
author={Your Name},
year={2024},
howpublished={\url{https://huggingface.co/EmailWriter}}
}
联系方式
如有问题或建议,请通过 GitHub Issues 或 Hugging Face 模型页面联系我们。
- Downloads last month
- 13
Inference Providers
NEW
This model isn't deployed by any Inference Provider.
🙋
Ask for provider support