AWS Knowledge Base Retrieval MCP Server
AWS 지식 기반 검색 MCP 서버
Bedrock Agent Runtime을 사용하여 AWS Knowledge Base에서 정보를 검색하기 위한 MCP 서버 구현입니다.
특징
RAG(검색 증강 생성) : 쿼리와 지식 기반 ID를 기반으로 AWS 지식 기반에서 컨텍스트를 검색합니다.
다중 결과 검색 지원 : 사용자 정의 가능한 개수의 결과를 검색하는 옵션입니다.
Related MCP server: DuckDB-RAG-MCP-Sample
도구
AWS에서 검색_KB
AWS Knowledge Base를 사용하여 검색 작업을 수행합니다.
입력:
query(문자열): 검색을 위한 검색 쿼리입니다.knowledgeBaseId(문자열): AWS Knowledge Base의 ID입니다.n(숫자, 선택 사항): 검색할 결과 수(기본값: 3).
응답 형식:
이제 응답은 두 개의 별도 콘텐츠 항목을 반환합니다.
지식 기반의 원시 컨텍스트를 담은 텍스트 항목입니다.
메타데이터(id, 파일 이름, 스니펫, 점수)가 포함된 구조화된 RAG 소스를 담은 JSON 항목입니다.
이러한 분리를 통해 결과를 더 유연하게 처리할 수 있습니다.
구성
AWS 자격 증명 설정
AWS 자격 증명을 구성하는 데는 두 가지 옵션이 있습니다.
옵션 1: IAM 액세스 키
AWS Management Console에서 AWS 액세스 키 ID, 비밀 액세스 키 및 지역을 얻습니다.
이러한 자격 증명에 Bedrock Agent Runtime 작업에 대한 적절한 권한이 있는지 확인하세요.
아래 구성 예시와 같이 환경 변수를 설정합니다.
임시 자격 증명의 경우
AWS_SESSION_TOKEN환경 변수를 사용하여 세션 토큰을 제공할 수도 있습니다.
옵션 2: AWS SSO(Single Sign-On)
이제 서버가 AWS SSO 자격 증명을 지원합니다.
SSO 프로필로 AWS CLI 구성:
aws configure ssoMCP 서버 구성에서 AWS_REGION 환경 변수만 설정합니다.
서버는 SSO 자격 증명을 포함하는 기본 자격 증명 공급자 체인을 사용합니다.
선택 사항: 기본 지식 기반 ID 구성
선택적으로 기본적으로 사용할 하나 이상의 지식 기반 ID를 지정할 수 있습니다.
JSON 형식으로 지식 기반 ID 배열을 만듭니다.
구성에서 이것을 AWS_KB_IDS 환경 변수로 설정하세요.
이것이 구성되면 도구에서
knowledgeBaseId매개변수가 선택 사항이 됩니다.
Claude Desktop과 함께 사용
claude_desktop_config.json 에 다음을 추가하세요:
IAM 액세스 키가 있는 Docker
지엑스피1
AWS SSO를 사용한 Docker
{
"mcpServers": {
"aws-kb-retrieval": {
"command": "docker",
"args": [ "run", "-i", "--rm", "-e", "AWS_REGION", "-e", "AWS_KB_IDS", "-v", "${HOME}/.aws:/root/.aws", "mcp/aws-kb-retrieval-server" ],
"env": {
"AWS_ACCESS_KEY_ID": "YOUR_ACCESS_KEY_HERE",
"AWS_SECRET_ACCESS_KEY": "YOUR_SECRET_ACCESS_KEY_HERE",
"AWS_SESSION_TOKEN": "YOUR_OPTIONAL_SESSION_ID_FOR_SSO_TEMPORARY_CREDENTIALS_HERE",
"AWS_REGION": "YOUR_AWS_REGION_HERE",
"AWS_KB_IDS": "[\"kb-12345\", \"kb-67890\"]"
}
}
}
}IAM 액세스 키가 있는 NPX
{
"mcpServers": {
"aws-kb-retrieval": {
"command": "npx",
"args": [
"-y",
"@modelcontextprotocol/server-aws-kb-retrieval"
],
"env": {
"AWS_ACCESS_KEY_ID": "YOUR_ACCESS_KEY_HERE",
"AWS_SECRET_ACCESS_KEY": "YOUR_SECRET_ACCESS_KEY_HERE",
"AWS_SESSION_TOKEN": "YOUR_OPTIONAL_SESSION_ID_FOR_SSO_TEMPORARY_CREDENTIALS_HERE",
"AWS_REGION": "YOUR_AWS_REGION_HERE",
"AWS_KB_IDS": "[\"kb-12345\", \"kb-67890\"]"
}
}
}
}AWS SSO를 갖춘 NPX
{
"mcpServers": {
"aws-kb-retrieval": {
"command": "npx",
"args": [
"-y",
"@modelcontextprotocol/server-aws-kb-retrieval"
],
"env": {
"AWS_ACCESS_KEY_ID": "YOUR_ACCESS_KEY_HERE",
"AWS_SECRET_ACCESS_KEY": "YOUR_SECRET_ACCESS_KEY_HERE",
"AWS_SESSION_TOKEN": "YOUR_OPTIONAL_SESSION_ID_FOR_SSO_TEMPORARY_CREDENTIALS_HERE",
"AWS_REGION": "YOUR_AWS_REGION_HERE",
"AWS_KB_IDS": "[\"kb-12345\", \"kb-67890\"]"
}
}
}
}로컬 저장소(복제/빌드된 저장소에서)
{
"mcpServers": {
"aws-kb": {
"command": "node",
"args": [
"/path/to/mcp-aws-kb/dist/index.js"
],
"env": {
"AWS_ACCESS_KEY_ID": "YOUR_ACCESS_KEY_HERE",
"AWS_SECRET_ACCESS_KEY": "YOUR_SECRET_ACCESS_KEY_HERE",
"AWS_SESSION_TOKEN": "YOUR_OPTIONAL_SESSION_ID_FOR_SSO_TEMPORARY_CREDENTIALS_HERE",
"AWS_REGION": "YOUR_AWS_REGION_HERE",
"AWS_KB_IDS": "[\"kb-12345\", \"kb-67890\"]"
},
"disabled": false,
"autoApprove": [
"retrieve_from_aws_kb"
],
"timeout": 120
}
}
}건물
도커:
docker build -t mcp/aws-kb-retrieval -f src/aws-kb-retrieval-server/Dockerfile .특허
이 MCP 서버는 MIT 라이선스에 따라 라이선스가 부여됩니다. 즉, MIT 라이선스의 약관에 따라 소프트웨어를 자유롭게 사용, 수정 및 배포할 수 있습니다. 자세한 내용은 프로젝트 저장소의 LICENSE 파일을 참조하세요.
이 README에서는 서버 패키지 이름이 @modelcontextprotocol/server-aws-kb-retrieval 이라고 가정합니다. 설정에서 패키지 이름과 설치 세부 정보가 다를 경우 수정하세요. 또한 서버 스크립트가 올바르게 빌드되었는지, 그리고 모든 종속성이 package.json 파일에서 제대로 관리되는지 확인하세요.
Available Tools
1 toolretrieve_from_aws_kbC
Performs retrieval from the AWS Knowledge Base using the provided query and Knowledge Base ID.
| Name | Required | Description | Default |
|---|---|---|---|
| query | Yes | The query to perform retrieval on | |
| knowledgeBaseId | Yes | The ID of the AWS Knowledge Base | |
| n | No | Number of results to retrieve |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
No annotations are provided, so the description carries the full burden of behavioral disclosure. It mentions retrieval but fails to describe key traits like authentication requirements, rate limits, error handling, or what the retrieval entails (e.g., returns text snippets, metadata). This leaves significant gaps in understanding how the tool behaves in practice.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is a single, efficient sentence that directly states the tool's function and inputs without any fluff. It's front-loaded with the core purpose and appropriately sized for the task, making it easy to parse quickly.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Given no annotations and no output schema, the description is incomplete. It doesn't explain what the retrieval returns (e.g., format, content), error conditions, or operational details like latency or costs. For a tool with 3 parameters and missing structured data, this leaves the agent under-informed about critical context.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema description coverage is 100%, so the schema fully documents all parameters (query, knowledgeBaseId, n). The description adds no additional meaning beyond what's in the schema, such as examples or constraints. This meets the baseline for high schema coverage but doesn't enhance parameter understanding.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states the action ('performs retrieval') and the resource ('from the AWS Knowledge Base'), making the purpose immediately understandable. It specifies the required inputs (query and Knowledge Base ID), which helps distinguish it from generic retrieval tools. However, without sibling tools, it doesn't need to differentiate further, so it's not a perfect 5.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description provides no guidance on when to use this tool versus alternatives, prerequisites, or contextual constraints. It merely states what the tool does without indicating appropriate scenarios or limitations, leaving the agent without usage direction.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
1 tool update
- First observed
retrieve_from_aws_kb
TDQS
Scored across 1 tool
With only one tool, there is no possibility of ambiguity or overlap between tools. The tool's purpose is clearly defined and distinct by default.
A single tool inherently has perfect naming consistency, as there are no other tools to compare it against for patterns or conventions.
One tool is too few for a server focused on AWS Knowledge Base retrieval, as it lacks essential operations like listing knowledge bases, managing queries, or handling configurations, making the scope feel incomplete and limiting.
The tool set is severely incomplete for the domain of AWS Knowledge Base operations. It only provides retrieval, missing critical functions such as creating, updating, or deleting knowledge base entries, which are necessary for a full workflow.
Maintenance
Related MCP Connectors
The AWS Knowledge MCP server is a fully managed remote Model Context Protocol server that provides real-time access to official AWS content in an LLM-compatible format. It offers structured access to AWS documentation, code samples, blog posts, What's New announcements, Well-Architected best practices, and regional availability information for AWS APIs and CloudFormation resources. Key capabilities include searching and reading documentation in markdown format, getting content recommendations, listing AWS regions, and checking regional availability for services and features.
MCP server for AI dialogue using various LLM models via AceDataCloud
Driflyte MCP server which lets AI assistants query topic-specific knowledge from web and GitHub.
Related MCP Servers
- AlicenseBqualityCmaintenanceAn MCP server that enables AI models to retrieve information from Ragie's knowledge base through a simple 'retrieve' tool.134 npm91MIT
- AlicenseNot gradedqualityDmaintenanceAn MCP server that enables RAG (Retrieval-Augmented Generation) on markdown documents by converting them to embedding vectors and performing vector search using DuckDB.4Apache 2.0
- FlicenseNot gradedqualityDmaintenanceAn MCP server that implements Retrieval-Augmented Generation to efficiently retrieve and process important information from various sources, providing accurate and contextually relevant responses.-
- FlicenseNot gradedqualityDmaintenanceAn MCP server integrating LangChain, RAG, and Agent to provide knowledge retrieval and tool invocation through natural language.-