Conversation
Document についてResearch を利用するために、GenU のデプロイをする方がどんな作業をすればいいのか説明する Document も追加をお願いできますでしょうか? Document については、以下を意識していただけると幸いです。 以下の DEPLOY_OPTION は簡潔に記載する。 詳細な Document を用意する場合は、以下のような新しいドキュメントを用意する |
- リサーチエージェントデプロイガイドを追加(日本語/英語/韓国語) - DEPLOY_OPTION.mdにリサーチエージェントセクションを追加 - Brave Search API取得手順の画像8枚を追加
00a6468 to
79cb1a8
Compare
- Add isResearchAgent flag to StrandsStreamProcessor - Detect research agent by checking mode field (technical-research, mini-research, general-research) - Process <final_report> tags only for research agent (content inside tags -> chat, outside -> trace) - Keep backward compatibility for other AgentCore features (generic, agent builder, MCP) - No changes to Lambda/backend, only frontend processing
- Add name field to image ExtraData - Add null checks for block.image.source and block.document.source - Fix regex pattern (remove extra parenthesis) - Add default values for optional fields
- Restore all deleted translation keys in meetingMinutes section - generation_panel, hide_prompt, style_diagram, style_whiteboard, etc. - diagram options (flowchart, mindmap, sequence, timeline) - UI controls (both_panel, input_source, microphone, option, settings) - Add research section translations for all 6 languages - Fix Tavily API key injection for research agent backend - Update documentation with deployment instructions - Clean up MCP configuration and agent prompts
e6eeb82 to
c2fc6e2
Compare
|
下記対応しました |
…me の 2 つ存在していたが、ほぼすべての状況でこちらは 1 個の変数のみ利用する形になるので、ユーザーへのわかりやすさを優先して 1 つにまとめる
Sugi275
left a comment
There was a problem hiding this comment.
各種指摘修正されているのを確認しました! Approved です!
There was a problem hiding this comment.
127 行目の "@aws-cdk" の後に追加するよりは、94 行目の "closedNetworkCreateResolverEndpoint" の後に記載いただくのが良いかなとおもいました。
There was a problem hiding this comment.
少し前の main ブランチからマージをされているような気がしています。議事録機能側の変更が少し前にデグレっています。最新のファイルに、議事録側を更新できますか?
There was a problem hiding this comment.
少し前の main ブランチからマージをされているような気がしています。議事録機能側の変更が少し前にデグレっています。最新のファイルに、議事録側を更新できますか?
There was a problem hiding this comment.
少し前の main ブランチからマージをされているような気がしています。議事録機能側の変更が少し前にデグレっています。最新のファイルに、議事録側を更新できますか?
There was a problem hiding this comment.
少し前の main ブランチからマージをされているような気がしています。議事録機能側の変更が少し前にデグレっています。最新のファイルに、議事録側を更新できますか?
packages/cdk/cdk.json
Outdated
| "researchAgentEnabled": false, | ||
| "createResearchAgentCoreRuntime": false, |
There was a problem hiding this comment.
researchAgentEnabled と createResearchAgentCoreRuntime を別に Flug を用意する必要はないのかなと思いました。
researchAgentEnabled は、フロントエンド側の表示を制御するためのもので、createResearchAgentCoreRuntime こちらは CDK 側で、AgentCore Runtime をデプロイするのかどうかのフラグだと理解しています。
Research のユースケースに関しては、1 個のフラグで管理することで問題ないかなと思っています。
createGenericAgentCoreRuntime について
createGenericAgentCoreRuntime に関しては、汎用的な AgentCore Runtime のデプロイをコントロールするもので、ユーザーが選択しても良いと思いますが、Research においては、2 つのフラグに分ける意図は思い浮かびませんでした~。
| *$py.class | ||
| .venv/ | ||
| .uv/ | ||
| uv.lock |
There was a problem hiding this comment.
uv.lock は、gitignore に入れてしまうと、GenU の Deploy に失敗してしまっていました。
uv.lock は、repository に入れる形になるかなと思っていますが、いかがでしょう?
エラーログ
Dockerfile:21
--------------------
19 |
20 | # Copy dependency files
21 | >>> COPY pyproject.toml .python-version uv.lock ./
22 | # Install Python dependencies
23 | RUN uv sync
--------------------
ERROR: failed to solve: failed to compute cache key: failed to calculate checksum of ref 3f5f5128-b8d9-41c0-92a2-a49a72017586::05e5lo44mff40m7ddu6djusiv: "/uv.lock": not found
ResearchAgentCoreStack: fail: docker build --tag cdkasset-41f0e080dd905095131f2c326b011c98a063c4398180a2df0db231319a0829f0 . exited with error code 1: #0 building with "default" instance using docker driver
#1 [internal] load build definition from Dockerfile
#1 transferring dockerfile: 1.14kB done
#1 DONE 0.0s
#2 [internal] load metadata for public.ecr.aws/docker/library/python:3.13
#2 DONE 0.9s
#3 [internal] load .dockerignore
#3 transferring context: 201B done
#3 DONE 0.0s
#4 [internal] load build context
#4 transferring context: 1.59kB done
#4 DONE 0.0s
#5 [ 3/11] RUN apt-get update -y && apt-get install curl nodejs npm -y
#5 CACHED
#6 [ 4/11] RUN curl -LsSf https://astral.sh/uv/install.sh | sh
#6 CACHED
#7 [ 2/11] WORKDIR /var/task
#7 CACHED
#8 [ 5/11] RUN npm install -g mcp-remote
#8 CACHED
#9 [ 6/11] COPY pyproject.toml .python-version uv.lock ./
#9 ERROR: failed to calculate checksum of ref 3f5f5128-b8d9-41c0-92a2-a49a72017586::05e5lo44mff40m7ddu6djusiv: "/uv.lock": not found
#10 [ 1/11] FROM public.ecr.aws/docker/library/python:3.13@sha256:02865b3929f3910fc2d6ebbf745bf00504d316478dacaea7d9e230e134411bcb
#10 resolve public.ecr.aws/docker/library/python:3.13@sha256:02865b3929f3910fc2d6ebbf745bf00504d316478dacaea7d9e230e134411bcb 0.0s done
#10 sha256:02865b3929f3910fc2d6ebbf745bf00504d316478dacaea7d9e230e134411bcb 10.96kB / 10.96kB done
#10 CANCELED
------
> [ 6/11] COPY pyproject.toml .python-version uv.lock ./:
------
Dockerfile:21
--------------------
19 |
20 | # Copy dependency files
21 | >>> COPY pyproject.toml .python-version uv.lock ./
22 | # Install Python dependencies
23 | RUN uv sync
--------------------
ERROR: failed to solve: failed to compute cache key: failed to calculate checksum of ref 3f5f5128-b8d9-41c0-92a2-a49a72017586::05e5lo44mff40m7ddu6djusiv: "/uv.lock": not found
| "brave-search-1": { | ||
| "command": "npx", | ||
| "args": ["-y", "@brave/brave-search-mcp-server"], | ||
| "env": { | ||
| "BRAVE_API_KEY": "" | ||
| }, | ||
| "metadata": { | ||
| "category": "Search", | ||
| "description": "Primary web search capabilities powered by Brave Search (API Key 1)" | ||
| } | ||
| }, | ||
| "brave-search-2": { | ||
| "command": "npx", | ||
| "args": ["-y", "@brave/brave-search-mcp-server"], | ||
| "env": { | ||
| "BRAVE_API_KEY": "" | ||
| }, | ||
| "metadata": { | ||
| "category": "Search", | ||
| "description": "Secondary web search capabilities powered by Brave Search (API Key 2)" | ||
| } | ||
| }, | ||
| "brave-search-3": { | ||
| "command": "npx", | ||
| "args": ["-y", "@brave/brave-search-mcp-server"], | ||
| "env": { | ||
| "BRAVE_API_KEY": "" | ||
| }, | ||
| "metadata": { | ||
| "category": "Search", | ||
| "description": "Tertiary web search capabilities powered by Brave Search (API Key 3)" | ||
| } | ||
| }, | ||
| "brave-search-4": { | ||
| "command": "npx", | ||
| "args": ["-y", "@brave/brave-search-mcp-server"], | ||
| "env": { | ||
| "BRAVE_API_KEY": "" | ||
| }, | ||
| "metadata": { | ||
| "category": "Search", | ||
| "description": "Quaternary web search capabilities powered by Brave Search (API Key 4)" | ||
| } |
There was a problem hiding this comment.
こちらって、MCP Server 4 つ起動する背景ってありそうですか? API Key は 1 個しか指定できないので、MCP Server も 1 個でいいんじゃないかなと思いました。
| brave_api_key = os.getenv("BRAVE_API_KEY", "") | ||
| if brave_api_key: | ||
| # Inject into brave-search server | ||
| if "brave-search" in servers: | ||
| if "env" not in servers["brave-search"]: | ||
| servers["brave-search"]["env"] = {} | ||
| servers["brave-search"]["env"]["BRAVE_API_KEY"] = brave_api_key | ||
| logger.info("Injected Brave API Key into brave-search MCP server") |
There was a problem hiding this comment.
ここの Brave の API key を挿入する実装なのですが、mcp-configs/mcp.json の brave-search-1, brave-search-2, brave-search-3, brave-search-4 の指定とずれていて、API キーが挿入されていないように見えています。
mcp-configs/mcp.json は、brave は 1 個だけでいいかなという気がしています。
| case 'video': | ||
| return { | ||
| video: { | ||
| format: getVideoFormatFromMimeType(data.source.mediaType), | ||
| source: { | ||
| bytes: base64Data, | ||
| }, | ||
| }, | ||
| }; | ||
|
|
There was a problem hiding this comment.
こちら、video を削除された背景はありますでしょうか?
Sugi275
left a comment
There was a problem hiding this comment.
LGTM です!各種修正されていることを確認しました。
Description of Changes
This PR introduces a new Research Agent feature that enables users to conduct comprehensive research tasks using web search capabilities.
New Features
Technical Changes
ResearchAgentCoreStackandResearchAgentCoreconstruct for deploying the research agent runtimeResearchAgentPage.tsx,useResearchAgent.tshook, andDiagramRenderer.tsxcomponentresearchAgentEnabled(default:false)createResearchAgentCoreRuntime(default:false)researchAgentBraveApiKey(single string, not array)researchAgentTavilyApiKey(single string, not array)Impact on Existing Users
researchAgentEnabled: trueand providing API keys incdk.json@aws-cdk/aws-bedrock-agentcore-alphapackage (already included)How to Enable
researchAgentEnabled: trueincdk.jsoncreateResearchAgentCoreRuntime: trueincdk.jsonresearchAgentBraveApiKeyorresearchAgentTavilyApiKey(or both)npm run cdk:deployChecklist
npm run cdk:testand if there are snapshot differences, executenpm run cdk:test:update-snapshotto update snapshotsRelated Issues
Related to #1000