if(coupledMi.inputs().size() != ((MultiInput)originInput).inputs().size())
throw new IllegalStateException("These multiple inputs have different length and can't be coupled");
// Raw inputs can only be coupled with another reference input
if(!(coupledMi.inputs().get(idx) instanceof ReferenceInput))
throw new IllegalStateException(" Reference can only be paired with another reference ");
ReferenceInput ri = (ReferenceInput) coupledMi.inputs().get(idx);
if(!(ri.reference().module().equals(curMultiRefInput.reference().module())))
throw new IllegalStateException(" Reference can only be paired with another reference from the same module");