big refactor of dependencies