Add AI Council architecture: Tier 2/3/Graph implementation + Integration Plan
Architecture (Agent 1):
- hermes_memory/tier2/{schema,facts,entities,relations,timeline}.py
- hermes_memory/tier3/{backend,chroma_backend,embedder}.py
- hermes_memory/graph/nx_store.py
- hermes_memory/api/memory_api.py (unified API)
- hermes_memory/cron/{consolidate,embed_queue,graph_refresh,prune}.py
- hermes_memory/config.py + pyproject.toml
Integration Plan (Agent 3):
- INTEGRATION_PLAN.md: Memory Provider Plugin strategy
- Hermes Core needs minimal changes
- sync_turn() + prefetch() hooks
- Skills integration via nextlevel_search/remember
Auto-Extraction (Agent 2):
- ARCHITECTURE.md: Full extraction pipeline docs
- Chunking, Pre-Filter, LLM Prompts, Classification
- Entity-Linking, Temporal Reasoning, Deduplication
All files: Python syntax checked, ECC standards applied.
This commit is contained in:
@@ -0,0 +1,35 @@
|
||||
"""Abstrakte Backend-Schnittstelle für Vektor-DBs."""
|
||||
|
||||
from abc import ABC, abstractmethod
|
||||
from dataclasses import dataclass
|
||||
from typing import Dict, List
|
||||
|
||||
|
||||
@dataclass
|
||||
class SearchResult:
|
||||
chunk_id: str
|
||||
score: float
|
||||
text: str
|
||||
metadata: Dict
|
||||
|
||||
|
||||
class VectorBackend(ABC):
|
||||
@abstractmethod
|
||||
def index(self, chunks: List[str], payloads: List[Dict]) -> List[str]:
|
||||
"""Indexiert Chunks, gibt chunk_ids zurück."""
|
||||
...
|
||||
|
||||
@abstractmethod
|
||||
def search(self, query_embedding: List[float], limit: int = 10, filters: Dict = None) -> List[SearchResult]:
|
||||
"""Semantische Suche mit Query-Embedding."""
|
||||
...
|
||||
|
||||
@abstractmethod
|
||||
def delete(self, chunk_ids: List[str]) -> bool:
|
||||
"""Löscht Chunks anhand ihrer IDs."""
|
||||
...
|
||||
|
||||
@abstractmethod
|
||||
def health(self) -> Dict:
|
||||
"""Gibt Status-Informationen zurück."""
|
||||
...
|
||||
Reference in New Issue
Block a user