Skip to content

Feat/14 session management tutorial#255

Open
vaibhavjainv wants to merge 2 commits into
strands-agents:mainfrom
vaibhavjainv:feat/14-session-management-tutorial
Open

Feat/14 session management tutorial#255
vaibhavjainv wants to merge 2 commits into
strands-agents:mainfrom
vaibhavjainv:feat/14-session-management-tutorial

Conversation

@vaibhavjainv

Copy link
Copy Markdown

Adds the 14-session-management tutorial to python/01-learn/.

The tutorial covers how to persist Strands agent conversation state across restarts using the session management system. It progresses through 5 notebooks:

01-baseline.ipynb — demonstrates the default stateless behavior (no persistence)
02-file-session-manager.ipynb — local persistence with FileSessionManager
03-s3-session-manager.ipynb — cloud persistence with S3SessionManager (self-contained: creates and deletes the S3 bucket)
04-custom-dynamodb-backend.ipynb — implementing a custom SessionRepository backed by DynamoDB
05-multi-agent-sessions.ipynb — session persistence with Swarm and Graph multi-agent patterns

- 5 notebooks: baseline, FileSessionManager, S3SessionManager,
  custom DynamoDB backend, multi-agent (Swarm/Graph) sessions
- Self-contained S3 notebook with bucket create/delete
- DynamoDB notebook with Decimal type handling for production use
- Architecture diagram (SVG)
- Tested end-to-end against live AWS (Bedrock, S3, DynamoDB)
…ix, AWS architecture diagram

- Add botocore[crt] to all notebook install cells and requirements.txt
- S3 notebook: auto-create/delete bucket using account ID
- DynamoDB notebook: int() casts for Decimal types from DynamoDB
- Replace SVG with PNG architecture diagram using AWS icons
- Strip notebook outputs
@github-actions

github-actions Bot commented May 7, 2026

Copy link
Copy Markdown

Latest scan for commit: f2a6dce | Updated: 2026-05-07 17:46:27 UTC

✅ Security Scan Report (PR Files Only)

Scanned Files

  • python/01-learn/14-session-management/01-baseline.ipynb
  • python/01-learn/14-session-management/02-file-session-manager.ipynb
  • python/01-learn/14-session-management/03-s3-session-manager.ipynb
  • python/01-learn/14-session-management/04-custom-dynamodb-backend.ipynb
  • python/01-learn/14-session-management/05-multi-agent-sessions.ipynb
  • python/01-learn/14-session-management/README.md
  • python/01-learn/14-session-management/images/architecture.png
  • python/01-learn/14-session-management/requirements.txt
  • python/01-learn/README.md

Security Scan Results

Critical High Medium Low Info
0 0 0 0 0

Threshold: High

No security issues detected in your changes. Great job!

This scan only covers files changed in this PR.

@manoj-selvakumar5

Copy link
Copy Markdown
Collaborator

Hi @vaibhav-jain-lilly - Thanks for this — the progression is good.

  • Let's consolidate 5 notebooks into 2. Right now 02-file-session-manager and 03-s3-session-manager are structurally the same notebook — create agent → two turns → inspect persisted data → restore → cleanup — and the only real difference is the manager constructor. The baseline is also just a few cells different.
  1. Single-agent persistence — start with the baseline failure (a few cells), introduce SessionManager, show FileSessionManager, then present S3 as "same agent, swap the backend." Add custom DynamoDB backend as advanced towards the end of notebook 1.
  2. Multi-agent persistence
  • Needs a rebase + renumber. This was branched off an older main
    Happy to look again once the structure is reworked !

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants