Skip to content

AI 301 · Module 5

Shared Context, Memory & Coordination

Should every agent share all information, or should each agent see only the context it needs?

Start Section 1
0 / 6 completed
Sync my progressJoin a session to keep progress across devices and share it with your instructor

Info

After you join, your completed lesson numbers are sent to your instructor together with your learner code, so they can see your progress. Use the codes your instructor gave you, and do not enter your name, company secrets or other personal data. Progress is kept with the rest of that session's data.

Learning objectives

  • Explain the difference between Shared Context and Private Context, and why a team of agents needs both
  • Describe Shared Memory, Local Memory, Shared Knowledge and a Source of Truth as concepts
  • Set Information Boundaries using ownership, access control and the five information classes
  • Recognize stale shared context and describe context freshness, version awareness and synchronization
  • Explain Coordination State and consensus concepts, then complete Activity 5 and produce a Shared Context Map

Shared and private context

9 min

Share everything, or share only what is needed?

In Module 4 agents learned to send each other messages. Now a harder question appears: what information should the agents hold in common? A team that shares nothing cannot work together. A team that shares everything wastes effort, leaks information and drowns each agent in noise.

Core question

Should multiple agents share all information, or should each agent see only the context it needs?

Key terms
TermPlain meaning
Shared ContextInformation that every agent on the team is meant to see, such as the goal and agreed facts
Private ContextInformation that belongs to one agent because only its own role needs it
Information BoundaryA deliberate line that says which information may cross between agents, or to a human
Context ownershipThe one role responsible for keeping a piece of information correct
Simulated example

A simulated customer-feedback team has a Research agent, an Analysis agent and a Reporting agent. All three need the shared goal and the list of approved sources. Only the Analysis agent needs its raw working notes. Only a human reviewer should see a draft that mentions an unresolved complaint.

Info

This module stays conceptual. We design what is shared and what is private. We do not build storage, checkpoints or recovery systems, which belong to AI 302.

Key takeaway: Multi-agent teams need a deliberate answer to what is shared and what is private, not a default of sharing everything.

9 min

Context architecture: shared, private and bounded

A context architecture starts from a Shared Goal. Below it sits one Shared Context that acts as the Source of Truth. Each agent then keeps its own Private Context beside it.

Context architecture
  1. Shared Goal: the purpose every agent works toward
  2. Shared Context / Source of Truth: agreed facts, task status and approved decisions
  3. Agent A Private Context: only what Agent A needs for its role
  4. Agent B Private Context: only what Agent B needs for its role
  5. Agent C Private Context: only what Agent C needs for its role

Info

Text version of the diagram: the Shared Goal is at the top. Under it is one Shared Context that serves as the Source of Truth. From that Shared Context, three branches lead to Agent A, Agent B and Agent C. Each of the three agents has its own Private Context that the other agents do not see by default.
Five classes of information
ClassMeaningExample (simulated)
Shared contextEvery agent on the team may see and rely on itThe goal, the approved source list, the report outline
Private agent contextVisible to one agent only, because only its role needs itThe Analysis agent's scratch calculations
Shared knowledge sourceA reference many agents read but none owns as working stateA policy handbook or product FAQ
Human-onlyReserved for a person to see and decide onA draft that names an unresolved complaint
RestrictedNot to be passed to any agent without explicit approvalPersonal data, credentials, confidential figures
Check yourself

An agent's rough working notes are only useful for its own step. Where do they belong?

An agent's rough working notes are only useful for its own step. Where do they belong?

Key takeaway: Share the goal and agreed facts, keep role-specific working material private, and classify each piece of information.

Memory, freshness and synchronization

9 min

Shared Memory, Source of Truth and ownership

Memory in a multi-agent team comes in two conceptual kinds. Shared Memory holds what the team has agreed or produced together. Local Memory holds what one agent wants to remember for its own work. Shared Knowledge is different again: it is reference material many agents read.

Memory and knowledge concepts
ConceptWho uses itDesign question
Shared MemoryThe whole teamWhat has the team agreed on, and who may change it?
Local MemoryOne agentWhat does this agent need to remember that others do not?
Shared KnowledgeMany agents, read onlyWhich reference sources are approved for everyone?
Source of TruthThe whole teamWhen two agents disagree about a fact, which record wins?
Ownership and access control
QuestionDesign rule
Who owns this piece of information?Exactly one role owns it and keeps it correct
Who may read it?Only roles that need it for their task
Who may write or change it?Usually the owner, or a role the owner has approved
Who reviews changes to important facts?A named role, and a human for high-impact facts

