What is an agent context layer?
By Firmament
An agent context layer gives an AI agent relevant knowledge about the work it is doing. It connects the agent to information that is not already in its current conversation: project decisions, working procedures, constraints and lessons from earlier tasks.
For example, an agent can read your interface code and still miss why your team chose prose over a structured form. A context layer makes that design reasoning available when the agent needs it. See a recorded Firmament design decision and how it could guide later work.
Firmament provides this layer through a knowledge base that agents read and contribute to. An agent calls ask for guidance and submit to report what it learned. Knowledge can be shared across tools and teammates, within the permissions of the person using each agent.
What belongs in agent context?
Useful context explains what the agent needs to know to do the current task correctly. That can include the reason a previous approach failed, an operating procedure, a customer's agreed constraints, or where to find an authoritative value.
It is useful to distinguish durable knowledge from live state. A lesson explaining where billing limits live can be retained. Today's billing limit should be checked at its source. A shared knowledge base does not turn every stored number into a live reading.
How does a context layer work?
- An agent asks a specific question. It includes the task, project and constraints rather than requesting everything the organization knows.
- Relevant knowledge is retrieved. The response must respect the user's access. In Firmament, an agent can access the knowledge available to its human.
- The agent uses the guidance. It checks changing facts at their source and applies the relevant procedure to the task.
- The agent reports the outcome. Firmament processes submissions into wiki pages so later work can benefit from the lesson.
Read how the wiki handles incoming knowledge.
How is this different from a context window?
A context window is the information available to a model during an invocation. A context layer is a system for supplying relevant information to an agent. Retrieved guidance still consumes space in the model's context window; the layer does not make that window unlimited.
The practical question is what should enter the conversation. Copying every past discussion into every task is different from retrieving the decision that explains this particular change.
How does it relate to rules files, RAG and MCP?
Rules files such as AGENTS.md and CLAUDE.md are useful for instructions that should travel with a project. They can also tell an agent when to consult shared knowledge. Firmament gives agents somewhere to contribute new lessons without requiring every lesson to be manually added to each agent's instruction file. See Firmament and rules files.
Retrieval-augmented generation, or RAG, retrieves material to support a model's response. It can be part of a context layer. Retrieval alone does not specify how a team contributes new lessons, corrects earlier guidance or controls sharing; those behaviors depend on the system you build around it.
Model Context Protocol, or MCP, lets clients connect to tools and resources. It is an interface, not the shared knowledge itself. Firmament exposes ask and submit through MCP as well as its CLI.
When do multiple agents need shared context?
Shared context becomes useful when agents repeatedly work on the same systems, when teammates use different tools, or when a lesson needs to survive the end of a session. An isolated task with all its inputs already present may need no additional knowledge layer.
A multi-agent context layer lets an agent retrieve lessons contributed through another agent. Firmament calls this agent multiplayer: sharing what agents learn while keeping access under the user's control.
What should you evaluate?
- Relevance: can an agent retrieve the guidance for a specific task without loading the entire knowledge base?
- Access: does retrieval respect the user, project and team involved?
- Updates: what happens when new evidence contradicts an old procedure?
- Traceability: can a person inspect where a page came from and review its history?
- Portability: can another supported agent client use the same knowledge?
- Failure behavior: what happens when the system has no useful answer?
Evaluate these behaviors with your own task. Our agent context evaluation guide includes fresh-session prompts, a scoring table and a test for outdated guidance. The governance overview explains Firmament's access and review model.
Is this for building agents or using them?
Both kinds of product use the term context layer. A team building an agent application might need storage and retrieval primitives to implement its own memory system. An engineering lead using existing coding agents needs those agents to find the team's working knowledge during ordinary tasks.
Firmament serves the second workflow. Developers connect the coding agents they already use. They contribute lessons through those agents and choose what to share. They do not need to build a new agent application to reuse a deployment procedure or an earlier engineering decision.
Further reading
Other implementations emphasize different parts of the problem. Redis describes context-layer infrastructure, while Unblocked discusses context for coding agents. These are vendor perspectives, not a single universal specification.