add bfs and some attributes