Amazon Bedrock Knowledge Base MCP Server
Provides comprehensive management of Amazon Bedrock Knowledge Bases, including creation, configuration, and updates of knowledge bases with various storage types (S3, S3_VECTORS), embedding models (Amazon Titan, Cohere, Amazon Nova Multimodal Embeddings), and data source operations. Enables RAG (Retrieval-Augmented Generation) queries, data ingestion job management, and S3 document operations for building AI-powered knowledge retrieval systems.
Click on "Deploy Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@Amazon Bedrock Knowledge Base MCP Serversearch my knowledge base for information about AWS security best practices"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
Amazon Bedrock Knowledge Base MCP Server (Unofficial)
Amazon Bedrock Knowledge Baseを管理するためのMCP(Model Context Protocol)サーバーです。
本プロジェクトでは FastMCPフレームワークを使用して Bedrock Knowledge Base に対する操作と RAG(Retrieval-Augmented Generation)機能を提供しています。
リポジトリ
https://github.com/r3-yamauchi/bedrock-kb-mcp-server
Related MCP server: kk-bedrock-agent-hub-mcp
起動方法
uvx --from git+https://github.com/r3-yamauchi/bedrock-kb-mcp-server bedrock-kb-mcp-server主な機能
Knowledge Base管理: 作成、一覧取得、詳細取得、更新(敢えて削除機能は実装していません)
ストレージタイプは S3 のみをサポート
カスタムパーシング設定とチャンキング設定のサポート
データソース管理: 作成、一覧取得(敢えて削除機能は実装していません)
カスタムパーシング設定とチャンキング設定のサポート
データ取り込みジョブ: 開始、ステータス確認
RAGクエリ: Knowledge Baseに対する検索クエリの実行
S3ドキュメント管理: アップロード、一覧取得
プロジェクト構造
bedrock-kb-mcp-server/
├── pyproject.toml # プロジェクト設定と依存関係
├── README.md # プロジェクトドキュメント
├── LICENSE # MITライセンス
├── .gitignore # Git除外設定
└── src/
└── bedrock_kb_mcp_server/
├── __init__.py # パッケージ初期化ファイル
├── main.py # MCPサーバーのメインエントリーポイント
├── bedrock_client.py # AWS Bedrock APIクライアントラッパー
├── models.py # Pydanticモデル(バリデーションと型定義)
├── types.py # TypedDict定義(型ヒントの改善)
└── utils.py # ユーティリティ関数(設定、エラーハンドリング、ログ、ARN正規化)技術スタック
コアライブラリ
FastMCP (
>=0.1.0): MCPサーバーを構築するためのフレームワークboto3 (
>=1.26.0): AWS SDK for Python - AWSサービスとの通信に使用pydantic (
>=2.0.0): データバリデーションと設定管理
開発ツール
pytest (
>=7.0): テストフレームワークpytest-asyncio (
>=0.21.0): 非同期テストサポートblack (
>=23.0): コードフォーマッターruff (
>=0.1.0): 高速なPythonリンターmypy (
>=1.0): 静的型チェッカー
Python要件
Python 3.12以上が必要です
クイックスタート
前提条件
Python 3.12以上がインストールされていること
uvがインストールされていることAWSアカウントと適切な認証情報が設定されていること
1. 依存関係のインストール
プロジェクトのルートディレクトリで以下のコマンドを実行します:
uv sync開発環境の場合は:
uv sync --all-extras2. AWS認証情報の設定
以下のいずれかの方法でAWS認証情報を設定します:
方法1: AWSプロファイルを使用(推奨)
export AWS_PROFILE=your-profile-name
export AWS_REGION=us-east-1方法2: 環境変数で直接設定
export AWS_ACCESS_KEY_ID=your-access-key-id
export AWS_SECRET_ACCESS_KEY=your-secret-access-key
export AWS_REGION=us-east-1方法3: AWS CLIで設定済みの場合
AWS CLIでaws configureを実行して設定済みの場合は、追加の設定は不要です。
3. 環境変数の設定(オプション)
ログレベルや構造化ログの設定を行います:
# ログレベルを設定(DEBUG, INFO, WARNING, ERROR, CRITICAL)
export FASTMCP_LOG_LEVEL=INFO
# 構造化ログ(JSON形式)を使用する場合
export FASTMCP_STRUCTURED_LOG=false4. サーバーの起動
以下のコマンドでサーバーを起動します:
uv run bedrock-kb-mcp-server正常に起動すると、以下のようなログが表示されます:
2024-01-01 12:00:00,000 - bedrock_kb_mcp_server.main - INFO - Starting Amazon Bedrock Knowledge Base MCP Server5. 動作確認
MCP Serverは標準入力(stdin)からJSON-RPC形式のリクエストを受け取り、標準出力(stdout)にJSON-RPC形式のレスポンスを返します。
動作確認方法1: サーバーが起動していることを確認
サーバーを起動すると、以下のようなログが表示されます。このログが表示されれば、サーバーは正常に起動しています。
動作確認方法2: MCPクライアントを使用(推奨)
MCP対応のクライアント(例: Claude Desktop、Cursor IDEなど)を使用して接続します。
Claude Desktopの場合:
~/Library/Application Support/Claude/claude_desktop_config.jsonを編集MCP Serverを追加:
{
"mcpServers": {
"bedrock-kb-mcp-server": {
"command": "uv",
"args": ["run", "--directory", "/path/to/bedrock-kb-mcp-server", "bedrock-kb-mcp-server"],
"env": {
"AWS_PROFILE": "your-profile-name",
"AWS_REGION": "us-east-1"
}
}
}
}Cursor IDEの場合:
設定からMCP Serverを追加
コマンドパスと環境変数を設定
動作確認方法3: テストスクリプトを使用
プロジェクトに含まれているtest_mcp_server.pyを使用:
python3 test_mcp_server.py注意: このスクリプトはサーバーが起動してリクエストに応答することを確認しますが、実際のAWS API呼び出しは行いません。
インストール
uv sync開発環境の場合は:
uv sync --all-extras使用方法
環境変数の設定
以下の環境変数を設定する必要があります:
AWS_PROFILE: AWSプロファイル名(認証情報の管理に使用)AWS_REGION: AWSリージョン(例:us-east-1、デフォルト:us-east-1)FASTMCP_LOG_LEVEL: ログレベル(DEBUG,INFO,WARNING,ERROR,CRITICAL、デフォルト:INFO)FASTMCP_STRUCTURED_LOG: 構造化ログ(JSON形式)を使用するか(true/false、デフォルト:false)
サーバーの起動
uv run bedrock-kb-mcp-server主要コンポーネント
1. bedrock_client.py - AWS Bedrock APIクライアント
AWS Bedrock Knowledge Base APIとの低レベルな通信を担当するラッパークラスです。
BedrockKBClient クラス
環境変数AWS_REGIONからリージョンを取得し、以下の3つのAWSクライアントを初期化します:
bedrock-agent: Knowledge Baseとデータソースの管理用bedrock-agent-runtime: RAGクエリ実行用s3: S3ドキュメント管理用
すべてのクライアントには以下の設定が適用されます:
リトライ設定(最大3回、adaptiveモード)
接続タイムアウト(10秒)
読み取りタイムアウト(30秒)
主要メソッド
Knowledge Base管理
create_knowledge_base(): 新しいKnowledge Baseを作成list_knowledge_bases(): すべてのKnowledge Baseを一覧取得(ページネーション対応)get_knowledge_base(): 特定のKnowledge Baseの詳細情報を取得update_knowledge_base(): Knowledge Baseの名前、説明、IAMロールを更新
データソース管理
create_data_source(): Knowledge Baseにデータソースを追加list_data_sources(): 指定されたKnowledge Baseのデータソース一覧を取得
データ取り込みジョブ管理
start_ingestion_job(): データソースからKnowledge Baseへのデータ取り込みジョブを開始get_ingestion_job(): 取り込みジョブのステータスと統計情報を取得
RAGクエリ
retrieve(): Knowledge Baseに対してRAGクエリを実行(結果数1-100を指定可能)
S3ドキュメント管理
upload_document_to_s3(): ローカルファイルをS3バケットにアップロードlist_s3_documents(): S3バケット内のドキュメント一覧を取得(プレフィックスでフィルタリング可能)
2. main.py - MCPサーバーメイン
FastMCPフレームワークを使用してMCPサーバーを構築し、BedrockKBClientの機能をMCPツールとして公開します。
MCPツール
Knowledge Base管理ツール
create_knowledge_base: Knowledge Baseを作成ストレージタイプ: S3、S3_VECTORS
埋め込みモデル: Amazon Titan、Cohere、Amazon Nova Multimodal Embeddings v1
パーシング設定: BEDROCK_FOUNDATION_MODEL、BEDROCK_DATA_AUTOMATION
チャンキング設定: FIXED_SIZE、HIERARCHICAL、SEMANTIC、NONE
マルチモーダルストレージ設定(supplementalDataStorageConfiguration)
S3 ARN形式とS3 URI形式の両方をサポート
IAMロールARNのアカウントID自動補完
list_knowledge_bases: すべてのKnowledge Baseを一覧取得get_knowledge_base: 特定のKnowledge Baseの詳細を取得update_knowledge_base: Knowledge Baseを更新
データソース管理ツール
create_data_source: データソースを作成パーシング設定とチャンキング設定のサポート
S3 ARN形式とS3 URI形式の両方をサポート
list_data_sources: データソース一覧を取得
データ取り込みツール
start_ingestion_job: 取り込みジョブを開始get_ingestion_job: 取り込みジョブのステータスを取得
RAGクエリツール
retrieve: Knowledge Baseに対してRAGクエリを実行
S3ドキュメント管理ツール
upload_document_to_s3: S3にドキュメントをアップロードlist_s3_documents: S3バケット内のドキュメント一覧を取得
3. models.py - Pydanticモデル
リクエスト/レスポンスのバリデーションと型安全性を提供するPydanticモデルを定義します。
StorageType: ストレージタイプの列挙型(S3, S3_VECTORS)SourceType: データソースタイプの列挙型(S3)ParsingStrategy: パーシング戦略の列挙型(BEDROCK_FOUNDATION_MODEL, BEDROCK_DATA_AUTOMATION)ChunkingStrategy: チャンキング戦略の列挙型(FIXED_SIZE, HIERARCHICAL, SEMANTIC, NONE)ParsingConfiguration: パーシング設定モデルChunkingConfiguration: チャンキング設定モデルVectorIngestionConfiguration: ベクトル取り込み設定モデルCreateKnowledgeBaseRequest: Knowledge Base作成リクエストのバリデーションS3 URI形式のサポート(自動的にARN形式に変換)
IAMロールARNのアカウントID自動補完
CreateDataSourceRequest: データソース作成リクエストのバリデーションS3 URI形式のサポート(自動的にARN形式に変換)
各種レスポンスモデル
4. types.py - TypedDict定義
APIレスポンスの型安全性を向上させるためのTypedDict定義を提供します。
KnowledgeBaseResponseDict: Knowledge Base作成/更新レスポンスDataSourceResponseDict: データソース作成レスポンスIngestionJobResponseDict: 取り込みジョブレスポンスその他のレスポンス型定義
5. utils.py - ユーティリティ関数
設定管理、エラーハンドリング、ログ出力、ARN正規化などの共通機能を提供します。
validate_aws_credentials(): AWS認証情報の検証get_log_level(): ログレベルの安全な取得handle_errors(): エラーハンドリングデコレータ(AWS APIエラーの適切な処理)10種類以上のAWSエラーコードに対応
AWSリクエストIDを含む詳細なエラー情報
get_aws_account_id(): STSを使用してAWSアカウントIDを取得normalize_s3_arn_or_uri(): S3 URI形式をARN形式に変換normalize_iam_role_arn(): IAMロールARNのアカウントIDを自動補完validate_required_string(): 必須文字列パラメータのバリデーション共通化StructuredFormatter: 構造化ログフォーマッター(JSON形式)sanitize_log_data(): 機密情報のマスキングsetup_logging(): ロギング設定の一元管理
ワークフロー例
1. Knowledge Baseの作成と設定
S3バケットにドキュメントをアップロード
upload_document_to_s3(local_file_path, bucket_name, s3_key)Knowledge Baseを作成(S3 URI形式とIAMロールARNの短縮形式を使用可能)
# 基本的なKnowledge Base create_knowledge_base( name="My Knowledge Base", description="Example KB", role_arn="role/BedrockKBRole", # アカウントIDなし形式(自動補完) storage_type="S3", bucket_arn="s3://my-bucket" # S3 URI形式 ) # S3 Vectorsを使用したKnowledge Base create_knowledge_base( name="Vector KB", description="Vector search enabled KB", role_arn="arn:aws:iam::123456789012:role/BedrockKBRole", storage_type="S3_VECTORS", bucket_arn="s3://vector-bucket", embedding_model_arn="arn:aws:bedrock:us-east-1::foundation-model/amazon.titan-embed-text-v1" ) # マルチモーダルKnowledge Base(Amazon Nova Multimodal Embeddings v1) create_knowledge_base( name="Multimodal KB", description="KB with Nova Multimodal Embeddings", role_arn="role/BedrockKBRole", storage_type="S3_VECTORS", bucket_arn="s3://vector-bucket", embedding_model_arn="arn:aws:bedrock:us-east-1::foundation-model/amazon.nova-2-multimodal-embeddings-v1:0", multimodal_storage_s3_uri="s3://multimodal-storage-bucket/" ) # カスタムパーシングとチャンキング設定を使用 create_knowledge_base( name="Custom KB", description="KB with custom parsing and chunking", role_arn="role/BedrockKBRole", storage_type="S3", bucket_arn="s3://my-bucket", parsing_strategy="BEDROCK_FOUNDATION_MODEL", parsing_model_arn="arn:aws:bedrock:us-east-1::foundation-model/anthropic.claude-3-sonnet-20240229-v1:0", parsing_modality="MULTIMODAL", chunking_strategy="FIXED_SIZE", chunking_max_tokens=1000, chunking_overlap_percentage=20 )データソースを作成(S3 URI形式とカスタム設定を使用可能)
# 基本的なデータソース create_data_source( knowledge_base_id="KB123", name="My Data Source", source_type="S3", bucket_arn="s3://my-bucket" # S3 URI形式 ) # カスタムパーシングとチャンキング設定を使用 create_data_source( knowledge_base_id="KB123", name="Custom Data Source", source_type="S3", bucket_arn="s3://my-bucket", parsing_strategy="BEDROCK_FOUNDATION_MODEL", parsing_model_arn="arn:aws:bedrock:us-east-1::foundation-model/anthropic.claude-3-sonnet-20240229-v1:0", chunking_strategy="FIXED_SIZE", chunking_max_tokens=1000, chunking_overlap_percentage=20 )データ取り込みジョブを開始
start_ingestion_job(knowledge_base_id, data_source_id)ジョブのステータスを確認
get_ingestion_job(knowledge_base_id, data_source_id, ingestion_job_id)
2. RAGクエリの実行
Knowledge Baseに対してクエリを実行
retrieve(knowledge_base_id, query, number_of_results)結果には関連ドキュメントと引用情報が含まれます
アーキテクチャの特徴
1. レイヤードアーキテクチャ
プレゼンテーション層:
main.py- MCPツールの定義と公開ビジネスロジック層:
bedrock_client.py- AWS APIとの通信データ層:
models.py- データバリデーションと型定義
2. エラーハンドリング
すべてのAWS API呼び出しは
ClientErrorを適切に処理10種類以上のAWSエラーコードに対応(InternalServerException、InvalidParameterException、ResourceNotFoundExceptionなど)
AWSリクエストIDを含む詳細なエラー情報
エラーコードに応じた日本語メッセージを提供
エラー情報はログに記録され、ユーザーには分かりやすいメッセージが返却される
3. ロギング
標準ログ: 人間が読みやすい形式(デフォルト)
構造化ログ: JSON形式で出力可能(
FASTMCP_STRUCTURED_LOG=trueで有効化)機密情報の自動マスキング: ARN、認証情報などが自動的にマスクされる
環境変数でログレベルを制御可能
4. 型安全性
Pydanticを使用したデータバリデーション
TypedDictを使用したAPIレスポンスの型定義
すべてのMCPツール関数とBedrockKBClientメソッドの戻り値型を具体的に定義
型ヒントの活用
mypyによる静的型チェック対応
IDEの補完機能と型安全性が向上
5. 入力バリデーションと正規化
ARN形式とURI形式の両方をサポート
S3 ARN形式:
arn:aws:s3:::bucket-nameS3 URI形式:
s3://bucket-nameまたはs3://bucket-name/path(自動的にARN形式に変換)IAMロールARN: 完全な形式または短縮形式(アカウントIDを自動補完)
必須フィールドのチェック
ストレージタイプ、パーシング戦略、チャンキング戦略の列挙型による型安全性の向上
Pydanticモデルによる包括的なバリデーション
6. リトライロジック
AWS API呼び出しにリトライメカニズムを実装
適応的リトライモード(adaptive)を使用
一時的なネットワークエラーやレート制限エラーに対する自動リトライ
セキュリティ考慮事項
AWS認証情報: 環境変数
AWS_PROFILEを使用して認証情報を管理IAMロール: Knowledge Baseには適切なIAMロールが必要
S3アクセス: S3バケットへのアクセス権限が必要
リージョン設定: 適切なAWSリージョンを指定
機密情報のマスキング: ログ出力時にARN、認証情報などが自動的にマスクされる
トラブルシューティング
よくある問題
AWS認証エラー
AWS_PROFILEが正しく設定されているか確認AWS認証情報が有効か確認
boto3が自動的に認証情報を取得する場合もあるため(IAMロール、EC2インスタンスプロファイル)、明示的な設定がなくても動作する場合があります
リージョンエラー
AWS_REGIONが正しく設定されているか確認Bedrockがそのリージョンで利用可能か確認
権限エラー
IAMロールに必要な権限があるか確認
S3バケットへのアクセス権限があるか確認
取り込みジョブの失敗
データソースの設定を確認
S3バケット内のドキュメント形式を確認
バリデーションエラー
ARN形式が正しい場合、エラーメッセージを確認
必須フィールドがすべて指定されているか確認
エラー: AWS認証情報が見つからない
WARNING - AWS認証情報が明示的に設定されていません。解決方法: AWS認証情報を設定してください(クイックスタートの手順2を参照)
エラー: モジュールが見つからない
ModuleNotFoundError: No module named 'fastmcp'解決方法: 依存関係をインストールしてください
uv syncエラー: Pythonバージョンが古い
ERROR: This package requires Python >=3.12解決方法: Python 3.12以上をインストールしてください
サーバーが起動しない
ログレベルを
DEBUGに設定して詳細なログを確認:
export FASTMCP_LOG_LEVEL=DEBUG
uv run bedrock-kb-mcp-server構造化ログを有効にしてJSON形式で確認:
export FASTMCP_STRUCTURED_LOG=true
uv run bedrock-kb-mcp-server実際の使用例
Knowledge Baseの一覧を取得
MCPクライアントからlist_knowledge_basesツールを呼び出すと、AWSアカウント内のすべてのKnowledge Baseが返されます。
Knowledge Baseを作成
{
"name": "my-knowledge-base",
"description": "テスト用のKnowledge Base",
"role_arn": "role/BedrockKnowledgeBaseRole",
"storage_type": "S3",
"bucket_arn": "s3://my-documents-bucket"
}注意:
role_arnは短縮形式(role/ROLE_NAME)も使用可能で、アカウントIDが自動補完されますbucket_arnはS3 URI形式(s3://bucket-name)も使用可能で、自動的にARN形式に変換されます
RAGクエリを実行
{
"knowledge_base_id": "YOUR_KB_ID",
"query": "ドキュメントの内容について教えてください",
"number_of_results": 5
}注意事項
実際のAWS APIを呼び出すため、適切なAWS認証情報とIAM権限が必要です
Knowledge Baseの作成には、適切なIAMロールが必要です
S3バケットへのアクセス権限が必要です
リージョンによってはBedrockが利用できない場合があります
開発
コードフォーマット
black src/
ruff check src/
mypy src/テスト(今後実装予定)
pytestライセンス
MIT License - see LICENSE file for details.
Available Tools
13 toolscreate_bedrock_kb_roleA
Amazon Bedrock Knowledge Base用のサービスロールを作成します。
このツールは、Bedrock Knowledge Baseが使用するIAMロールを作成します。 ロールには以下の信頼ポリシーが設定されます:
Service: bedrock.amazonaws.com
Condition: aws:SourceAccountとaws:SourceArnによる制限
aws:SourceAccount: 現在のAWSアカウントID
aws:SourceArn: arn:aws:bedrock:[REGION]:[ACCOUNT_ID]:knowledge-base/*
Args: role_name: 作成するIAMロールの名前(必須) 例: "BedrockKnowledgeBaseRole" 注意: ロール名はAWSアカウント内で一意である必要があります region: Knowledge Baseを作成する先のリージョン(デフォルト: "us-east-1") 例: "us-east-1", "ap-northeast-1" 注意: 信頼ポリシーのaws:SourceArnにこのリージョンが使用されます このリージョンは、Knowledge Baseを作成する際に指定するリージョンと一致させる必要があります description: ロールの説明(デフォルト: "Bedrock Knowledge Base access") max_session_duration: 最大セッション時間(秒)(デフォルト: 3600秒 = 1時間) 範囲: 3600秒(1時間)から43200秒(12時間)まで
Returns: IAMRoleCreateResponseDict: ロール作成結果 - role_name: 作成されたロール名 - role_arn: ロールのARN(arn:aws:iam::ACCOUNT_ID:role/service-role/ROLE_NAME形式) - path: ロールのパス(/service-role/) - status: 作成ステータス("created")
Raises: ValueError: role_nameが空の場合、またはmax_session_durationが無効な範囲の場合 ClientError: AWS API呼び出しが失敗した場合 例: ロール名が既に使用されている、権限がないなど
Example: # 基本的なロール作成(デフォルトリージョン) create_bedrock_kb_role("BedrockKnowledgeBaseRole")
# 特定のリージョン用のロール作成
create_bedrock_kb_role("BedrockKnowledgeBaseRole", region="ap-northeast-1")
# カスタム説明とセッション時間を指定
create_bedrock_kb_role(
"MyBedrockRole",
description="Custom Bedrock KB role",
max_session_duration=7200
)Note: - ロールは /service-role/ パスに作成されます - 信頼ポリシーには、現在のAWSアカウントIDとリージョンが自動的に設定されます - ロール作成後、適切な権限ポリシーをアタッチする必要があります - ロール名が既に使用されている場合、EntityAlreadyExistsエラーが発生します
| Name | Required | Description | Default |
|---|---|---|---|
| role_name | Yes | ||
| region | No | us-east-1 | |
| description | No | Bedrock Knowledge Base access | |
| max_session_duration | No |
Output Schema
| Name | Required | Description |
|---|---|---|
| path | Yes | |
| status | Yes | |
| role_arn | Yes | |
| role_name | Yes |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
With no annotations provided, the description carries the full burden of behavioral disclosure. It does an excellent job describing what gets created (IAM role with specific trust policy), constraints (role name must be unique, region must match Knowledge Base region), error conditions (ValueError, ClientError), and post-creation requirements (attaching permission policies). The only minor gap is lack of explicit rate limit or authentication requirement information.
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 well-structured with clear sections (Args, Returns, Raises, Example, Note) and front-loaded purpose statement. While comprehensive, some sections could be slightly more concise (e.g., the Example section has multiple similar examples). Every sentence adds value, but there's minor redundancy in the parameter explanations.
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 the complexity of creating an AWS IAM role with specific trust policies, no annotations, and 0% schema coverage, the description provides complete context. It explains the tool's purpose, all parameters, return values (though an output schema exists), error conditions, usage examples, and important implementation notes. Nothing essential appears missing for this type of infrastructure creation tool.
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?
With 0% schema description coverage, the description fully compensates by providing detailed semantic information for all 4 parameters: purpose, examples, constraints, and important notes. Each parameter gets specific guidance beyond what the bare schema provides, including default values, valid ranges, and usage implications.
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 specific action ('creates an IAM role') and resource ('for Amazon Bedrock Knowledge Base'), distinguishing it from sibling tools like create_knowledge_base or create_s3_bucket. It explicitly mentions the trust policy configuration, which further clarifies its specialized purpose.
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 clear context about when to use this tool (to create a service role for Bedrock Knowledge Base) and mentions prerequisites like attaching appropriate permission policies afterward. However, it doesn't explicitly state when NOT to use it or name specific alternatives among the sibling tools.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
create_data_sourceA
Knowledge Baseにデータソースを作成します。
データソースは、Knowledge Baseがデータを取得する場所を定義します。 S3バケットを指定し、必要に応じて特定のプレフィックス(フォルダ)のみを 含めることができます。パーシング設定とチャンキング設定を指定することで、 データソースごとに異なる処理方法を適用できます。
注意: Knowledge Baseのstorage_typeがS3_VECTORSでも、データソースのtypeは
常にS3になります。これらは異なる概念です:
storage_type: Knowledge Baseのストレージ設定(S3またはS3_VECTORS)dataSourceConfiguration.type: データソースのタイプ(S3, WEB, CONFLUENCEなど)
Args: knowledge_base_id: データソースを追加するKnowledge BaseのID name: データソースの名前(1-100文字) source_type: データソースタイプ(現在は'S3'のみサポート、デフォルト: 'S3') bucket_arn: データソースとして使用するS3バケットのARN(arn:aws:s3:::BUCKET_NAME形式) inclusion_prefixes: 含めるS3プレフィックスのカンマ区切り文字列(オプション) 例: "documents/,images/" のように複数のプレフィックスを指定可能 空文字列の場合はバケット内のすべてのオブジェクトが対象
パーシング設定(オプション):
parsing_strategy: パーシング戦略
- 'BEDROCK_FOUNDATION_MODEL': Foundation Modelを使用したパーシング
(マルチモーダルデータ(画像、表、グラフなど)を処理可能、プロンプトカスタマイズ可能)
- 'BEDROCK_DATA_AUTOMATION': Bedrock Data Automationを使用したパーシング
(マルチモーダルデータを処理可能、完全マネージド、追加プロンプト不要)
注意: 指定しない場合はKnowledge Baseのデフォルト設定が使用されます
parsing_model_arn: Foundation ModelのARN(parsing_strategy='BEDROCK_FOUNDATION_MODEL'の場合必須)
例: "arn:aws:bedrock:us-east-1::foundation-model/anthropic.claude-3-sonnet-20240229-v1:0"
サポートされているモデル: Claude 3 Sonnet, Claude 3 Opus, Claude 3 Haikuなど
parsing_modality: マルチモーダル設定
- 'MULTIMODAL': テキストと画像の両方を処理(オプション)
parsing_prompt_text: パーシングプロンプトのテキスト(オプション)
Foundation Modelにドキュメントの解釈方法を指示するテキスト
例: "Extract all text, tables, and figures from this document."
チャンキング設定(オプション):
chunking_strategy: チャンキング戦略
- 'FIXED_SIZE': 固定サイズのチャンクに分割(推奨: max_tokens=1000, overlap_percentage=20)
- 'HIERARCHICAL': 階層的なチャンクに分割(大きなチャンクと小さなチャンクの2層)
- 'SEMANTIC': セマンティックなチャンクに分割(NLPを使用して類似コンテンツでグループ化)
- 'NONE': チャンクに分割しない(各ファイルが1つのチャンクとして扱われる)
注意: 指定しない場合はKnowledge Baseのデフォルト設定が使用されます
chunking_max_tokens: 最大トークン数(chunking_strategy='FIXED_SIZE'または'SEMANTIC'の場合に使用)
- FIXED_SIZE: 1以上(推奨: 500-2000)
- SEMANTIC: 1以上(推奨: 1000-3000)
chunking_overlap_percentage: オーバーラップ率(chunking_strategy='FIXED_SIZE'の場合に使用)
範囲: 1-99(推奨: 10-30)
隣接するチャンク間で重複するトークンの割合
chunking_overlap_tokens: オーバーラップトークン数(chunking_strategy='HIERARCHICAL'の場合に使用)
階層チャンキングで使用する重複トークン数
chunking_buffer_size: バッファサイズ(chunking_strategy='SEMANTIC'の場合に使用)
範囲: 0-1(推奨: 1)
文を比較する際の移動コンテキストウィンドウのサイズ
chunking_breakpoint_threshold: ブレークポイントのパーセンタイル閾値(chunking_strategy='SEMANTIC'の場合に使用)
範囲: 50-99(推奨: 80-95)
チャンクを分割するための類似度閾値(低いほど多くのチャンクが作成される)Returns: DataSourceResponseDict: データソースの作成結果 - data_source_id: 作成されたデータソースのID - status: データソースのステータス('CREATING', 'ACTIVE', 'FAILED'など)
Raises: ValueError: 入力値が無効な場合(source_typeが無効、バリデーションエラーなど) - source_typeが'S3'以外の場合 - parsing_strategy='BEDROCK_FOUNDATION_MODEL'でparsing_model_arnが指定されていない場合 - ARN形式が無効な場合
Examples: # 基本的なデータソースの作成(デフォルト設定) create_data_source( knowledge_base_id="KB123", name="My Data Source", source_type="S3", bucket_arn="arn:aws:s3:::my-bucket" )
# 特定のプレフィックスのみを含めるデータソース
create_data_source(
knowledge_base_id="KB123",
name="Documents Only",
source_type="S3",
bucket_arn="arn:aws:s3:::my-bucket",
inclusion_prefixes="documents/,pdfs/"
)
# カスタムパーシングとチャンキング設定を使用
create_data_source(
knowledge_base_id="KB123",
name="Custom Data Source",
source_type="S3",
bucket_arn="arn:aws:s3:::my-bucket",
parsing_strategy="BEDROCK_FOUNDATION_MODEL",
parsing_model_arn="arn:aws:bedrock:us-east-1::foundation-model/anthropic.claude-3-sonnet-20240229-v1:0",
parsing_modality="MULTIMODAL",
chunking_strategy="FIXED_SIZE",
chunking_max_tokens=1000,
chunking_overlap_percentage=20
)| Name | Required | Description | Default |
|---|---|---|---|
| knowledge_base_id | Yes | ||
| name | Yes | ||
| source_type | No | S3 | |
| bucket_arn | No | ||
| inclusion_prefixes | No | ||
| parsing_strategy | No | ||
| parsing_model_arn | No | ||
| parsing_modality | No | ||
| parsing_prompt_text | No | ||
| chunking_strategy | No | ||
| chunking_max_tokens | No | ||
| chunking_overlap_percentage | No | ||
| chunking_overlap_tokens | No | ||
| chunking_buffer_size | No | ||
| chunking_breakpoint_threshold | No |
Output Schema
| Name | Required | Description |
|---|---|---|
| status | Yes | |
| data_source_id | Yes |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
With no annotations provided, the description carries the full burden of behavioral disclosure. It does well by explaining the creation operation, clarifying conceptual distinctions, noting current limitations (only S3 supported), and documenting error conditions (ValueError cases). It could improve by mentioning authentication requirements or rate limits.
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 well-structured with clear sections (overview, args, parsing settings, chunking settings, returns, raises, examples). While comprehensive, it's appropriately sized for a complex tool with many parameters. Some sections could be more concise, but overall it's well-organized and front-loaded with essential information.
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 the tool's complexity (15 parameters, 0% schema coverage, no annotations), the description provides comprehensive documentation. It covers purpose, parameters, return values, error conditions, and includes practical examples. The presence of an output schema means the description doesn't need to fully explain return values, and it appropriately focuses on usage guidance.
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?
With 0% schema description coverage and 15 parameters, the description provides extensive parameter documentation beyond what the schema offers. It explains each parameter's purpose, provides examples, notes optional vs required status, documents dependencies between parameters, and gives recommended values for many settings.
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 tool creates a data source for a Knowledge Base, specifying it defines where data is retrieved from. It distinguishes from siblings by focusing on data source creation rather than other operations like listing, retrieving, or updating knowledge bases.
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 clear context about when to use this tool (to create data sources for Knowledge Bases) and clarifies important conceptual distinctions between storage_type and dataSourceConfiguration.type. However, it doesn't explicitly mention when NOT to use it or name specific alternative tools for different scenarios.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
create_knowledge_baseA
新しいAmazon Bedrock Knowledge Baseを作成します。
Args: name: Knowledge Baseの名前(1-100文字) description: Knowledge Baseの説明(1文字以上) role_arn: Knowledge Baseが使用するIAMロールのARN - 完全な形式: "arn:aws:iam::ACCOUNT_ID:role/ROLE_NAME" - アカウントIDなし: "arn:aws:iam::role/ROLE_NAME" または "role/ROLE_NAME"(自動補完) storage_type: ストレージタイプ - 'S3': 標準的なS3ストレージ(デフォルト) - 'S3_VECTORS': S3 Vectorsを使用したベクトル検索対応ストレージ bucket_arn: ドキュメントを保存するS3バケットのARNまたはS3 URI - ARN形式: "arn:aws:s3:::BUCKET_NAME" - URI形式: "s3://BUCKET_NAME" または "s3://BUCKET_NAME/path" S3_VECTORSの場合はベクトルバケットARNまたはURIを指定 region: Knowledge Baseを作成する先のリージョン(デフォルト: "us-east-1") 例: "us-east-1", "ap-northeast-1" 注意: Knowledge Baseのリージョンは作成時に決定され、後から変更できません embedding_model_arn: 埋め込みモデルのARN(S3_VECTORSタイプの場合必須) 形式: "arn:aws:bedrock:REGION::foundation-model/MODEL_ID"
サポートされている埋め込みモデル:
- Amazon Titan Embeddings G1 - Text:
"arn:aws:bedrock:REGION::foundation-model/amazon.titan-embed-text-v1"
(ベクトル次元数: 1536、タイプ: Floating-point)
- Amazon Titan Text Embeddings V2:
"arn:aws:bedrock:REGION::foundation-model/amazon.titan-embed-text-v2:0"
(ベクトル次元数: 256, 512, 1024、タイプ: Floating-point, binary)
- Cohere Embed Multilingual:
"arn:aws:bedrock:REGION::foundation-model/cohere.embed-multilingual-v3"
(ベクトル次元数: 1024、タイプ: Floating-point, binary)
- Amazon Nova Multimodal Embeddings v1:
"arn:aws:bedrock:REGION::foundation-model/amazon.nova-2-multimodal-embeddings-v1:0"
(ベクトル次元数: 1024、タイプ: Floating-point)
(マルチモーダル対応: テキスト、画像、動画、音声を処理可能)
注意: マルチモーダルコンテンツを処理する場合は、supplementalDataStorageConfiguration
でマルチモーダルストレージ先を指定する必要があります
例: "arn:aws:bedrock:us-east-1::foundation-model/amazon.titan-embed-text-v1"
注意: リージョンは実際に使用するリージョンに置き換えてください
パーシング設定(オプション):
parsing_strategy: パーシング戦略
- 'BEDROCK_FOUNDATION_MODEL': Foundation Modelを使用したパーシング
(マルチモーダルデータ(画像、表、グラフなど)を処理可能、プロンプトカスタマイズ可能)
- 'BEDROCK_DATA_AUTOMATION': Bedrock Data Automationを使用したパーシング
(マルチモーダルデータを処理可能、完全マネージド、追加プロンプト不要)
注意: 指定しない場合はデフォルトパーサーが使用されます(テキストのみ、無料)
parsing_model_arn: Foundation ModelのARN(parsing_strategy='BEDROCK_FOUNDATION_MODEL'の場合必須)
例: "arn:aws:bedrock:us-east-1::foundation-model/anthropic.claude-3-sonnet-20240229-v1:0"
サポートされているモデル: Claude 3 Sonnet, Claude 3 Opus, Claude 3 Haikuなど
parsing_modality: マルチモーダル設定
- 'MULTIMODAL': テキストと画像の両方を処理(オプション)
parsing_prompt_text: パーシングプロンプトのテキスト(オプション)
Foundation Modelにドキュメントの解釈方法を指示するテキスト
例: "Extract all text, tables, and figures from this document."
チャンキング設定(オプション):
chunking_strategy: チャンキング戦略
- 'FIXED_SIZE': 固定サイズのチャンクに分割(推奨: max_tokens=1000, overlap_percentage=20)
- 'HIERARCHICAL': 階層的なチャンクに分割(大きなチャンクと小さなチャンクの2層)
- 'SEMANTIC': セマンティックなチャンクに分割(NLPを使用して類似コンテンツでグループ化)
- 'NONE': チャンクに分割しない(各ファイルが1つのチャンクとして扱われる)
注意: 指定しない場合はデフォルトのチャンキングが使用されます
chunking_max_tokens: 最大トークン数(chunking_strategy='FIXED_SIZE'または'SEMANTIC'の場合に使用)
- FIXED_SIZE: 1以上(推奨: 500-2000)
- SEMANTIC: 1以上(推奨: 1000-3000)
chunking_overlap_percentage: オーバーラップ率(chunking_strategy='FIXED_SIZE'の場合に使用)
範囲: 1-99(推奨: 10-30)
隣接するチャンク間で重複するトークンの割合
chunking_overlap_tokens: オーバーラップトークン数(chunking_strategy='HIERARCHICAL'の場合に使用)
階層チャンキングで使用する重複トークン数
chunking_buffer_size: バッファサイズ(chunking_strategy='SEMANTIC'の場合に使用)
範囲: 0-1(推奨: 1)
文を比較する際の移動コンテキストウィンドウのサイズ
chunking_breakpoint_threshold: ブレークポイントのパーセンタイル閾値(chunking_strategy='SEMANTIC'の場合に使用)
範囲: 50-99(推奨: 80-95)
チャンクを分割するための類似度閾値(低いほど多くのチャンクが作成される)Returns: KnowledgeBaseResponseDict: Knowledge Baseの作成結果 - knowledge_base_id: 作成されたKnowledge BaseのID - status: Knowledge Baseのステータス('CREATING', 'ACTIVE', 'FAILED'など) - arn: Knowledge BaseのARN(オプション)
Raises: ValueError: 入力値が無効な場合(バリデーションエラー) - storage_typeが無効な値の場合 - S3_VECTORSタイプでembedding_model_arnが指定されていない場合 - parsing_strategy='BEDROCK_FOUNDATION_MODEL'でparsing_model_arnが指定されていない場合 - ARN形式が無効な場合
Examples: # 基本的なKnowledge Baseの作成(デフォルト設定) create_knowledge_base( name="My Knowledge Base", description="Example KB", role_arn="arn:aws:iam::123456789012:role/BedrockKBRole", storage_type="S3", bucket_arn="s3://my-bucket" # S3 URI形式も使用可能 )
# S3 Vectorsを使用したKnowledge Baseの作成
create_knowledge_base(
name="Vector KB",
description="Vector search enabled KB",
role_arn="role/BedrockKBRole", # アカウントIDなし形式も使用可能(自動補完)
storage_type="S3_VECTORS",
bucket_arn="s3://vector-bucket", # S3 URI形式も使用可能
embedding_model_arn="arn:aws:bedrock:us-east-1::foundation-model/amazon.titan-embed-text-v1"
)
# カスタムパーシングとチャンキング設定を使用
create_knowledge_base(
name="Custom KB",
description="KB with custom parsing and chunking",
role_arn="arn:aws:iam::123456789012:role/BedrockKBRole",
storage_type="S3",
bucket_arn="arn:aws:s3:::my-bucket",
parsing_strategy="BEDROCK_FOUNDATION_MODEL",
parsing_model_arn="arn:aws:bedrock:us-east-1::foundation-model/anthropic.claude-3-sonnet-20240229-v1:0",
parsing_modality="MULTIMODAL",
chunking_strategy="FIXED_SIZE",
chunking_max_tokens=1000,
chunking_overlap_percentage=20
)
# Amazon Nova Multimodal Embeddings v1を使用したマルチモーダルKnowledge Base
create_knowledge_base(
name="Multimodal KB",
description="KB with Nova Multimodal Embeddings",
role_arn="arn:aws:iam::123456789012:role/BedrockKBRole",
storage_type="S3_VECTORS",
bucket_arn="arn:aws:s3:::vector-bucket",
embedding_model_arn="arn:aws:bedrock:us-east-1::foundation-model/amazon.nova-2-multimodal-embeddings-v1:0",
multimodal_storage_s3_uri="s3://multimodal-storage-bucket/"
)| Name | Required | Description | Default |
|---|---|---|---|
| name | Yes | ||
| description | Yes | ||
| role_arn | Yes | ||
| storage_type | No | S3 | |
| bucket_arn | No | ||
| embedding_model_arn | No | ||
| region | No | us-east-1 | |
| parsing_strategy | No | ||
| parsing_model_arn | No | ||
| parsing_modality | No | ||
| parsing_prompt_text | No | ||
| chunking_strategy | No | ||
| chunking_max_tokens | No | ||
| chunking_overlap_percentage | No | ||
| chunking_overlap_tokens | No | ||
| chunking_buffer_size | No | ||
| chunking_breakpoint_threshold | No | ||
| multimodal_storage_s3_uri | No |
Output Schema
| Name | Required | Description |
|---|---|---|
| arn | Yes | |
| status | Yes | |
| knowledge_base_id | Yes |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
With no annotations provided, the description carries the full burden. It discloses key behavioral traits: the region is immutable after creation, certain parameters are required conditionally (e.g., embedding_model_arn for S3_VECTORS), and it raises ValueError for invalid inputs. It also notes default values and recommendations, though it lacks details on permissions, rate limits, or costs.
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 well-structured with sections for args, parsing settings, chunking settings, returns, raises, and examples. However, it is very long and dense, which may overwhelm. While informative, some details could be streamlined or moved to schema descriptions for better conciseness, though it remains organized.
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 the high complexity (18 parameters, 0% schema coverage, no annotations) and the presence of an output schema, the description is highly complete. It covers all parameters thoroughly, explains returns and errors, and provides multiple examples. The output schema handles return values, so the description appropriately focuses on inputs and behavior.
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?
The schema description coverage is 0%, so the description must compensate fully. It provides extensive parameter semantics: detailed explanations for each parameter, including formats, allowed values, examples, dependencies, and recommendations. This adds significant value beyond the bare schema, making parameters understandable and actionable.
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 tool's purpose: '新しいAmazon Bedrock Knowledge Baseを作成します' (creates a new Amazon Bedrock Knowledge Base). It specifies the exact resource (Knowledge Base) and distinguishes it from siblings like update_knowledge_base (which modifies) and get_knowledge_base (which retrieves).
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 clear context for when to use this tool (to create a Knowledge Base) and includes examples with different configurations. However, it does not explicitly state when not to use it or compare it to alternatives like update_knowledge_base for modifications, though the purpose implies it's for initial creation only.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
create_s3_bucketA
S3バケットを新規作成します。
バケット名は以下のルールに従う必要があります:
3文字以上63文字以下
小文字、数字、ハイフン(-)、ピリオド(.)のみ使用可能
先頭と末尾は小文字または数字である必要がある
連続するハイフンやピリオドは使用不可
IPアドレス形式(例: 192.168.1.1)は使用不可
バケット名はグローバルに一意である必要があります
注意: セキュリティ上の理由から、パブリックアクセスブロックは常に有効化されます。
Args: bucket_name: 作成するS3バケット名(必須) 例: "my-documents-bucket" region: バケットを作成するリージョン(デフォルト: "us-east-1") 例: "us-east-1", "ap-northeast-1" 注意: us-east-1リージョンの場合、LocationConstraintは指定しません
Returns: S3BucketCreateResponseDict: バケット作成結果 - bucket_name: 作成されたバケット名 - region: バケットが作成されたリージョン - arn: バケットのARN(arn:aws:s3:::bucket-name形式) - status: 作成ステータス("created")
Raises: ValueError: bucket_nameが空の場合、またはバケット名が無効な形式の場合 ClientError: AWS API呼び出しが失敗した場合 例: バケット名が既に使用されている、権限がないなど
Example: # 基本的なバケット作成(デフォルトリージョン、パブリックアクセスブロック有効) create_s3_bucket("my-documents-bucket")
# 特定のリージョンにバケットを作成
create_s3_bucket("my-documents-bucket", region="ap-northeast-1")Note: - バケットの作成には数秒かかる場合があります - バケット名が既に使用されている場合、BucketAlreadyOwnedByYouまたはBucketAlreadyExistsエラーが発生します - パブリックアクセスブロック設定は、バケット作成後に自動的に適用されます
| Name | Required | Description | Default |
|---|---|---|---|
| bucket_name | Yes | ||
| region | No | us-east-1 |
Output Schema
| Name | Required | Description |
|---|---|---|
| arn | Yes | |
| region | Yes | |
| status | Yes | |
| bucket_name | Yes |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
With no annotations provided, the description carries full burden and does an excellent job disclosing behavioral traits. It explains security implications (public access block always enabled), timing considerations (creation may take seconds), error conditions (bucket name conflicts, permission issues), and post-creation behavior (automatic public access block application). The only minor gap is lack of rate limit or quota information.
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 well-structured with clear sections (description, rules, Args, Returns, Raises, Example, Note) and front-loads the core purpose. While comprehensive, some redundancy exists (bucket naming rules appear in both the main description and parameter documentation), and the Japanese/English mix slightly affects readability. Every section adds value, but could be more tightly integrated.
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 the tool's complexity (creation with security implications), 0% schema coverage, and presence of an output schema, the description is exceptionally complete. It covers purpose, detailed constraints, parameters, return values (though output schema handles this), error conditions, examples, and important behavioral notes. The output schema existence means the description doesn't need to explain return structure in detail.
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?
With 0% schema description coverage, the description fully compensates by providing rich parameter semantics. It explains bucket_name requirements with detailed naming rules, provides examples, and clarifies region behavior including special handling for us-east-1. The Args section explicitly documents both parameters with examples and important notes about default values and constraints.
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 tool's purpose: 'S3バケットを新規作成します' (creates a new S3 bucket). It specifies the exact resource (S3 bucket) and action (create), and distinguishes it from sibling tools like 'upload_document_to_s3' or 'list_s3_documents' by focusing on bucket creation rather than document operations.
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 implied usage context through bucket naming rules and region defaults, but lacks explicit guidance on when to use this tool versus alternatives. It doesn't mention scenarios where other tools like 'create_data_source' or 'create_knowledge_base' might be more appropriate, or prerequisites for bucket creation.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
get_ingestion_jobA
取り込みジョブのステータスと詳細情報を取得します。
取り込みジョブの進捗状況、統計情報、エラー情報などを取得できます。
Args:
knowledge_base_id: Knowledge BaseのID
data_source_id: データソースのID
ingestion_job_id: 取り込みジョブのID(start_ingestion_jobで取得)
Returns: IngestionJobResponseDict: 取り込みジョブの詳細情報 - ingestion_job_id: 取り込みジョブのID - status: ジョブのステータス - "STARTING": ジョブが開始中 - "IN_PROGRESS": ジョブが実行中 - "COMPLETE": ジョブが完了 - "FAILED": ジョブが失敗 - statistics: 統計情報(オプション、ジョブが進行中または完了している場合) - numberOfDocumentsScanned: スキャンされたドキュメント数 - numberOfDocumentsModified: 変更されたドキュメント数 - numberOfDocumentsDeleted: 削除されたドキュメント数 - numberOfDocumentsFailed: 失敗したドキュメント数
Raises: ValueError: いずれかのIDが空の場合
| Name | Required | Description | Default |
|---|---|---|---|
| knowledge_base_id | Yes | ||
| data_source_id | Yes | ||
| ingestion_job_id | Yes |
Output Schema
| Name | Required | Description |
|---|---|---|
| status | Yes | |
| statistics | Yes | |
| ingestion_job_id | Yes |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
With no annotations provided, the description carries the full burden. It discloses that the tool retrieves status, progress, statistics, and error information, and mentions a ValueError for empty IDs, which adds some behavioral context. However, it lacks details on permissions, rate limits, or side effects, leaving gaps for a mutation-free but potentially sensitive operation.
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 well-structured with clear sections (Args, Returns, Raises) and uses bullet points for returns, making it easy to scan. It is appropriately sized, though the Japanese text might be slightly verbose; every sentence adds value without redundancy.
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 the tool's complexity (3 required parameters, no annotations, but has an output schema), the description is fairly complete. It explains the purpose, parameters, return values (including status enums and statistics), and error conditions. The output schema reduces the need to detail returns, but more behavioral context (e.g., idempotency, auth) would enhance completeness.
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 0%, so the description must compensate. It adds meaning by explaining each parameter's purpose (e.g., knowledge_base_id as Knowledge Base ID, ingestion_job_id from start_ingestion_job) and includes a 'Raises' section for error conditions, which goes beyond the bare schema. However, it doesn't detail parameter formats or constraints beyond IDs being non-empty.
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 tool's purpose: '取り込みジョブのステータスと詳細情報を取得します' (Get ingestion job status and detailed information). It specifies the verb '取得します' (get) and resource '取り込みジョブ' (ingestion job), but does not explicitly differentiate from sibling tools like 'start_ingestion_job' beyond mentioning it as the source for the job ID.
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 implies usage by referencing 'start_ingestion_job' for obtaining the ingestion_job_id, suggesting it should be used after starting a job. However, it lacks explicit guidance on when to use this tool versus alternatives (e.g., monitoring vs. initiating jobs) or any exclusions, leaving some ambiguity.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
get_knowledge_baseB
特定のAmazon Bedrock Knowledge Baseの詳細情報を取得します。
Args: knowledge_base_id: Knowledge BaseのID
Returns: KnowledgeBaseDetailDict: Knowledge Baseの詳細情報 - id: Knowledge BaseのID - name: Knowledge Baseの名前 - status: Knowledge Baseのステータス - description: Knowledge Baseの説明(オプション) - arn: Knowledge BaseのARN(オプション) - その他の設定情報
Raises: ValueError: knowledge_base_idが空の場合
| Name | Required | Description | Default |
|---|---|---|---|
| knowledge_base_id | Yes |
Output Schema
| Name | Required | Description |
|---|---|---|
| id | Yes | |
| arn | Yes | |
| name | Yes | |
| status | Yes | |
| description | Yes |
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. It states this is a retrieval operation ('取得します'), implying it's likely read-only, but doesn't explicitly confirm this or disclose other behavioral traits such as authentication needs, rate limits, error handling beyond the ValueError, or what happens if the ID is invalid. The description adds minimal behavioral context beyond the basic purpose.
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 appropriately sized and front-loaded with the purpose in the first sentence. The Args, Returns, and Raises sections are structured but could be more concise; for example, the Returns section lists details that might be better covered by the output schema. Overall, it's efficient with minimal waste.
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 the tool has an output schema (implied by 'Has output schema: true'), the description doesn't need to fully explain return values, and it adequately covers the single parameter and basic error case. However, with no annotations and multiple sibling tools, it lacks context on usage and behavioral details, keeping it from a perfect score.
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?
The input schema has 0% description coverage, but the description compensates well by explaining the single parameter 'knowledge_base_id' as 'Knowledge BaseのID' and noting it raises a ValueError if empty. This adds clear meaning beyond the bare schema. With 0% schema coverage and one parameter, the baseline is high, and the description meets it effectively.
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 tool's purpose: '特定のAmazon Bedrock Knowledge Baseの詳細情報を取得します' (retrieves detailed information for a specific Amazon Bedrock Knowledge Base). It specifies the verb '取得します' (retrieve) and resource 'Knowledge Baseの詳細情報' (Knowledge Base details). However, it doesn't explicitly differentiate from sibling tools like 'list_knowledge_bases' or 'update_knowledge_base', which would require a 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. It doesn't mention sibling tools like 'list_knowledge_bases' (for listing all knowledge bases) or 'update_knowledge_base' (for modifying one), nor does it specify prerequisites or contexts for usage. The only implicit guidance is that you need a specific knowledge_base_id, but this is insufficient for a higher score.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
list_data_sourcesB
指定されたKnowledge Baseのデータソース一覧を取得します。
Knowledge Baseに紐づけられているすべてのデータソースを取得します。
Args: knowledge_base_id: Knowledge BaseのID
Returns: DataSourceListResponseDict: データソース一覧 - count: データソースの数 - data_sources: データソースの詳細情報のリスト 各要素には以下の情報が含まれます: - id: データソースのID - name: データソースの名前 - status: データソースのステータス - dataSourceConfiguration: データソースの設定情報
Raises: ValueError: knowledge_base_idが空の場合
| Name | Required | Description | Default |
|---|---|---|---|
| knowledge_base_id | Yes |
Output Schema
| Name | Required | Description |
|---|---|---|
| count | Yes | |
| data_sources | Yes |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
With no annotations provided, the description carries full burden. It states the tool retrieves data (read-only implied) and mentions an error case (ValueError for empty ID), but lacks critical behavioral details: whether it requires authentication, rate limits, pagination handling (the 'count' field suggests multiple items), or what happens if the knowledge base doesn't exist. For a read operation with zero annotation coverage, this is insufficient.
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 appropriately sized but not optimally structured. It front-loads the purpose, but includes a redundant second sentence. The Args/Returns/Raises sections are clear but could be more integrated. Some details (like error handling) are useful, but the overall flow could be tighter.
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 the tool's low complexity (single parameter, read operation) and the presence of an output schema (implied by the detailed return description), the description is mostly complete. It covers purpose, parameters, returns, and an error case. However, it lacks behavioral context (e.g., auth, pagination) which would be needed for full completeness, especially with no annotations.
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 0%, so the description must compensate fully. It does: it explicitly documents the single parameter 'knowledge_base_id' with its purpose ('Knowledge BaseのID'), and provides detailed return value semantics including nested structure ('count', 'data_sources' with 'id', 'name', 'status', 'dataSourceConfiguration'). This adds substantial meaning beyond the bare schema.
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 ('取得します' - retrieve/get) and resource ('データソース一覧' - data source list) for a specific Knowledge Base. It distinguishes from siblings like 'list_knowledge_bases' (which lists knowledge bases themselves) and 'list_s3_documents' (which lists documents in S3). However, it doesn't explicitly contrast with 'get_knowledge_base' which retrieves details of a single knowledge base.
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. It doesn't mention prerequisites (e.g., needing an existing knowledge base), nor does it compare with sibling tools like 'get_knowledge_base' for single knowledge base details or 'list_knowledge_bases' for listing knowledge bases themselves. The context is implied but not explicit.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
list_knowledge_basesB
すべてのAmazon Bedrock Knowledge Baseの一覧を取得します。
Returns: KnowledgeBaseListResponseDict: Knowledge Base一覧 - count: Knowledge Baseの数 - knowledge_bases: Knowledge Baseの詳細情報のリスト
| Name | Required | Description | Default |
|---|---|---|---|
No parameters | |||
Output Schema
| Name | Required | Description |
|---|---|---|
| count | Yes | |
| knowledge_bases | Yes |
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 only states what the tool does and the return structure, but doesn't cover important aspects like whether it's read-only, if there are rate limits, authentication requirements, pagination behavior, or error handling. For a tool with zero annotation coverage, this is a significant gap in transparency.
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 appropriately sized and front-loaded, with the main purpose stated first in a clear sentence. The return information is provided concisely. However, the Japanese text might add slight complexity for non-Japanese agents, and it could be slightly more structured by separating purpose and returns more distinctly.
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 the tool's low complexity (0 parameters) and the presence of an output schema (which describes the return structure), the description is somewhat complete. It states the purpose and hints at the return format. However, without annotations and with missing behavioral details (e.g., safety, performance), it doesn't fully compensate for the lack of structured context, making it adequate but with clear gaps.
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?
The input schema has 0 parameters with 100% coverage, so the schema fully documents the lack of parameters. The description doesn't need to add parameter information, and it correctly doesn't mention any parameters. This meets the baseline for tools with no parameters, as it doesn't mislead about inputs.
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 tool's purpose as 'すべてのAmazon Bedrock Knowledge Baseの一覧を取得します' (get a list of all Amazon Bedrock Knowledge Bases), which is a specific verb+resource combination. However, it doesn't explicitly differentiate from sibling tools like 'get_knowledge_base' (which retrieves details of a specific knowledge base) or 'list_data_sources' (which lists data sources rather than knowledge bases), missing full sibling differentiation.
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. It doesn't mention scenarios like needing a full list versus a specific knowledge base (use 'get_knowledge_base'), or how it relates to other listing tools like 'list_data_sources'. There's no context on prerequisites or exclusions, leaving usage unclear.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
list_s3_documentsA
S3バケット内のドキュメント一覧を取得します。
指定されたプレフィックス(フォルダ)に一致するドキュメントのみを 取得することもできます。
Args: bucket_name: S3バケット名 prefix: フィルタリングするS3プレフィックス(オプション) 例: "documents/" を指定すると、documents/フォルダ内の ファイルのみが返されます
Returns: S3DocumentListResponseDict: ドキュメント一覧 - count: ドキュメントの数 - bucket: バケット名 - prefix: 使用されたプレフィックス(指定した場合) - documents: ドキュメントの詳細情報のリスト 各要素には以下の情報が含まれます: - key: S3オブジェクトキー(ファイルパス) - size: ファイルサイズ(バイト) - last_modified: 最終更新日時(ISO形式)
Raises: ValueError: bucket_nameが空の場合
Example: # すべてのドキュメントを取得 list_s3_documents("my-bucket")
# 特定のプレフィックスのドキュメントのみを取得
list_s3_documents("my-bucket", "documents/")| Name | Required | Description | Default |
|---|---|---|---|
| bucket_name | Yes | ||
| prefix | No |
Output Schema
| Name | Required | Description |
|---|---|---|
| count | Yes | |
| bucket | Yes | |
| prefix | Yes | |
| documents | Yes |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
With no annotations provided, the description carries full burden. It discloses the read-only nature through '取得します' (retrieves) and mentions error conditions (ValueError for empty bucket_name). However, it doesn't cover important behavioral aspects like pagination, rate limits, authentication requirements, or whether it lists all objects recursively within prefixes.
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 well-structured with clear sections (Args, Returns, Raises, Example) and uses both Japanese and English effectively. While comprehensive, some information could be more concise - the prefix explanation uses multiple lines when one might suffice. Overall, most sentences earn their place.
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 the tool's moderate complexity, no annotations, but with output schema coverage, the description is reasonably complete. It explains parameters thoroughly, documents the return structure in detail, shows error conditions, and provides usage examples. The main gap is lack of behavioral context like pagination or authentication requirements.
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?
With 0% schema description coverage, the description fully compensates by providing detailed parameter semantics. It explains both parameters thoroughly: bucket_name as S3 bucket name, prefix as optional filtering parameter with a clear example showing how it works. The Japanese and English explanations add clarity beyond what the bare schema provides.
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 tool's purpose: 'S3バケット内のドキュメント一覧を取得します' (retrieves a list of documents in an S3 bucket). It specifies the verb (取得/retrieve) and resource (ドキュメント一覧/document list), but doesn't explicitly differentiate from sibling tools like 'list_data_sources' or 'list_knowledge_bases' beyond the S3 context.
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 implied usage context through the optional prefix parameter explanation and examples, showing when to use it for filtering. However, it doesn't explicitly state when to choose this tool over alternatives like 'upload_document_to_s3' or 'list_data_sources', nor does it mention prerequisites or exclusions.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
retrieveB
Knowledge Baseに対してRAG(Retrieval-Augmented Generation)クエリを実行します。
ベクトル検索を使用して、クエリに関連するドキュメントを取得します。
Args: knowledge_base_id: クエリ対象のKnowledge BaseのID query: 検索クエリのテキスト number_of_results: 返す結果の数(デフォルト: 5、範囲: 1-100)
Returns: RetrieveResponseDict: クエリ結果 - results: 検索結果のリスト(各結果にはcontent、location、score、metadataが含まれる) - query: 実行したクエリテキスト
Raises: ValueError: 入力値が無効な場合(knowledge_base_idやqueryが空、number_of_resultsが範囲外など)
| Name | Required | Description | Default |
|---|---|---|---|
| knowledge_base_id | Yes | ||
| query | Yes | ||
| number_of_results | No |
Output Schema
| Name | Required | Description |
|---|---|---|
| query | Yes | |
| results | Yes |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
With no annotations provided, the description carries the full burden of behavioral disclosure. It does mention that it 'raises ValueError' for invalid inputs, which adds some error-handling context. However, it doesn't describe important behavioral aspects like authentication requirements, rate limits, performance characteristics, or what happens when no results are found. The description provides basic operational context but misses key behavioral traits for a query tool.
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 well-structured with clear sections (purpose, Args, Returns, Raises) and front-loads the core functionality. Each sentence earns its place by providing essential information. The Japanese/English mix is slightly inconsistent but doesn't hinder understanding. It could be slightly more concise in the opening paragraph but overall maintains good information density.
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 the tool's moderate complexity (3 parameters, query operation), no annotations, but with an output schema (Returns section), the description provides adequate context. The output schema existence means the description doesn't need to fully explain return values, which it acknowledges with the Returns section. It covers parameters well and provides basic error information. For a retrieval tool with output schema support, this is reasonably complete though could benefit from more behavioral 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?
With 0% schema description coverage, the description must compensate for the lack of parameter documentation in the schema. It successfully documents all three parameters with clear explanations: 'knowledge_base_id: クエリ対象のKnowledge BaseのID', 'query: 検索クエリのテキスト', and 'number_of_results: 返す結果の数(デフォルト: 5、範囲: 1-100)'. The description adds meaningful context beyond what the bare schema provides, including default values and valid ranges.
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 tool's purpose: 'Knowledge Baseに対してRAG(Retrieval-Augmented Generation)クエリを実行します。ベクトル検索を使用して、クエリに関連するドキュメントを取得します。' This specifies the verb (execute RAG query), resource (Knowledge Base), and method (vector search). It distinguishes from siblings by focusing on retrieval rather than creation, listing, or management operations. However, it doesn't explicitly contrast with potential similar retrieval tools (none exist among siblings).
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. While the purpose is clear, there's no mention of prerequisites (e.g., needing an existing knowledge base), typical use cases, or comparisons to other tools. The sibling tools are all management/creation operations, so this is the only query tool, but the description doesn't acknowledge this context or provide any usage context beyond the basic function.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
start_ingestion_jobA
データソースからKnowledge Baseへのデータ取り込みジョブを開始します。
このジョブは非同期で実行され、データソース内のドキュメントを
Knowledge Baseに取り込みます。ジョブの進捗はget_ingestion_jobで確認できます。
Args: knowledge_base_id: Knowledge BaseのID data_source_id: データソースのID
Returns: IngestionJobResponseDict: 取り込みジョブの開始結果 - ingestion_job_id: 開始された取り込みジョブのID - status: ジョブのステータス(通常は "STARTING" または "IN_PROGRESS") - statistics: 統計情報(オプション、ジョブ開始時は通常None)
Raises: ValueError: knowledge_base_idまたはdata_source_idが空の場合
Note:
取り込みジョブは非同期で実行されるため、この関数は即座に返ります。
ジョブの完了を待つには、get_ingestion_jobを定期的に呼び出して
ステータスを確認してください。
| Name | Required | Description | Default |
|---|---|---|---|
| knowledge_base_id | Yes | ||
| data_source_id | Yes |
Output Schema
| Name | Required | Description |
|---|---|---|
| status | Yes | |
| statistics | Yes | |
| ingestion_job_id | Yes |
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. It effectively discloses key behavioral traits: the job is asynchronous, returns immediately, and progress must be monitored via get_ingestion_job. It also mentions error conditions (ValueError for empty IDs). However, it lacks details on permissions, rate limits, or side effects (e.g., whether it overwrites existing data), leaving some gaps in transparency.
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 well-structured and appropriately sized. It starts with a clear purpose statement, followed by usage notes, parameter explanations, return values, and error handling. Each sentence adds value (e.g., explaining asynchronicity, monitoring, and error cases) without redundancy. The use of sections (Args, Returns, Raises, Note) enhances readability.
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 the tool's complexity (asynchronous job initiation) and the presence of an output schema (which covers return values like ingestion_job_id, status, statistics), the description is complete. It explains the tool's purpose, usage, parameters, and behavioral aspects (asynchronicity, monitoring). No annotations are provided, but the description compensates adequately, making it self-sufficient for an agent to use the tool correctly.
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?
The schema description coverage is 0%, so the description must compensate. It adds clear semantics for both parameters: knowledge_base_id is the ID of the Knowledge Base, and data_source_id is the ID of the data source. This goes beyond the schema's basic type definitions. However, it doesn't specify format constraints (e.g., UUID) or provide examples, which could improve clarity further.
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 tool's purpose: 'データソースからKnowledge Baseへのデータ取り込みジョブを開始します' (starts a data ingestion job from a data source to a Knowledge Base). It specifies the exact action (start ingestion job) and resources involved (data source, Knowledge Base), distinguishing it from sibling tools like get_ingestion_job (monitors progress) or create_data_source (creates resources).
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 explicit guidance on when and how to use this tool. It states that the job runs asynchronously, recommends using get_ingestion_job to check progress, and warns that this function returns immediately without waiting for completion. It also mentions prerequisites (knowledge_base_id and data_source_id must not be empty) and raises ValueError if they are, helping users avoid errors.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
update_knowledge_baseA
Amazon Bedrock Knowledge Baseを更新します。
Knowledge Baseの名前、説明、IAMロールを更新できます。 空文字列のパラメータは更新されません(既存の値が保持されます)。
Args: knowledge_base_id: 更新対象のKnowledge BaseのID name: 新しい名前(オプション、空文字列の場合は更新されない) description: 新しい説明(オプション、空文字列の場合は更新されない) role_arn: 新しいIAMロールARN(オプション、空文字列の場合は更新されない)
Returns: KnowledgeBaseResponseDict: 更新されたKnowledge Baseのステータス - knowledge_base_id: Knowledge BaseのID - status: Knowledge Baseのステータス - arn: Knowledge BaseのARN(オプション)
Raises: ValueError: knowledge_base_idが空の場合
| Name | Required | Description | Default |
|---|---|---|---|
| knowledge_base_id | Yes | ||
| name | No | ||
| description | No | ||
| role_arn | No |
Output Schema
| Name | Required | Description |
|---|---|---|
| arn | Yes | |
| status | Yes | |
| knowledge_base_id | Yes |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
With no annotations provided, the description carries the full burden. It discloses key behavioral traits: it's a mutation tool (implied by '更新します'), handles partial updates (empty strings don't change existing values), and raises a ValueError for empty knowledge_base_id. However, it lacks details on permissions, rate limits, side effects, or error handling beyond the one exception mentioned.
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 well-structured with clear sections (purpose, updatable fields, parameter details, returns, raises). It's appropriately sized, but the 'Args' and 'Returns' sections could be more integrated into natural language. Every sentence adds value, though minor redundancy exists (e.g., repeating '空文字列の場合は更新されない').
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, 0% schema coverage, but an output schema exists, the description is fairly complete. It covers purpose, parameters, return values (though output schema handles details), and one error case. However, for a mutation tool, it could better address behavioral aspects like idempotency, concurrency, or authentication needs.
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 0%, so the description must compensate fully. It does so by explaining all 4 parameters: 'knowledge_base_id' (ID of the target), 'name' (new name, optional, empty string preserves existing), 'description' (new description, optional, empty preserves), and 'role_arn' (new IAM role ARN, optional, empty preserves). It adds crucial semantics like optionality and update behavior not in the schema.
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 tool's purpose: 'Amazon Bedrock Knowledge Baseを更新します' (updates an Amazon Bedrock Knowledge Base). It specifies the resource (Knowledge Base) and action (update), and lists updatable fields (name, description, IAM role). However, it doesn't explicitly differentiate from sibling tools like 'create_knowledge_base' or 'get_knowledge_base' beyond the verb 'update'.
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 implies usage context through the parameter explanations (e.g., empty strings preserve existing values) and the required 'knowledge_base_id', suggesting this is for modifying existing knowledge bases. However, it doesn't explicitly state when to use this tool versus alternatives like 'create_knowledge_base' or provide prerequisites (e.g., needing an existing knowledge base ID).
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
upload_document_to_s3A
ローカルファイルをS3バケットにアップロードします。
アップロードされたファイルは、Knowledge Baseのデータソースとして 使用できます。
Args: local_file_path: アップロードするローカルファイルのパス bucket_name: アップロード先のS3バケット名 s3_key: S3オブジェクトキー(バケット内のパス) 例: "documents/myfile.pdf" のようにパスを指定可能
Returns: S3UploadResponseDict: アップロード結果 - s3_uri: アップロードされたファイルのS3 URI(s3://bucket/key形式) - status: アップロードステータス("uploaded")
Raises: ValueError: パラメータが空の場合、またはファイルが存在しない場合
Example: upload_document_to_s3( "/path/to/document.pdf", "my-bucket", "documents/document.pdf" ) # 戻り値: {"s3_uri": "s3://my-bucket/documents/document.pdf", "status": "uploaded"}
| Name | Required | Description | Default |
|---|---|---|---|
| local_file_path | Yes | ||
| bucket_name | Yes | ||
| s3_key | Yes |
Output Schema
| Name | Required | Description |
|---|---|---|
| s3_uri | Yes | |
| status | Yes |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
With no annotations provided, the description carries the full burden of behavioral disclosure. It does reveal some behavioral traits: it describes the return format (S3UploadResponseDict with s3_uri and status), error conditions (ValueError for empty parameters or missing files), and provides an example. However, it lacks details on permissions needed, rate limits, file size constraints, or whether the operation is idempotent/destructive.
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 well-structured with sections (Args, Returns, Raises, Example) and front-loaded with the core purpose. It's appropriately sized for a 3-parameter tool with output schema. Some minor redundancy exists (e.g., repeating parameter info in example), but overall it's efficient and organized.
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 the tool's moderate complexity (3 parameters, no annotations, but has output schema), the description is fairly complete. It covers purpose, parameters, return values, errors, and provides an example. The output schema existence means it doesn't need to explain return values in detail. However, it could better address integration with sibling tools and operational constraints.
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 0%, so the description must compensate. It provides clear semantics for all three parameters: local_file_path (path to upload), bucket_name (destination bucket), and s3_key (S3 object key with example). The example further clarifies usage. However, it doesn't specify constraints like path formats, bucket naming rules, or key structure limitations beyond the example.
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 tool's purpose: 'ローカルファイルをS3バケットにアップロードします' (Upload local files to an S3 bucket). It specifies the verb (upload) and resource (local files to S3 bucket). However, it doesn't explicitly differentiate from sibling tools like 'create_s3_bucket' or 'list_s3_documents', which would be needed for a perfect score.
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 implied usage context by mentioning that uploaded files can be used as Knowledge Base data sources, which suggests integration with other sibling tools. However, it doesn't explicitly state when to use this tool versus alternatives (e.g., vs. 'create_data_source' or 'start_ingestion_job'), nor does it provide clear exclusions or prerequisites beyond parameter validation.
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.
13 tool updates
v0.1.0- First observed
create_bedrock_kb_role - First observed
create_data_source - First observed
create_knowledge_base - First observed
create_s3_bucket - First observed
get_ingestion_job - First observed
get_knowledge_base - First observed
list_data_sources - First observed
list_knowledge_bases - First observed
list_s3_documents - First observed
retrieve - First observed
start_ingestion_job - First observed
update_knowledge_base - First observed
upload_document_to_s3
TDQS
Scored across 13 tools
Each tool has a distinct purpose with clear boundaries: create_bedrock_kb_role handles IAM role creation, create_s3_bucket and upload_document_to_s3 manage S3 infrastructure, create_knowledge_base and update_knowledge_base manage KB lifecycle, create_data_source configures data sources, start_ingestion_job and get_ingestion_job handle ingestion workflows, list_* tools provide read-only views, and retrieve performs querying. There is no functional overlap between tools.
All tools follow a consistent verb_noun naming pattern with snake_case: create_bedrock_kb_role, create_data_source, create_knowledge_base, create_s3_bucket, get_ingestion_job, get_knowledge_base, list_data_sources, list_knowledge_bases, list_s3_documents, retrieve, start_ingestion_job, update_knowledge_base, upload_document_to_s3. The pattern is perfectly uniform across all 13 tools.
With 13 tools, the set is well-scoped for managing Amazon Bedrock Knowledge Bases. It covers the full lifecycle: infrastructure setup (S3, IAM), KB CRUD operations, data source management, ingestion workflows, querying, and listing operations. Each tool serves a necessary purpose without redundancy.
The toolset provides comprehensive coverage for core KB workflows: create, read, update, list, and query operations are well-represented. Minor gaps include the lack of delete operations for knowledge bases, data sources, or S3 resources, and no tool to attach policies to the created IAM role. However, agents can still accomplish most tasks with the available tools.
Maintenance
Related MCP Connectors
Ingest, manage, and retrieve documents for RAG-powered AI applications
Universal persistent memory and knowledge retrieval layer for AI agents and LLMs.
- KumbukaOAuthai.kumbuka
Governed, auditable knowledge your team curates for its AI assistants, self-hostable
Turn documents into structured, AI-ready data by parsing, enriching, chunking, and embedding.
Related MCP Servers
- AlicenseAqualityDmaintenanceEnables creation and querying of knowledge bases using Google's Gemini API File Search feature, allowing AI applications to upload documents and retrieve information through RAG (Retrieval-Augmented Generation).3106MIT
- AlicenseAqualityDmaintenanceEnables AI assistants to query and retrieve information from Amazon Bedrock Knowledge Base using the Retrieve API, returning search results with content, location, and relevance scores.1MIT
- FlicenseNot gradedqualityBmaintenanceConnects RAG knowledge bases to Claude Desktop and Claude Code, allowing retrieval-augmented generation from ingested documents.-
- AlicenseNot gradedqualityCmaintenanceEnables querying, listing, and summarizing personal knowledge base documents using RAG with hybrid search and LLM.MIT