Codebook and script