You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Features & Security — AI Admin Calls, RAG suggestions, and Real-Time Chat Sync
AI Admin Calls Tool & Manual Button: Implemented the call_admin tool for the AI assistant and a manual "Call Admin" button for players. Added configurable anti-spam limits (cooldown period, daily user limit, global hourly limit) to prevent spam.
Separated Call Admin Configuration: Split the configuration toggles so that the manual button and the AI tool calling capability can be enabled or disabled independently from the admin panel.
RAG Knowledge Suggestion panel: Created a new workflow where the AI assistant can suggest additions to the RAG knowledge base. Admins can review, edit, approve, or reject suggestions directly from a newly designed "Conversations IA" section in the admin panel.
Multi-language Error Handling: Modified backend cooldown verification endpoints to return structured data (error_code and params) instead of hardcoded French text. Enhanced the client API class to pass structured errors, enabling dynamic translation of cooldown limits using $t Svelte helper on the player's view (supporting French, English, and Spanish).
Notification Filtering via Active Chat Tracking: Introduced an /active-chat/{conv_id} endpoint and a frontend ping interval (every 4 seconds) to track which conversation a player is actively viewing. If the player is looking at the chat window, database notifications are skipped on admin message interventions to prevent unread notification badges from flashing.
Real-Time WebSocket Message Deletion Sync: Integrated WebSocket broadcasts (ia_message_deleted) when messages are deleted. Implemented local action locks (isProcessingLocalAction) on the frontend to avoid race conditions and infinite reload loops during batch message deletions.
AI Response Regeneration Fix: Resolved a frontend bug where the "Retry" button on bot messages blocked the request by setting loading = true too early. Added support for skip_save_user payload flag to prevent prompt duplication in both the database and the Svelte UI during regeneration.
Unified Button Styling: Replaced the default unstyled btn-ghost with the project-wide semi-transparent btn-secondary class for Dismiss (Admin calls) and Reject (RAG suggestions) actions.