How to Create AI Assistant
This guide walks you through the process of creating and training your AI Assistant using uploaded knowledge base files in WhatsMark SaaS.
Introduction
After configuring AI integration, you can create intelligent AI assistants that use your uploaded documents to provide contextual responses to user queries. The AI Assistant can analyze PDF, DOC, DOCX, TXT, and MD files to build a comprehensive knowledge base.
Step 1: Access AI Assistant Section
Navigate to AI Assistant Management
- Log in to your WhatsMark SaaS admin dashboard
- Go to AI Assistant in the left sidebar menu
- The list shows all your existing assistants along with today's usage stats: total replies, input tokens, and output tokens consumed by each assistant today
- Click "+ Create New Assistant" button to start creating your assistant

Step 2: Configure Assistant Basic Settings
Create New Personal Assistant Form
Fill out the assistant creation form with the following details:
Assistant Configuration Parameters
| Field | Description | Example | Required |
|---|---|---|---|
| Assistant Name | Unique identifier for your assistant | SmartFlow AI | ✅ Yes |
| Description | Brief explanation of assistant purpose | An intelligent virtual assistant designed to streamline workflows | ✅ Yes |
| System Instructions | Behavior and personality guidelines | You are SmartFlow AI, a proactive and helpful assistant... | ✅ Yes |
| Select Provider | AI provider for this assistant | OpenAI, Gemini | ✅ Yes |
| AI Model | OpenAI model selection | GPT-4o Mini, GPT-4o, GPT-4.1 | ✅ Yes |
AI Model Options
OpenAI Models
| Model | Performance | Cost | Best For |
|---|---|---|---|
| GPT-4o Mini | Fast | Low | Basic queries, quick responses |
| GPT-4o | Balanced | Medium | General purpose, most use cases |
| GPT-5.4 | Advanced | High | Complex reasoning, detailed analysis |
Gemini Models (v1.1.0+)
| Model | Performance | Cost | Best For |
|---|---|---|---|
| Gemini 2.5 Flash | Fast | Low | Quick responses, cost-effective tasks |
| Gemini 2.5 Pro | Advanced | Medium | Complex reasoning, longer context tasks |
System Instructions Template
Use this template for professional assistant behavior:
You are [Assistant Name], a proactive and helpful assistant. Always provide clear,
concise, and context-aware responses. Anticipate user needs, suggest relevant
actions, and ensure user interactions are productive and pleasant.Step 3: Build the Knowledge Base v1.1.0
Once your assistant is created, open its Knowledge tab to feed it the content it should answer from. The Knowledge tab supports four source types, so you are no longer limited to uploading files — you can also pull in entire websites, individual web pages, and manually written text.

