Skip to main content

Content moderation (native GPT)

Bellamy Book moderates posts and stories inside the monorepo with OpenAI GPT (same stack as Live Chat). There is no external ContentDetect / Ollama service.

This is the safety layer behind Release 2: keep harmful content out of member feeds while giving operators a review queue.

Flow

  1. User creates a post or story → API saves it as Pending + hidden.
  2. One RabbitMQ message (ContentType: post | story) → ContentModerationWorker.
  3. Worker calls GPT (caption text + image vision). Video frames skipped in v1.
  4. high → Rejected (stays hidden) + admin alert + notify creator.
  5. none / low / medium → Approved + unhide + notify creator (+ friends). Low/medium also create admin alerts.

Enable

ContentModeration__Enabled=true
# Optional — falls back to LiveChat__OpenAiApiKey if empty
ContentModeration__OpenAiApiKey=sk-...
ContentModeration__Model=gpt-4o-mini
ContentModeration__NotifyAdminsByEmail=true
Frontend__AdminBaseUrl=https://admin.example.com

Ensure content-moderation-worker is running (included in dockerProd / dockerPublish compose). SMTP must work for admin alert emails. Set the OpenAI key on both API and ContentModerationWorker.

Admin

Open Admin → Content → Content Alerts to review, hide, unhide, delete, or dismiss (works for posts and stories).