Announcing US$ 3.2M pre-seed round · OneVC · Maya · Norte Ventures Read →
Back to blog

Context layer:
what it is and why it comes before agents

In short

A company with three AI projects under way usually has three integrations with the same CRM. The customer service assistant, the collections agent and the board's question dashboard were built by different teams, each with its own filters, its own access rules and its own hand-assembled text for the model. When the product catalogue changes, the three integrations break in different weeks. The context layer is the piece of architecture that avoids this repetition. At Strattum, it is called the Company Brain, the layer that knows the company: which data exists, where it lives, how it connects and who can see what.

Every AI project without a common base rebuilds the same integration

A company's data lives in silos. Orders and invoices are in the ERP, opportunities in the CRM, tickets in the helpdesk and contracts in a management tool. Each system holds little about the records in the others.

Without a common base, every AI project connects the sources, resolves the differences between records, writes the access rules and assembles the context the model receives. That context is usually put together by hand, by someone who picks which columns go into the prompt.

By the third project, the same business rule exists in three versions, and every change at the source requires three fixes.

The context layer sits between the company's systems and the models

A context layer is the intermediate layer that organises what AI models receive about the company. It queries the source systems, which remain the source of the data. Five functions define it:

  1. connecting the sources only once, for every use case;
  2. resolving entities, recognising that records in different systems describe the same client, supplier or product;
  3. defining terms, so that invoiced order or active contract has a single meaning;
  4. applying the permissions of the person asking, inherited from the source system;
  5. serving the right slice to the model, with the source of each piece of information.

Graph, ontology, semantic layer and MCP make up the layer

Each function depends on a technical component:

  • Knowledge graph: records the business entities and the relationships between records in different systems.
  • Business ontology: defines what each term means in this company, with an owner and a version.
  • Semantic layer: translates a natural language question into the right query, using the ontology's terms and the graph's paths.
  • Delivery over MCP: serves the slice to the model or agent through an open protocol, without a custom integration for each application.
  • Traceability: records which system each piece of information came from and on whose behalf it was queried.

In practice, the question enters through the semantic layer, which interprets the terms through the ontology and walks the graph to the records. Permissions filter the result before it goes out. MCP handles delivery, and the protocol specification describes resources, tools and prompts as what a server offers to AI applications.

Components of the context layer: semantic layer, ontology, graph, permissions and MCP
The components of the context layer act in sequence on every question

The context layer comes before agents in the investment order

The market tends to start with the agent, because it demos well in a meeting, and the problem shows up when it acts on incomplete data. A collections agent that cannot see the helpdesk sends the dunning sequence to a client who opened a ticket disputing that same invoice.

The order that reaches production starts with the context layer. With the sources connected and the relationships resolved, the collections agent receives the invoice already linked to the open ticket. The next agent consumes the same layer and adds only the sources that are missing.

Investment order with the context layer before AI agents
With the context layer first, each agent starts from what is already connected

Organised context lowers the cost of every call and every project

The first effect is on tokens. Without a context layer, projects make up for the lack of precision by sending whole tables or long documents to the model. With the slice resolved, the prompt carries only the records and definitions the question requires.

The second effect is on model choice. When context arrives organised, a good share of tasks runs on lower-cost models, because finding and linking the data was done before the call. Switching models also does not require rebuilding the integration.

The third effect is on reused integration. The second project starts from the sources connected, the entities resolved and the permissions already applied by the first.

Data warehouses, data lakes and standalone RAG solve other problems

A data warehouse consolidates historical data in tables modelled for reporting and BI, and handles aggregations over closed periods well. A data lake stores large volumes of raw data in its original format, for later processing. Standalone RAG indexes the documents of one repository for one project and retrieves passages similar to the question.

The context layer can use all three as sources. It adds the link between records in different systems, the agreed meaning of each term, per-person permissions at question time and delivery to agents over a protocol.

Context layer compared with a data warehouse, a data lake and standalone RAG
The context layer uses the warehouse, the lake and documents as sources

Company Brain is the context layer applied to one company

Company Brain is the name Strattum gives to the context layer built for a specific company, with that company's entities, terms and permissions. Two companies with the same ERP have different brains, because invoiced order follows its own rules in each of them.

The data stays in the client's systems and environment. At question time, the model receives the slice that the asker's permissions allow, under the terms of the contract with the provider.

The layer depends on an owner, accessible sources and agreed definitions

  • Owner: a team responsible for connections and definitions, usually data or technology.
  • Accessible sources: read access to the systems, through an API or the database, with readable source permissions.
  • Agreed definitions: conflicting terms decided by the people accountable for them.

The layer reduces wrong answers caused by missing context. Answer quality still depends on the quality of the data at the source.

The starting point is the sources projects already share

The first step is to list the AI projects under way and planned, with the sources and terms of each. The overlap points to the first slice. If customer service and collections both depend on client, contract and invoice, those three entities and their sources form the base, and the following projects start from it.

Get the next articles on the Company Brain