fixed code for substituting AA alignment to internal representation and setting protein model