JanitorAI - Dynamic Character Avatars

Logs the last bot message and shows an emotion-based avatar. Completly customizable.

您需要先安裝使用者腳本管理器擴展,如 TampermonkeyGreasemonkeyViolentmonkey 之後才能安裝該腳本。

您需要先安裝使用者腳本管理器擴充功能,如 TampermonkeyViolentmonkey 後才能安裝該腳本。

您需要先安裝使用者腳本管理器擴充功能,如 TampermonkeyViolentmonkey 後才能安裝該腳本。

您需要先安裝使用者腳本管理器擴充功能,如 TampermonkeyUserscripts 後才能安裝該腳本。

你需要先安裝一款使用者腳本管理器擴展,比如 Tampermonkey,才能安裝此腳本

您需要先安裝使用者腳本管理器擴充功能後才能安裝該腳本。

(我已經安裝了使用者腳本管理器,讓我安裝!)

你需要先安裝一款使用者樣式管理器擴展,比如 Stylus,才能安裝此樣式

你需要先安裝一款使用者樣式管理器擴展,比如 Stylus,才能安裝此樣式

你需要先安裝一款使用者樣式管理器擴展,比如 Stylus,才能安裝此樣式

你需要先安裝一款使用者樣式管理器擴展後才能安裝此樣式

你需要先安裝一款使用者樣式管理器擴展後才能安裝此樣式

你需要先安裝一款使用者樣式管理器擴展後才能安裝此樣式

(我已經安裝了使用者樣式管理器,讓我安裝!)

作者
ZephyrThePink
今日安裝
0
安裝總數
26
評價
1 0 0
版本
1.7
建立日期
2025-07-17
更新日期
2025-07-17
尺寸
35.3 KB
授權條款
MIT
腳本執行於

JanitorAI - Dynamic Character Avatars

Overview

This Tampermonkey userscript adds dynamic, emotion-based avatars to JanitorAI chats. It analyzes the bot's last message and displays a character avatar that matches the detected emotion, making conversations more expressive and visually engaging.

Features

  • Automatic Emotion Detection: Uses Google Gemini API to analyze the bot's last message and determine the displayed emotion.
  • Dynamic Avatars: Shows a customizable avatar for each emotion and character.
  • Draggable & Resizable: Avatars can be moved and resized on the screen.
  • Mobile & Desktop Support: Works on both desktop and mobile browsers.
  • Customizable: Easily add or change characters and emotion images.

Setup Instructions

  1. Get a Gemini API Key:
  2. Configure the Script:
    • Open Tampermonkey dashboard, find the script, and click "Edit".
    • In Section 2 of the script, replace YOUR_OWN_API_KEY with your Gemini API key.
    • (Optional) Change the model if needed (default: gemini-2.0-flash).
  3. Save and Reload JanitorAI:
    • Save the script and reload your JanitorAI chat page. The avatar should appear when the bot sends a message.

Customization

Add or Change Emotions

  • In Section 1 of the script, you’ll find the characterEmotionAvatars object.
  • Each emotion is mapped to a number and an image URL.
  • To add new emotions:
    1. Add a new number and image URL to the character’s object.
    2. Update the emotion list in Section 5 (Gemini prompt) to match your changes.

Add More Characters

  • Add a new character to the characterEmotionAvatars object, using the same emotion number mapping.
  • Example: const characterEmotionAvatars = { Ashley: { ... }, Bob: { 1: "https://example.com/bob-happy.png", // Admiration 2: "https://example.com/bob-amused.png", // Amusement // ... add more emotions }, // Add more characters here }; - Make sure the emotion numbers and descriptions in the Gemini prompt (Section 5) match your avatar setup.

Tips

  • Only edit Sections 1, 2, and 5 for customization. Other sections are core logic.
  • If you add/remove emotions, always update the Gemini prompt so detection matches your avatars.
  • Avatars are draggable and resizable for convenience.

Support

For questions or help, you can contact me on discord (@xzeph__)