### What this PR does / why we need it? Extracts repeated `attn_metadata[layer_name].decode` access into a single variable to improve code readability and reduce redundancy. Uses `getattr` with a default value to safely access the decode attribute, making the code more defensive against potential attribute errors. ### Does this PR introduce _any_ user-facing change? None. ### How was this patch tested? None. - vLLM version: v0.12.0 - vLLM main: https://github.com/vllm-project/vllm/commit/ad32e3e19ccf0526cb6744a5fed09a138a5fb2f9 Signed-off-by: Yizhou Liu <liu_yizhou@outlook.com>