Automation library · Customer support

Answer HR questions with OpenAI and PostgreSQL

Started by another system calling it, and works across Pinecone and Postgres. It puts OpenAI behind a retrieval step, so answers are drawn from documents you supply rather than from the model alone. 26 steps, 5 branches: large, and worth reading before you trust it with anything live.

LargeCalls a model: OpenAIRetrieval

26 stepsLarge: read it before trusting it with anything live
5Branches: places the flow splits
0Loops or waits
2Services it connects to

The flow

Starts it 5Model 7Logic 11Service 3

The steps in the order they run, from what starts it.

  1. 1Webhook - HR Bot ChatWebhookStarts it
  2. 2OpenAI Model - TranslationLm Chat Open AiModel
  3. 3OpenAI GPT-4o-miniLm Chat Open AiModel
  4. 4PostgreSQL - HR Database ToolPostgres ToolService
  5. 5OpenAI EmbeddingsEmbeddings Open AiModel
  6. 6PostgreSQL Chat MemoryMemory Postgres ChatModel
  7. 7Validate Identity (Mobile/Email)IfLogic
  8. 8Translate to EnglishChain LlmModel
  9. 9HR Assistant AI AgentAgentModel
  10. 10Pinecone - HR Policy Knowledge BaseVector Store PineconeModel
  11. 11Check Audio InputIfLogic
  12. 12Error - Invalid Mobile/EmailRespond To WebhookStarts it
  13. 13Merge Translation ContextSetLogic
  14. 14Format Final ResponseCodeLogic
  15. 15ElevenLabs - Transcribe AudioEleven LabsService
  16. 16Validate MessageIfLogic
  17. 17Fetch Employee DataPostgresService
  18. 18Send Success ResponseRespond To WebhookStarts it
  19. 19Extract TranscriptSetLogic
  20. 20Parse Input & Detect LanguageCodeLogic
  21. 21Error - Invalid MessageRespond To WebhookStarts it
  22. 22Validate EmployeeIfLogic
  23. 23Needs Translation?IfLogic
  24. 24Merge Employee & Language ContextCodeLogic
  25. 25Error - Employee Not FoundRespond To WebhookStarts it
  26. 26Skip Translation (English)SetLogic

How it's built

Starts on
Another system calling it
Steps
26, with 5 branches
Size
Large: read it before trusting it with anything live
Connects to
Pinecone, Postgres
Model
OpenAI
Retrieval
Answers are drawn from documents you supply, not from the model alone

Questions

What does it need to run?

An n8n account, plus your own Pinecone and Postgres accounts, and a key for OpenAI. You connect your own accounts after importing it; none are included.

What starts it?

It starts on another system calling it.

Does it use AI?

Yes. It calls OpenAI. Its answers draw on documents you give it, not on the model alone. Model calls are billed by the provider, not by n8n.

How long does it take to set up?

Take your time. At 26 steps it is large: read it before trusting it with anything live.

How do I import it?

Copy the workflow, open a new workflow in n8n and paste. The steps appear on the canvas, ready for your own accounts.

Before you run it

Nothing here has been tested by us. It is somebody's working automation, read and described from its own steps. Treat the connections it wants as a list of accounts it will touch, and read the 26 steps before you point it at anything that matters.