Patch Changes
-
#3400
678b848Thanks @danielmlr! - Fixes the AI moderation plugin'scomment:beforeCreateandcomment:moderatehooks being skipped at startup with awithout users:read capability — skippingwarning, so no comment reached Workers AI. The plugin now declaresusers:read. Upgradeemdashin the same step.A site that ran the plugin under an earlier release has the built-in moderator stored as its moderator choice, because the skipped hooks left the built-in moderator as the only one, and it keeps that choice. On such a site the plugin now sends each new comment to Workers AI and records the result in the comment's moderation metadata, while the built-in moderator still decides the comment's status. This continues until the plugin is disabled or AI moderation is selected as the moderator.
On a site with no stored moderator choice, AI moderation replaces the built-in moderator. An earlier
emdashselects neither there and holds every new comment for review.When AI moderation decides, Auto-approve clean comments is on by default, so comments that Llama Guard rates clean are approved even on collections that hold comments for review. Comments from logged-in CMS users are approved even when the collection's Auto-approve authenticated users setting is off. To fall back to each collection's moderation setting for clean comments, turn Auto-approve clean comments off on the plugin's AI Moderation settings page.