aws / aws/bedrock-agentcore-sdk-python

Port AgentCoreMemoryStore (MemoryStore interface) from TypeScript SDK to Python

オープン
#661 コメント 0 件 リアクション 0 件 担当者 0 名 GitHub で見る

まだ誰も着手していません。

enhancement
主要言語
Python
スター
764
フォーク
148
平均マージ
1日 23時間
マージ済み PR(30日)
7

説明

### Problem Statement

The TypeScript `bedrock-agentcore` SDK (v0.4.1+) ships an `AgentCoreMemoryStore` that implements the Strands `MemoryStore` interface, enabling AgentCore Memory to plug into the `MemoryManager` pipeline with recall (search tool), injection (automatic prompt augmentation), and server-side extraction. It is documented on the Strands integrations page: https://strandsagents.com/docs/integrations/memory-stores/agentcore-memory-store/

The Python `bedrock-agentcore` SDK currently only integrates AgentCore Memory as a session manager (`AgentCoreMemorySessionManager`). There is no `MemoryStore` implementation, so Python developers cannot use AgentCore Memory with `MemoryManager`.

### Proposed Solution

Port the `AgentCoreMemoryStore` from the TypeScript SDK to Python. The integration lives at `bedrock-agentcore/memory/integrations/strands/` in the TS package and maps:

- `search` to AgentCore's `retrieveMemoryRecords`
- `add_messages` to conversation ingestion for server-side extraction
- Per-namespace store creation via a `create_agentcore_memory_stores` factory

Target usage:

```python
from strands import Agent
from strands.memory import MemoryManager
from bedrock_agentcore.memory.integrations.strands.memory_store import (
AgentCoreMemoryStore,
create_agentcore_memory_stores,
)

stores = create_agentcore_memory_stores(
memory_id="mem-abc",
actor_id="user-123",
session_id="session-1",
namespaces=[
{"namespace": "/facts/{actorId}", "writable": True},
{"namespace": "/preferences/{actorId}"},
],
extraction=True,
)

agent = Agent(memory_manager=MemoryManager(stores=stores))
```

### Use Case

Python agents that want to use AgentCore Memory as a long-term memory backend through the standard `MemoryManager` pipeline, with injection, recall tools, and extraction.

### Additional Context

- TypeScript implementation: https://github.com/aws/bedrock-agentcore-sdk-typescript/tree/main/src/memory/integrations/strands
- Strands integration page (TS only): https://strandsagents.com/docs/integrations/memory-stores/agentcore-memory-store/
- The existing Python `AgentCoreMemorySessionManager` would remain for session persistence use cases. The `MemoryStore` is complementary.

コントリビューションガイド

コントリビューションガイドを開く

はじめの一歩

  1. issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
  2. 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
  3. リポジトリをフォークし、ブランチを切って変更します。
  4. issue 番号を参照したプルリクエストを送ります。

調査の方向性

まず bedrock-agentcore/memory/integrations/strands 配下の TypeScript 実装を読み、Python AgentCoreMemorySessionManager と比較します。issue で説明されている Python memory_store.py のエントリポイントと factory を追加し、search と add_messages を AgentCore Memory にマッピングします。Python ユーザーが作成された store を Strands MemoryManager に渡して recall、injection、extraction に利用できれば完了です。

索引モデルが issue の本文から書いたものです。

評価

技術スタック
aws, python, typescript
領域
ai, backend
issue の種類
機能追加
難易度
4/5
見積もり時間
3〜5日
活発さ
活発
明瞭さ
おおむね明確
初心者へのやさしさ
58/100

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。