refactored nell base graph builder and base graph builder