Added configs feature and code improvements