FinanceEducationAssistant / src /data /chroma_config.py
Fade0510's picture
Add Knowledge base
db2df31
Raw
History Blame Contribute Delete
478 Bytes
"""
Centralized Chroma configuration.
The project intentionally uses a single persistent Chroma collection and separates
different logical stores (KB docs, Tavily web cache, semantic cache, etc.) via a
`namespace` metadata field.
"""
from __future__ import annotations
import os
PERSIST_DIRECTORY = "src/data/.chroma"
COLLECTION_NAME = "finance_assistant"
def ensure_persist_dir(path: str = PERSIST_DIRECTORY) -> str:
os.makedirs(path, exist_ok=True)
return path