added graph prototype