Saltar al contenido principal

Clasificar Mensaje Publicitario de Twitch

Workflow usado por el bot moderador de Twitch para clasificar mensajes publicitarios de venta de espectadores, venta de suscriptores y similares como spam, y luego emitir el veredicto de moderación como texto de conversación.

workflow manual llm structured-output twitch moderation spam

Descargar ZIP

Qué está incluido

CampoValor
NombreClasificar Mensaje Publicitario de Twitch
TipoWorkflow
Triggermanual
Pasos2
Entradas2

JSON Completo

Clic para expandir
{
"description": "Workflow used by the Twitch moderator bot to classify spammy viewer-selling, subscriber-selling, and similar advertising messages, then emit the moderation verdict as conversation text.",
"tags": [
"workflow",
"manual",
"llm",
"structured-output",
"twitch",
"moderation",
"spam"
],
"linkedExamples": [
{
"type": "agents",
"variant": "twitch-bot-assistant-moderator",
"relationship": "Companion Twitch bot agent routes non-command chat messages into this workflow for moderation."
}
],
"document": {
"name": "Classify Twitch Advertising Message",
"enabled": true,
"log_level": "info",
"trigger": {
"type": "manual"
},
"workflowInput": [
{
"name": "twitch_username",
"description": "Twitch username that sent the chat message",
"schema": {
"type": "string",
"required": true,
"enableEnums": false,
"enum": []
}
},
{
"name": "twitch_message",
"description": "Raw Twitch chat message text to classify",
"schema": {
"type": "string",
"required": true,
"enableEnums": false,
"enum": []
}
}
],
"steps": [
{
"condition": {
"expr": "true",
"onFailure": "throw",
"fallback": "",
"resultType": "any",
"strict": false,
"useSimpleCel": false
},
"action": {
"actionType": "actions/ai/llm/chat/generate",
"actions/ai/llm/chat/generate": {
"is_advanced": true,
"platform": "openai",
"model": "gpt-4.1-mini",
"temperature": 0,
"max_tokens": 400,
"enable_structured_outputs": true,
"structured_output_schema_name": "output",
"structured_output_schema": {
"expr": "{\n \"type\": \"object\",\n \"description\": \"Classify Twitch chat for moderation.\",\n \"additionalProperties\": false,\n \"required\": [\"is_advertising\", \"confidence\", \"category\", \"reason\", \"signals\"],\n \"properties\": {\n \"is_advertising\": { \"type\": \"boolean\" },\n \"confidence\": { \"type\": \"number\", \"minimum\": 0, \"maximum\": 1 },\n \"category\": {\n \"type\": \"string\",\n \"enum\": [\"viewer_advertising\", \"bot_spam_advertising\", \"not_advertising\"]\n },\n \"reason\": { \"type\": \"string\", \"minLength\": 1, \"maxLength\": 200 },\n \"signals\": {\n \"type\": \"array\",\n \"items\": { \"type\": \"string\", \"minLength\": 1, \"maxLength\": 80 }\n }\n }\n}",
"onFailure": "fallback",
"fallback": "",
"resultType": "any",
"strict": false,
"useSimpleCel": false
},
"messages": [
{
"role": "user",
"content_type": "text",
"audio_format": "mp3",
"content": {
"expr": "'You classify Twitch chat for moderation. Return ONLY valid JSON with exact keys: is_advertising (boolean), confidence (number from 0 to 1), category (viewer_advertising|bot_spam_advertising|not_advertising), reason (short string), signals (array of short strings). Mark as advertising for promotions, self-promo, follower/follow-back, links, codes, giveaways, paid offers, suspicious repetitive spam, or DM bait. If uncertain, return not_advertising with lower confidence. Do not include markdown code fences.'",
"onFailure": "fallback",
"fallback": "",
"resultType": "any",
"strict": false,
"useSimpleCel": false
}
},
{
"role": "user",
"content_type": "text",
"audio_format": "mp3",
"content": {
"expr": "'Twitch username: ' + twitch_username + '\\nMessage: ' + twitch_message",
"onFailure": "fallback",
"fallback": "",
"resultType": "any",
"strict": false,
"useSimpleCel": false
}
}
]
}
}
},
{
"condition": {
"expr": "true",
"onFailure": "throw",
"fallback": "",
"resultType": "any",
"strict": false,
"useSimpleCel": false
},
"action": {
"actionType": "actions/messaging/conversation/response/compose",
"actions/messaging/conversation/response/compose": {
"messages": [
{
"type": "text",
"payload": {
"text": {
"expr": "json_stringify(get(step(0), 'choices.0.message.content.is_advertising'))",
"onFailure": "throw",
"fallback": "",
"resultType": "any",
"strict": false,
"useSimpleCel": false
}
}
}
]
}
}
}
],
"customAttributes": {},
"returnExpression": {
"expr": "\"\"",
"onFailure": "fallback",
"fallback": "",
"resultType": "any",
"strict": false,
"useSimpleCel": false
}
}
}

Como Importar

  1. Descargue el archivo ZIP usando el botón de arriba
  2. Navegue a Configuración de la Empresa → Transferencia de Datos en su panel de AutoTalk
  3. Haga clic en Importar y seleccione el archivo ZIP descargado
  4. Revise el resumen de importación y confirme
  5. Todos los IDs de documentos se remapean automáticamente — no se necesita edición manual de IDs