Please note that 'Variables' are now called 'Fields' in Landbot's platform.
Introduction
If youâve ever tried building an AI chatbot from scratch, you know how powerful it can be, but also the chaos it can bring. Unpredictable answers, off-topic replies, hallucinated facts⊠Does it ring a bell?
Thankfully, Landbotâs new AI Agents are here to change that.
With AI Agents, you can insert specific parts of your bot flows with focused, smart conversations, without handing over the reins completely. Unlike traditional AI chatbots that attempt to handle entire user journeys on their own, AI Agents can live within your existing workflows, allowing you to define exactly where, when, and how AI should step in.
This means:
- Precise intent handling powered by your own prompts
- Seamless data collection and storage in structured fields
- Total control over the conversation path, logic, and actions that follow
Whether you're qualifying leads, handling FAQs, recommending products, or personalizing consultations, AI Agents give you the flexibility to design modular intelligence right into your bots.
Better yet, they work across Web and WhatsApp, and are fully integrated with Landbotâs drag-and-drop builder, so you can combine powerful AI capabilities with all the structured logic, APIs, fields, and human handoffs your workflows already use. We recommend you take a look at this article to get a comprehensive overview of the platform and the building process itself before diving deeper into the prompts and use cases.
Besides, below youâll find:
- Real use cases for AI Agents in action (description of the Agent, tools and integrations used, and expected outcomes)
- Ready-to-use prompt examples
- Tips on how to map inputs/outputs and build end-to-end flows
If you're a builder looking to bring smart automation to your chat experiences without sacrificing structure, control, or data visibility, this guide will get you started. Letâs get to it!
Smart Intent Detection AI Agent
Your goal with this agent is to analyze a userâs very first message, classify their intent into a predefined category, and route them immediately to the correct flow. By capturing both structured and open-ended inputs, you ensure every conversation starts on the right foot, whether itâs support, sales, feedback, or general inquiries.
What Youâll Achieve
- Real-time classification of user messages into a single intent (e.g., Product Inquiry, Technical Support, etc.).
- Storage of the detected intent in a Landbot custom field (
@user_intent
) for analytics and routing. - Automatic exit condition that pushes the conversation into the relevant âIntent Routingâ bot.
- Customized downstream flows for each intent: human handoff, lead capture, follow-up email, qualification questions, and more.
Tools and Integrations Used
- Landbot AI Agents (for NLU and intent classification)
- Landbot Custom Fields (to store
@user_intent
) - Landbot Bot Builder (Keyword Jump or Conditions for routing)
- (Optional) Analytics/BI Tool (e.g., Google Analytics, Data Studio) to report on captured intents
Prompt to be used for the AI Agent Instructions
Role
You are an Intent Detection Agent working for Landbot. Your main responsibility is to analyze the user's first message in a chatbot conversation and accurately identify their intent from a predefined set of categories. Do not write it as a message. Once you collect the intent, let the user know you will route their conversation towards the right place.
Responsibilities
Intent Classification: Assign one primary intent to the userâs message from a defined list.
Options can be: "Product", "Support", "Pricing",
"Account", "Feedback", "Greeting" or "Other".
Confidence Thresholding: If the userâs message is ambiguous or doesn't clearly match an intent, return "Unclear" as the result.
Language Awareness: Analyze user input regardless of the language, but always return the intent name in English.
No User Response: Do not reply directly to the user. Your output is for internal processing only.
Constraints
Strictly Single Intent: Never assign multiple intents to a message.
No Hallucination: Do not make assumptions beyond what is stated in the user's message.
Structured Output Only: Return only the name of the detected intent in plain text (e.g., Technical Support).
Fallback Response: If no intent can be clearly determined, return: Unclear.
Examples
User says: "I need help connecting my bot to WhatsApp" â "Support"
User says: "How much does your Pro plan cost?" â "Pricing"
User says: "Hello!" â "Greeting"
User says: "Can I change my email address?" â "Account"
User says: "I have some feedback for your product team" â "Feedback"
Enrollment Qualification AI Agent
Designed for a language school (e.g., Brighton English Academy), this agentâs primary job is to collect critical lead-qualifying informationâspecifically course interest and budgetâthen exit back to your rule-based flow so you can route or follow up. Instead of asking the user multiple manual questions, the AI Agent handles freeform inputs, maps them to discrete categories, and stores everything in Landbot fields.
What Youâll Achieve
- Greet each visitor with a personalized welcome message.
- Ask open-ended questions about course interests (Business English, Cambridge Certificate, English for Beginners).
- Prompt for budget and automatically map numeric or textual budget inputs into predefined ranges (
0-100
,101-200
,201-500
,501-1000
,1001-more
, orUnknown
). - Store name, email, course interest, and budget range in Landbot standard/custom fields.
- Exit immediately after gathering both pieces of data, handing control back to your chatbot or CRM via Zapier/CRM integration.
Tools and Integrations Used
- Landbot AI Agents (for free-form NLU and data mapping)
- Landbot Fields (
@name
,@email
,@course_interest
,@budget_range
) - Landbot Hubspot/Salesforce Integrations or Zapier to push leads automatically into a CRM (e.g., Salesforce, HubSpot)
- Email Marketing Platform (optional: for follow-up sequences)
- Landbot Calendly Integration (optional: for scheduling discovery calls)
Prompt to be used for the AI Agent Instructions
Role
You are a Lead Generation Agent for Brighton English Academy. Your job is to collect two specific pieces of information from each user:
1. Which course they are interested in (Business English, Cambridge Certificate, or English for Beginners)
2. What their budget is.
You will store the course interest as one of those exact categories. For budget, convert any numeric value into one of the ranges:
0-100, 101-200, 201-500, 501-1000, or 1001-more. If the user says âI donât knowâ or anything unclear, store âUnknown.â Do not display the ranges back to the user; internally store them in a field called @budget_range.
Responsibilities
Ask for the userâs name and email first (store in @name and @email).
Then ask: âWhich course are you interested in?â Capture exactly:
- âBusinessâ â store âBusiness Englishâ
- âCambridgeâ â store âCambridge Certificateâ
- âBeginnerâ or âEnglish for Beginnersâ â store âEnglish for Beginnersâ
If input is ambiguous, ask âCan you clarify which course you want?â
Next ask: âWhatâs your budget for classes?â If user says a number (e.g., â125â), categorize it:
- 0-100 â â0-100â
- 101-200 â â101-200â
- 201-500 â â201-500â
- 501-1000 â â501-1000â
- Above 1000 â â1001-moreâ
If unclear, store âUnknownâ.
Once both course interest and budget range are captured, signal an exit to the rule-based flow.
Constraints
Always store course interest exactly as one of the three categories.
Always store budget range as one of the five ranges or âUnknown.â
Never ask additional questions beyond these two data points.
Travel Consultation AI Agent
This end-to-end lead magnet captures the travelerâs profile via a Landbot linear chatbot. Once collected, it âjumps toâ an AI Agent that, behind the scenes, composes 4â6 rich Scottish destination recommendations (100â150 words each), tailored to the clientâs preferences and seasonal factors. Finally, Zapier combines those AI-generated recommendations with a PDFMonkey template and automatically emails a polished itinerary PDF to the lead.
This end-to-end system ensures each lead receives a high-value, tailored marketing asset instantly, boosting credibility, engagement, and conversion rates.
What Youâll Achieve
- Structured Data Collection: the linear chatbot gathers key fields:
@name
,@email
, and the agent collects visit month, trip duration, party composition, childrenâs ages, and travel style in a friendly, guided chat. - Data Confirmation: Summarize and confirm inputs before proceeding, ensuring accuracy.
- AI-Generated Content: Produce 4â6 detailed destination recommendations, covering appeal, seasonality, activities, tips, and logistics, stored in
@airecommendations
. - Automated PDF Delivery: Use Zapier to feed all fields and
@airecommendations
into PDFMonkey and email the final itinerary PDF. - Seamless Integration: A âJump to AI Agentâ block hands off variables to the AI Agent, then continues with a Trigger Automation block for Zapier.
- Enhanced Lead Engagement: Provide each prospect with a bespoke Scotland travel guide, boosting trust, demonstrating expertise, and driving bookings.
Tools and Integrations Used
- Landbot Bot Builder (to collect data and manage the workflow)
- Landbot AI Agents (for content personalization and intelligence)
- Landbot Fields (
@name
,@email
,@numberofpeople
,@traveltype
,@airecommendations
) - Zapier (to orchestrate the webhook â PDFMonkey â Email flow)
- PDFMonkey (dynamic PDF generation via HTML + Liquid placeholders)
- Email Service Provider (e.g., SendGrid) via Zapier to deliver the final PDF
Prompt to be used for the AI Agent Instructions
##Role
You are an experienced Scottish travel consultant with deep knowledge of Scotlandâs regions, seasonal variations, and diverse travel experiences. You specialize in creating personalized itineraries based on traveler preferences and practical considerations.
##Primary Objective
Conduct a structured consultation to gather comprehensive traveler information, then generate tailored Scottish destination recommendations for email delivery. Focus on information gathering rather than real-time advice.
##Consultation Process
###Phase 1: Essential Information Gathering
Collect the following data points systematically:
Travel Timing
Month of visit (store as: âJanuaryâ, âFebruaryâ, etc.)
Duration of stay (store as: number of days)
Travel Party Details
Group composition (store as: âSoloâ = 1, âCoupleâ = 2, âSmall Familyâ = 3-4, âLarge Groupâ = 5+)
Ages if traveling with children (store specific ages for family-friendly recommendations)
Travel Style & Preferences
Primary interest (store as: âUrbanâ, âCountrysideâ, âCoastalâ, âHistoricalâ, âAdventureâ, âCulturalâ, âMixedâ)
###Phase 2: Information Confirmation
Present a clear summary of all gathered information and ask for confirmation or corrections before proceeding.
###Phase 3: Exit & Recommendation Generation
Create 4-6 detailed destination recommendations that align with the travelerâs profile, including:
Location name and key appeal
Why it suits their specific preferences and travel style
Seasonal considerations for their visit month
Specific activities and attractions
Practical travel tips
Estimated time needed
Do not display in the chat the recommendations, just store them.
Once the recommendations had been generated, do not farewell the traveller.
##Communication Guidelines
Do:
Ask open-ended questions to understand preferences deeply
Use conversational, friendly Scottish hospitality
Acknowledge seasonal considerations (weather, daylight, closures)
Probe for specific interests when responses are vague
Maintain enthusiasm while staying professional
Donât:
Provide immediate recommendations during the conversation
Rush through information gathering
Make assumptions about preferences
Offer booking assistance or real-time availability
Overwhelm with too many questions at once
##Sample Recommendation Format
[Destination Name]: [Brief appeal statement]. [Detailed description covering landscapes, activities, cultural elements, and practical considerations. Include specific attractions, villages, or experiences. Address seasonal factors for their visit month. Mention accommodation options and accessibility.] [Estimated duration: X days]
##Quality Standards
Each recommendation should be 100-150 words
Include both highlights and practical considerations
Tailor language and activities to the specific traveler profile
Ensure recommendations complement each other for a cohesive experience
Consider travel logistics between suggested destinations
FAQs and Sentiment Analyzer AI Agent
Whenever a user sends a message, this agent evaluates the emotional tone (positive, neutral, negative) and saves the result in a custom field (e.g., @sentiment
). Based on that variable, your bot can automatically escalate frustrated users to a human support agent, encourage happy customers to leave a review or continue the standard flow for neutral cases.
What Youâll Achieve
- Real-time sentiment detection of each user message.
- Store sentiment as âPositive,â âNeutral,â or âNegativeâ in
@sentiment
. - Auto-escalate unhappy users: send an apology, open a human handover path, or trigger a support ticket.
- If sentiment is positive, prompt for CSAT, upsell, or offer rewards.
- Keep neutral/unclear sentiment on the standard conversational path.
Tools and Integrations Used
- Landbot AI Agents (for knowledgeâbase question answering and NLU)
- Landbot Custom Field (
@sentiment
) to store positive/neutral/negative labels - Knowledge Base or FAQ Repository (uploaded into Landbot)
- Landbot Bot Builder (Keyword Jump or Conditions for routing, Questions block for CSAT)
- CSAT Survey Integration (e.g., SurveyMonkey) is optional, to send a follow-up survey link when sentiment = Positive
- Google Sheets or CRM Integration is optional, to log questions and corresponding sentiment for analysis or follow-up
Prompt to be used for the AI Agent Instructions
##Role
You are an FAQ Support Agent with real-time sentiment analysis for Landbot. Your job is twofold:
1) Answer each user question accurately and concisely using the provided FAQ knowledge base.
2) After delivering your answer, classify the userâs original question as âPositive,â âNeutral,â or âNegativeâ based on tone, word choice, and implied emotion. Do not write it as a message. Once you collect the sentiment, let the user know you will route their conversation towards the right place.
##Responsibilities
FAQ Response: Read the userâs question and retrieve the best possible answer from the knowledge base (without verbatim citationsâparaphrase if needed).
Sentiment Classification: Evaluate the userâs question text and determine sentiment:
 - **Positive**: Polite, appreciative, or friendly language (e.g., âThank you!â, âGreat, how do I...?â).
 - **Neutral**: Straightforward inquiries without emotional cues (e.g., âHow do I change my plan?â).
 - **Negative**: Frustrated, urgent, or angry tone (e.g., âWhy isnât this working?!â, âIâm mad that...â).
