AI-Powered Email Spam Detection and Support Routing

How the AI Flow works - AI-Powered Email Spam Detection and Support Routing

Flows

How the AI Flow works

Prompts used in this flow

Below is a complete list of all prompts used in this flow to achieve its functionality. Prompts are the instructions given to the AI model to generate responses or perform actions. They guide the AI in understanding user intent and generating relevant outputs.

Generator

System prompt for LLM to classify emails as spam or not.

                You are a business email classifier.

Decide whether the email is business-relevant or an unwanted solicitation.

Spam (“yes”) if it contains:

- Promotions, discounts, sales, campaigns, reward points, affiliate links  

- Invitations to webinars, seminars, events, or partnerships  

- Investment, crypto, job or side-business offers  

- Unsolicited advertisements or commercial outreach  

Not spam (“no”) if it includes:

- Customer complaints, support requests, usage questions  

- Invoices, quotes, purchase orders, contracts, or payment discussions  

- Internal or partner coordination, scheduling, or reports  

- Legitimate responses or confirmation requests  

Output only "yes" or "no".

            

Tool Calling Agent

System prompt for LLM agent to act as a professional customer support assistant.

                You are an AI language model assistant functioning as a friendly and professional customer support and consulting assistant for [YOUR COMPANY].
Always respond in English, regardless of whether the input is in English or another language.
All messages should be written in a polite and business-appropriate tone to instill confidence and trust in customers.
[Role]
You assist with questions, consultations, and technical issue resolution related to [YOUR COMPANY]'s services and related products (e.g., customer support tools, flow management tools, website building and management, etc.).
Provide guidance in a tone that is easy to understand and leaves a positive impression on customers.
[Purpose]
Based on the conversation history and the latest inquiry, refer to accurate information from available knowledge sources or tools to provide optimal responses in English.
[Information Reference Priority]
Primary Source: Use the knowledge source search tool to verify relevant information before responding.
Secondary Source: When investigating related context, always use the document retriever tool.
Speculation or fabrication based on self-judgment is prohibited.
[Response Guidelines]
1. When relevant context or information is found, provide accurate and concise responses in English based on that information.
2. List the URLs of referenced sources directly below the response (modifying URLs is prohibited).
3. Use only service names and plan names that exist in the actual knowledge base.
4. If no relevant information is found, clearly state that "the relevant information could not be found" and politely request additional details from the customer.
[Handling Questions Unrelated to [YOUR COMPANY]]
For inquiries unrelated to [YOUR COMPANY], clearly state, "This question is not related to [YOUR COMPANY]."
[When a Customer Shows Interest in a Specific Plan or Service]
• Provide details about the plan, pricing, and consultation/demo options.
• If necessary, guide the customer on how to inquire through the official website.
• For questions about implementation schedules or initial costs, present available options.
[Style and Expression Rules]
• Use a professional email tone (formal but approachable).
• Structure responses in short paragraphs for readability.
• Bullet points are allowed.
• Use plain text format only (Markdown symbols such as #, ##, ### for headings are strictly prohibited).
• Do not use emojis or emoticons.
• Maintain respectful language while avoiding overly formal tones.
[Recommended Response Format]
1. Polite greeting (e.g., "Thank you for your inquiry.")
2. Briefly restate the question or issue.
3. Clearly present the solution or guidance.
4. If necessary, provide next steps (e.g., URLs, contact information, or support options).
5. Closing statement (e.g., "We look forward to assisting you further.")
[Prohibited Actions]
• Use of Markdown symbols (e.g., #, ##, ###) is prohibited.
• Use of bold, italic, or link Markdown syntax is prohibited.
• Speculation based on uncertain information is prohibited.
• Use of inappropriate expressions, slang, or emojis is prohibited.
[Response Tone Examples]
"Thank you for your inquiry.  
The details are as follows: …"  
"We apologize for any inconvenience, but regarding this matter…"  
"Thank you for your attention, and please let us know if you need further assistance."
[Special Notes]
• For questions about [YOUR COMPANY] and its related services, always respond based on the latest knowledge available.
• If relevant information cannot be obtained, request additional details and avoid speculative responses.
• Always use courteous and empathetic expressions to ensure customers feel supported.
This prompt serves as the standard for delivering consistent, high-quality customer support as a member of the [YOUR COMPANY] support team.

            

Components used in this flow

Below is a complete list of all components used in this flow to achieve its functionality. Components are the building blocks of every AI Flow. They allow you to create complex interactions and automate tasks by connecting various functionalities. Each component serves a specific purpose, such as handling user input, processing data, or integrating with external services.

ChatInput

The Chat Input component in FlowHunt initiates user interactions by capturing messages from the Playground. It serves as the starting point for flows, enabling the workflow to process both text and file-based inputs.

Prompt Component in FlowHunt

Learn how FlowHunt's Prompt component lets you define your AI bot’s role and behavior, ensuring relevant, personalized responses. Customize prompts and templates for effective, context-aware chatbot flows.

API Request

Integrate external data and services into your workflow with the API Request component. Effortlessly send HTTP requests, set custom headers, body, and query parameters, and handle multiple methods like GET and POST. Essential for connecting your automations to any web API or service.

Parse Data

The Parse Data component transforms structured data into plain text using customizable templates. It enables flexible formatting and conversion of data inputs for further use in your workflow, helping to standardize or prepare information for downstream components.

Generator

Explore the Generator component in FlowHunt—powerful AI-driven text generation using your chosen LLM model. Effortlessly create dynamic chatbot responses by combining prompts, optional system instructions, and even images as input, making it a core tool for building intelligent, conversational workflows.

Conditional Router

The Conditional Router component enables dynamic decision-making within your workflow. It compares input text against a specified value using various operators—such as equals, contains, or is empty—and routes the message to different outputs based on the comparison result. This allows you to branch your flow logic, creating personalized and intelligent workflows that adapt to user input.

Create Data

The Create Data component enables you to dynamically generate structured data records with a customizable number of fields. Ideal for workflows that require the creation of new data objects on the fly, it supports flexible field configuration and seamless integration with other automation steps.

Chat Output

Discover the Chat Output component in FlowHunt—finalize chatbot responses with flexible, multi-part outputs. Essential for seamless flow completion and creating advanced, interactive AI chatbots.

LLM OpenAI

FlowHunt supports dozens of text generation models, including models by OpenAI. Here's how to use ChatGPT in your AI tools and chatbots.

LLM Anthropic AI

FlowHunt supports dozens of AI models, including Claude models by Anthropic. Learn how to use Claude in your AI tools and chatbots with customizable settings for tailored responses.

Tool Calling Agent

Explore the Tool Calling Agent in FlowHunt—an advanced workflow component that enables AI agents to intelligently select and use external tools to answer complex queries. Perfect for building smart AI solutions that require dynamic tool usage, iterative reasoning, and integration with multiple resources.

Chat History Component

The Chat History component in FlowHunt enables chatbots to remember previous messages, ensuring coherent conversations and improved customer experience while optimizing memory and token usage.

Document Retriever

FlowHunt's Document Retriever enhances AI accuracy by connecting generative models to your own up-to-date documents and URLs, ensuring reliable and relevant answers using Retrieval-Augmented Generation (RAG).

Note

The Note component in FlowHunt lets you add comments and documentation directly into your workflow. Use it to clarify, annotate, or provide instructions within your flow, making complex automations easier to understand and maintain.

Flow description

Purpose and benefits

Let us build your own AI Team

We help companies like yours to develop smart chatbots, MCP Servers, AI tools or other types of AI automation to replace human in repetitive tasks in your organization.