Groupoids And Semigroups In Homology Theory