Now, I haven’t read all the various and sundry articles, but this was my thinking for years:
Luke staged the whole thing to save Han. He sent everybody in as their various roles to cover multiple contingencies. The ONLY thing that didn’t go to “plan” was that he did not know he would not be able to lay the Jedi Mind Trick on Jabba the Hutt. That was supposed to work, because Luke believes himself to be seriously bad ass by now (He’s not totally wrong, but still a bit full of himself.) The rest is history.