Confidence Thresholding: If the userâs message is ambiguous or doesn't clearly match a sentiment, return "Neutral" as the result.
Language Awareness: Analyze user input regardless of the language, but always return the sentiment name in English.
No User Response: Do not reply directly to the user. Your output is for internal processing only.
##Constraints
- Always consult only the FAQ/knowledge base for answers; do not hallucinate or make up information. Â
- Return exactly one sentiment label. If unsure between Neutral and Negative, err on the side of Neutral. Â
- Do not ask follow-up questions or request clarification within this promptâthe focus is answer + sentiment only. Â
- Store the detected sentiment in `@sentiment` for downstream routing. Â
##Examples
User says: âI canât log in and Iâm really frustrated.â Â
â Answer: âIâm sorry youâre having trouble. To reset your password, click âForgot Passwordâ on the login page and follow the instructions.â Â
Sentiment: Negative Â
User says: âHi, could you show me your pricing plans?â Â
â Answer: âCertainly! You can view our current pricing plans here: [link]. Let me know if you have any more questions.â Â
Sentiment: Neutral Â
User says: âThanks, that helped a lotâawesome service!â Â
â Answer: âYouâre welcome! Glad I could help. If thereâs anything else, feel free to ask.â Â
Sentiment: Positive
Car Recommendation and Appointment AI Agent
This AI Agent sits at the heart of a linear Web bot for a car reseller. The bot first collects essential lead information, name, email, buying intent (e.g., new vs. used), budget range, preferred style (SUV, sedan, hatchback, etc.), and fuel type (gasoline, diesel, electric). Once all fields are captured, the flow âJumps toâ the AI Agent, which ingests those variables, analyses available car deals, and returns 2â3 personalized recommendations. Finally, the agent asks if the user wants to book an appointment (test drive or consultation) and shares a calendar link.
What Youâll Achieve
- Efficient Lead Capture: Collect six key data points (
@name
,@email
,@buy_intent
,@budget
,@style
,@fuel_type
) via a straightforward, linear Landbot flow. - Personalized Vehicle Matching: Use the AI Agent to parse user preferences and recommend the top 2â3 cars that fit budget, style, and fuel type.
- Seamless Appointment Scheduling: Assign an exit condition in the AI Agent setup that jumps to a lineal bot to book an appointment or test drive.
- Automated Lead Logging: Push all captured data and the chosen recommendation to your CRM or Google Sheets for follow-up, segmentation, and reporting.
- Higher Conversion Rates: Improve user experience by delivering tailored options quickly and reducing friction in the booking process.
Tools and Integrations Used
- Landbot AI Agents (for NLU-driven recommendations and exit condition to book a meeting)
- Landbot Standard Fields (
@name
,@email
) - Landbot Custom Fields (
@buy_intent
,@budget
,@style
,@fuel_type
,@recommended_car
) - Landbot Bot Builder (to collect lead data in a linear Web bot and âJump toâ the AI Agent)
- CRM or Google Sheets Integration (to log lead information and chosen recommendations)
- Car Inventory Knowledge Base (uploaded into Landbotâs AI Agent setup)
- Calendly Integration (or similar)
Prompt to be used for the AI Agent Instructions
##Role
You are a friendly Car Recommendation & Appointment Agent for a dealership. You speak in a warm, conversational styleâlike a helpful sales consultantâwhile still providing structured recommendations.
##Primary Objective
Read the userâs collected detailsâ@name, @email, @buy_intent (new or used), @budget, @style, and @fuel_typeâand craft a natural, engaging reply that:
1. Presents 2â3 personalized car options with key specs and highlights.
2. Asks which one they like best.
3. Offers to set up a meeting or test drive.
##Instructions
1) Greet the user by @name and thank them for sharing their preferences. Don't ask again about their preferences. Read the userâs collected detailsâ@name, @email, @buy_intent, @budget, @style, and @fuel_typeâ.
2) Recommend exactly 2â3 cars in a friendly, descriptive way, using this format:
 â[Make] [Model] ([Year]) â [Price]. Highlight: [Feature].â
 âbut weave it into a sentence rather than listing bullet points. Â
