Skip to main content

Knowledge Sources

A knowledge source is a body of existing material — documentation, source code, API specifications, architecture notes — that workers can search by meaning rather than by filename. Knowledge sources give a worker access to what your organisation has already written down, while keeping the worker's prompt to the passages that matter.

This is distinct from memories. Memories are what workers have learned; knowledge sources are what your organisation has authored. Memories accumulate through work, while knowledge sources are registered deliberately and re-indexed when the underlying material changes.

How retrieval works

Registered material is split into passages and indexed by meaning. When a worker searches, its query is compared against those passages and the closest matches are returned. For example, a search for "how do we handle expired sessions" can return a passage about session timeout behaviour that uses entirely different wording.

A search returns the matching passages, which is what makes large bodies of documentation usable. A worker retrieves the few relevant paragraphs from a manual that runs to hundreds of pages.

Defining a knowledge source

FieldPurpose
NameA human-readable label for the source
TypeWhat kind of material this is
PathWhere the material lives — a file, a file pattern, or a URL
Split strategyHow the material is divided into passages
Indexing modelWhich model is used to index the material
Last indexedWhen the source was last processed

Source types

TypeCovers
MARKDOWNMarkdown documentation files
CODESource code files
API_DOCSAPI specifications such as OpenAPI or Swagger
ARCHITECTUREArchitecture and design documents

The type describes what the material is, which helps workers judge how much weight to give a result — for example, an architecture document carries different authority to a code comment.

Split strategies

How material is divided affects the quality of every search against it. Small passages retain less of their surrounding context, while large passages produce broader, less precise matches.

StrategyBehaviourBest for
HEADINGSplit on headings onlyWell-structured documentation with consistent heading use
FIXED_SIZEFixed-length passages with overlap between themMaterial with little or no structure, such as plain code
HEADING_WITH_FALLBACKSplit on headings, then split any oversized section by fixed lengthMost documentation — the default

HEADING_WITH_FALLBACK is the default because it follows a document's own structure where that structure exists, and divides any section that grows too long for a single passage.

Built-in sources

Each tenant is created with a starter set of knowledge sources covering common platform material. These can be used as they are, adjusted, or removed, and you can register as many additional sources as you need.

Keeping sources current

A knowledge source is indexed when it is registered and re-indexed when the underlying material changes. The record of when each source was last indexed tells you whether what workers are retrieving reflects the current state of the material.

important

Re-index a source after significant documentation or code changes. Searches return passages as they were at the last indexing, and a worker reads the passage it receives as current.

Searching knowledge

Workers search knowledge through the WRM toolset:

  • Search knowledge — find the passages most relevant to a question, optionally narrowed to a single source
  • List sources — see which sources are registered and when each was last indexed
  • Register a source — add new material for indexing
  • Update a source — change a source's path, type, or split strategy

Searches can be limited to one source when a worker knows where the answer should be. For example, a worker resolving an endpoint contract can narrow its search to the API specification.