Библиотека / RAG и базы знаний
RAG и базы знаний
Ответы на вопросы в чате поддержки по загруженным документам с помощью OpenAI и вебхука
Индексирует загруженные PDF, CSV и текстовые файлы во векторное хранилище в памяти, затем отвечает на каждое сообщение чата, отправленное на вебхук, с помощью OpenAI, сохраняя историю сеанса.
Что делает
# Support chatbot answering from your own documents A chat API that answers customer questions from files you upload. Ask it anything over your PDFs, CSVs or text files and it replies in a natural conversation, remembering what was said earlier. Point a website widget, WhatsApp bot or app at the webhook and it just works. ### How it works 1. You upload documents through a simple form. They are split, embedded with OpenAI and held in an in-memory vector store. 2. A webhook receives each chat message along with a session ID, protected by header authentication. 3. The support agent answers common questions straight from its system prompt. For anything specific it calls a second agent that searches the uploaded documents and hands back only the facts it found. 4. Conversation memory keeps the last 15 messages per session, so follow-up questions and multi-step requests work naturally. 5. The reply is formatted and returned to whatever sent the message. ### Setup 1. Add your OpenAI API key to the three model and embedding nodes. 2. On the Receive chat message node, create a header auth credential. Your chat app must send that same header and secret. 3. Open the Support agent node and replace every bracketed placeholder in the system prompt with your own company details. 4. Activate, open the form URL, upload your documents, then POST to the webhook with a JSON body containing message and session_id. ### Customization The in-memory store is cleared whenever n8n restarts, so re-upload after a restart. For permanent storage, swap both vector store nodes for Pinecone, Qdrant or Supabase.
Шаги
- Upload files to the knowledge base
- Embeddings - OpenAI
- Data Loader - Split uploaded files
- Store documents in vector store
- Search knowledge base
- Chat model - Knowledge base agent
- Receive chat message
- Support agent
- Chat model - Support agent
- Conversation memory
- Knowledge base agent
- Send reply
- Format reply
Похожие автоматизации
Поддержка клиентов и служба помощиОтветы на вопросы поддержки в Telegram с Gemini и SupabaseШагов: 13RAG и базы знанийДобавление цитат в ответы OpenAI по файламШагов: 12RAG и базы знанийОтветы на вопросы по документам с OpenAI и Pinecone RAGШагов: 24RAG и базы знанийСоздание RAG-чатбота по файлам Google Drive с OpenAI и PineconeШагов: 20