Knowledge Source Types
| Source Type | What It Adds | Best For |
|---|---|---|
| Websites | All pages listed in a site's sitemap.xml | Ingesting an entire help center or documentation site |
| URLs | A single web page | A specific article, policy, or landing page |
| Documents | Uploaded files (PDF, DOC, DOCX, TXT, MD) | Manuals, guides, internal reports |
| Snippets | Short blocks of manually typed text | FAQs, quick facts, canned answers |
Each source you add appears in a list showing its type, title/URL, and sync status. You can open any source to review it, re-sync it, or delete it.
Source Status
As each source is processed, its status moves through these stages:
| Status | Meaning |
|---|---|
| Pending | Queued, waiting to be processed |
| Fetching | Content is being downloaded (URL/website sources) |
| Processing | Content is being indexed for AI search |
| Completed | Source is fully synced and ready to answer from |
| Failed | Something went wrong — open the source for details and re-sync |
Add a Website (Sitemap)
Use this to ingest many pages at once from a site's sitemap.xml.
- Open the Knowledge tab → Websites sub-tab
- Click Add
- Paste the full Sitemap URL (for example,
https://example.com/sitemap.xml) - Optionally set a page limit (default and maximum: 20 pages)
- Click Save

Each page found in the sitemap is fetched and indexed as its own source. Larger sites take longer to finish — monitor the status column as pages move to Completed.
TIP
Only the sitemap.xml is read — the assistant does not crawl by following links. Make sure the site exposes a valid sitemap.
Add a Single URL
Use this for one specific page.
- Open the Knowledge tab → URLs sub-tab
- Click Add
- Paste the page URL
- Click Save

The page is fetched, converted to clean text, and indexed for the assistant to answer from.
Upload Documents
The interface provides a drag-and-drop area for uploading knowledge documents:

- Drag and Drop: Drag files directly into the upload area
- Click to Upload: Click the upload area to browse and select files
- File Format Support: PDF, DOC, DOCX, TXT, MD up to 10MB each
- Multiple Files: Upload multiple documents at once
Supported File Formats
| Format | Extension | Max Size | Use Case |
|---|---|---|---|
| PDF Documents | 10MB | Manuals, guides, reports | |
| Word Documents | .doc, .docx | 10MB | Policies, procedures |
| Text Files | .txt | 10MB | FAQs, simple content |
| Markdown Files | .md | 10MB | Technical documentation |
Document Upload Process
Prepare Your Documents
- Ensure files contain relevant business information
- Remove any sensitive or confidential data
- Organize content logically with clear headings
Upload Files
- Click Upload Knowledge Documents
- Select multiple files (up to 10MB each)
- Wait for upload completion
Document Processing
- System automatically extracts text content
- Documents are indexed for vector search
- Processing status shows as "Sync Status"
Add Snippets and Articles
When you don't have a file or a URL, type the content directly.
- Snippets — a short block of text. Give it a title and a body. Ideal for FAQs and quick facts.

- Open the Knowledge tab → Snippets
- Click Add
- Fill in the title and body
- Click Save
The text is indexed immediately and becomes available to the assistant once its status shows Completed.
Content Types for Knowledge Base
| Content Type | Purpose | Examples |
|---|---|---|
| FAQs | Common questions and answers | Product questions, troubleshooting |
| Product Information | Detailed descriptions | Features, specifications, pricing |
| Process Documentation | Step-by-step guides | Installation, setup procedures |
| Company Policies | Terms and procedures | Support policies, return procedures |
| Contact Information | Support channels | Phone numbers, email addresses |
Synchronization Notice
After adding a source, the system processes it through a queue job for AI analysis and indexing. The synchronization time depends on:
- Content Length: Sources with more text take longer to process
- Source Type: Websites with many pages take longer than a single snippet
- Queue Load: Processing time may vary based on system queue
Expected Processing Time: 2-10 minutes per document or page
Please wait for the status to show Completed (or "Fully Synced" for documents) before testing your AI Assistant. You can monitor progress in the Knowledge tab.
Step 4: Monitor Assistant Status
AI Assistant Dashboard - Processing State

The dashboard shows your assistant with initial processing status:
Status Indicators
| Status | Description | Action Required |
|---|---|---|
| Sync Status: Processing | Documents being indexed | Wait for completion |
| Sync Status: 100% | All documents processed | Ready for use |
| AI Assistant: Ready | Assistant created successfully | Can start chatting |
| Knowledge Base: Synced | Vector store ready | Fully operational |
Assistant Integration Dashboard
Once processing is complete, the dashboard shows:

| Component | Purpose | Status Indicator |
|---|---|---|
| Total Documents | Number of uploaded files | Shows count |
| Sync Progress | Document processing status | Percentage complete |
| Overall Status | System readiness | "Fully Synced" when ready |
| Assistant ID | Unique identifier | For API integration |
| Vector Store | Document search system | Search functionality status |
Step 5: Test Your AI Assistant
AI Integration Details
Click on the assistant card to view comprehensive status information:

Chat Interface Testing
The chat interface provides several testing capabilities:
| Feature | Description | Benefits |
|---|---|---|
| Real-time Messaging | Instant responses | Test conversation flow |
| Knowledge Base Sidebar | Uploaded documents display | Verify document access |
| Document Status | Sync indicators | Confirm processing complete |
| Chat History | Complete logs | Review conversation quality |

Testing Scenarios
| Test Type | Example Query | Expected Response |
|---|---|---|
| FAQ Questions | "What are your business hours?" | Accurate info from uploaded docs |
| Product Inquiries | "Tell me about your premium plan" | Detailed product information |
| Process Questions | "How do I reset my password?" | Step-by-step instructions |
| General Support | "I need help with billing" | Relevant guidance or handoff |
Step 6: Integrate with Bot Flows
Message Bot Integration

To use your AI Assistant in automated conversations:
Bot Flow Builder Integration
| Component | Function | Configuration |
|---|---|---|
| Text Message | Simple responses | Basic text replies |
| Button Message | Interactive options | Quick response buttons |
| List Message | Menu selections | Structured choices |
| AI Personal Assistant | Smart responses | Connect to your assistant |
Flow Configuration Parameters
| Setting | Options | Description |
|---|---|---|
| Contact Type | Lead, Customer, Prospect | Target audience |
| Trigger Type | "on exact match" | Activation method |
| Keywords | Custom keywords | Trigger words/phrases |
| Assistant Selection | Your created assistants | Choose AI to use |

Example Bot Flow Setup
Start Trigger
- Contact Type: Lead
- Trigger: "help", "support", "question"
AI Assistant Node
- Select: SmartFlow AI
- Configure response parameters
- Set fallback options
Reply Duration v1.1.0
When you attach an AI Personal Assistant in either a Bot Flow or a Message Bot, you can now set a Reply Duration — the length of time the AI keeps replying to a particular chat. Once this window passes, the AI automatically stops responding to that conversation and hands the chat off to a human agent. You can also choose Always On, which lets the AI keep replying indefinitely with no automatic handoff.

How to Configure
- Add the AI Personal Assistant node (Bot Flow) or select the Personal Assistant option (Message Bot)
- Locate the Reply Duration field
- Choose how long the AI should keep replying:
- Enable Always On to let the AI reply indefinitely, or
- Enter a number and choose a unit (minutes or hours) for a fixed window
- Save the flow or bot
How It Works
| Option | Description |
|---|---|
| Always On | The AI keeps replying to the chat indefinitely. The conversation is never auto-handed off. |
| Number | The amount of time the AI should keep answering this chat (when Always On is off) |
| Unit | The time unit for that number — minutes or hours |
- The timer starts when the AI first begins replying to a contact.
- While the duration is active, the AI answers messages from that contact as normal.
- When the duration elapses, the AI stops replying to that specific chat and the conversation is handed over to a human agent so support can continue seamlessly.
- With Always On enabled, there is no timer — the AI continues to handle the chat until you intervene manually.
Per-Chat Behaviour
Reply Duration applies per conversation. When a fixed window expires, only that contact's chat is handed off — other active chats continue to be served by the AI based on their own timers (or stay active if set to Always On).
Step 7: AI Reply Controls & Working Hours v1.1.0
Beyond Reply Duration, two settings let you control when and how often the AI responds.
Out of Knowledge Base Reply Limit
This setting caps how many times the AI will reply to questions that fall outside its uploaded knowledge base before it automatically stops responding.

What Counts as "Out of Knowledge Base"
- Any question the AI cannot answer from the uploaded documents
- General conversational messages such as "Hi", "Hello", "How are you?", "Thanks", etc.
Greetings Count Toward the Limit
Generic greetings and small-talk — like "hi", "hello", or "thanks" — are counted as out-of-knowledge-base replies. Account for these when setting your limit so the AI does not stop too early in a conversation.
How to Configure
- Go to Settings → AI Assistant Settings
- Find the Out of Knowledge Base Reply Limit field
- Enter the maximum number of out-of-knowledge-base replies allowed (e.g.,
5) - Click Save Changes
Once the limit is hit for a contact, the AI stops replying for that conversation, preventing it from consuming tokens on irrelevant or off-topic exchanges indefinitely.
Setting a Good Limit
A value of 5–10 is a reasonable starting point for most use cases.
Working Hours AI Control
Inside Working Days Settings, two independent switches control when the AI is active:
| Switch | Description |
|---|---|
| Enable AI during working hours | When ON, the AI responds to messages received during your configured working hours. |
| Enable AI outside working hours | When ON, the AI responds to messages received outside your configured working hours. |
You can enable one, both, or neither switch depending on your support model.

Common Configurations
| Use Case | During Working Hours | Outside Working Hours |
|---|---|---|
| AI handles all hours | ON | ON |
| AI only during business hours (human support after hours) | ON | OFF |
| AI only after hours (human team handles daytime) | OFF | ON |
| AI fully paused | OFF | OFF |
Bot Flow Must Match Working Hours
If you trigger the AI through a Bot Flow, the bot flow's own working-hours schedule must align with the AI's working-hours setting. For example, if the AI is enabled only during working hours but the bot flow runs outside working hours, the AI node will not trigger. Always keep the two consistent.
Best Practices
Content Preparation
| Practice | Description | Benefit |
|---|---|---|
| Clear Structure | Use headings and sections | Better AI understanding |
| Current Information | Regular content updates | Accurate responses |
| Simple Language | Avoid jargon | Improved comprehension |
| Specific Examples | Include real scenarios | Better context |
Response Quality
| Factor | Best Practice | Impact |
|---|---|---|
| Consistency | Maintain same tone | Professional image |
| Accuracy | Verify information | User trust |
| Completeness | Provide sufficient detail | User satisfaction |
| Relevance | Address actual question | Efficiency |
Troubleshooting
Common Issues
| Issue | Symptoms | Solution |
|---|---|---|
| Documents Not Processing | Sync status stuck | Check file formats and size |
| Poor Response Quality | Irrelevant answers | Update system instructions |
| Assistant Not Responding | No AI responses | Verify OpenAI API key |
| Knowledge Base Empty | No document access | Re-upload and wait for sync |
Error Messages
| Error | Meaning | Resolution |
|---|---|---|
| "Knowledge Base Pending" | Documents still processing | Wait for completion |
| "API Key Invalid" | OpenAI key issue | Check API key in settings |
| Model Not Available | Selected model unavailable | Choose different model |
| Upload Failed | File upload error | Check file size and format |
Next Steps
Once your AI Assistant is created and tested:
- Deploy in Chat Flows - Integrate with your bot builder
- Monitor Performance - Track user interactions and satisfaction
- Continuous Improvement - Regular updates and optimizations
- Scale Usage - Expand to additional use cases
Need Help?
For assistance with AI Assistant creation:
- Email Support: [email protected]
- Support Tickets: support.corbitaltech.dev
- OpenAI Configuration: Check our OpenAI Setup Guide