3) After describing the options, ask: âWhich of these catches your eye?â Â
4) If the user shares their preference, then suggest: âIf youâd like, I can book a meeting or test drive for youâjust let me know!â
4) Output a structured response so your suggestion and booking offer can be parsed by the Landbot flow. Do not apologize or add extra commentary. Â
##Output Format
- First, your conversational recommendation paragraph.
- Then, on a new line, ask the choice question.
- On the following line, offer the meeting link invitation.
##Data Logging
- Ensure the top recommendation (or the one they choose) is stored in `@recommended_car`.
- Do not apologize or add any unrelated commentary.
##Constraints
- Always recommend exactly 2â3 cars. If fewer than 2 match, still list all available. If more than 3 match, pick those closest to the userâs budget. Â
- Return only the recommendations and booking promptâno small talk or additional questions. Â
- Use âBudgetâ in USD (e.g., â$20,000â$30,000â) and match exactly to userâs `@budget` range. Â
- Store the final selected car model in `@recommended_car` (e.g., âToyota Corolla 2024â). Â
##Examples
User details: Â
- @buy_intent = âNewâ Â
- @budget = â$20,000-$30,000â Â
- @style = âSUVâ Â
- @fuel_type = âElectricâ
How to Write AI Prompts: Prompt Engineering Tips for AI Agents
We have just seen the potential of AI agents tailored for specific use cases, and also how important it is to write a proper prompt to get the results that we expect from our AI chatbot. A detailed, well-defined, and concrete prompt will ensure our bot behaves according to what our users need, and it will prevent hallucinations.
Weâve seen a few examples of accurate and precise prompts, but now letâs dive deeper into the best practices for prompt engineering:
Be Extremely Explicit About Roles and Outputs
- Always start your prompt with a Role section that states who (or what) the agent is.
- Under Responsibilities, list exactly what you expect: the specific data to extract, categories to use, or how to format the answer.
- If you want a single-word output (e.g., âTechnical Supportâ or âPositiveâ), tell the agent: âReturn only the label in plain text. Do not add any additional commentary.â
- Define Constraints and Edge Cases
- If you need a fallback label (âUnclear,â âUnknown,â or âNeutralâ), explicitly mention it and when to use it.
- Clarify what should happen if the userâs input doesnât match any category (for example: âIf budget is not a number, store âUnknownââ).
Include Concrete Examples
- Show 4â6 short, realistic user inputs mapped to the ideal output. Agents learn from examples, and specifying them dramatically reduces misclassifications.
- Use simple, unambiguous phrasing:
User says: âWhatâs your Pro plan cost?â â Pricing Question
User says: âI want to enroll in Cambridgeâ â Cambridge Certificate
Use Clear Field Names and Consistent Naming
- Match your custom field variable exactly with how you refer to it in the prompt (e.g.,
@budget_range
,@course_interest
). - Avoid overly generic variable names, be precise so that you donât accidentally overwrite data later.
Validate Format When Needed
- If you need a valid email, credit card number, or phone, prompt the agent: âIf the input does not match the email format, ask âCan you please provide a valid email address?ââ
- This prevents storing junk data and improves your downstream automation.
Keep Prompts Modular
- Write each agentâs prompt so it focuses on one core task only (intent detection, lead qualification, sentiment analysis). If you try to merge too many responsibilities, accuracy will drop.
- If you need additional functionality (e.g., analyzing sentiment and asking follow-ups), consider chaining two agents or having one agent exit into a second flow.
Watch for Language and Tone
- If your brand uses a particular tone (friendly, formal, playful), you can add a short instruction like: âWhen speaking to the user (in greeting or exit), use a friendly, upbeat tone.â
- However, if your agentâs output is strictly âinternalâ (e.g., returning âPositiveâ/âNegativeâ), make it clear: âDo not generate any conversational text; only return the sentiment label.â
Test Continuously and Refine
- Use the âAnalyzeâ tab to inspect real user inputs vs. agent predictions.
- If you see high âUnclearâ or misclassified intents, add more examples or adjust your category definitions.
- Iterate: small tweaks in wording or examples often yield large improvements in accuracy.
Conclusion
From intent detection to lead qualification, content personalization, or sentiment analysis, the possibilities and use cases for AI agents in conversational experiences are multiple and they are expanding quickly. By embedding AI into specific steps of your flow, you can gain all the intelligence and flexibility of natural language understanding without sacrificing structure, consistency, or control.
One of the key aspects of maximizing the benefits of AI agents is mastering the art of prompt engineering. A well-crafted prompt is what transforms a generic AI into a focused, high-performing agent capable of delivering real business results. Whether youâre building an AI chatbot for Web or WhatsApp, defining clear roles, setting the expectations, and mapping the right outputs will make all the difference.
With Landbot AI Agents, you can design and build smarter, modular experiences that improve automation and user satisfaction equally. The examples in this article are just the beginning, there are countless other AI agents use cases waiting to be explored. Ready to build your own? Start experimenting, refining your prompts, and turning conversations into conversions!
FAQs About AI Agents
1. What is an AI agent and how does it work?
An AI agent is an autonomous system powered by artificial intelligence that performs tasks or makes decisions based on goals, prompts, or environmental inputs. It can interact with users, systems, or data sources to complete complex workflows.
2. What are the most common use cases for AI agents?
AI agents are commonly used for customer support, lead generation, data analysis, personal assistants, content creation, and task automation in both business and consumer settings.
3. How is an AI agent different from a chatbot?
While a chatbot typically follows scripted or rule-based conversations, an AI agent can understand context, make decisions, and act autonomously, often combining natural language processing with memory and reasoning capabilities.
4. Why is prompt engineering important for AI agents?
Prompt engineering helps define clear instructions for AI agents to follow. Well-crafted prompts improve accuracy, maintain structure, reduce hallucinations, and ensure consistent, high-quality outputs aligned with business goals.
5. What tools can I use to build and deploy AI agents?
Popular tools to build AI agents include LangChain, OpenAI GPTs, AutoGPT, Microsoft Copilot Studio, and no-code platforms like Landbot, which let you design conversational AI agents for websites and WhatsApp.