Ask Steves · Daily notes · VPS, 20% off · AI Profit Lab · SEO · Money Hub

19 November 2026 · Practical AI builds

How do I build a chatbot that answers from my own files?

By the end of this you will have a small chatbot that reads your own documents, such as price lists, policies, manuals and FAQs, and answers questions from them. It also tells you which file each answer came from. It suits a small business, a freelancer or a small team that answers the same questions every week and wants the answers to match what is already written down.

I learn my automation tips in the AI Profit Boardroom. Have a look here. Affiliate link.

What you need

Step by step

  1. Write down 20 real questions that customers or colleagues ask, with the correct answer to each. These are your test, and you will use them all the way through.
  2. Gather the files and tidy them up. Remove old versions, drafts and anything private. The bot can only be as accurate as the files you give it.
  3. Try the quick route first. Upload the files to a project-style feature in an assistant you already use, tell it to answer only from those files, and ask your 20 questions. If it is only for you, this may be all you need.
  4. If other people need to use it, or it has to sit on your website, build it yourself. The usual method is called retrieval-augmented generation (RAG): find the passages that matter first, then give only those to the model.
  5. Turn each file into plain text and split it into chunks of a few hundred words. Keep the file name and the nearest heading with each chunk so the bot can say where an answer came from.
  6. Run each chunk through the embedding model. This turns the text into a list of numbers that captures its meaning. Save those in your vector store, and do it again whenever a file changes.
  7. When a question comes in, embed it the same way, pull back the five or so closest chunks, and send them to the model along with the question and a strict instruction.
  8. The instruction matters most. Tell the model to use only the passages, to say when it cannot find an answer, and to name its sources. A simple version is below.
  9. Ask your 20 test questions again and compare the answers with yours. If answers are weak, change the chunk size or the number of chunks, or fix the files themselves.
  10. Put it behind a simple web page and keep it private at first, either behind a login or on your own machine. Log every question and answer so you can check them.
You answer questions for sitename using only the passages below.
If the passages do not contain the answer, reply:
I could not find that in our documents. Please contact user@example.com.
Do not guess and do not use outside knowledge.
At the end of each answer, list the file names you used.

Passages:
{passages}

Question:
{question}

What good looks like

It gets most of your 20 test questions right and names the right file for each. When you ask something your documents do not cover, it says it could not find the answer instead of making one up. When you update a file and rebuild the store, the answers change to match. Your question log shows people getting answers without a follow-up message to you.

Watch out for

Accuracy. A strict prompt cuts down on made-up answers but does not stop them completely. Old or conflicting files also lead to confident wrong answers. Have a person check anything to do with prices, refunds, legal or health matters before anyone relies on it, and say clearly on the page that answers come from an AI.

Privacy. Whatever you put in, and every question people ask, is sent to the model provider unless you run the model yourself. Read the provider's data terms, and keep personal customer details out unless you are allowed to share them. A public chatbot can sometimes be talked into repeating anything in its files, so only include what you would be happy to publish.

Questions people ask

Do I need to train my own AI model?

No. With retrieval the model stays the same and reads the right passages fresh each time, so keeping it up to date just means replacing a file and rebuilding the store.

Can it read scanned PDFs or photos of documents?

Only after the text has been pulled out with OCR (optical character recognition). Check that text before you add it, because a misread number becomes a wrong answer.

To sum up: tidy your files, test with real questions, find the relevant passages and hand only those to the model with a strict instruction. Keep it private and checked by a person until the answers are reliable.

Want more automation tips? The AI Profit Boardroom on Skool is where I get mine. Have a look here. Affiliate link.

Related AI builds: How do I make an FAQ bot from my existing help docs? · How do I back up a small AI app and its data on a VPS? · How do I build a simple AI assistant for my team's shared documents? · All daily notes