Skip to content

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

542 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

MP Ukagaka

A WordPress plugin for creating interactive ukagaka (伺か) characters with AI-powered features.

Plugin Version WordPress PHP

🌍 Other Languages: 繁體中文 | 日本語

📢 Preface (Please Read)

This plugin is an extensively expanded version based on the original WordPress plugin "MP Ukagaka" released by Ariagle over 10 years ago.

⚠️ Important Notice: Approximately 90% of this plugin's code was developed using AI-assisted development (Vibe Coding). Although it has undergone countless rounds of debugging and improvements, there may still be unknown bugs or imperfect code structures. Please understand this risk before use.

📺 Demo Site: https://www.moelog.com

About Character Personality Creation

While this plugin provides the Create New Character Personality feature (see GHOST_CREATE_GUIDE.md), development efforts have primarily focused on the default character "Frieren". Therefore, this feature has not been fully tested. Your understanding is appreciated.

If you simply want to use the default character "Frieren", basic dialogues are built-in and ready to use out of the box. For richer, more interactive conversations, we recommend configuring an AI model API Key. Additionally, the character memory configuration files (loading sequence: personality.md, instructions.md, and then system_prompt.md, containing memories from anime Season 1) are also built-in. You can configure your Admin full nickname, Admin short name, and Admin birthday (MM-DD format, e.g., 10-18) directly in Settings → MP Ukagaka → General Settings. The personality files use {{admin_nickname}}, {{admin_name}}, and {{admin_birthday}} as placeholders — these are automatically filled in from your backend settings at runtime, so you no longer need to manually edit the personality files or calendar.json. The character will also celebrate your birthday automatically based on this setting.

AI Model Recommendations

This plugin supports multiple AI providers including Gemini, OpenAI, Claude, and Ollama. Based on testing, GPT-4o Mini offers an excellent balance between dialogue generation quality and API costs, making it a highly recommended choice.

📸 Screenshot

MP Ukagaka Demo

Frieren character displaying AI-generated dialogue based on article content

💡 More Screenshots:

  • screenshot2.PNG - General Settings & LLM Settings pages
  • screenshot3.PNG - Interactive Chat Mode demo (v2.3.0 feature)

✨ Core Features

  • Multiple Characters: Create and manage multiple ukagaka characters
  • AI Context Awareness: Intelligent responses using Gemini, OpenAI, Claude, or Ollama
  • Interactive Chat Mode: Real-time conversations with visitors, including SSE streaming responses
  • External Dialog Files: Support for TXT and JSON format dialogues
  • Canvas Animation: Single image or multi-frame animation support
  • Multi-Language: English, Traditional Chinese, and Japanese
  • Security First: API key encryption, CSRF protection, XSS prevention

🚀 Quick Start

Installation

  1. Download or clone this repository to wp-content/plugins/
  2. Activate the plugin in WordPress Admin → Plugins
  3. Go to Settings → MP Ukagaka

Basic Setup

  1. General Settings: Choose default character and configure display settings
  2. Create Character: Add character with image URL and dialogues
  3. Dialog Files: Dialogues are automatically saved to dialogs/ folder

Enable AI Features (Optional)

LLM Settings:

  • Choose provider: Ollama (free), Gemini, OpenAI, or Claude
  • Enter API key (automatically encrypted) or configure Ollama endpoint
  • Enable "Replace Built-in Dialogues"

AI Settings:

  • Enable "Page Awareness"
  • Set trigger probability (10-30% recommended for cost control)
  • Customize character personality in System Prompt

Chat Mode:

  • Enable "Interactive Chat Mode" in General Settings
  • "Change Ukagaka" button becomes a chat interface

🤖 AI Providers

Provider Cost Setup
Ollama Free Install locally or connect to remote server
Gemini Paid API Get key from Google AI Studio
OpenAI Paid API Get key from OpenAI Platform
Claude Paid API Get key from Anthropic Console

📚 Documentation

For detailed information, please refer to:

🎉 What's New in v2.28.0

Per-item variant substitution for gift reactions (v2.28.0): Item catalog entries can now define an optional variants list. When present, /touch/give picks one at random and substitutes it into the item prompt's {variant} placeholder, so a single gift or food item produces varied, content-aware reactions instead of one fixed line. Frieren's 魔導書 gift ships 10 distinct variants so repeated gifting no longer returns the same response. See the Character Creation Guide for the full items.json format.

Chat integrity session follow-up (v2.27.7): Checksum verification and storage now use the same full 40-entry transport window while the LLM context remains capped at 20 entries. Each page instance also receives a fresh checksum session ID, including duplicated tabs whose sessionStorage was copied by the browser.

Review follow-up hardening (v2.27.6): Legacy LLM settings now migrate from the raw stored option without being masked by defaults, settings reset no longer risks a PHP type error, and chat checksum storage/verification shares the same 40-entry raw-history window used by browser persistence and REST transport. Gift provider diagnostics are now kept server-side instead of being shown to visitors.

Earlier releases: housekeeping and uninstall cleanup (v2.27.5), checksum window filtering (v2.27.4), gift reliability & checksum consolidation (v2.27.3), the 🎁 Gift / Feeding system (v2.27.0), daytime nap (v2.26.0), the frontend modular split (v2.25.7), authenticated AES-256-GCM key encryption (v2.25.6), and inline emotion tags (v2.25.0), among others.

View Full Changelog

❓ Common Questions

Why isn't AI triggering?

  • Check API key is valid
  • Verify page matches trigger conditions (e.g., is_single)
  • Ensure probability is set (try 100% for testing)
  • Check content length (>300 characters required)

How to control API costs?

  • Set probability to 10-20%
  • Use cheaper models (gemini-2.5-flash, gpt-4o-mini)
  • Limit trigger pages to is_single

LLM connection failed?

  • For Ollama: Ensure service is running on port 11434
  • For remote: Check Cloudflare Tunnel or network connection
  • Test connection using the test button in settings

More FAQ in User Guide

🔒 Security Features

  • API Key Encryption: AES-256-GCM encryption for all API keys
  • CSRF Protection: WordPress nonce verification for all forms
  • XSS Prevention: Input/output sanitization using WordPress core functions
  • Secure File Operations: Path validation and WordPress Filesystem API

💬 Support

👥 Credits

  • Original Author: Ariagle
  • Maintainer: Horlicks (MOELOG.COM)
  • Inspired by: Classic MP Ukagaka plugin / 伺か (Ukagaka)

📄 License

Based on the original MP Ukagaka plugin. Please refer to the original plugin's license terms.


Made with ❤ for the WordPress community

About

Create your own ukagakas and display one of them on your wordpress blog. You can get more information about ukagaka at [Wikipedia](http://en.wikipedia.org/wiki/Ukagaka)

Topics

Resources

Stars

Watchers

Forks

Releases

Packages

Contributors

Languages