Documentation

    Agent Prompt

    The agent prompt displays contextual information to the presenter during a session. Use it to create dynamic sales scripts that update in real time based on what's being shown, customer profile data, or any other information available on the page.

    Setting the Agent Prompt

    Use updateConnection to set information that will be shown to the presenter:

    Upscope("updateConnection", {
      agentPrompt: "## Product Overview\n\nKey talking points:\n- **30% faster** than competitors\n- Integrates with existing tools\n- No setup fees"
    });
    

    The prompt supports markdown formatting.

    Dynamic Updates

    Update the prompt as you navigate through your presentation:

    // On the pricing page
    Upscope("updateConnection", {
      agentPrompt: "## Pricing Discussion\n\n- Mention the **annual discount**\n- Enterprise plan includes dedicated support\n- Offer a trial extension if hesitant"
    });
    
    // On the demo page
    Upscope("updateConnection", {
      agentPrompt: "## Live Demo\n\n1. Show the dashboard first\n2. Highlight the **reporting feature**\n3. Ask about their current workflow"
    });
    

    Personalizing with Customer Data

    Pull in any data available on the page to personalize the prompt in real time:

    Upscope("updateConnection", {
      agentPrompt: `## ${customer.name} - ${customer.company}\n\n` +
        `Plan: **${customer.plan}**\n` +
        `Usage: ${customer.usage}%\n\n` +
        `Suggested upsell: ${customer.usage > 80 ? "Enterprise plan" : "Additional seats"}`
    });
    

    Clearing the Prompt

    Set to null to clear the agent prompt:

    Upscope("updateConnection", {
      agentPrompt: null
    });