Block 1 - Postgres PGVector Store2
- Type / Role
- @n8n/n8n-nodes-langchain.vectorStorePGVector - vectorStorePGVector
- Config choices
- Version 1.1
This workflow is provided as-is. Please review and test before using in production.
Description This workflow vectorizes the TUSS (Terminologia Unificada da Saúde Suplementar) table by transforming medical procedures into vector embeddings ready for semantic search. It automates t...
@n8n/n8n-nodes-langchain.vectorstorepgvector, @n8n/n8n-nodes-langchain.textsplittertokensplitter, @n8n/n8n-nodes-langchain.embeddingsgooglegemini, n8n-nodes-base.stickynote, n8n-nodes-base.manualtrigger, n8n-nodes-oracle-database-parameterization.oracle database with parameterization, n8n-nodes-base.code, n8n-nodes-base.splitinbatches
This workflow is cataloged by N8N Workflows and links back to its original n8n.io source page by Thiago Vazzoler Loureiro.
Original n8n.io sourceThis workflow vectorizes the TUSS (Terminologia Unificada da Saúde Suplementar) table by transforming medical procedures into vector embeddings ready for semantic search.
It automates the import of TUSS data, performs text preprocessing, and uses Google Gemini to generate vector embeddings. The resulting vectors can be stored in a vector database, such as PostgreSQL with pgvector, enabling efficient semantic queries across healthcare data.
Searching for medical procedures using traditional keyword matching is often imprecise. This workflow enhances the search experience by enabling semantic similarity search, which can retrieve more relevant results based on the meaning of the query instead of exact word matches.
You can adapt the preprocessing logic to your own language or domain-specific terms.
Swap Google Gemini with another embedding model, such as OpenAI or Cohere.
Adjust the chunking logic to control the granularity of semantic representation.
Prepare a source (database or CSV) with TUSS data. You need at least two fields:
CD_ITEM (Medical procedure code)
DS_ITEM (Medical procedure description)
Configure your Oracle or PostgreSQL database credentials in the Credentials section of n8n.
Make sure your PostgreSQL database has pgVector installed.
Replace the placeholder table and column names with your actual TUSS table.
Connect your Google Gemini credentials (via OpenAI proxy or official connector).
Run the workflow to vectorize all medical procedure descriptions.
This catalog entry is organized from the workflow JSON. The node-level section below shows the executable blocks available for review before importing the template.
| Workflow | Vectorize Medical Procedures for Semantic Search with TUSS, Gemini & pgVector |
|---|---|
| Complexity | intermediate |
| Nodes | 11 |
| Categories | Engineering, AI RAG |
| Author | Thiago Vazzoler Loureiro |
| Published | 27 Jul 2025 |
Use the JSON export at /data/workflows/6543/6543.json as the source template for this automation.
Open n8n, import the downloaded JSON, and review each node before activating the workflow.
Replace placeholder credentials, API keys, webhook URLs, account IDs, and environment-specific values with your own settings.
Run the workflow manually or in a staging workspace, inspect node output, and confirm downstream systems receive the expected data.
Enable the workflow only after testing, then monitor executions, errors, and rate limits during the first production runs.
Review imported nodes carefully before activation. This catalog entry is intended to help you inspect the workflow structure, understand required services, and find related templates faster.
Node names, credentials, schedules, webhook paths, and external service limits may need adjustment for your workspace.
Description This workflow vectorizes the TUSS (Terminologia Unificada da Saúde Suplementar) table by transforming medical procedures into vector embeddings ready for semantic search. It automates t...
Review the workflow JSON, configure any required credentials in n8n, and test the automation in a safe workspace before using it in production.
Yes. Use the block-by-block analysis and the downloadable JSON to inspect each node, then adjust credentials, prompts, schedules, filters, or destinations for your Engineering, AI RAG use case.