This article is a machine translation of the contents of the following URL, which I wrote in Japanese:

【AWS】エージェント共通の「社内知識」をどう持たせるか AWS Contextを図で理解する【AWS Context】 #ClaudeCode - Qiita

はじめに Claude Code や Kiro に社内の知識を渡すとき、CLAUDE.md や steering ファイル、スキルを手で書いている方は多いと思います。私もそうしていますが、エージェントごとに書き分ける手間がかかり、業務が変わるたびに書き直す必要があります。...

favicon qiita.com

Introduction

When you give Claude Code or Kiro your company's knowledge, you probably write CLAUDE.md files, steering files, or skills by hand. I do too, but it takes effort to write them for each agent, and they have to be rewritten every time the business changes.

On December 1, 2026, AWS Context became generally available. It tackles this problem head-on. It builds a graph of "what your terms mean, how your numbers are calculated, and which rules apply" from your data and documents, and lets any agent query it over MCP. Amazon's announcement describes the limits of hand-written context like this:

Today, companies try to guide agents and provide them with their organization's context with Markdown files, steering files, prompts, or agent skills. Each one is written by hand for a single agent and needs updating as the business changes.

Source: https://www.aboutamazon.com/news/aws/aws-context-launches-free-context-graph-creation

In this article, I use diagrams to organize the following points.

  • What AWS Context is, and what problem it tries to solve
  • Where the data lives, and what runs where
  • How agents use it, and what comes with the answers
  • Who can see what, and how changes to the graph are approved
  • What is free, and what costs money

This article is for readers who have used MCP servers with Claude Code or Kiro and are wondering how to give their agents company knowledge. It is based on the official documentation as of December 2, 2026, and on what I confirmed by running the official sample in the US East (N. Virginia) Region (us-east-1). The Tokyo Region is not supported at this time.

What Is AWS Context?

AWS Context overview: data sources stay in place, AWS Context builds a context graph, and agents query it over MCP

AWS Context is a service that teaches agents "what this word means in this company, how this number is calculated, and which rules to follow." The user guide opens with this description:

AWS Context connects to these sources where they already live. It builds a context graph that maps your business: what your terms mean, how your numbers are calculated, and which rules apply.

Source: https://docs.aws.amazon.com/context/latest/userguide/what-is-service.html

The key point is that your data is not copied into AWS Context. What AWS Context holds is a graph built from metadata and documents, and it queries the source systems only when the actual data is needed.

AWS Context doesn't move your data out of its source systems. It indexes your metadata and documents and builds the Agent Context from them. When an answer needs the data itself, it queries the source directly.

Source: https://docs.aws.amazon.com/context/latest/userguide/what-is-service.html

The console also has a diagram of this relationship. Agents (Kiro, AWS Quick, Amazon Bedrock, Strands Agents, Claude, ChatGPT, and Gemini CLI) are at the top, AWS Context is in the middle, and the data sources are at the bottom.

How it works diagram in the AWS Context console

The Four Resources

Four resources appear when you use AWS Context. Each one has its own ARN and is an independent resource.

Resource Role
Agent Context What agents query. A context graph that represents one bounded data estate. You can create up to 20 per account
Connection A link to a data source. It holds the role and authorization settings and can be reused across multiple Agent Contexts
Ontology Definitions of business entity types, attributes, and relationships. Three are provided out of the box (Enterprise, Business Process, and Data), and you can bring your own
Curation policy Decides whether a change to the graph is applied automatically, sent to human review, or discarded

Source: https://docs.aws.amazon.com/context/latest/userguide/what-is-key-resources.html

How It Differs from Bedrock Knowledge Bases

If you only need to search documents and pass them to an agent, Amazon Bedrock Knowledge Bases (RAG) can do that. AWS Context is different in that it puts table schemas, column descriptions, business glossaries, and relationships between tables into one graph along with documents, and handles SQL queries through the same entry point.

In fact, documents are ingested into AWS Context through a Bedrock managed knowledge base. Knowledge Bases is not something AWS Context replaces; it is one of its entry points.

Overview: Hand-Written Context vs. a Shared Context Graph

Comparison of hand-written context and AWS Context: who writes it, how changes propagate, access scope, and justification

The table below summarizes the differences between hand-written context and AWS Context.

