TL;DR
- Treat a report, a review case, a moderation decision, and an appeal as different records. Reports are evidence or signals; a report count alone should not determine the outcome.
- Route work by policy, urgency, reviewer capability, and deadline. Use durable claims with leases so a worker or reviewer disconnect does not lose the case or leave it assigned forever.
- Store a versioned decision with the content revision, policy, rationale, actor, and user notice. Keep an appeal as a new review event with independent ownership and a path to reverse the earlier action.
- Automation can assist with deduplication and triage, but high-impact decisions need an accountable review path. Preserve privacy by limiting stored evidence and setting retention by purpose and applicable law.
Why a growing moderation queue needs a case model
A small community can handle reports in a shared inbox. At larger volume, a single list sorted by arrival time creates avoidable problems. A time-sensitive threat report competes with a low-impact spam complaint. Duplicate reports multiply the apparent queue size. A reviewer changes a decision, but the system overwrites the previous status and loses the explanation. A user asks for an appeal, and the original decision maker is assigned it again.
Build the system around a durable case lifecycle. A report captures a notice or signal about content. A case groups related reports and defines the work to review. A decision records a policy outcome and any action taken. An appeal asks for review of a specific decision. Keeping these entities separate lets the service deduplicate reports without erasing them, re-review a prior decision without rewriting history, and route appeals to a different workflow.
Moderation is not a single binary label. The policy may allow content, restrict visibility, add an age gate, remove a post, suspend an account, or request more context. A decision must refer to the policy and content revision in force when it was made. If the policy changes, the old decision still needs to be explainable under the policy used at that time.
Model reports, cases, decisions, and appeals separately
A report should capture who or what submitted it, the target content revision, a structured reason, a concise description, jurisdiction or policy context where relevant, and receipt time. Avoid copying the full content into each report. Store a controlled reference to the relevant revision and restrict access to evidence based on reviewer role. If content can be edited or removed while a case is open, preserve the minimum reviewable snapshot required by policy and retention rules.
A case contains routing and workflow state: priority class, queue, owner, lease, due time, and status. A decision is append-only and records outcome, policy identifier and revision, rationale code, explanation shown to the affected user, reviewer or automated system, timestamps, and content revision. An appeal points to the challenged decision, captures the appeal reason and supporting information, and stores its own reviewer, outcome, and user notification.
CREATE TABLE moderation_report (
id uuid PRIMARY KEY,
content_id uuid NOT NULL,
content_revision text NOT NULL,
reporter_id uuid,
source text NOT NULL CHECK (source IN ('user', 'system', 'authority')),
reason_code text NOT NULL,
received_at timestamptz NOT NULL DEFAULT now(),
case_id uuid,
status text NOT NULL CHECK (status IN ('open', 'linked', 'dismissed'))
);
CREATE TABLE moderation_case (
id uuid PRIMARY KEY,
content_id uuid NOT NULL,
content_revision text NOT NULL,
policy_version text NOT NULL,
queue_name text NOT NULL,
priority_class smallint NOT NULL,
state text NOT NULL CHECK (state IN
('queued', 'claimed', 'needs_context', 'decided', 'appealed', 'closed')),
available_at timestamptz NOT NULL DEFAULT now(),
due_at timestamptz,
lease_owner uuid,
lease_until timestamptz,
created_at timestamptz NOT NULL DEFAULT now()
);
CREATE INDEX moderation_case_ready
ON moderation_case (queue_name, priority_class DESC, available_at, created_at)
WHERE state = 'queued';
Use foreign keys for the decision and appeal relationships, unique identifiers for provider or event IDs, and database constraints for allowed state transitions where practical. Keep a separate audit event for transitions instead of relying only on the mutable current status. Enforce who can read reporter identity, private evidence, and reviewer notes. Reviewers need enough context to decide, but not every internal record needs the reporter's full account details.
Ingest and group reports without turning popularity into guilt
Accept reports through a user-friendly form that captures the target and the policy concern with enough specificity to investigate. Give the reporter a receipt identifier and status where appropriate. Validate that the actor can report the target, rate-limit automated abuse, and keep an audit trail for system-generated signals. For external notice mechanisms, keep the notice source, received time, and response state distinct from user reports.
Several reports may point to the same content revision and policy category. Link them to an open case rather than creating a separate identical review job. Preserve each report for audit and reporter feedback, but do not count the number of submissions as proof that content violates policy. Coordinated reporting can be an attack. A report is a reason to inspect content; it is not itself a decision.
Deduplication needs a stable key such as content revision plus policy category, with a bounded time window and explicit rules for reopening closed cases. Do not merge materially different concerns into one case merely because they share a post. If a report introduces new evidence, reopen or append it in a way reviewers can see. Record why a case was linked so later audits can distinguish duplicate volume from distinct allegations.
Route work by urgency, skill, and time budget
Define queues around operational needs rather than a single score. A queue may separate urgent safety reports, account integrity, intellectual property notices, routine community policy, and appeals. The categories depend on the service and jurisdiction. Each queue needs an accountable owner, expected review process, escalation contact, and policy for cases it cannot resolve.
Priority can combine expected impact, confidence in the signal, exposure, and deadline, but the underlying facts should remain visible. A risk score should help order investigation rather than obscure why a case is first. Avoid letting a speculative score automatically decide whether content is removed. Route language or expertise needs to qualified reviewers, and preserve a path for unclassified cases. Do not let a low-confidence automated model suppress a report that meets a separate urgent-routing rule.
Strict priority queues can starve routine work when urgent volume remains high. Use separate capacity reservations, bounded service classes, and aging so old eligible work eventually receives attention. Track queue age and due-time misses by class, plus the age of the oldest case. A single aggregate review time hides the fact that one queue is accumulating work while another stays fast.
Claim cases durably with a lease
For asynchronous triage and notification tasks, multiple workers can claim rows using PostgreSQL's FOR UPDATE SKIP LOCKED. PostgreSQL explains that this produces an inconsistent view and is intended for queue-like consumers rather than general reads. Keep claim transactions short, persist a lease deadline, and reclaim expired claims. A UI reviewer assignment should likewise have a clear owner, expiry or handoff process, and visible state. PostgreSQL SELECT locking clauses
BEGIN;
WITH candidate AS (
SELECT id
FROM moderation_case
WHERE state = 'queued'
AND available_at <= statement_timestamp()
AND (due_at IS NULL OR due_at > statement_timestamp())
ORDER BY priority_class DESC, available_at, created_at, id
FOR UPDATE SKIP LOCKED
LIMIT 1
)
UPDATE moderation_case AS c
SET state = 'claimed',
lease_owner = $1,
lease_until = statement_timestamp() + interval '5 minutes'
FROM candidate
WHERE c.id = candidate.id
RETURNING c.*;
COMMIT;
The five-minute lease is illustrative, not a recommended universal duration. Set it from the unit of work, worker heartbeat behavior, and recovery objective. Human review work can take longer than a process lease and should not be treated as a transient message lock. For human assignments, use explicit claim and release actions, escalation, and a safe way to reassign work after an absence.
For a worker task, renew the lease only if the current owner still matches and the prior lease has not expired. A stale worker must not overwrite a newer attempt. Add attempt identifiers or compare-and-set state transitions. Use bounded retries with delay and a terminal error state for failed notifications or classifier calls. Keep a reconciliation job for stuck claims and track the oldest lease that has expired without recovery.
Separate automated signals from final decisions
Automation can group duplicate reports, find likely language or policy categories, detect known hashes, and route cases to reviewers. Preserve the signal, model or rule version, input scope, and confidence as evidence that can be assessed. A classifier result is not the same as a policy decision. When an automated action restricts access, it needs the same decision record, explanation path, appeal handling, and auditability as other restrictions.
Use policy-specific thresholds and measure false positives and false negatives against reviewed samples. Slice by language, content type, account tenure, and other relevant dimensions where lawful and appropriate. Keep an unclassified path. Establish who can override a model result and how a reviewer records that override. Reassess the model and thresholds after meaningful changes to policy, input data, or model version.
For EU-covered hosting services, the Digital Services Act includes notice-and-action requirements and statements of reasons. For covered online platforms, Article 20 provides an internal complaint-handling system for at least six months after specified decisions and says complaint decisions are taken under appropriately qualified staff supervision, not solely by automated means. Applicability, exceptions, and other local obligations depend on service scope and law, so have counsel map requirements to your product. EU Digital Services Act, Regulation (EU) 2022/2065
Design appeals as a first-class workflow
Send a decision notice that identifies the affected content or account, the action, the policy basis, the relevant facts, and the available way to contest it. Keep internal reviewer notes separate from the explanation a user receives. The explanation should be specific enough to be useful without disclosing another person's identity, detection logic that enables evasion, or sensitive evidence that the recipient is not entitled to see.
An appeal must refer to the exact decision and content revision it challenges. Preserve its submission time and the user's stated reason. Route it to a reviewer who can inspect the original rationale and relevant evidence, while avoiding automatic assignment back to the original decision maker where an independent review is appropriate. Record whether the appeal upholds, modifies, or reverses the decision, and notify the user of the result.
Appeal outcomes should feed policy and quality review. A reversal may reveal a reviewer training gap, an ambiguous policy, stale evidence, a model threshold problem, or a product bug. Track reversal rates by policy version and decision path, then sample both upheld and reversed cases. Do not optimize for a low reversal rate alone: reviewers may simply be failing to correct mistakes.
Protect privacy and reviewer wellbeing
Moderation evidence can include personal data, private communications, and sensitive information. Define why each field is collected, who can see it, how it is protected, and when it is deleted or de-identified. The GDPR principles include purpose limitation, data minimisation, and storage limitation. These principles support designing separate retention for active cases, appeal windows, security investigations, and aggregated quality metrics rather than keeping everything indefinitely. General Data Protection Regulation, Article 5
Use role-based access for case queues, mask unnecessary personal identifiers, and log access to sensitive evidence. Do not place full content or personal information in generic analytics events. Store encrypted references to content revisions and restrict exports. Define a secure procedure for evidence that must be preserved under an applicable legal process, separate from ordinary retention, and remove it when that basis expires.
Reviewer workload is a system concern. Provide queue caps, breaks, escalation paths, and specialized handling for distressing or complex categories. Avoid exposing reviewers to unnecessary media or repeat content. Keep explanations and assignment changes clear so review quality does not depend on personal memory. Staffing and review rates should be based on actual workload and policy risk, not a generic productivity target.
Measure outcomes rather than raw throughput
Monitor intake volume, deduplication, eligible case age, time to first review, time to decision, appeal age, reversal rate, and the share of cases awaiting more context. Break these down by queue, content type, language, and automation path where the analysis is appropriate. Track report-to-case conversion and the fraction of reports linked to an existing case to identify coordinated reporting or duplicate bursts without treating either as proof of abuse.
Review accuracy with sampled labels and adjudication. Measure agreement between reviewers, disagreement by policy section, and outcome differences across relevant groups. A rising disagreement rate may indicate unclear policy or inconsistent training. A high closure count can coexist with poor decisions if cases are closed too quickly or appeal access is hard to find.
Run operational drills for duplicate report floods, reviewer absence, a downstream classifier outage, a policy version change, and appeal volume spikes. Verify leases are recovered, old cases remain visible, notices contain the correct policy revision, and a reviewer can reverse an action without editing the original record. A queue that stays green while users cannot appeal or understand a decision is not healthy.
Frequently asked questions
Should report count determine whether content is removed?
No. Multiple reports can help surface content for review, but coordinated users can also create a burst of duplicate or abusive reports. Group related reports into a case and preserve each notice, then apply the published policy to the content and context. Report volume is an operational signal, not proof of a violation.
Should an AI model make the final moderation decision?
It depends on the policy, impact, service scope, and applicable obligations. Automation can classify, deduplicate, and route work, but high-impact decisions need an accountable review path. Preserve the model and policy versions, expose a way to appeal, and measure errors on reviewed samples. The EU Digital Services Act has specific requirements for covered services.
How should a moderation system handle appeals?
Bind each appeal to a specific decision and content revision, preserve the submission and outcome, and route it to an appropriately qualified reviewer. Give the reviewer the original rationale and evidence, allow them to uphold, modify, or reverse the action, and notify the user. Keep the initial decision immutable for audit.
How long should moderation evidence be retained?
Set retention by the purpose of each record, applicable law, appeal windows, and operational need. Keep only the information needed for review and audit, protect access to sensitive evidence, and define a separate process for lawful preservation holds. GDPR includes data minimisation and storage limitation principles for covered personal data.
Make the case history understandable to people
A scalable moderation system is a workflow and accountability system, not just a queue. Preserve report provenance, content and policy versions, reviewer decisions, user notices, and appeal outcomes. Route work by risk and expertise, protect routine work from starvation, and make stale claims recoverable. Measure decision quality and access to redress alongside throughput.
If you are designing trust and safety tooling, talk with our engineering team about case modeling, reviewer workflows, queue recovery, and auditability. For a related PostgreSQL scheduling pattern, see multi-tenant worker quotas and database-enforced booking constraints.
