Detect contract compliance violations with Notion, Google Sheets and Groq
Ready for 3.0What this workflow does
This AI workflow has 14 nodes and runs on a schedule (every day at 06:00). Along the way it connects Notion, Google Sheets and Groq Chat Model.
How it runs
Trigger: On a schedule (every day at 06:00).
- Fetch Active Contracts (Notion): get many (database page)
- Fetch Recent Transactions (Google Sheets): uses Google Sheets
- Compare Terms vs Actuals (Code): runs custom JavaScript code
- Violation Detected Router (If): checks a condition and branches into true / false
- Fetch Violation History (Google Sheets): uses Google Sheets
- Log Compliant Transactions (Google Sheets): append
- Analyze Trends & Leakage (Code): runs custom JavaScript code
- Batch Current Violations (Loop Over Items (Split in Batches)): loops over the items in batches
- AI Analysis Chain (Basic LLM Chain): sends a prompt to an LLM, with model: Groq Inference Engine; output parser: Enforce JSON Schema
- Extract AI Recommendations (Edit Fields (Set)): sets 3 fields: action_category, urgency, recommendation
…plus 1 more step. See the full node list below.
Services it uses
Other Groq + Google Sheets templates (156) · Other Notion + Google Sheets templates (87) · Other Groq + Notion templates (26)
Before you upgrade to n8n 3.0
Nothing in this workflow is removed in n8n 3.0, so it should import and run after the upgrade.
- Code node: the task timeout drops from 300s to 60s. Test with a realistic data volume.
Nodes used (10)
- Schedule Trigger
n8n-nodes-base.scheduleTrigger - Notion
n8n-nodes-base.notion - Google Sheets
n8n-nodes-base.googleSheets - Code
n8n-nodes-base.code - If
n8n-nodes-base.if - Loop Over Items (Split in Batches)
n8n-nodes-base.splitInBatches - Basic LLM Chain
@n8n/n8n-nodes-langchain.chainLlm - Groq Chat Model
@n8n/n8n-nodes-langchain.lmChatGroq - Structured Output Parser
@n8n/n8n-nodes-langchain.outputParserStructured - Edit Fields (Set)
n8n-nodes-base.set
From the author
Quick overview This workflow runs daily to compare procurement transactions in Google Sheets against active contract terms stored in Notion, flags pricing/SLA/volume violations with calculated leakage, and uses Groq LLM analysis to generate corrective…