Aspect CLAUDE.md, steering, skills AWS Context
Who writes it People write it for each agent Built automatically from data source metadata and documents, then corrected by people
How changes propagate Only affects agents that use the edited file Affects every agent that uses the same Agent Context
Change approval Left to file review (Git, etc.) Every change goes through a curation policy
Access scope Anyone who can read the file sees all of it Limited to the caller's permissions
Justification Cannot be seen from the agent's answer Answers include sources (tables, columns, documents)
Cost None Charges for operations such as retrieval (see below)

What impressed me most in testing was the table descriptions. The material behind AWS Context's answers included descriptions like this:

# Table: orders Customer orders with status and shipping address. - Grain: One row per order. - Primary key: order_id - When to use: Order status, who placed an order and where it ships. - When not to use: What an order contains (use order_items) or what was paid (use payments). 

These are usage rules, "use this table in these cases, not in these cases," of the kind you would write in a CLAUDE.md file or a skill. AWS Context appears to keep them on the data side rather than on the agent side.

1. Architecture

What Runs Where

What runs where: Claude Code and mcp-proxy-for-aws on the developer PC, and the MCP server, Agent Context, connections, Glue Data Catalog, and a managed knowledge base in us-east-1

Agents query an MCP server hosted by AWS. Behind the MCP server is the Agent Context, which connects to the data sources through Connections.

Each type of data source has a different entry point.

Type Entry point Can agents query the data? Stage
Glue tables, S3 Tables Glue Data Catalog Yes (SQL and agentic retrieval) GA
Redshift, DynamoDB, Aurora PostgreSQL, RDS for Oracle Glue Data Catalog (Glue connection required) Yes (agentic retrieval) GA
Athena workgroups, S3 general purpose buckets Glue Data Catalog No (metadata only) GA
RDS for PostgreSQL, MySQL, etc., SageMaker AI, Kinesis, MSK Glue Data Catalog No (metadata only) Preview
Documents in SharePoint, Google Drive, Confluence, Salesforce, etc. Bedrock managed knowledge base Returns passages through the knowledge base Not stated on the product page
Snowflake and Databricks catalogs Each catalog The product page only mentions ingesting metrics Preview

Sources: https://docs.aws.amazon.com/context/latest/userguide/aws-native-structured-sources.html , https://aws.amazon.com/data/context/features/

Testing with the Sample

This time, I checked the behavior with the official sample.

Item Value
Region us-east-1
Sample Created with "Create context with sample data" in the console
MCP client Claude Code 2.1.331 (Windows)
Test date December 2, 2026

With one click in the console, the Agent Context became Active in 1 to 2 minutes. The sample is an online store with tables for customers, orders, products, and shipments, plus documents such as a store policy and customer support chat transcripts.

Two Connections were created. Tables come in through a Glue Data Catalog connection, and documents through a managed knowledge base connection.

Connections tab of the sample Agent Context

Note that right after it became Active there were 0 entities. A few minutes later there were 111, and later still 131. "Active" seems to mean "ready to use," and ingestion continues after that.

What Goes into the Graph?

The Details tab shows the context graph as a diagram. Tables spread out from the Glue database at the center, and each table has its columns attached. Documents and business terms are in the same graph.

Context graph view on the Details tab

When you hover over a node, its relationships are highlighted in bold and their names (such as HAS_TABLE) are shown. The legend lists 14 entity types: besides tables and columns, there are documents (Document), glossaries (Glossary, GlossaryTerm), and data lineage (Job, LineageDataset), among others.

Zoomed-in context graph with the legend expanded

Opening an entity shows where it came from. For example, the customers table came from Glue and had 10 relationships to its columns (HAS_COLUMN).

Details of the customers table entity

Business terms were ingested from the Glue business glossary. The term "Customer authentication" has the description "Confirming who a customer is, by email or by name and ZIP code."

Details of the Customer authentication glossary term

2. Usage

The Console Chat and MCP Use the Same API

You can ask an Agent Context questions in two ways: the console chat and MCP. The chat screen says "Responses come from the AgenticRetrieveStream API, the same API your agents call," so it answers with the same API that agents call.

When I asked the official tutorial question, "How many orders are still pending, and what are they worth in total?", in English, it answered "423 orders, $727,580.50" in 14.7 seconds. This matches the expected answer in the tutorial.

Console chat answers to the question in English and in Japanese

Expanding the steps shows that it searched the graph, found the related tables (orders, order_items, and payments), then built and ran a SQL query.

Steps of the answer, including the SQL that was run

