Bibliothek / Monitoring, Betrieb & Störungen
Monitoring, Betrieb & Störungen
Fehlgeschlagene n8n-Workflows mit Ollama diagnostizieren und Triage an Discord senden
Läuft als Fehler-Workflow für andere n8n-Workflows, ruft die fehlgeschlagene Ausführung ab, schwärzt Geheimnisse, lässt ein lokales Ollama-Modell sie diagnostizieren und postet einen Triage-Bericht an Discord.
Was sie bewirkt
## Diagnose failed n8n workflows with a local Ollama model and post to Discord ### Who's it for Anyone running n8n who gets failure alerts but still has to open the execution to work out what went wrong, and who wants that analysis to stay on their own hardware. ### How it works 1. Runs as the error workflow for your other workflows, as a sub-workflow called by an existing error handler, or from the test trigger. 2. Fetches the failed execution and the workflow definition through the n8n API. Trigger failures with no execution fall back to the error message. 3. Redacts tokens, JWTs, emails, keyed URLs and webhook URLs before anything reaches the model. 4. Skips repeats: the same workflow, node and error within dedup_hours is diagnosed once, so a failing schedule can't flood the channel. 5. A local model returns schema-checked JSON: what broke, likely cause, suggested fix, fix type, confidence and risk. 6. A Code node checks the model's labels, formats the message and posts it to Discord. Nothing is changed in the failing workflow. ### Setup - n8n API credential (Settings > n8n API) - Ollama reachable from n8n; set ollama_url and model in Build Config - A data table triage_history: text columns fingerprint, workflow_id, workflow_name, failed_node, error_message, execution_id, fix_type, and a date column diagnosed_at. Select it in both data table nodes. - A Discord webhook credential - Set n8n_editor_url, and add your error handler's ID to excluded_workflow_ids - Point workflows' Error workflow setting here, or call it from your error handler (companion template: *Send n8n workflow failure alerts to Discord*) ### Limits Only sees runs that fail. An expression that reads a missing field returns empty and the run succeeds, so add data checks for those. Nodes referenced with $(): Skip Excluded Workflows, Get Failed Execution, Redact and Build Context, Skip Repeat Failures, Format Diagnosis.
Die Schritte
- On Workflow Error
- Normalize Failure
- Test with Sample Failures
- Sample Failures
- Build Config
- Skip Excluded Workflows
- Get Failed Execution
- Get Workflow Definition
- Redact and Build Context
- Diagnose Failure
- Format Diagnosis
- Post Diagnosis to Discord
- Called by Error Handler
- Get Recent Diagnoses
Insgesamt 16 Schritte.
Ähnliche Automatisierungen
Monitoring, Betrieb & Störungenn8n-Workflow-Fehlermeldungen an Discord senden und in Data Table protokollieren7 SchritteChatbots & Messaging-BotsMit lokalen LLMs über n8n und Ollama chatten3 SchritteBerichte, Analysen & Dashboardsn8n-Creators-Leaderboard mit einem KI-Agenten analysieren27 SchritteKI-Agenten & Assistentenn8n-Creators-Leaderboard mit einem KI-Agenten abfragen27 Schritte