[memory/RAG] Dead code: src/rag_manager.py is a zero-value wrapper that just delegates to VectorRAG #747

Closed
opened 2026-06-03 00:17:58 +02:00 by sleepy · 0 comments
Owner

File: src/rag_manager.py — 59 lines

RAGManager is a pure delegation class where every method (search, retrieve, rebuild_index, get_stats, add_document, add_documents_batch, index_personal_documents) does nothing but call self.vector_rag.<same_method>().

It also has a fragile triple-import fallback chain:

try:
    from rag_vector import VectorRAG
except ImportError:
    try:
        from .rag_vector import VectorRAG
    except ImportError:
        from src.rag_vector import VectorRAG

This wrapper adds no logic, no caching, no transformation — just an extra indirection layer. All callers could import VectorRAG directly.

Action: Audit all callers of RAGManager and replace with direct VectorRAG usage, then delete src/rag_manager.py.

**File**: `src/rag_manager.py` — 59 lines `RAGManager` is a pure delegation class where every method (`search`, `retrieve`, `rebuild_index`, `get_stats`, `add_document`, `add_documents_batch`, `index_personal_documents`) does nothing but call `self.vector_rag.<same_method>()`. It also has a fragile triple-import fallback chain: ```python try: from rag_vector import VectorRAG except ImportError: try: from .rag_vector import VectorRAG except ImportError: from src.rag_vector import VectorRAG ``` This wrapper adds no logic, no caching, no transformation — just an extra indirection layer. All callers could import `VectorRAG` directly. **Action**: Audit all callers of `RAGManager` and replace with direct `VectorRAG` usage, then delete `src/rag_manager.py`.
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
sleepy/odysseus#747
No description provided.