Retrieval Optimization: From Tokenization to Vector Quantization