Automation Lab

Automation Lab

Production workflows and AI agents built in n8n. Every one of these replaced something a person used to do by hand.

Production document AI pipeline2026

Smart Scanner Extraction Pipeline

The production pipeline behind Smart Scanner. Every invoice — photo or PDF — is verified as a real invoice, parsed with GPT-4.1 Vision, validated, deduplicated, and persisted. It reads Arabic, English, and mixed documents, and is tuned for handwritten Arabic invoices and ZATCA e-invoice fields.

  • Rejects any file that is not a genuine invoice, before anything is saved
  • Extracts 70+ fields plus line items: vendor, buyer, totals, VAT, dates
  • Classifies every line item into per-company expense categories at extraction time
  • Refuses politely and explains why when required data is missing — accuracy before speed
Outcome
Manual invoice entry disappears entirely; a photo becomes structured accounting data in about ten seconds.

Scheduled agent with human-in-the-loop2026

AI Job-Match Pipeline

A scheduled pipeline that runs five daily search queries across LinkedIn, Indeed, and Glassdoor, scores each role's fit from one to ten with a structured-JSON LLM evaluator, and delivers only the high scorers.

  • Structured-JSON evaluator scoring fit on a 1–10 scale
  • Deduplication against n8n Data Tables so nothing is seen twice
  • Telegram delivery of high-scoring matches only
  • Human-in-the-loop approval before any application is sent
  • Semi-automated applications with tailored AI-generated cover letters via Gmail
Outcome
Daily job hunting collapses into reviewing a short, pre-scored shortlist.

Scraping and enrichment pipeline2025

Smart Lead Finder

Automated B2B lead generation across the Saudi and Jordanian markets: multi-query place search, website scraping to extract emails and WhatsApp numbers, prioritisation scoring, and duplicate-safe appends into segmented sheets.

  • Multi-query place search across two markets
  • Extracts emails and WhatsApp numbers from company websites
  • Prioritisation scoring so the best prospects surface first
  • Duplicate-safe appends into segmented sheets
Outcome
Manual prospect research became a hands-off scheduled pipeline producing scored, deduplicated lead lists.

Video-to-data webhook service2026

Lesson Quality Evaluator

A webhook service that transcribes lesson videos with speaker separation and returns structured JSON scoring teacher quality and student engagement.

  • Speaker diarization separates teacher from student
  • Structured outputs guarantee a parseable result every time
  • Returns a score, not a transcript — the caller gets data, not homework
Outcome
Lesson review becomes measurable instead of anecdotal.

Data quality pipeline · proof of concept2026

CRM Lead Cleaner

Incoming CRM leads arrive scattered — duplicates, malformed emails, missing fields — and cost sales teams hours of manual triage. This pipeline cleans them automatically and reports on what it did.

  • Removes duplicates and validates email addresses
  • Flags missing fields rather than silently dropping records
  • Splits results into Clean and Rejected, with a reason on every rejection
  • Produces a quality summary after each run
Outcome
Designed to plug straight into a CRM, turning hours of manual triage into a summary line.

A case study in cost: one branch, three quarters saved

  • $0.02 per PDF, vision model
  • $0.005 per PDF, text model
  • 75% cut per document
Webhook — file arrives PDF with extractable text?
  • Yes Text model reads it $0.005
  • No Vision model sees it $0.02
Extraction came back empty? The PDF was only a scan — send it back to the vision branch.

1,000 receipts a month, half PDF, half photos $20 $12.50

  1. The mistake in my first workflow was sending every file that arrived at the webhook straight to a vision model. It worked. It also cost roughly three times more than it needed to.

  2. The reason is simple: a PDF usually already contains readable text. A vision model does not need to look at the page when a text model can read it — and reading costs a fraction of seeing.

  3. The fix was a single branching decision placed just after the webhook: if the file is a PDF with extractable text, send the text to a text model; otherwise send the image to the vision model. The per-document cost dropped by about three quarters.

  4. One detail matters more than the branch itself: always keep a fallback. If text extraction returns empty — because the PDF is really just a scanned image — the file has to go back to the vision branch. Without that, the cheap path silently produces nothing.