Skip to content

Fixes 145: using a supported model for Mem0 in the tutorial#227

Open
tomdee2 wants to merge 1 commit intostrands-agents:mainfrom
tomdee2:main
Open

Fixes 145: using a supported model for Mem0 in the tutorial#227
tomdee2 wants to merge 1 commit intostrands-agents:mainfrom
tomdee2:main

Conversation

@tomdee2
Copy link

@tomdee2 tomdee2 commented Feb 24, 2026

Issue #145

Description of changes:

Mem0 defaults to Claude 3.5 Haiku if a model is not explicitly specified. This causes the error below when trying to running tutorial 7.

An error occurred (ValidationException) when calling the InvokeModel operation: Invocation of model ID          │
anthropic.claude-3-5-haiku-20241022-v1:0 with on-demand throughput isn’t supported. Retry your request with the │
ID or ARN of an inference profile that contains this model. 

This PR fixes this issue by explicitly setting the model for Mem0 to use as the same model which is being used elsewhere.

By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.

@github-actions
Copy link

github-actions bot commented Mar 6, 2026

Latest scan for commit: cddc32a | Updated: 2026-03-06 01:45:41 UTC

✅ Security Scan Report (PR Files Only)

Scanned Files

  • 01-tutorials/01-fundamentals/07-memory-persistent-agents/personal_agent_with_memory.ipynb

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.

"from strands import Agent, tool\n",
"from strands.models import bedrock\n",
"from strands_tools import mem0_memory\n",
"from strands_tools.mem0_memory import Mem0ServiceClient\n",
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hi @tomdee2 - the main branch has already been updated to the latest us.anthropic.claude-sonnet-4-5-20250929-v1:0 model. Could you please update this PR?

Also, lets use the environment variable instead of importing Mem0ServiceClient class, which I think should work

os.environ["MEM0_LLM_MODEL"] = "us.anthropic.claude-sonnet-4-5-20250929-v1:0"]

@manoj-selvakumar5
Copy link
Collaborator

@tomdee2 - Please apply the same fix the the Python file as well

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.

2 participants