feat: add campaign context to Captain v2 prompts (#13644)
Co-authored-by: Aakash Bakhle <48802744+aakashb95@users.noreply.github.com>
This commit is contained in:
@@ -8,7 +8,7 @@ You are {{name}}, a helpful and knowledgeable assistant. Your role is to primari
|
||||
|
||||
Don't digress away from your instructions, and use all the available tools at your disposal for solving customer issues. If you are to state something factual about {{product_name}} ensure you source that information from the FAQs only. Use the `captain--tools--faq_lookup` tool for this.
|
||||
|
||||
{% if conversation || contact -%}
|
||||
{% if conversation || contact || campaign.id -%}
|
||||
# Current Context
|
||||
|
||||
Here's the metadata we have about the current conversation and the contact associated with it:
|
||||
@@ -20,6 +20,10 @@ Here's the metadata we have about the current conversation and the contact assoc
|
||||
{% if contact -%}
|
||||
{% render 'contact' %}
|
||||
{% endif -%}
|
||||
|
||||
{% if campaign.id -%}
|
||||
{% render 'campaign' %}
|
||||
{% endif -%}
|
||||
{% endif -%}
|
||||
|
||||
{% if response_guidelines.size > 0 -%}
|
||||
|
||||
@@ -8,7 +8,7 @@ You are a specialized agent called "{{ title }}", your task is to handle the fol
|
||||
|
||||
If you believe the user's request is not within the scope of your role, you can assign this conversation back to the orchestrator agent using the `handoff_to_{{ assistant_name }}` tool
|
||||
|
||||
{% if conversation || contact %}
|
||||
{% if conversation || contact || campaign.id %}
|
||||
# Current Context
|
||||
|
||||
Here's the metadata we have about the current conversation and the contact associated with it:
|
||||
@@ -20,6 +20,10 @@ Here's the metadata we have about the current conversation and the contact assoc
|
||||
{% if contact -%}
|
||||
{% render 'contact' %}
|
||||
{% endif -%}
|
||||
|
||||
{% if campaign.id -%}
|
||||
{% render 'campaign' %}
|
||||
{% endif -%}
|
||||
{% endif -%}
|
||||
|
||||
|
||||
|
||||
8
enterprise/lib/captain/prompts/snippets/campaign.liquid
Normal file
8
enterprise/lib/captain/prompts/snippets/campaign.liquid
Normal file
@@ -0,0 +1,8 @@
|
||||
# Campaign Context
|
||||
This conversation was initiated in response to a campaign message.
|
||||
- Campaign: {{ campaign.title }}
|
||||
- Type: {{ campaign.campaign_type }}
|
||||
{% if campaign.description -%}
|
||||
- Description: {{ campaign.description }}
|
||||
{% endif -%}
|
||||
- Original Message Sent: {{ campaign.message }}
|
||||
Reference in New Issue
Block a user