How to Create an AI Assistant with a Knowledge Base (OpenAI Assistant)
OpenAI assistants on Latenode are primarily designed for building chatbots and advanced text-generation assistants that require specific behavior settings and the ability to maintain large information context (such as your internal documentation). They allow you to create intelligent assistants that can answer questions, perform tasks, and use external tools. With a built-in knowledge base (RAG), the assistant gains access to up-to-date information and context, making it much more useful.
Step 1: Create an Assistant in OpenAI
- Go to the OpenAI Playground. Here you'll see a list of your assistants (as you can see, I already have one)
- Click "Create Assistant".

- Give your assistant a name.

- Choose a model (I usually prefer
gpt-4o-mini
because it offers a good balance between cost and performance).

- Configure the system instructions — briefly explain how the assistant should act.

Let’s say we want to create a sales representative assistant.
Here’s a simple instruction example:
You are a helpful assistant for a sales representative.
Step 2: Add a Knowledge Base (RAG)
- In the "Files" section, enable the file search toggle to activate the storage functionality.

- Then click + Files

- Upload PDF, TXT, or other documents that contain important information (e.g., your documentation). For example, I’ll upload a file called
sales_assistant_instructions.txt

These files will be used via Retrieval-Augmented Generation (RAG) — the assistant will treat them as its memory.
Make sure your files are well-structured: use headings, bullet points, and logical sections.
Step 3: Test the Assistant
On the right side of the screen, you can test your assistant.

Let’s ask a question that pulls from the uploaded knowledge base.
Example:
Question: "Do we have any secret promo codes for important clients?"

As you can see, the assistant accessed the knowledge base and provided a correct answer.
And that’s it — you’ve created your first assistant with a knowledge base!
Getting the API Key
To get your assistant’s API key, go to the dashboard section where you'll find the API Keys tab.

Here, you can see all your keys and create a new one.

Select a project, name the key, and set the permissions.

Then copy your key and save it somewhere safe.

Connecting the Assistant on Latenode
Latenode offers many tools for fully remote management of your assistants, including creation, configuration, file updates, and more.

But to get started, the most basic and universal tool is Send Message to Assistant (Complete Flow).

Add it and authorize using your API key.

Then select the assistant you created, define the role (who the message is from), and enter your message (again, you can use the same test question).

Run the scenario and get the response.

Your assistant is working!
Each conversation with the assistant creates a "thread". If you specify an existing thread ID, the assistant will maintain the context of previous messages — which is essential for chatbot functionality.
💡 Useful Tips
- Regularly update your knowledge files when your product changes.
- Use FAQs or real user questions as the foundation of your knowledge base.
- Don’t overload the assistant with huge files — break them into topics.
Free Template
To learn how to create a simple chatbot with context support,

Thanks for reading!