[Proposal] Discussion Feature Additions: Soft Deletion, Mute/Ban, Spam Detection
Open edX Proposal (OEP) โ Discussions: AI-Assisted Spam Moderation and Learner Mute/Block Controls
- 1 Open edX Proposal (OEP) โ Discussions: AI-Assisted Spam Moderation and Learner Mute/Block Controls
- 1.1 OEP Metadata
- 1.2 1. Abstract
- 1.3 2. Motivation and Problem Statement
- 1.3.1 2.1 AI-Assisted Moderation
- 1.3.2 2.2 Learner Mute/Block
- 1.4 3. Goals and Non-Goals
- 1.4.1 3.1 Goals
- 1.4.2 3.2 Non-Goals
- 1.5 4. Proposed Solution Overview
- 1.6 5. Detailed Specification
- 1.7 6. Privacy, Legal, and Security
- 1.8 7. Backwards Compatibility
- 1.9 8. Observability and Metrics
- 1.10 9. Rollout Plan
- 1.11 10. Alternatives Considered
- 1.12 11. Risks and Mitigations
- 1.13 12. Open Questions
- 1.14 13. Implementation Notes
OEP Metadata
OEP: Assigned by maintainers on acceptance
Title: AI-Assisted Spam Moderation and Learner Mute/Block Controls for Open edX Discussions
Author(s): Spencer Tiberi (2U/edX)
Stakeholders: Product (2U/edX), Partner Institutions, Open edX Community Maintainers, Security/Privacy Reviewers
Status: Proposal
Type: Feature / Architecture (cross-repository)
Created: Apr 15, 2026
Target Release: Next named release after acceptance (to be proposed during review)
Related OEPs: OEP-17 Feature Toggles; OEP-30 PII Markup and Auditing; OEP-4 Application Authorization (Scopes), as applicable
1. Abstract
This OEP proposes two enhancements to Open edX Discussions (Forums v2):
Soft delete: allow messages to be hidden from view without permanently deleting them, if the need to recover becomes necessary. Course team members can permanently delete messages if desired upon review.
AI-assisted spam/scam moderation (AI Monitoring): Automatically flags and temporarily hides high-risk posts from general learner view pending human review (i.e. โsoft deletesโ); opt-in via feature toggles.
Learner mute/report controls: Enables learners to hide another userโs discussion content for themselves, reducing exposure to spam or harassment without requiring staff intervention. Learners can report others for potential bans, with course teams making the final decision.
Course ban controls: Similarly, staff can review reported messages and ban learners.
The features are opt-in, privacy-conscious, human reviewable (โhuman-in-the-loopโ), and compatible with existing moderation workflows.
2. Motivation and Problem Statement
2.1 AI-Assisted Moderation
At-scale Open edX deployments can experience persistent, adaptive spam and scams in discussion forums. Purely reactive strategies (manual moderation, keyword blacklists, CAPTCHA) create operational burden and lag behind adversaries. AI-assisted monitoring provides earlier detection, reduces learner exposure, and allows staff to focus on nuanced cases.
2.2 Learner Mute/Block
Even with staff moderation, learners may face harassment, repeated unwanted contact, or spam that slips through. A per-learner mute/block feature enables immediate self-protection and improves learning focus while preserving staff moderation for policy enforcement.
3. Goals and Non-Goals
3.1 Goals
AI Monitoring
Minimize learner exposure to likely spam/scams via near real-time temporary hides.
Provide a human review queue with restore/soft-delete actions.
Offer org/site-level opt-in toggles and a safe โshadow mode.โ
Learner Mute/Block
Allow learners to mute/block another learner so their posts are hidden or collapsed for the muter.
Provide clear affordances to unmute/unblock or show content temporarily.
3.2 Non-Goals
Automatic hard deletes by AI.
Configurable policy-builder UI for institutions (beyond enable/disable and thresholds).
Broad โtoxicityโ classification; focus is spam/scam.
4. Proposed Solution Overview
4.1 AI Monitoring Flow
Learner submits a thread/reply/comment.
Cheap, local triggers evaluate risk (links, contact patterns, velocity, etc.).
If triggered, system sends a minimal payload to a pluggable classifier.
Classifier returns a verdict. On โhide,โ post is hidden from other learners while visible to the author and moderators.
Moderators review and either restore or soft-delete; all actions are logged.
4.2 Learner Mute/Block Flow
Learner chooses โMute/Block userโ from a post or profile in Discussions.
Platform records a per-learner preference (course-scoped by default).
Rendering logic collapses/omits muted user content for that learner; muted user is not notified.
Learner can unmute/unblock at any time.
5. Detailed Specification
Implementation details map to the modern Discussions stack (MFE + backend services) and should be adapted as needed for legacy forums if required.
5.1 Feature Toggles and Configuration
DISCUSSIONS_AI_MONITORING_ENABLED(org/site): enables classification pipeline.DISCUSSIONS_AI_MONITORING_SHADOW_MODE(org/site): log-only classification; do not hide.DISCUSSIONS_AI_MONITORING_HIDE_ENABLED(org/site): enforce hides from learners.DISCUSSIONS_LEARNER_MUTE_ENABLED(site): enable learner mute/block UI and APIs.
All toggles should follow OEP-17 guidance (clearly documented owner, default off, explicit cleanup plan).
5.2 Trigger Heuristics
High author velocity (e.g., more than 5 posts in 24 hours).
Presence of external links or URL shorteners.
Contact info patterns (phone, WhatsApp, Telegram, email obfuscations).
Impersonation-like usernames (e.g., โedX staff,โ โcourse_adminโ).
Configurable suspicious keyword list.
If no trigger matches, skip classification to minimize cost and latency.
5.3 Classifier Interface (Pluggable)
Introduce a provider abstraction with a standard API:
POST /api/discussions/moderation/classify
{
"post_id": "uuid",
"course_id": "course-v1:Org+Num+Run",
"org": "Org",
"user_id_hash": "sha256(...)",
"content_text": "Post content (truncated as needed)",
"links": ["example.com", "t.me/..."],
"metadata": {"client_version":"...", "lang":"..."}
}
Response:
{
"verdict": "allow" | "hide",
"confidence": 0.0-1.0,
"reasons": ["link_farm","contact_info"],
"classifier_version": "vX.Y"
}Backends: external LLM API, in-house model, or rule-only fallback. Institutions can disable or select providers via settings.
5.4 Post Hiding Semantics
Hidden posts are not shown to learners other than the author.
Authors see their own post with a neutral banner (e.g., โUnder reviewโ).
Moderators/staff see full context and can restore or soft-delete.
Hidden state is reversible; no hard deletes by AI.
5.5 Moderator Review Queue
Filtering by course, date, confidence, trigger reason, and author.
Batch actions for restore and soft-delete.
Context view (thread lineage, author history, prior flags).
Action logging with actor, decision, timestamp, reason codes.
5.6 Learner Mute/Block Data Model
Table schema:
(muter_user_id, muted_user_id, course_id, created_at).Scope: default course-scoped. Consider optional site-wide scope later through settings.
Constraints: unique key on (muter, muted, course_id) to prevent duplicates; soft-delete for reversibility.
5.7 UI Behavior and Accessibility
Mute/Block action accessible from post overflow menu and profile cards.
Muted content is collapsed with โShow postโ and โUnmuteโ options.
Respect in-thread and list views; ensure consistent behavior in notifications.
Keyboard navigable controls; clear labels and status messages for assistive tech.
5.8 API Surfaces and Permissions
POST
/api/discussions/v1/mutes/: body {muted_user_id, course_id}; authenticated learner; idempotent.DELETE
/api/discussions/v1/mutes/{muted_user_id}?course_id=...: unmute.GET
/api/discussions/v1/mutes?course_id=...: list muted users for current learner.GET
/api/discussions/v1/moderation/queue: staff-only; paginated queue of AI-hidden posts.POST
/api/discussions/v1/moderation/{post_id}/restoreand/soft_delete: staff-only.
If scopes are used, align with OEP-4; otherwise, use role checks consistent with Discussions APIs.
6. Privacy, Legal, and Security
6.1 Data Minimization and Redaction
Send only essential fields to classifiers; hash user identifiers.
Redact or mask emails/phones before external transmission when feasible.
Truncate long content and exclude attachments.
6.2 PII Handling and Auditing
Document data flows per OEP-30; mark fields containing PII.
Maintain audit logs for classification calls and moderator actions.
6.3 External Provider Use
Require contractual guarantees: no training on customer data, retention limits, SOC2/ISO controls.
Provide admin controls to disable or run shadow mode.
6.4 Abuse and Adversarial Risks
Do not expose granular detection reasons in learner UI.
Rate-limit classification calls; circuit-break on provider errors.
Monitor false-positive rates and adjust thresholds.
7. Backwards Compatibility
When toggles are off, behavior is unchanged.
New hidden state is ignored by legacy UIs unless enforcement is enabled.
Mute/block is additive and limited to personal visibility; no impact on roles/permissions.
8. Observability and Metrics
AI Monitoring: classification rate, hide rate, moderator restore vs. delete, latency percentiles, provider error rate, cost per 1k posts.
Mute/Block: adoption rate, unmute rate, effect on report/spam flags, support contacts related to harassment.
9. Rollout Plan
Develop feature flags, APIs, and minimal UI; add unit/integration tests.
Enable shadow mode on a small set of courses/orgs; collect metrics and tune triggers.
Enable hide enforcement for pilot orgs; closely monitor false positives and learner feedback.
Gradually expand opt-in availability; publish documentation and admin guidance.
Reassess defaults and consider deprecating shadow mode after maturity.
10. Alternatives Considered
10.1 Rules-Only Filtering
Pros: simple, low cost; Cons: high evasion risk, ongoing maintenance, poor generalization.
10.2 Always-On Classification
Pros: uniform coverage; Cons: cost, latency, privacy exposure. Decision: trigger-gated classification.
10.3 Learner โBanโ vs. โMute/Blockโ
Platform-wide โbanโ by learners invites abuse and retaliation. Decision: per-learner mute/block for visibility control; staff retain ban/suspension tools.
11. Risks and Mitigations
False positives hide legitimate posts: conservative triggers, shadow mode, easy restore, ongoing threshold tuning.
Posting latency increases: async classification, optimistic UI, fast-path allows, short timeouts.
Privacy concerns: minimize/redact content, provider contracts, clear opt-out.
Moderator workload spikes: batch actions, filters, triage heuristics, alerting only on confidence thresholds.
12. Open Questions
Exact Discussions surface(s) targeted: legacy forums, modern MFE, or both?
Terminology preference: โmute,โ โblock,โ or โignoreโ per community norms?
Initial classifier backend and configuration strategy?
13. Implementation Notes
Repositories likely touched: Discussions MFE, Discussions backend service or edx-platform APIs, IDA settings/config.
Database migrations: new table for mute relationships; new post-state field for โhidden_by_ai.โ
i18n: new strings for banners, actions, and accessibility labels.
Docs: admin guide for toggles; moderator guide for the review queue; learner guide for mute/block.