
The ideas, evidence and practical work behind the demonstration.
A folder can hold years of documents while leaving the reasoning between them in someone’s head. Knowledge management is the work of capturing that reasoning, organising the material and keeping it reliable enough to use again.
A knowledge graph is one way to do this. It records things and the relationships between them, so a person or a computer can follow a connection from one piece of information to another.
A map of connected records
Imagine a section of legislation beside a definition it uses, a provision that qualifies it and a remedy that may follow a breach. A graph makes those connections explicit. You can start at a section and inspect the surrounding material without having to remember every cross-reference.
Give each thing an identity
A node is a record for something you want to keep track of. Here, each node represents one section of an Act. A unique identifier keeps section 9 of this Act separate from section 9 of another Act.
The example uses the express reference in Fair Trading Act 1986, section 5D(1). The official rendered page was checked on 18 November 2026. It carries a notice about unincorporated amendments.
The technical names are nodes for the records and edges for their connections. A statement such as “section 5D refers to section 9” has a subject, a relationship and an object. Several statements can share the same record, forming a network. The W3C’s RDF primer explains this approach to representing information.
The work around the graph
A useful knowledge system needs people to decide what belongs in it, who can see it and who is responsible for keeping it up to date. Open each part below.
CaptureKeep the source and the reason it matters.
Save the source document with its title, origin, date and version. Record the decision or observation it supports. Someone revisiting the record should be able to open the material that was actually used.
For a team, this might be a project decision linked to a meeting note and the policy considered. For legislation, it might be a section linked to the exact version of the Act.
ConnectUse names that explain each relationship.
Agree on the kinds of records and relationships you need. An ontology defines this shared vocabulary and the meaning of its relationships. For example, a section belongs to an Act, refers to another section, or uses a defined term. The W3C’s ontology primer explains how explicit meanings help people and software work consistently with the same information.
Keep an explicit reference separate from a reviewer’s interpretation. Both can be useful if the reader can see the basis of each.
Ontology and interpretation shows how those choices change what a reader, or an AI tool, takes from the same material.
RetrieveBring the supporting context into view.
Search finds a starting record. Following its saved connections brings in related material. A system can look one connection away, or follow a longer path within a stated limit.
The useful result includes the records found, why they were included and any gaps in coverage. The map only contains the connections someone has recorded.
MaintainAssign ownership, review changes and keep the history.
Give each collection an owner and a review schedule. When a source changes, retain the earlier version and identify the summaries and relationships that need another check.
For confidential information, apply access controls to the connected records and to the results returned from them. A relationship can itself reveal sensitive information.
Why AI makes knowledge management significant
A maintained knowledge collection gives an AI assistant sources to consult, connections to follow and evidence the reader can check. The benefit grows as the collection is reused across questions, people and tools.
Give the model useful material to work fromRefresh its sources without retraining it.
A large language model, or LLM, learns patterns during training and uses them to generate text. It may know a great deal about a subject. That does not establish that it has the exact document, the latest amendment or the context of your question. A fluent answer can still rest on an incomplete picture.
Knowledge management gives an AI application a maintained body of material it can consult. Your sources, decisions and relationships become reusable inputs to its work. As the collection improves, future questions can draw on that improvement without retraining the model.
The material supplied for a particular answer is called its context. This can include your question, relevant passages, definitions, source dates and instructions about the task. Finding useful evidence and supplying it to the model is called retrieval-augmented generation, usually shortened to RAG.
The original RAG research by Lewis and colleagues describes combining a trained language model with retrieved documents. Updating a retrieval collection and changing a model’s trained parameters are separate operations.
Why connections change the answerTry the same question with more of its context.
Information often gets its meaning from its surroundings. A definition sets the meaning of a word. An exception changes the reach of a rule. A date identifies the version being used. A source shows whether a statement is legislation, a summary or someone’s interpretation.
A search result can contain the right words while omitting one of those dependencies. A graph records the connections so the retrieval service can bring the relevant material together. The relationship also explains why another passage belongs in the context.
Research question: “A contract says the Fair Trading Act does not apply. What would I need to check?”
A relevant starting point
In the context bundle- FTA s 9: misleading and deceptive conduct
The assistant receives the selected section 9 excerpt and its source link. It has material about the general prohibition.
What this enables
It can identify the starting provision and explain the words supplied. This excerpt alone does not address the proposed contractual exclusion.
What remains openMissing from the supplied context: the contracting-out provisions, defined terms and the facts needed to apply them.
Illustration of context assembly, with no model call or generated legal answer. Basis: FTA s 5D, checked on the rendered official page on 18 November 2026. Inspect the teaching graph and its evidence.
How the LLM uses your knowledgeFind, connect, select, explain and check.
| Step | What happens |
|---|---|
| Find | Search identifies promising records. Keyword search finds exact names and section numbers; search by meaning can find passages written in different words. |
| Connect | The retrieval service follows selected relationships to definitions, qualifications and supporting evidence. It applies the user’s access permissions. |
| Select | It chooses relevant passages within a size limit, retaining their source identities, relationship labels and known gaps. |
| Explain | The application supplies the evidence with the question. The LLM can compare it, summarise it, draft from it and identify questions that the material leaves unanswered. |
| Check | The reader checks the explanation against its cited passages. The application can also check that cited records exist and were actually retrieved. |
Microsoft’s GraphRAG local-search documentation describes combining connected graph records with source passages, then selecting material for the model’s context.
What you need to understandJudge whether the evidence is enough for the question.
You do not need to memorise every connection. You need to understand the kinds of connection that matter, so you can judge whether the system has brought enough evidence into view. In legal research, that includes asking which version is being used, whether a qualification has been followed and what remains outside the collection.
A maintained collection can save repeated searches, preserve a team’s reasoning, supply newer material and make answers easier to check. It can also support several models and applications: the source record remains useful when the tool changes.
Keep the context usefulSelect relevant evidence and check the resulting answer.
The selection matters. Adding every connected document can bury useful evidence in irrelevant material. Research on long contexts found that the tested models’ performance depended on where relevant information appeared. A sensible retrieval service keeps the most relevant evidence together and makes omissions visible.
A graph is useful where relationships carry meaning. A small collection may work well with ordinary search and well-labelled passages. Anthropic’s contextual-retrieval explanation shows how retaining a passage’s surrounding context can help retrieval even without a graph.
A model can still misread good evidence, and an incorrect graph connection can send it in the wrong direction. Knowledge management makes the material and the reasoning path inspectable; checking the answer remains part of the work.
Much of this can now run automatically
APIs, structured source files, databases and scheduled jobs make a small knowledge system straightforward to assemble and host. Software can collect changed documents, preserve their versions, extract explicit references and rebuild a search index. An AI assistant can help write the importer and suggest relationships for review.
For New Zealand legislation, the starting point is a PCO API key. A server can use it to discover source versions and their file links, then feed an import process. The next guide shows the requests, a downloadable source-capture script and the pieces needed to turn it into a maintained service.
A New Zealand example
The supplied example contains 15 selected provisions and 30 curated relationships across the Fair Trading Act 1986 and Consumer Guarantees Act 1993. It shows how a section can connect to definitions, qualifications and remedies. Most provision records contain editorial summaries.
The interactive example preserves those labels and the evidence recorded for each connection. It also shows why an official source link, a complete source file and a verified legal conclusion are separate things.
Further reading
These sources explain the methods and the research behind them.
- W3C: RDF 1.1 Primer. A foundation for representing records and their relationships.
- W3C: OWL 2 Web Ontology Language Primer. How an ontology defines concepts and relationships so their meaning can be shared.
- Lewis and colleagues: Retrieval-Augmented Generation. The original research on combining retrieved documents with a language model.
- Microsoft: GraphRAG local search. How connected records and source passages can be selected for an AI answer.
- Anthropic: Contextual Retrieval. Why a passage’s surroundings matter when searching.
- Liu and colleagues: Lost in the Middle. Research into how the tested models used information in long contexts.
- PCO: New Zealand Legislation developer API. Official access to legislation records and source formats.