codebook format fix