v2.0.19
Mem0 Python SDK (v2.0.19)
Added 1
- Add provider_override to AWSBedrockConfig for explicit provider name when model is an application inference profile ARN
Changed 1
- mem0.proxy no longer auto-installs litellm via subprocess and instead raises ImportError with installation instructions
Fixed 5
- HuggingFaceEmbedding now falls back to the HUGGINGFACE_API_KEY environment variable, then a placeholder key, when huggingface_base_url is set and no api_key is configured
- remove_code_blocks() now accepts list-shaped content by joining each block's text before stripping code fences instead of raising AttributeError
- create_procedural_memory() now raises a clear ValueError when the LLM returns no content for the summary instead of continuing with empty content
- get_all() now sends page and page_size as independent query params instead of requiring both to be set before either was sent
- VllmConfig now falls back to the VLLM_BASE_URL environment variable when vllm_base_url is not passed explicitly
From Mem0
Bug Fixes:
- Embeddings:
HuggingFaceEmbeddingnow falls back to theHUGGINGFACE_API_KEYenv var, then a placeholder key, whenhuggingface_base_urlis set and noapi_keyis configured. The OpenAI-compatible client used to talk to TEI endpoints raises at construction when no key resolves at all, so a TEI deployment that doesn't require a real key previously failed to initialize (#6947) - Core:
remove_code_blocks()now accepts list-shaped content (a sequence of{"text": ...}blocks, as some agent frameworks pass) by joining each block's text before stripping code fences, instead of raisingAttributeErrorfrom calling.strip()on a list (#6947) - Core:
create_procedural_memory()(MemoryandAsyncMemory) now raises a clearValueErrorwhen the LLM returns no content for the summary, instead of continuing with empty content that surfaced as a confusing error further down the call (#6947) - Proxy:
mem0.proxyno longer auto-installslitellmvia apip installsubprocess when the import fails; it now raisesImportErrorwith instructions to install it yourself. The auto-install could hang or fail silently in restricted environments and ran an unreviewed install on the caller's behalf (#6947) - Client:
get_all()(sync and async) now sendspageandpage_sizeas independent query params instead of requiring both to be set before either was sent. Passing onlypage_sizewithoutpagepreviously had it silently dropped, so results came back at the server's default page size (#6900) - LLMs: Add
provider_overridetoAWSBedrockConfig, an explicit provider name (for example"anthropic") for whenmodelis an application inference profile ARN whose opaque ID has no provider substring forextract_provider()to detect. Without it, those ARNs raisedValueError: Unable to determine provider(#6899) - LLMs:
VllmConfignow falls back to theVLLM_BASE_URLenv var whenvllm_base_urlisn't passed explicitly. The default was filled in before the env var was ever checked, soVLLM_BASE_URLwas silently ignored (#6897)