refactor config getter and add formal tag into config