让轻量级大模型更懂用户意图,自动优化提示词
PromptTailor: Multi-turn Intent-Aligned Prompt Synthesis for Lightweight LLMs
- 用对话数据微调轻量LoRA适配器,生成符合用户意图的提示词
- 在多模型测试中优于思维链提示,仅需3次调用即达最佳效果
- 适合移动端部署,兼顾隐私与响应质量,非专家也能用
轻量级语言模型适用于本地设备和隐私敏感场景,但其输出对提示词质量极为敏感。非专业用户常因缺乏知识或时间,难以持续生成高质量提示,依赖提示优化工具。然而关键挑战在于确保优化后的提示真实契合用户原始意图。我们提出PromptTailor系统,通过意图对齐的提示合成,提升开放式文本生成的质量。该系统将简短用户指令扩展为富含领域信息的丰富提示,同时保留用户明确偏好。系统基于12,300条跨41个日常领域的提示优化对话数据,由三款更强的大模型蒸馏而成,使用量化版Llama3-8B模型,并通过轻量LoRA适配器微调。该适配器可附加于任意Llama3-8B基模型,支持边缘部署。在人类评估和LLM裁判的多目标模型对比中,PromptTailor在偏好率上优于思维链提示,且达到或超越当前最优提示优化方法,仅需3次模型调用(相比9次),证明小型学生模型在强教师指导下,可学会有效提示生成策略,在保持意图对齐的同时显著提升输出质量。
原文摘要 · Abstract (English)
Lightweight language models remain attractive for on-device and privacy-sensitive applications, but their responses are highly sensitive to prompt quality. For open-ended generation, non-expert users often lack the knowledge or time to consistently craft high-quality prompts, leading them to rely on prompt optimization tools. However, a key challenge is ensuring the optimized prompts genuinely align with users' original intents and preferences. We introduce PromptTailor, a system for controllable prompt generation for open-ended text that improves model output quality by intent-aligned prompt synthesis. PromptTailor expands minimal user instructions into rich, domain-aware prompts while preserving the user's stated preferences. The system is a quantized Llama3-8B model fine-tuned with a lightweight LoRA adapter on 12,300 prompt-refinement dialogues spanning 41 everyday domains, distilled from three stronger LLMs. The adapter attaches to any Llama3-8B base, enabling edge deployment. In human and LLM-judge evaluations across multiple target models and optimization baselines, PromptTailor yields higher preference rates than chain-of-thought prompting and matches or surpasses state-of-the-art prompt optimization methods while requiring fewer model calls (e.g., 3 vs. 9). These results show that a compact student, guided by powerful teachers, can learn effective prompt-generation strategies that enhance response quality while maintaining alignment with user intent.
Thank you to arXiv for use of its open access interoperability. PaperDance 不是 arXiv 官方产品;中文卡片由大模型生成,请以原文为准。