Automated Discord Spam Moderation with AI and Human-in-the-Loop — Workflow n8n

Élevé complexité Déclencheur23 nœuds🏷️ Miscellaneous👁 831 vuespar Jimleuk

Aperçu

This n8n template demonstrates how you can automate community moderation using human-in-the-loop functionality for Discord.

The use-case is for detecting and dealing with spam messages in a predefined and consistent way. Human-in-the-loop allows for a balance between overly aggressive bots and time and effort from the moderation team.

How it works A scheduled trigger is used to scan the most recent messages in a Discord Channel. Messages are tagged via the "Remove Duplicates" node so they don'

Nœuds utilisés

DiscordCodeOpenAI Chat ModelText Classifier

Aperçu du workflow

1. Get Channel Messages
Read more about the scheduled Trigger
The scheduled trigger is used to execute this w
2. Group Messages By User
Learn more about the loop node
When dealing with nested data such as user and messag
3. Spam Detection using AI-powered Text Class
[Learn more about the text classification node](https:/
5. Moderation using Human-in-the-Loop
Read more about n8n's human-fallback functionality
In this step, we can use the "Send and Wait for
6. Execute Moderation Actions
Learn more about the Discord node
Finally, moderation actions can be executed on behalf
4. Concurrent Processing using Subworkflows
Learn more about Subworkflow Trigger
One issue we might come acros
Try it out
This n8n template demonstrates how you can automate com
The use-case is for detecting and dealing with spam mes
model
Spam Detection
Get Recent Messages
O
Only Once
Model
Warn User
Warn User Only
Group By User
F
For Each User...
S
Split Out
Message to List
Notify Moderators with S…
F
Flag as Spam
F
Flag as Not Spam
M
Merge
S
Spam Messages Only
H
Has Flagged Messages?
Get Message IDs
Delete Messages
R
Receive Instructions
M
Moderation Subworkflow
W
When Executed by Another…
N
No Action Taken
S
Schedule Trigger
23 nodes24 edges

Comment ça fonctionne

  1. 1

    Déclencheur

    Le workflow démarre avec un déclencheur déclencheur.

  2. 2

    Traitement

    Les données transitent par 23 nœuds, connecting code, discord, executeworkflow.

  3. 3

    Sortie

    Le workflow termine son automatisation et livre le résultat à la destination configurée.

Détails des nœuds (23)

DI

Discord

discord

#1
CO

Code

code

#2
OP

OpenAI Chat Model

n8n-nodes-langchain.lmChatOpenAi

#3
TE

Text Classifier

n8n-nodes-langchain.textClassifier

#4

Comment importer ce workflow

  1. 1Cliquez sur le bouton Télécharger JSON à droite pour enregistrer le fichier du workflow.
  2. 2Ouvrez votre instance n8n. Accédez à Workflows → Nouveau → Importer depuis un fichier.
  3. 3Sélectionnez le fichier automated-discord-spam-moderation-with-ai-and-human-in-the-loop téléchargé et cliquez sur Importer.
  4. 4Configurez les identifiants pour chaque nœud de service (clés API, OAuth, etc.).
  5. 5Cliquez sur Tester le workflow pour vérifier que tout fonctionne, puis activez-le.

Ou collez directement dans n8n → Importer depuis JSON :

{ "name": "Automated Discord Spam Moderation with AI and Human-in-the-Loop", "nodes": [...], ...}

Intégrations

codediscordexecuteworkflowexecuteworkflowtriggerfilteriflmchatopenaimergeremoveduplicatesscheduletriggersetsplitinbatchessplitoutswitchtextclassifier

Obtenir ce workflow

Téléchargez et importez en un clic

Télécharger JSONVoir sur n8n.io
Nœuds23
Complexitéhigh
Déclencheurtrigger
Vues831
CatégorieMiscellaneous

Créé par

Jimleuk

Jimleuk

@jimleuk

Tags

codediscordexecuteworkflowexecuteworkflowtriggerfilteriflmchatopenaimergeremoveduplicatesscheduletrigger

Nouveau sur n8n ?

n8n est un outil d'automatisation de workflows gratuit et open-source. Hébergez-le vous-même ou utilisez la version cloud.

Obtenir n8n gratuitement →

Related Miscellaneous Workflows