wrote a limited node class and remove_duplicate main