What an AI knowledge base is
The phrase used to mean a help centre: articles written for people to browse. A knowledge base for AI is the machine-facing version. Its content is the same kind of material, docs, policies, product pages, manuals, but it is stored as clean text, split into retrievable chunks, and indexed so a program can ask a question and get back the passages that answer it.
It is also more than a vector database. A vector database is one component; a knowledge base also holds the source pages and their URLs, a keyword index, the ingestion jobs that fill it, and some way to keep it current.
A knowledge base is not a thing you build. It is a thing you keep, and the keeping is most of the cost.
How one is built
- Collect: crawl websites, upload files, connect sources.
- Convert everything to one clean format, usually markdown.
- Deduplicate: normalise URLs, hash content, filter near-duplicates.
- Chunk and embed each document.
- Index for keyword and vector search.
- Refresh incrementally, re-processing only what changed.
The first five steps happen once per document; the last one never stops. A docs site changes weekly, and a knowledge base that rewrites everything nightly is slow and expensive, while one that never refreshes drifts. Hashing each page's extracted text and re-processing only pages whose hash changed turns refresh from a job proportional to the corpus into one proportional to what changed.
Common mistakes
- Ingesting everything. Tag archives, changelogs and old doc versions crowd out the pages that matter. Three versions of every page means two wrong answers per question.
- Building once. A knowledge base that is never refreshed answers confidently about last year's product.
- Skipping the negative test. Ask something you know is not in it. If it answers anyway, add a confidence check.
- Ignoring documents. Real corpora are half web pages and half PDFs and Office files.
- Unclear data handling. Know where the content is stored, who can query it and whether a vendor trains on it.
- No provenance. Every chunk should carry its source URL or file, so answers can cite it and a wrong answer can be traced back to the document that caused it.
How SarvCrawl handles it
In SarvCrawl the knowledge base is the core object. You fill it by crawling or scraping sites and uploading PDF, Office, EPUB, image and audio files; every item is converted to markdown, chunked on headings, embedded and indexed. You query it with keyword, semantic or hybrid search (paid plans) over REST, the sarvcrawl Node and Python SDK, the sarv-kb CLI, an n8n node, or 21 MCP tools from Claude Code, Cursor and VS Code.
Content exports as JSONL or CSV, and we do not train models on customer content. Text is metered at roughly 500 tokens per page, and new accounts get 1 billion tokens free with no card. A worked example: build a RAG knowledge base from a documentation site.
Frequently asked questions
What is the difference between a knowledge base and a vector database?
A vector database stores and searches embeddings. A knowledge base is the whole system around it: source documents, chunking, keyword and vector indexes, ingestion jobs and refresh.
How do I keep an AI knowledge base up to date?
Re-crawl incrementally. Hash each page's extracted text, compare it with the last run, and re-chunk and re-embed only pages that changed.
Can an AI knowledge base include PDFs and scans?
It should. Text PDFs can be parsed directly and scanned PDFs need OCR first; both end up as text that is chunked and indexed with everything else.