vapi-prompt-builder
Compare original and translation side by side
🇺🇸
Original
English🇨🇳
Translation
ChineseVapi Prompt Builder
Vapi提示词构建器
Core Workflow
核心工作流
Use this skill to produce production-ready Vapi voice agent system prompts. Optimize for spoken interaction, low latency, explicit turn-taking, tool reliability, safe escalation, and predictable call outcomes.
Start by classifying the request:
- Create: Build a new Vapi system prompt from a business goal or agent concept.
- Improve: Rewrite an existing prompt while preserving intended behavior.
- Audit: Review an existing prompt and return findings, gaps, and recommended changes.
Then resolve deployment shape:
- Single assistant: one Vapi assistant owns the call flow.
- Squad: multiple specialized assistants hand off between each other.
If the request is ambiguous and the workflow may involve multiple specialized roles, routing, or handoffs, stop and ask: "Should this be designed as one Vapi assistant, or as a Vapi Squad with multiple assistants and handoffs?" Do not draft until this is resolved.
Read when the user mentions squads, Handoff Tools, handoffs between assistants or squads, silent handoffs, dynamic routing, router/triage assistants, specialist assistants, or a workflow that is too broad for one reliable prompt.
references/squad-prompting.mdBefore writing or preserving workflow details, run a capability-grounding pass. Verify that every claimed input, artifact, tool action, side effect, and example is possible through the actual call channel, runtime context, visible Vapi tools, or explicitly described backend behavior. Read when the prompt mentions files, uploads, attachments, documents, screenshots, browser/web actions, async jobs, integrations, or any action the phone caller cannot perform directly during the call.
references/capability-grounding.mdRead when creating or substantially rewriting a prompt, or when the request involves voice style, examples, tool behavior, information collection, or call endings.
references/voice-prompt-patterns.mdRun an identifier-hygiene pass before finalizing. Read when the prompt uses tool names, resource IDs, snake_case identifiers, placeholder names, or generic values such as .
references/identifier-hygiene.mdthe_tool_nameRun a Vapi trust-boundary pass when the prompt, tools, or configuration mention authentication, caller identity, account IDs, permissions, secrets, secure values, verified values, static parameters, , dynamic variables, , tool aliases, handoff arguments, or sensitive tool responses. Read before recommending where those values belong.
function.parametersvariableExtractionPlanreferences/vapi-security-trust.mdRun a Vapi readiness pass before presenting an artifact as ready to build or configure. Read when the output includes tools, structured outputs, dynamic variables, Squads, handoffs, pronunciation guidance, testing/evals, or configuration notes. Separate confirmed Vapi configuration from assumptions and missing deployment inputs.
references/vapi-readiness.md使用本技能生成可投入生产的Vapi语音Agent系统提示词。针对口语交互、低延迟、明确话轮转换、工具可靠性、安全升级处理及可预测通话结果进行优化。
首先对请求进行分类:
- 创建:从业务目标或Agent概念出发,构建全新的Vapi系统提示词。
- 优化:重写现有提示词,同时保留其预期行为。
- 审核:审查现有提示词,返回发现的问题、存在的缺口及建议修改方案。
然后确定部署模式:
- 单助手模式:由一个Vapi助手主导通话流程。
- Squad模式:多个专业助手之间互相转接。
如果请求模糊不清,且工作流可能涉及多个专业角色、路由或转接,请暂停并询问:“该系统应设计为单个Vapi助手,还是包含多个助手及转接机制的Vapi Squad?”在明确此问题前,请勿起草提示词。
当用户提及squads、Handoff Tools、助手或squads之间的转接、静默转接、动态路由、路由/分诊助手、专业助手,或是某个工作流范围过广,无法通过单个可靠提示词实现时,请阅读。
references/squad-prompting.md在编写或保留工作流细节前,先执行能力适配校验。验证所有声称的输入、工件、工具动作、副作用及示例是否可通过实际通话渠道、运行时上下文、可见的Vapi工具或明确描述的后端行为实现。当提示词提及文件、上传、附件、文档、截图、浏览器/网页操作、异步任务、集成,或是来电者在通话期间无法直接执行的任何操作时,请阅读。
references/capability-grounding.md在创建或大幅重写提示词,或是请求涉及语音风格、示例、工具行为、信息收集或通话结束环节时,请阅读。
references/voice-prompt-patterns.md在定稿前执行标识符规范校验。当提示词使用工具名称、资源ID、蛇形命名标识符、占位符名称或这类通用值时,请阅读。
the_tool_namereferences/identifier-hygiene.md当提示词、工具或配置提及认证、来电者身份、账户ID、权限、密钥、安全值、已验证值、静态参数、、动态变量、、工具别名、转接参数或敏感工具响应时,请执行Vapi信任边界校验。在建议这些值的归属位置前,请阅读。
function.parametersvariableExtractionPlanreferences/vapi-security-trust.md在将工件呈现为可构建或配置的就绪状态前,执行Vapi就绪性校验。当输出包含工具、结构化输出、动态变量、Squads、转接、发音指导、测试/评估或配置说明时,请阅读。将已确认的Vapi配置与假设及缺失的部署输入区分开。
references/vapi-readiness.mdIntake
需求收集
Ask the fewest questions needed to make a useful first draft. Prefer a complete draft with clear assumptions over a long upfront questionnaire.
Always collect or infer:
- Business or use case
- Deployment shape: single assistant or Squad
- Agent role and call objective
- Caller type and likely intents
- Success criteria
- Required workflows
- Handoff/routing boundaries when using a Squad
- Tools or actions the agent can use
- Tool schemas, structured outputs, and handoff destinations that are already known
- Model provider when Handoff Tool configuration patterns depend on it
- Which values are server-trusted, caller-spoken, tool-returned, LLM-derived, or security-sensitive
- How each required input becomes available to the agent or backend
- Human handoff or escalation rules
- Information the agent may collect
- Information the agent must not collect
- Tone, persona, and brand constraints
Read when the request is vague, high-risk, or missing several essentials.
references/intake-question-bank.mdIf the user provides an existing prompt, inspect it before asking questions. Ask only about missing facts, contradictions, tool behavior, compliance constraints, or ambiguous handoff rules.
提出最少的问题,以生成有用的初稿。优先提供包含明确假设的完整初稿,而非冗长的前期问卷。
务必收集或推断以下信息:
- 业务或用例
- 部署模式:单助手或Squad
- Agent角色及通话目标
- 来电者类型及可能的意图
- 成功标准
- 必需的工作流
- 使用Squad时的转接/路由边界
- Agent可使用的工具或动作
- 已知的工具 schema、结构化输出及转接目标
- 当Handoff Tool配置模式依赖模型提供商时,需明确模型提供商
- 哪些值是服务器可信、来电者口述、工具返回、LLM生成或安全敏感的
- 每个必需输入如何被Agent或后端获取
- 人工转接或升级处理规则
- Agent可能收集的信息
- Agent禁止收集的信息
- 语气、人设及品牌约束
当请求模糊、高风险或缺少多个关键信息时,请阅读。
references/intake-question-bank.md如果用户提供了现有提示词,请先检查再提问。仅询问缺失的事实、矛盾点、工具行为、合规约束或模糊的转接规则相关问题。
Prompt Sections
提示词模块
For a single assistant, generate or improve these sections unless the user asks for a narrower output:
- Identity and purpose
- Personality and speaking style
- Response guidelines
- Guardrails and safety behavior
- Context and dynamic variables
- Workflow and intent routing
- Tool-use rules
- Error handling and recovery
- Smart information collection
- Escalation, transfer, and call ending
- Few-shot examples
For a Squad, generate or improve:
- Squad purpose and member map
- Entry assistant behavior
- One focused system prompt per assistant
- Handoff decision rules
- Context handoff requirements
- Tool boundaries per assistant
- Shared guardrails
- Per-assistant examples, including handoff examples
- External test scenarios for routing and context preservation
For new prompts and substantial rewrites, include a compact section inside the final Vapi system prompt unless the user explicitly asks to omit examples or there is a strong latency/token reason to keep the prompt minimal. Do not substitute external test scenarios for in-prompt examples.
ExamplesKeep the final system prompt lean. Do not include tutorial prose, rationale, or markdown intended for humans unless the user requests it. Use section headers only if they improve maintainability.
Format the final prompt for fast model parsing, not as human-facing documentation:
- Prefer compact bullets, numbered workflow steps, and short imperative rules over dense paragraphs.
- Keep each rule to one idea; split multi-clause paragraphs into separate rules.
- Use paragraphs only for brief identity/personality context, and keep them to one to three short sentences.
- Do not confuse prompt formatting with spoken output: markdown is acceptable inside the system prompt, but instruct the agent not to speak markdown, bullets, or numbered lists to callers.
- Before finalizing, compress any section that reads like explanatory prose into operational instructions.
对于单助手模式,除非用户要求更窄范围的输出,否则需生成或优化以下模块:
- 身份与目标
- 个性与说话风格
- 响应准则
- 防护规则与安全行为
- 上下文与动态变量
- 工作流与意图路由
- 工具使用规则
- 错误处理与恢复
- 智能信息收集
- 升级处理、转接与通话结束
- 少样本示例
对于Squad模式,需生成或优化以下内容:
- Squad目标与成员映射
- 入口助手行为
- 每个助手的聚焦型系统提示词
- 转接决策规则
- 上下文转接要求
- 各助手的工具边界
- 共享防护规则
- 每个助手的示例(包括转接示例)
- 用于路由及上下文保留的外部测试场景
对于新提示词及大幅重写的提示词,需在最终Vapi系统提示词中加入简洁的模块,除非用户明确要求省略示例,或是存在强烈的延迟/令牌消耗原因需简化提示词。请勿用外部测试场景替代提示词内的示例。
Examples保持最终系统提示词简洁。除非用户要求,否则请勿包含面向人类的教程性文字、原理说明或markdown格式。仅在有助于可维护性的情况下使用章节标题。
为模型快速解析优化最终提示词格式,而非作为面向人类的文档:
- 优先使用简洁的项目符号、编号工作流步骤及简短的命令式规则,而非密集段落。
- 每条规则仅包含一个核心观点;将多从句段落拆分为独立规则。
- 仅在简短的身份/个性说明中使用段落,且段落限制为1-3个短句。
- 请勿混淆提示词格式与口语输出:系统提示词内可使用markdown,但需指示Agent不要向来电者说出markdown、项目符号或编号列表。
- 在定稿前,将任何类似说明性文字的模块压缩为可执行指令。
Example Design
示例设计
Design in-prompt examples as behavioral training data for the voice agent:
- Include at least three examples when the prompt covers a complete workflow: happy path, edge case, and error recovery.
- Cover each primary workflow when the agent has multiple high-value intents.
- Show realistic caller turns, concise assistant responses, tool calls, and tool outcomes.
- Include branching behavior for zero results, multiple results, invalid input, unclear speech, and tool failure when relevant.
- Ground every example in actual channel, runtime, tool, or backend capabilities.
- Use exact tool identifiers only in explicit lines or machine-facing configuration notes.
Tool Call: - Keep examples short enough to justify their latency cost.
- Use shape examples instead of repeating forbidden phrases, sensitive values, or unsupported artifacts.
Keep external test scenarios separate from the final prompt. Test scenarios are for the human/operator to validate the prompt; examples are instructions embedded in the prompt for the model to imitate.
将提示词内的示例设计为语音Agent的行为训练数据:
- 当提示词覆盖完整工作流时,至少包含三个示例:正常路径、边缘场景及错误恢复。
- 当Agent有多个高价值意图时,覆盖每个主要工作流。
- 展示真实的来电者话轮、简洁的助手响应、工具调用及工具结果。
- 当相关时,包含针对无结果、多结果、无效输入、语音不清及工具故障的分支行为。
- 确保每个示例都基于实际渠道、运行时、工具或后端能力。
- 仅在明确的行或面向机器的配置说明中使用精确的工具标识符。
Tool Call: - 控制示例长度,以平衡其带来的延迟成本。
- 使用形式示例替代重复的禁用短语、敏感值或不支持的工件。
将外部测试场景与最终提示词分开。测试场景供人类/操作员验证提示词;示例是嵌入提示词中的指令,供模型模仿。
Voice Optimization
语音优化
Before returning the final prompt, run a voice-agent pass:
- Keep caller-facing turns short, usually one or two sentences.
- Ask one question at a time.
- Avoid numbered lists, bullets, markdown, and visual formatting in agent responses.
- Convert dates, phone numbers, currency, times, and URLs to spoken-friendly forms.
- Replace tool IDs, resource slugs, snake_case identifiers, and placeholder names in prose with natural capability descriptions.
- Add explicit rules for interruptions, silence, unclear input, and tool failures.
- Distinguish light banter from hard off-topic requests.
- Calibrate human-feel controls to the use case: all production agents need natural pacing, repair, and warmth; only add disfluency, banter, or personal rapport when they fit the persona and risk profile.
- Remove channel-impossible behaviors unless a tool or backend contract makes them real.
- Prefer deterministic Vapi configuration over prompt instructions when reliability or security matters.
在返回最终提示词前,执行语音Agent校验:
- 保持来电者可见的话轮简短,通常为1-2句话。
- 一次只问一个问题。
- 在Agent响应中避免使用编号列表、项目符号、markdown及视觉格式。
- 将日期、电话号码、货币、时间及URL转换为适合口语表达的形式。
- 将 prose 中的工具ID、资源别名、蛇形命名标识符及占位符名称替换为自然的能力描述。
- 添加针对打断、沉默、输入不清及工具故障的明确规则。
- 区分轻松闲聊与严重偏离主题的请求。
- 根据用例调整拟人化控制:所有生产级Agent都需要自然的语速、纠错能力及亲和力;仅当符合人设及风险概况时,才加入语误、闲聊或个人 rapport。
- 删除渠道无法实现的行为,除非工具或后端协议使其可行。
- 当涉及可靠性或安全性时,优先使用确定性Vapi配置而非提示词指令。
Tool and Configuration Notes
工具与配置说明
When tools are involved, review both prompt instructions and tool configuration. Flag items that should be configured outside the system prompt:
- Tool descriptions should say when to call, when not to call, and required parameter formats.
- Prompt prose should describe tools by capability. Exact tool names belong only in tool-call examples, schemas, configuration notes, or Query Tool instructions where Vapi needs the system prompt to name the search tool.
- Do not invent deployable tool schemas, structured output schemas, enum values, server URLs, or handoff destinations. Ask for them or mark them as configuration needed.
- Transfer and end-call tools need explicit descriptions.
- Slow tools should use request-start messages to fill dead air.
- Pronunciation issues should use pronunciation dictionaries when available.
- Values that must be secure, verified, or impossible for the LLM to fake should use Vapi's server-side/static-parameter patterns, not prompt text or LLM-filled schemas.
- Tool responses should be short, structured, and limited to fields the model needs.
当涉及工具时,同时审查提示词指令与工具配置。标记应在系统提示词外配置的项:
- 工具描述应说明调用时机、禁用调用时机及必需的参数格式。
- Prompt prose应按能力描述工具。精确的工具名称仅应出现在工具调用示例、schema、配置说明或Query Tool指令中(此时Vapi需要系统提示词指定搜索工具)。
- 请勿发明可部署的工具schema、结构化输出schema、枚举值、服务器URL或转接目标。如需这些信息,请询问用户或标记为“需配置”。
- 转接及结束通话工具需要明确的描述。
- 慢速工具应使用请求启动消息填充等待间隙。
- 发音问题应在可用时使用发音词典解决。
- 必须安全、已验证或LLM无法伪造的值应使用Vapi的服务器端/静态参数模式,而非提示词文本或LLM填充的schema。
- 工具响应应简短、结构化,并限制为模型所需的字段。
Output Modes
输出模式
For a new prompt, return:
- Brief assumptions, if any
- Final Vapi system prompt, or Squad prompt set when using a Squad
- Suggested Vapi configuration notes, if relevant
- Configuration needed or blocking questions, if deployment-critical details are missing
- External test scenarios, separate from the prompt
For an improved prompt, return:
- Final revised prompt, or revised Squad prompt set when using a Squad
- Important changes made
- Remaining questions or risks
- Configuration needed or blocking questions, if deployment-critical details are missing
- External test scenarios, separate from the prompt
For an audit, return:
- Findings ordered by severity
- Missing or weak prompt sections
- Vapi configuration concerns
- Concrete rewrite recommendations
Read before finalizing an audit or substantial rewrite.
references/review-checklist.md对于新提示词,返回:
- 简短的假设(如有)
- 最终Vapi系统提示词,或使用Squad模式时的Squad提示词集
- 建议的Vapi配置说明(如相关)
- 需配置项或阻塞性问题(如缺少部署关键细节)
- 外部测试场景(与提示词分开)
对于优化后的提示词,返回:
- 最终修订后的提示词,或使用Squad模式时的修订后Squad提示词集
- 已做出的重要修改
- 剩余问题或风险
- 需配置项或阻塞性问题(如缺少部署关键细节)
- 外部测试场景(与提示词分开)
对于审核结果,返回:
- 按严重性排序的发现
- 缺失或薄弱的提示词模块
- Vapi配置问题
- 具体的重写建议
在完成审核或大幅重写前,请阅读。
references/review-checklist.md