Skip to content

What is an AI knowledge base, and how do you ask questions of your own documents?

By Daniel Stoffels

Short answer

An AI knowledge base combines a search of selected documents with an answer expressed in natural language. Retrieval-Augmented Generation searches for relevant passages and provides them to the language model as a basis; reliable use requires source references, document-level permissions, current versions and tests with known answers.

Key points

  • The answer should lead back to identifiable source passages and explicitly identify missing evidence.
  • Good retrieval and good wording are separate capabilities that are tested separately.
  • Permissions must apply when documents are retrieved, rather than being introduced only in the answer text.
  • Current rules, older versions and conflicting documents need a clearly identifiable order.
  • A shared project can bring team knowledge together, but replaces neither maintenance nor approval by a subject specialist.
From question to evidenced answer

Definition

An AI knowledge base is a selected collection of documents with a search and answer function based on a language model. Retrieval-Augmented Generation, or RAG, is the process of first retrieving relevant content and then using it as context for an answer.

How a question becomes an answer grounded in sources

From question to evidenced answer: the question directs the search, the search provides relevant passages, and relevant passages support the answer.

Imagine a finance team with approved process descriptions, KPI sheets and closing instructions. Someone asks: which documents are needed to approve a provision? The search should provide relevant passages from the designated documents. The language model uses them to formulate a clear answer. Whether it is technically correct depends on whether the right passages were found and accurately represented.

Documents are often divided into smaller sections for retrieval. Alongside words, semantic methods can be used to recognise similarity in meaning. An embedding is a numerical representation of text that allows such similarities to be compared. The search can therefore also find passages that use different words from the question. A similar text is not, however, necessarily an authoritative source.

The retrieved sections are provided to the model together with the question and the rules for answering. This adds to the context; it does not automatically train the model on the document collection. The answer should contain only statements supported by this basis. Where the collection does not allow an answer, a clear indication of missing knowledge is better professional practice than a general addition from the model.

Two types of error need to be distinguished: the search fails to find an important passage, or the model misrepresents a passage it has found. A third difficulty lies in the collection itself: an outdated instruction can be found correctly and summarised correctly and still be the wrong basis for action. Testing and maintenance must therefore consider retrieval, answers and source quality separately.

Source references must support the specific statement

A source reference needs more than a file name. The document title, version and specific location, such as a section or page, are useful. Text recognition must be checked for scanned documents. A misread negative can reverse the meaning of a rule. In tables, column headings, units and the relationships between rows are particularly important.

The reference should lead directly to the supporting passage. Check a sample to see whether it actually says what the answer claims. A correct reference on a similar topic is not evidence for the specific statement. Assign a supporting source to each material statement rather than simply appending a list of documents.

Where documents conflict, the tool should show the contradiction and identify the versions. An answer that silently mixes them can create a rule that appears in no document. Define which types of approved document are authoritative and who resolves conflicts. The AI should apply this order, but should not decide for itself which subject-matter rule should apply in future.

Preserve access rights for each document

Shared search access must not mean that everyone can see everything. Assign authorised people or groups to documents. These permissions must take effect before content is provided to the model. If unauthorised content has already entered the context, an instruction such as ‘do not disclose’ comes too late to serve as the sole control.

Check derived content too: search results, summaries, saved answers and conversation histories can contain information from protected documents. Revoked document access must therefore be taken into account in the further handling of this content. The functions the tool offers for this need to be tested specifically. A role name in the interface does not in itself demonstrate an effective restriction.

Before including documents, establish whether they may be used for this purpose. Contractual confidentiality, personal data and internal approvals are separate questions. Freely chosen documents with known answers may suffice for an initial test. A demonstration that produces substantively correct results is not permission to then include any company documents in the same process.

Keep knowledge current and organise team memory

Each authoritative document needs a responsible person, an approval status and an indication of its validity. A new version triggers an identifiable update to the search. Afterwards, check whether the old version still appears as the current rule. An updated document is not yet an updated basis for answers until the search processing has caught up.

A project workspace can bring together documents, shared instructions and confirmed decisions. It serves as a team's memory when important content is retained in an organised form and reused for new tasks. A long conversation history alone does not fulfil this function. Decisions on subject-matter issues belong in approved, findable documents rather than remaining among discarded drafts.

