Estimated Read Time: 8 minutes
Overview
When you build a workflow in AskElephant, your AI agent relies entirely on the information you give it. A well-written prompt is the foundation of a workflow that actually works. This guide walks you through the key principles of prompt writing so your AI agent delivers the results you need.
Key Terms
Prompt: The instructions you give your AI agent.
Context: The background information and data your AI agent needs to complete the task.
Variables: Placeholders in your workflow that pull in real data—like a customer name, email, or information from a previous step.
Output: The final result your AI agent produces based on your prompt and the information provided.
The Three C's of Prompt Writing
Every effective prompt follows three core principles. Master these, and your workflows will perform significantly better.
Clear
Your AI agent can only work with what you explicitly tell it. Vague instructions lead to vague results.
What this means:
- Use proper formatting, punctuation, and complete sentences
- Avoid assuming the AI knows what you mean by industry jargon—explain it
- Be specific about what you want, not general
Example of unclear: "Tell me about our sales."
Example of clear: "Summarize the top three deals closed by our sales team in the last 30 days, including customer name, deal value, and close date."
Concise
Include only the information your AI agent needs to complete the task. Unnecessary details can confuse the outcome.
What this means:
- Stay on topic
- Remove irrelevant details, even if they seem related
- Focus on information that directly drives the result you want
Example of too much information: "Jim closed a deal with a company in New Jersey. They needed forklifts for their warehouse. The forklift cost $15,000 and could do 360-degree turns. This impacted our pricing, so we lowered the deal from $45,000 to $30,000. How can we onboard this customer better?"
Better approach: "We just onboarded a customer in New Jersey after closing a $30,000 deal. What are the top three onboarding best practices for this customer profile?"
Consistent
When you mention something in your prompt, refer to it the same way every time. Inconsistent language confuses your AI agent.
What this means:
- Don't use multiple terms for the same thing
- If you define a metric or category, use that exact definition throughout
- Keep your language and terminology steady within the prompt
Example of inconsistent: "Identify the top 10–15% of prospects most likely to buy…. ….remember to filter for the top 10–20% of people who might purchase…. ….Finally, show me the top 25–30% of customers interested…"
Better approach: "Identify the top 15% of prospects most likely to buy based on engagement level and company size."
Structural Best Practices
Beyond the Three C's, structure matters. Here's how to organize your prompts for maximum clarity.
Assign Your AI Agent a Role
Give your AI agent a specific identity or expertise level. This helps it tailor its response to match your needs.
Example: "You are a customer success manager with 10+ years of experience onboarding enterprise clients. Your goal is to create a smooth transition for new customers."
Use Headers to Organize Information
Break your prompt into clear sections so your AI agent understands what information serves which purpose.
Recommended sections:
- Role: The expertise or perspective you want
- Instructions: What you want the AI agent to do
- Context: Background information relevant to the task
- Output Format: Exactly how you want the results structured
- Business Importance: Why this matters and what's at stake
Example structure:
**Role:**
You are a sales analyst...
**Instructions:**
Review the following customer feedback and...
**Context:**
[Customer data]
**Output Format:**
Provide a bulleted list with three sections...
**Business Importance:**
Accurate categorization helps us prioritize follow-up calls and improve customer retention.
Provide Examples
Show your AI agent exactly what good output looks like. This is one of the most powerful techniques for consistent, high-quality results.
How to do this:
- Create a sample output in the exact format you want
- Include it in your prompt under a section like "Example Output"
- Make the example realistic and representative
Why it works: Your AI agent uses the example as a template. If you reuse the prompt, you'll get consistent formatting and structure every time.
Explain Business Importance
Tell your AI agent why this task matters. Include what happens if the output is wrong or incomplete.
Example: "This analysis is critical because incorrect prioritization will cause us to miss high-value renewal opportunities. Failed renewals directly impact revenue and team morale."
When your AI agent understands the stakes, it performs more carefully and tailors its responses to avoid common pitfalls.
The Critical Role of Variables and Context
Here's something essential: your AI agent can only see what you put in the prompt. If you don't reference it, the AI agent won't know it exists.
Why Variables Matter in Workflows
In a workflow, information flows from step to step. When you move to a new step in your workflow, the AI agent in that step doesn't automatically know what happened in previous steps. You have to explicitly tell it.
This is where variables come in.
Variables are placeholders that pull real data into your prompt. They might be:
- Customer information (name, email, company)
- Outputs from previous workflow steps
- Data from your CRM or other tools
- User inputs
How to Use Variables for Context
Step 1: Identify what information you need
Look at your workflow. What data from earlier steps or from your system does this prompt need?
Step 2: Reference that data in your prompt using variables
When you insert a variable, you're telling your AI agent "use this specific piece of information." The variable pulls the actual data into the prompt at runtime.
Step 3: Make the variable reference clear
Don't just drop a variable into your prompt. Explain what it is so your AI agent understands its relevance.
Example of weak variable use:
Analyze {{ customer_data }}.
Example of strong variable use:
**Context:**
Customer Name: {{ customer_name }}
Company: {{ customer_company }}
Previous Interaction Summary: {{ previous_interaction_output }}
**Instructions:**
Based on this customer's background and our last conversation with them, recommend the next best action.
A Real Workflow Scenario
Imagine your workflow has two steps:
Step 1: AI agent reviews a customer conversation and identifies their pain points.
Output: A summary of pain points (stored as a variable: {{ pain_points }})
Step 2: AI agent drafts a follow-up email.
If you write Step 2's prompt without referencing the pain points, the AI agent won't know them. Your email will be generic.
Correct approach for Step 2:
**Role:**
You are a customer success representative known for personalized, empathetic outreach.
**Context:**
Customer Name: {{ customer_name }}
Identified Pain Points: {{ pain_points }}
**Instructions:**
Craft a follow-up email that directly addresses the customer's pain points and offers a specific solution.
**Output Format:**
Subject line and email body (no more than 150 words).
Now your AI agent has everything it needs to write a targeted, relevant email.
Summary
Strong prompts are built on three principles: clear, concise, and consistent. Organize your prompts with headers and assign roles. Always show examples of what good output looks like.
Most importantly, remember that your AI agent is only as smart as the context you provide. Use variables to pull in data from previous steps and existing systems. Reference everything explicitly—don't assume your AI agent will know what you're referring to.
When you take the time to write thoughtful prompts, your workflows deliver better results and work more reliably.
Next Steps
Ready to build your first workflow? Start by identifying a repetitive task that could benefit from AI assistance. Outline the Three C's in your prompt, organize it with headers, and include real examples. If your workflow has multiple steps, map out what information each step needs from the previous one—and use variables to reference it explicitly.
Have questions? Connect with the Herd in our community forum for tips and inspiration.
Need Additional Help?
If you have questions or need further assistance, the AskElephant support team is here to help!
You can reach our support team in several ways:
- click the chat button in the bottom right corner of your screen,
- email us at support@askelephant.ai
- or use @askelephant support in your dedicated Slack channel.
We're committed to getting you the answers you need as quickly as possible.
