added graph class and logistic APIs