finish codebook