Simple and generic algebraic multigrid framework