add building prompt
code refactoring