The answer also explained its assumptions: "I took an order's value to be the sum of its line prices in order_items" and "if you want the amounts actually charged instead, payments has an amount column; I didn't query it." When a number can be defined in more than one way, it states which definition it chose.

When I asked the same question in Japanese, the same answer came back in Japanese. However, I asked it as a continuation of the English chat, so the answer took the earlier conversation into account. I did not check whether it can answer correctly from a Japanese question alone.

For a question about documents, the behavior changed. When I asked in English, "What does the store policy say about returning or exchanging a delivered order?", it answered in 6.6 seconds without using SQL, based only on a passage from the store policy document.

Question Steps Time Basis
Number and total value of pending orders 9 14.7 s Query result and column descriptions
Return and exchange policy 2 6.6 s A passage from a document (store_policy.md)

The same entry point switches what it queries depending on the question.

The MCP Server

The MCP server is hosted by AWS, and you deploy nothing. The endpoint is https://context-mcp.<region>.api.aws/mcp, and a local proxy, mcp-proxy-for-aws, signs requests with your AWS credentials. The Integration tab of the Agent Context shows the connection details and a configuration you can paste as is.

Integration tab of the Agent Context

As in the official tutorial, you can add it to Claude Code with one line.

claude mcp add agent-context --env AWS_PROFILE=<profile-name> --env AWS_REGION=us-east-1 -- uvx mcp-proxy-for-aws https://context-mcp.us-east-1.api.aws/mcp --service context-mcp --region us-east-1 

Six tools are used for retrieval.

Tool What it does
context___SearchAgentContext Searches the graph for entities
context___TraverseAgentContext Follows the neighbors of an entity
context___AgenticRetrieve Answers a question and returns one result
context___AgenticRetrieveStream Same as above, with progress notifications
context___ExecuteSql Runs a read-only SQL query over Glue Data Catalog tables
context___RetrieveKnowledgeBase Retrieves passages from a managed knowledge base

Source: https://docs.aws.amazon.com/context/latest/userguide/mcp-server.html

There are also tools for reading the Agent Context, making changes (change sets), handling curation proposals, and sending traces, for 18 tools in total.

The documentation warns that the tool list is returned in pages, and a client that does not follow the pagination sees only the first 4 tools, which do not include search or SQL.

A client that doesn't follow the cursor sees only the first 4 tools, so it can't search, traverse, or run SQL.

Source: https://docs.aws.amazon.com/context/latest/userguide/mcp-server.html

In my test, Claude Code saw all 18 tools. This problem did not occur with Claude Code.

The agent-context MCP server shown with 18 tools in Claude Code

What Happens When You Ask from Claude Code?

Two flows for the same question: left to Claude Code, which built the answer with low-level tools in 1 min 14 s, and with AgenticRetrieve specified, which answered in 22 s

When I asked the official tutorial question, "Which customer has placed the most orders?", from Claude Code, the answer was "Harper Johansson, 9 orders," the same as the expected answer. However, while the tutorial describes AgenticRetrieve being called once and answering in about 15 seconds, Claude Code took 1 minute 14 seconds.

Claude Code's answer to the question

Claude Code's session log shows that it did not use AgenticRetrieve and built the answer itself in this order:

  1. Got the Agent Context settings with GetAgentContext
  2. Searched for "orders customers table" with SearchAgentContext
  3. Looked for table and column names in the search results
  4. Looked at 2 rows each of orders and customers with ExecuteSql
  5. Counted orders per customer with ExecuteSql

Each call to AWS Context finished in 2 to 3 seconds; most of the time went to Claude Code's own reasoning and reading the results. The search result in step 2 was about 60,000 characters, more than Claude Code accepts at once, so it was saved to a file.

Next, I asked the same question while specifying AgenticRetrieve.

Using only the context___AgenticRetrieve tool of the agent-context MCP server, ask agent context <Agent Context ID>: which customer has placed the most orders? 

This time the answer came back in 22 seconds. AWS Context's processing time was about 15 seconds, the same as the tutorial's estimate.

Claude Code's answer when AgenticRetrieve was specified

Item Left to Claude Code AgenticRetrieve specified
Tools used GetAgentContext, SearchAgentContext, ExecuteSql x3 AgenticRetrieve x1
Time 1 min 14 s 22 s
3rd place (tied at 6 orders) 3 customers (limited to 5 rows, so 1 was missed) 4 customers
Sources None Source tables and columns for each part of the answer

