ALL WORKFLOWS
RAG · Chat

Knowledge-grounded chat agent

Two flows working together. The retrieval flow runs on every user message — looks up relevant docs, recalls prior conversation, and generates a grounded answer. The ingestion flow runs whenever the knowledge base needs an update — pulls files from Drive, chunks them, and writes the vectors to Supabase.

Flow 1 of 2 · Ingestion

Building the knowledge base

Runs manually (or on a schedule) when the knowledge base needs new content. Pulls a file from Drive, chunks it cleanly, embeds it with Gemini, and writes the vectors to Supabase pgvector.

workflow · rag ingestion
triggerfileExecute manuallytriggerDownload fileGoogle DriveVector StoreSupabase pgvectorEmbeddingsGoogle GeminiData Loaderchunk + clean
Trigger a knowledge refreshstep 1 / 5
Flow 2 of 2 · Retrieval

Answering a user message

Runs on every chat turn. The agent loads prior conversation, retrieves the most relevant docs from the vector store, and generates a grounded answer.

workflow · rag retrieval
messageresponseChat messageuser inputAI AgentorchestrationSend responseto userChat ModelOpenRouterChat MemoryPostgresKnowledge BaseSupabase VectorEmbeddingsGoogle Gemini
User sends a messagestep 1 / 7
live on this site

This one isn't a demo. It's running right now.

The chat bubble in the corner of this site is this exact workflow — an n8n RAG agent answering from LazyLoop's own knowledge base. Ask it about pricing, timelines or what's automatable.

Stack in this flow
n8n
Orchestration backbone
Supabase
Postgres + pgvector for memory
OpenRouter
Routed access to GPT-4, Claude, etc.
Gemini
Text embeddings for retrieval
Google Drive
Source-of-truth document store
Telegram
Output channel (or Slack, email, SMS)

What makes it production-ready

01

Retrieval-grounded answers

Every reply is anchored to a real document in your knowledge base — no hallucinations, no stale facts.

02

Stateful conversations

Postgres-backed memory means the agent remembers prior turns, customer context, and unresolved threads.

03

Swappable LLM

Routed through OpenRouter so you can A/B Claude vs GPT-4 vs Llama without touching the workflow.

04

Production-grade

Error retries, structured logging, rate limits, and graceful human hand-off when the agent isn't confident.

Want one built for you?
I build workflows like this end-to-end — scoping, infrastructure, agent prompt, evals, the lot.
Start a build