Search, stored context and permissions also vary with the design of project features in particular products. Check which content actually goes into an answer and which users can use it. The label ‘project’ implies neither complete memory nor document-level permission checks. Describe the observed function before the team builds its workflow around it.

Maintenance starts with frequent questions. If several people are searching for the same unclear part of a process, the responsible subject specialist should improve the source. Saving the improvement only in a personal answer does not help the next user. A defined route from incorrect answers back to corrected documents prevents the knowledge base from repeating the same mistake.

Trial a knowledge base step by step

  1. Limit the questions and document collection

    Start with a clearly defined subject area and the documents approved for it. Collect questions the team actually needs to ask. Define which decisions an answer may help prepare and when review by a subject specialist remains necessary.

  2. Prepare sources and assign permissions

    Remove duplicate versions and mark drafts, archive material and current rules. Check readability and document structure. Assign responsibility and access to each document. Uncertain documents are clarified before they serve as authoritative knowledge.

  3. Define rules for answers

    Require specific source passages, visible contradictions and an indication when evidence is missing. Document texts remain source material. Instructions contained in them must not change the search permissions or the tool's task. Test this boundary with a suitable counterexample.

  4. Test known questions and counterexamples

    Write down the correct answer and its authoritative source location before the test. Add questions without an answer, questions about old versions and unauthorised access attempts. Assess correct statements and appropriate non-answers separately.

  5. Connect use and maintenance

    Collect missing or incorrectly evidenced answers with document references. Assign their resolution to the responsible subject specialist. After a correction, test the affected questions again. Record the tested versions of the collection and tool.

Evaluate test results by error type

The round case numbers are illustrative. Four groups of 10 questions each produce 40 tests. A test passes only if the content, source reference and intended access boundary are correct. For a question without a suitable source, an explicit non-answer is the expected result. The overall pass rate is 36 ÷ 40 = 90 per cent.

The rate alone is not sufficient for acceptance. Three errors concern the selection of the current version and one concerns handling missing knowledge. Both groups need targeted improvements and retesting. The passed permission cases are an important finding for the tested configuration, but do not provide general proof for every possible access attempt.

Example: testing a knowledge base with known answers

Table scrolls sideways

Case groupTestsPassedFailedExpectation
Unambiguous current source10100Answer with a relevant source location
Old and new version1073Use the current rule
No suitable source1091Identify missing evidence
No document permission10100Do not provide protected content
Total40364Assess results by error type

Typical errors and limitations

The verification criterion is: an authorised user receives a technically correct answer to a known question, with a supporting current source location. Where knowledge or permission is missing, the relevant boundary is maintained in search results and subsequent answers too.

  • Including the entire file collection without checking it: start with approved knowledge and clarified versions. More documents can multiply contradictions and outdated rules.
  • Believing source references without checking them: open the source location and compare the specific statement. A source that sounds similar is not enough.
  • Setting permissions only in the answer: restrict retrieval itself and check derived content. A language instruction does not replace technical access control.
  • Treating maintenance as a one-off import: name those responsible for changes and queries. After an update, the search must use the same version.
  • Turning document search into a reconciliation of figures: calculate and check financial values using a suitable method. A retrieved figure may refer to a different period or definition.

Frequently asked questions

Is RAG a form of model training?

RAG provides retrieved content as context. It does not require training on the document collection. The processing and storage performed by a specific tool are assessed separately using its functions and terms.

Can the knowledge base work with scanned PDFs?

If the text is made accessible through text recognition. Check reading errors, tables and page references. Numbers, negatives and ambiguous layouts in particular can lead to incorrect answers.

Is every answer with a source reliable?

No. The source may be outdated, may not support the statement or may be misrepresented. Reliability comes from suitable sources, appropriate retrieval, accurate representation and review by a subject specialist appropriate to the decision.

What happens when manuals conflict?

The contradiction is displayed with the affected versions. A named subject specialist clarifies the valid rule and corrects the collection. The tool must not assemble a new binding rule from conflicting passages.

Is the method suitable for current bank balances?

A document search alone does not establish a current bank balance. This requires a suitable data connection with a checked update status and appropriate permissions. Historical figures in a manual remain historical figures.

Sources

Last updated:

Lewis et al. (2020), original paper on Retrieval-Augmented Generation (arXiv:2005.11401); general specialist knowledge of source verification and organisational knowledge management

Summary by Heldensystem

Related questions

Next step

Free initial call, 30 minutes