fix(api): add full parameter to GET /api/v1/memories for full episode content#132
Open
Jah-yee wants to merge 3 commits intoEverMind-AI:mainfrom
Open
fix(api): add full parameter to GET /api/v1/memories for full episode content#132Jah-yee wants to merge 3 commits intoEverMind-AI:mainfrom
Jah-yee wants to merge 3 commits intoEverMind-AI:mainfrom
Conversation
- Rename stage3_memory_retrivel.py to stage3_memory_retrieval.py (typo fix) - Replace == None with is None (Python anti-pattern) - Replace != True with is not True (Python anti-pattern) - Replace bare except with except Exception - Remove duplicate 'rrf' entry in docstring - Remove unused MongoDB init script volume mount from docker-compose.yaml - Add missing env template setup step in STARTER_KIT.md quick start Fixes: EverMind-AI#115, EverMind-AI#113, EverMind-AI#107, EverMind-AI#97, EverMind-AI#91, EverMind-AI#90, EverMind-AI#86
…v slicing
When using sliced runs (e.g. --from-conv 234 --to-conv 264), the index
files were being saved with sequential indices (0, 1, 2...) but search
was looking up with global conversation IDs (234, 235, 263), causing
'BM25 index not found' errors.
Changes:
- stage2_index_building.py: Use conversation_ids to name index files with
extracted numeric IDs (e.g., 'bm25_index_conv_234.pkl')
- evermemos_adapter.py:
- Pass conversation_ids to stage2 for proper file naming
- Fix conv_id_to_index mapping to map conversation_id -> extracted
numeric ID (not sequential index)
- Update _check_missing_indexes to use proper file naming
- Save conversation_index_mapping.json for debugging
This ensures index files and search lookups use consistent IDs.
… content This commit addresses issue EverMind-AI#131 by adding a 'full' query parameter to the GET /api/v1/memories endpoint. When full=True, the response includes the complete episode field which is not returned by default for backward compatibility. Changes: - Add 'full' parameter to FetchMemRequest DTO - Add 'episode' field to EpisodicMemoryModel (optional, returned only when full=True) - Update find_memories method to accept 'full' parameter - Update _convert_episodic_memory to conditionally include episode content - Update memory_manager to pass 'full' parameter to fetch service This allows external benchmarks and third-party integrations to access the full episodic memory content for auditing and verification purposes. See: EverMind-AI#131
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Good day,
I noticed that the GET /api/v1/memories endpoint does not return the full episode content, which prevents external users (benchmarks, third-party integrations) from accessing the complete episodic memory data.
Changes Made
full: Optional[bool] = Falseparameter toFetchMemRequestepisodefield toEpisodicMemoryModelwith proper documentationfullparameter tofind_memoriesmethod signature_convert_episodic_memoryto conditionally include episode content whenfull=Truefullparameter from request to fetch serviceHow It Works
titleandsummary(backward compatible)episodefield containing the full episodic contentExample Usage
Testing
python3 -m py_compile)Note on Issue #131
This addresses the first part of issue #131 (adding
?full=trueparameter).Thank you for your dedication to this project. I hope this helps. If there are any issues or areas for improvement, please leave a comment, and I will address them.
Warmly,
Spark