Text this: Reduction of the molecular hamiltonian matrix using quantum community detection