If I use a replacement rule like
Times[2, Plus[Times[AuRr, BuRb], Times[AuRb, BuRr]], h10] /.
{Times[r_, Plus[Times[x_, y_], Times[v_, w_]], h10] :>
r*TensorProduct[(TensorProduct[x, y] + TensorProduct[v, w]), h10]}
I get correctly
(* 2 (AuRb \[TensorProduct] BuRr + AuRr \[TensorProduct] BuRb) \[TensorProduct]h10 *)
Nevertheless, if I try to do the same thing more general, i.e. allowing for a general last coefficient, not specifically h10:
Times[2, Plus[Times[AuRr, BuRb], Times[AuRb, BuRr]], h10] /.
{Times[r_, Plus[Times[x_, y_], Times[v_, w_]], h_] :>
r*TensorProduct[(TensorProduct[x, y] + TensorProduct[v, w]), h]}
I get the wrong result
(* 2 h10 (AuRb \[TensorProduct] BuRr + AuRr \[TensorProduct] BuRb) *)
Any ideas about what is going wrong here, would be much appreciated!