When left to Claude Code, it limited the aggregation to the top 5 rows, so one of the four customers tied for 3rd place was missed. After receiving the AgenticRetrieve answer, Claude Code explained on its own that "my earlier ranking showed only three of them because I limited it to 5 rows."

In this test, Claude Code chose to build the answer itself with low-level tools even though AgenticRetrieve was available. That is fine when you want to check the SQL yourself, but if you value speed, completeness, and sources, I think it is better to tell it to use AgenticRetrieve.

Connecting from AgentCore and Other Services

How to connect to AWS Context: one MCP server as the entry point, with Claude Code tested and AgentCore Gateway, harness, and Runtime supported per the documentation

So far I have used it from Claude Code on my own machine, but agents running on AgentCore can use it too. The AWS Context user guide says it can be exposed as an AgentCore Gateway target.

You can expose an Agent context to agents built on Amazon Bedrock AgentCore as an Amazon Bedrock AgentCore Gateway target.

Source: https://docs.aws.amazon.com/context/latest/userguide/use-aws-context-with-agentcore.html

However, there is no dedicated integration. When I checked the Gateway's add-target screen, AWS Context did not appear in the target types (MCP server, Lambda ARN, REST API, API Gateway, Connector), in the connector's preconfigured targets, or in the list of other integrations. Since AWS Context has a single MCP server as its entry point, it appears that you connect to it as an MCP server.

The client side needs three things.

Requirement Details
Connect to a remote MCP server The endpoint is https://context-mcp.<region>.api.aws/mcp over Streamable HTTP
Pass authentication SigV4 signing with the signing name context-mcp, or sign-in through an identity provider
Follow pagination of the tool list Otherwise only the first 4 tools, which do not include search or SQL, are visible

On the AgentCore side, both the Gateway's MCP server target and the harness's remote_mcp tool support SigV4 signing. The Gateway signs with the gateway role, and the harness signs with the harness execution role.

Sign requests to the remote MCP server with Signature Version 4 (SigV4) using the harness execution role.

Source: https://docs.aws.amazon.com/bedrock-agentcore-control/latest/APIReference/API_HarnessRemoteMcpOutboundAuth.html

Harness connections (a feature that connects through AWS-provided connectors) does not include AWS Context in the connector list in the release notes, so it does not appear to be usable. Note that I did not run any connection method other than Claude Code in this article.

3. Governance

Results Are Limited to the Caller's Permissions

For each request, AWS Context returns only what the calling user or agent is allowed to see.

Identity-aware means that AWS Context scopes every request to the permissions of the requesting user or agent, so an agent receives context only for data that the caller is authorized to see.

Source: https://docs.aws.amazon.com/context/latest/userguide/what-is-service.html

The bottom of the graph view also says, "The graph shows only unrestricted entities. Restricted entities inherit access control from their source. Only the owners of that source can access them." Restricted entities inherit the permissions of their data source.

On the Integration tab, you can choose the authentication method from "AWS credentials" and "Identity provider sign-in." The latter scopes results by the identity of a user who signs in through your company's identity provider.

Whose Permissions Are Used

What scopes the results is the identity that signed the MCP request. You cannot specify a different user in the tool arguments.

Each call runs as the identity that signed it; you can't pass a different user in tool arguments. For per-user results, sign with a session that carries the user's trusted identity, such as an IAM Identity Center session.

Source: https://docs.aws.amazon.com/context/latest/userguide/authentication-and-identity-for-mcp.html

In my test, Claude Code signed with my own IAM user, so the answers were limited to what I can see. When you go through Gateway, harness, or Runtime, the signer is each of their roles. As is, any user who asks would get answers within what that role can see. If you want to separate what each end user can see, you need to set up passing the user's identity (trusted identity propagation) separately.

Answers Include Sources

In the console chat, each number in the answer comes with a source. The sources include the query result as well as column descriptions (such as "Price paid for the line in USD."). Column metadata is used directly as the basis for the answer.

Sources listed under the answer in the console chat

When the answer comes from a document, the document name has a "Managed Knowledge Base" label, and the quoted passage is shown.

Answer based on the store policy document, with the source labeled Managed Knowledge Base

The response from AgenticRetrieve over MCP also contained pairs of character positions in the answer and the nodes (tables and columns) used as the basis.

Changes to the Graph Go Through the Curation Policy

How changes reach the graph: every change becomes a changeset, and the curation policy applies it, sends it to review, or discards it

