refactor for houdci