Rapls AI Chatbot add an AI chatbot to your site with OpenAI, Claude, Gemini, or OpenRouter. Includes site learning, knowledge base, and web search.
Key Features
- Multiple AI Providers — OpenAI, Anthropic Claude, Google Gemini, and OpenRouter (100+ models via single API key)
- Web Search — AI automatically searches the web when the knowledge base lacks a sufficient answer, using each provider’s built-in capability (OpenAI web_search_preview, Claude web_search, Gemini google_search)
- Site Learning — Crawl and index your website content (posts, pages, custom post types, WooCommerce products) for context-aware responses
- Vector Embedding RAG — Hybrid search combining keyword matching (40%) and vector similarity (60%) for accurate retrieval
- Custom Knowledge Base — Add Q&A pairs, free-form content, PDF/DOCX uploads with priority levels and draft/published workflow
- MCP Server — 7 built-in tools via JSON-RPC 2.0 for AI agent integration (Claude Desktop, Cursor, VS Code)
- WordPress Abilities API — Auto-register MCP tools as WordPress Abilities for discovery by MCP Adapters
- Gutenberg Block — Insert AI Chatbot block in the block editor with height, theme, and bot-id settings; SSR support
- Response Language Auto-detect — Automatically detect browser language for welcome message and AI responses
- Cross-site Embed — Embed the chatbot on external sites via iframe or script loader
- Conversation History — Save and review all chat conversations with configurable retention
- Usage Statistics — Track token usage and estimated API costs with visual charts and provider breakdown
- Feedback & Regeneration — Users can rate responses (thumbs up/down) and request regeneration
- 6 Built-in Themes — Default, Simple, Classic, Light, Minimal, Flat
- Security — reCAPTCHA v3, rate limiting, consent mode, Cloudflare support, security diagnostics
- Settings Import/Export — Backup and restore all settings as JSON
- Multilingual — Japanese translation included; welcome messages configurable in 13 languages
Supported AI Models
OpenAI: * GPT-5.2, GPT-5.1, GPT-5 series (Latest generation) * GPT-4.1 series (Long context, 1M tokens) * GPT-4o, GPT-4o-mini (Multimodal) * o1, o3, o4-mini (Reasoning models)
Anthropic Claude: * Claude Opus 4.6 (Most powerful) * Claude Sonnet 4.5 (Recommended — fast and powerful) * Claude Haiku 4.5 (Recommended — fastest) * Claude Opus 4.5, Opus 4.1, Sonnet 4, 3.7 Sonnet
Google Gemini: * Gemini 3 Pro/Flash (Preview, latest) * Gemini 2.5 Pro/Flash (Recommended) * Gemini 2.0 Flash (Stable) * Gemini 1.5 Pro/Flash (Legacy)
OpenRouter: * Access 100+ models from multiple providers through a single API key
Dashboard
The dashboard provides an at-a-glance overview of your chatbot’s activity:
- Statistics cards: total conversations, today’s messages, indexed pages, knowledge entries, monthly AI responses with usage limit
- Status indicators: AI provider, site learning, conversation history
- API usage statistics (past 30 days): total tokens, input/output tokens, estimated cost, daily usage chart, provider breakdown
Settings (5 Tabs)
AI Settings — Configure your AI provider, model, and API key. Enable vector search (RAG) with embedding provider. Set up MCP server with API key generation and Claude Desktop configuration example.
Chat Settings — Customize bot name, avatar (emoji or image), welcome messages (13 languages: English, Japanese, Chinese, Korean, Spanish, French, German, Portuguese, Italian, Russian, Arabic, Thai, Vietnamese), system prompt, response language, message history count, feedback buttons, and API quota error message. Advanced: context prompts for knowledge matching, Q&A format, and site learning; feature prompts for regeneration instructions, good/bad example learning, and conversation summary.
Display Settings — Choose from 6 free themes (Default, Simple, Classic, Light, Minimal, Flat). Configure badge position (4-corner grid), margins, primary/secondary colors, mobile display, Markdown rendering, typing indicator, maximum input length, page exclusion, footer text, and cross-site embed options (script or iframe).
Security Settings — Enable reCAPTCHA v3 with site key, secret key, and score threshold. Configure access control: consent strict mode, rate limiting, Cloudflare integration, reverse proxy trust, reCAPTCHA failure mode. View security diagnostics (read-only): allowed origins, trusted proxies, IP detection, API key status, WP Consent API, rate limiting, reCAPTCHA, SSL/TLS, CSRF.
Data Management — Enable/disable conversation history with configurable retention period. Import/export settings (optionally including knowledge base). Reset all settings to defaults.
Knowledge Base
- Add entries as text: title, content, category, priority level
- File import: .txt, .csv, .md, .pdf, .docx (server-side parsing)
- Statistics: total entries, active, inactive, categories
- Filter by status: all, published, draft
- Sortable table: ID, title, category, type, priority, updated date
- Unlimited entries
Site Learning
The plugin crawls and indexes your published content for context-aware AI responses:
- Posts and Pages
- Custom Post Types
- WooCommerce Products
- Any public content
With vector embedding enabled, hybrid search combines keyword matching (40%) and vector similarity (60%) for better retrieval accuracy.
Free vs Pro
The free version is fully functional with no artificial limits — you pay only your own AI API costs. An optional Pro add-on is available for business-oriented features.
- Free — Full AI chat, unlimited responses, unlimited knowledge base, 6 themes, MCP server, Gutenberg block
- Pro — Adds analytics, lead capture, scenarios, operator mode, WooCommerce, LINE, and more
What Free includes:
- All 4 AI providers (OpenAI, Claude, Gemini, OpenRouter)
- Unlimited AI responses and knowledge base entries
- Web search, site learning with vector RAG
- MCP server, Gutenberg block, cross-site embed
- 6 themes, feedback, regeneration, reCAPTCHA, security diagnostics
What Pro adds:
- Analytics dashboard with satisfaction scores, FAQ ranking, and PDF export
- Lead capture forms, CSV/JSON export, webhooks, Google Sheets
- Conversation scenarios, business hours, human handoff, operator mode
- WooCommerce product cards, LINE Messaging API, Slack notifications
- 10 additional themes, dark mode, voice input/TTS, multimodal
- Response caching, encryption, audit logs, and more
Learn more at raplsworks.com
External Services
This plugin connects to the following external third-party services. No data is sent to any service until you configure an API key and enable the feature in the plugin settings. Each service requires the site administrator to create an account and obtain API credentials. By using these services, you agree to their respective terms and privacy policies listed below.
1. OpenAI (GPT models) — AI Provider
Used when you select OpenAI as your AI provider. User messages and optionally site content are sent to generate AI responses.
- Service URL: https://api.openai.com/
- Terms of Use: https://openai.com/terms/
- Privacy Policy: https://openai.com/privacy/
2. Anthropic (Claude models) — AI Provider
Used when you select Anthropic Claude as your AI provider. User messages and optionally site content are sent to generate AI responses.
- Service URL: https://api.anthropic.com/
- Terms of Use: https://www.anthropic.com/terms
- Privacy Policy: https://www.anthropic.com/privacy
3. Google (Gemini models) — AI Provider
Used when you select Google Gemini as your AI provider. User messages and optionally site content are sent to generate AI responses.
- Service URL: https://generativelanguage.googleapis.com/
- Terms of Use: https://policies.google.com/terms
- Privacy Policy: https://policies.google.com/privacy
4. OpenRouter — AI Provider
Used when you select OpenRouter as your AI provider. OpenRouter is a unified API gateway that routes requests to various AI models.
- Service URL: https://openrouter.ai/api/
- Terms of Use: https://openrouter.ai/terms
- Privacy Policy: https://openrouter.ai/privacy
5. Google reCAPTCHA v3 (Optional)
Used only if you enable reCAPTCHA in the plugin settings for spam protection. The visitor’s IP address and interaction data are sent to Google for verification.
- Service URL: https://www.google.com/recaptcha/
- Terms of Use: https://policies.google.com/terms
- Privacy Policy: https://policies.google.com/privacy
6. LINE Messaging API (Pro Add-on, Optional)
Used only if you enable the LINE integration via the Pro add-on. Connects to the LINE Messaging API for chatbot-to-LINE messaging.
- Service URL: https://api.line.me/
- Terms of Use: https://terms.line.me/
- Privacy Policy: https://line.me/en/terms/policy/
Cross-Site Embed
The plugin includes an optional embed loader script (embed-loader.js) for embedding the chatbot on external websites via an iframe. This script does not load any external CDN resources or third-party scripts — it creates an iframe pointing back to your own WordPress site. All data processing occurs on your server.
Data Transmitted to External Services
- User messages: Chat messages entered by visitors (sent to the configured AI provider only)
- Site content (if Site Learning is enabled): Excerpts from your published posts/pages (sent to the configured AI provider)
- Knowledge base (if configured): Custom Q&A entries you create (sent to the configured AI provider)
- IP address (reCAPTCHA only): Sent to Google for spam verification
Data Storage
- Conversation history: Stored locally in your WordPress database (can be disabled)
- Visitor IP: Stored as SHA-256 hash (not plain text) for rate limiting
- Retention: Configurable auto-deletion period (default 90 days)
User Controls
You can disable these features in the plugin settings: * Conversation history saving * Site content crawling/learning * Google reCAPTCHA verification * Web search
Privacy
Data Collected
When conversation history is enabled, the plugin stores: * Chat messages (user and AI responses) * Session identifiers * Page URLs where chats occurred * Hashed IP addresses (SHA-256, not reversible) * Timestamps
Data Retention
Conversation data is automatically deleted after the configured retention period (default: 90 days). Administrators can manually delete conversations at any time.
User Rights
Site administrators can: * View all conversation history * Delete individual or all conversations * Export settings (does not include conversation data) * Disable history saving entirely= Developer Information =
The plugin provides hooks and filters for customization:
Available Filters
raplsaich_system_prompt— Modify the system prompt sent to AIraplsaich_context— Modify the context from site learningraplsaich_ai_response— Filter the AI response before displayraplsaich_chatbot_enabled— Control chatbot visibility programmaticallyraplsaich_allowed_origins— Add allowed origin hosts for same-origin checkraplsaich_chat_response_data— Filter chat response data before returning to clientraplsaich_gpt5_token_multiplier— GPT-5 reasoning token multiplier (default: 4, range: 1-8)
Example: Custom System Prompt
add_filter( 'raplsaich_system_prompt', function( $prompt, $settings ) {
return $prompt . "\n\nAlways end responses with a friendly emoji.";
}, 10, 2 );
Example: Conditionally Hide Chatbot
add_filter( 'raplsaich_chatbot_enabled', function( $enabled ) {
// Hide on checkout page
if ( is_page( 'checkout' ) ) {
return false;
}
return $enabled;
} );
REST API Endpoints
The plugin registers REST API endpoints under the rapls-ai-chatbot/v1 namespace:
Session authentication: Pass the session ID via the X-RAPLSAICH-Session HTTP header (recommended). When the header is present, any session_id in the request body is ignored (prevents APM/WAF body-logging leakage). Query string parameters (?session_id=...) are not accepted for GET requests to prevent session leakage in server access logs.
Free:
GET /rapls-ai-chatbot/v1/session— Get or create a chat sessionPOST /rapls-ai-chatbot/v1/chat— Send a message and receive AI responseGET /rapls-ai-chatbot/v1/history/{session_id}— Get conversation historyPOST /rapls-ai-chatbot/v1/feedback— Rate a response (thumbs up/down)POST /rapls-ai-chatbot/v1/regenerate— Regenerate AI responseGET /rapls-ai-chatbot/v1/message-limit— Check message limitsPOST /rapls-ai-chatbot/v1/lead— Submit lead formGET /rapls-ai-chatbot/v1/lead-config— Lead form configuration
The Pro add-on registers additional endpoints for analytics, scenarios, LINE, and more. See the Pro documentation for details.
Settings Architecture
Extension settings are stored under the extensions key in raplsaich_settings. For backward compatibility, the legacy pro_features key is read as a fallback but all new settings are written to extensions.
Database Tables
The plugin creates the following database tables:
{prefix}_aichat_conversations— Chat sessions{prefix}_aichat_messages— Individual messages with token tracking{prefix}_aichat_index— Site learning content index{prefix}_aichat_knowledge— Custom knowledge base entries{prefix}_aichat_leads— Lead capture data
Uninstallation
When uninstalled with “Delete data on uninstall” enabled, the plugin removes all database tables, options, and transients. Without this setting, data is preserved for re-installation.
Development
Release ZIPs are CI-verified for packaging correctness. Report any issues via the support forum.
Credits
- Chart.js (MIT License) — Usage statistics charts