The graph is designed to improve with use. Expert corrections and knowledge proposed from agent feedback all become units of change called changesets, and the curation policy decides what happens to them.

Every change — whether from ingestion, analysis, one-time imports, direct API updates, or feedback — becomes a changeset. The policy decides whether to apply it automatically, hold it for human review, or discard it.

Source: https://docs.aws.amazon.com/context/latest/userguide/what-is-key-resources.html

Applied changes reach every agent that uses the same Agent Context. With hand-written context, fixing a file only affects agents that read that file, but with AWS Context, a fix in one place reaches everyone. In this test, I did not try the flow of proposing and reviewing changes.

Watch Out for Document ACLs

Document permissions have a pitfall. If a managed knowledge base data source is configured not to crawl ACLs (access control lists), its documents are treated as readable by anyone.

If a data source doesn't crawl ACLs, its documents are sent as public, and every caller that can query the Agent Context can receive content extracted from them.

Source: https://docs.aws.amazon.com/bedrock/latest/userguide/integrate-managed-kb-context.html

If you want to show different documents to different users, you need to turn on ACL crawling for each data source.

Pricing

Item Price
Graph creation and storage (from AWS structured data such as Aurora, RDS, DynamoDB, Redshift, Athena, and S3) Free
Agentic operations such as retrieval, creation, curation, and feedback 0.04 USD per agent unit (billed per second)
Graph storage from other sources 5 USD per GB-month
Trial 3,750 agent units, once, in the first 30 days

Source: https://aws.amazon.com/data/context/pricing/

The announcement headline says "free graph creation," but only graph creation and storage from AWS structured data are free. Storage for graphs built from documents, and retrieval from agents, are charged. According to the pricing page, the 3,750 trial agent units cover about 2,700 retrievals with answer generation.

In my test, I could not find any screen that showed the agent units used. Nothing appeared in the console, CloudWatch metrics, the AgenticRetrieve response, or the Free Tier page. Budgets in agent units are listed as "Coming soon" on the pricing page.

Practical Notes

Aspect Note
Regions us-east-1, us-west-2, and eu-west-1. Tokyo is not supported
Using it from AgentCore There is no dedicated integration; you connect to it as an MCP server. Through Gateway, harness, or Runtime, answers use that role's permissions
Using it from Claude Code Left alone, Claude Code may build answers itself with low-level tools, which can be slower and miss results. Specifying AgenticRetrieve is faster and adds sources
Size of search results SearchAgentContext results can be large (about 60,000 characters in my test) and exceed what Claude Code accepts. You can narrow them with maxResults (1 to 50)
First MCP connection On first use, uvx downloads the proxy package, so Claude Code's connection check can time out at 30 seconds
Credentials Even with invalid credentials, Claude Code's connection check shows "Connected," and fails with "Authentication failed" only when fetching the tool list
Document ACLs Documents from data sources that do not crawl ACLs are treated as readable by anyone
Ingestion timing Right after it becomes Active, there may be 0 entities. Ingestion continues after Active
Usage At the time of testing, I could not find any screen showing agent unit consumption
Cleanup Deleting the Agent Context leaves the Connections, knowledge base, S3 bucket, Glue database, and IAM roles in place

A note on cleanup. The official steps only say "delete the Agent Context," but the delete confirmation also says "2 connections will be detached (the underlying data sources are preserved)."

Delete agent context dialog with the impact analysis

After trying the sample, delete things in this order to clean up everything that was created.

  1. Delete the Agent Context
  2. Delete the two Connections on the Connections page of AWS Context
  3. Delete the Bedrock knowledge base (agent-context-sample-managed-knowledgebase)
  4. Empty and delete the S3 bucket (agent-context-sample-...)
  5. Delete the Glue database (agent_context_sample_database)
  6. Delete the four IAM roles (AgentContextSample...Role_...) and the four managed policies attached to them

Conclusion

AWS Context moves the context we used to write by hand for agents to the data side and shares it across the organization. When I saw table descriptions that even said "use this in these cases, not in these cases," I felt it was the same kind of information I had been writing in skills.

On the other hand, when using it from Claude Code, unless you tell it to use AgenticRetrieve, Claude Code may choose to build the answer itself, which can be slower and miss results. Considering that there is no screen yet for checking usage and that the Tokyo Region is not supported, I think it is best to first check the behavior with the sample and then try it with your own data.

References