Warning

Two owners means no owner. If two agents can both rewrite the same fact, they will eventually contradict each other. Give each shared fact one owner and one Source of Truth.
Check yourself

Why should each shared fact have one owner?

Why should each shared fact have one owner?

Key takeaway: Distinguish shared memory, local memory and shared knowledge, and give every shared fact one owner and one Source of Truth.

9 min

Stale context, freshness and synchronization

Shared context changes over time. When one agent updates a fact and another keeps using the old version, the team works from stale shared context. The result can look confident and still be wrong.

Simulated example

The Research agent updates the approved source list to remove a source that turned out to be outdated. The Reporting agent, still holding the earlier list, cites that source in its draft. Nobody made a mistake alone; the two agents were not synchronized.

Ways to reduce stale context (concepts only)
IdeaPlain meaning
Context freshnessHow recent a piece of shared information is, and how long it stays trustworthy
Version awarenessEach shared fact carries a version or time so an agent can tell if it is holding an older copy
Context synchronizationA planned moment when agents refresh their view of the shared context
Change noticeA message, using the Module 4 contract, that tells others a shared fact changed

Info

Text version of the idea: an agent that reads shared context should know how old it is. An agent that changes shared context should tell the others. A refresh point before an important step lets agents compare their versions with the Source of Truth.

Warning

Boundary: this is about designing for freshness. Building storage, checkpoint or recovery machinery to guarantee it is a later topic in AI 302.
Check yourself

Which practice best helps an agent notice it is using an outdated fact?

Which practice best helps an agent notice it is using an outdated fact?

Key takeaway: Attach version or time to shared facts, tell others when they change, and refresh before important steps.

Coordination, practice and deliverable

10 min

Coordination state and consensus concepts

Besides facts, a team needs to know where the work stands. Coordination State is the shared picture of who is doing what, which steps are done, and which are waiting. It is a design idea here, not a database schema.

What a Coordination State might show (conceptual)
ItemQuestion it answers
Task statusWhich tasks are open, in progress or finished?
AssignmentWhich role holds each task now?
Waiting onWhich task or human decision is blocking progress?
Decisions madeWhich choices has the team settled, and by whom?
Open questionsWhich points remain undecided?

Sometimes agents hold different views and the team needs one answer. Consensus, as a concept, is a rule for reaching a shared decision. Rules can be simple: the owner decides, the supervisor decides, a majority of reviewers agree, or a human decides.

Consensus concepts compared
ApproachStrengthWatch out for
Owner decidesFast and clear accountabilityOne agent's blind spot becomes the team's
Majority of reviewersSeveral checks on one answerAgents built the same way may repeat the same mistake
Human decidesJudgment and accountability stay with a personSlower, so reserve it for high-impact points

Warning

Agreement among agents is not proof of correctness. For high-impact decisions, a human still reviews and remains responsible.
Check yourself

Three agents agree on an answer that will affect a customer contract. What is the safest conclusion?

Three agents agree on an answer that will affect a customer contract. What is the safest conclusion?

Key takeaway: Coordination State shows where work stands, consensus is a rule for one answer, and humans keep high-impact decisions.

9 min

Activity 5: Shared or Private? and the Shared Context Map

Take a simulated multi-agent team, or the team you designed in Modules 2 to 4. Sort its information into the five classes and decide who owns and who may see each item.

  1. List the information
    Write 8 to 12 pieces of information the team uses or produces.
  2. Classify each item
    Choose one: shared context, private agent context, shared knowledge source, human-only or restricted.
  3. Assign an owner
    Name the one role responsible for keeping each shared item correct.
  4. Set access and boundaries
    Note which roles may read it and which may change it.
  5. Plan freshness
    For each shared item, note how agents will know it changed and when they refresh.

Warning

Privacy reminder: use simulated or already-public information. Do not enter company secrets, client personal data or unauthorized sensitive information.

Info

Deliverable: a Shared Context Map. It lists each information item with its class, owner, who may read, who may change, freshness plan, and the coordination state the team tracks. Keep it for your Multi-Agent Architecture Canvas.
Check yourself

Your list includes a customer's personal details. Which class fits, and what should you do?

Your list includes a customer's personal details. Which class fits, and what should you do?

Key takeaway: Classify each item, name an owner, set boundaries and plan freshness, then record it in your Shared Context Map.

What next?