compressed js libs
refactoring tree builder