Skip to content

Fixed s3 vectors memory initialization issue from configuration#3481

Merged
parshvadaftari merged 3 commits intomem0ai:mainfrom
abdullahirfann:fix/s3-vector-memory-initialization-from-config
Sep 20, 2025
Merged

Fixed s3 vectors memory initialization issue from configuration#3481
parshvadaftari merged 3 commits intomem0ai:mainfrom
abdullahirfann:fix/s3-vector-memory-initialization-from-config

Conversation

@abdullahirfann
Copy link
Copy Markdown
Contributor

Description

Support for S3 Vectors was provided in v0.1.117. However, upon testing, it was found that initializing Memory via config with S3VectorConfig throws an AttributeError. Upon further investigation, turns out that S3VectorConfig contains the index_name attribute, while initializing Memory with config requires the collection_name attribute to be present in the config object.

This fix uses the collection_name attribute name to store the index name to be used within the S3 vector bucket. This aligns with the uniformity provided across other vector stores and their interaction with the Memory class.

Type of change

  • Bug fix (non-breaking change which fixes an issue)
  • Documentation update

How Has This Been Tested?

  • Unit Test

Test Details

  • leveraged the existing tests/vector_stores/test_s3_vectors.py file
  • added a test test_memory_initialization_with_config to ensure an AttributeException exception is not thrown while initializing Memory with an S3VectorConfig config, and confirm successful initialization of the Memory object

Checklist:

  • My code follows the style guidelines of this project
  • I have performed a self-review of my own code
  • I have commented my code, particularly in hard-to-understand areas
  • I have made corresponding changes to the documentation
  • My changes generate no new warnings
  • I have added tests that prove my fix is effective or that my feature works
  • New and existing unit tests pass locally with my changes
  • Any dependent changes have been merged and published in downstream modules
  • I have checked my code and corrected any misspellings

Strikethrough means 'Not Applicable'

Maintainer Checklist

  • closes #xxxx (Replace xxxx with the GitHub issue number)
  • Made sure Checks passed

@CLAassistant
Copy link
Copy Markdown

CLAassistant commented Sep 18, 2025

CLA assistant check
All committers have signed the CLA.

@abdullahirfann
Copy link
Copy Markdown
Contributor Author

Please review this issue with top priority to ensure the functioning of the framework aligns with the documentation. I was about to migrate to mem0 from Langchain in my production application before I came across this issue so I wanted to make sure noone else finds themselves in the same situation 😊

@parshvadaftari
Copy link
Copy Markdown
Contributor

@abdullahirfann Thanks for pointing it out. Can you fix the failing tests as well?

@abdullahirfann
Copy link
Copy Markdown
Contributor Author

@abdullahirfann Thanks for pointing it out. Can you fix the failing tests as well?

@parshvadaftari Waiting for approval on builds

@parshvadaftari parshvadaftari merged commit 9df392b into mem0ai:main Sep 20, 2025
6 of 7 checks passed
@parshvadaftari
Copy link
Copy Markdown
Contributor

Thanks a lot for pointing it out and your contribution.

jamebobob pushed a commit to jamebobob/mem0-vigil-recall that referenced this pull request Mar 29, 2026
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