refactoring the CORTEX_DB_DIR path awareness, carrying it around in all processes now as installations tend to get lost in terms of backend paths