vllm-project/vllm · error · ValueError

Parameter `normalize` was removed; use `use_activation` inst

Error message

Parameter `normalize` was removed; use `use_activation` instead.

What it means

A before-mode pydantic model_validator on PoolerConfig rejects the legacy 'normalize' keyword. The normalize parameter (sigmoid/softmax normalization of reward scores) was replaced by use_activation, which controls whether the pooler applies its activation function. The validator inspects raw input (including ArgsKwargs) so it fires even before field parsing.

Source

Thrown at vllm/config/pooler.py:125

    If set, only the score corresponding to the `step_tag_id` in the
    generated sentence should be returned. Otherwise, the scores for all tokens
    are returned.
    """
    returned_token_ids: list[int] | None = None
    """
    A list of indices for the vocabulary dimensions to be extracted,
    such as the token IDs of `good_token` and `bad_token` in the
    `math-shepherd-mistral-7b-prm` model.
    """

    @model_validator(mode="before")
    @classmethod
    def reject_removed_parameters(cls, data):
        values = data.kwargs if isinstance(data, ArgsKwargs) else data
        if not isinstance(values, dict):
            return data
        if "normalize" in values:
            raise ValueError(
                "Parameter `normalize` was removed; use `use_activation` instead."
            )
        check_removed_pooling_task(values.get("task"))
        return data

    def __post_init__(self) -> None:
        if self.logit_sigma is not None and self.logit_sigma == 0:
            raise ValueError("logit_sigma cannot be 0 (division by zero)")

        if pooling_type := self.pooling_type:
            if self.seq_pooling_type is not None:
                raise ValueError(
                    "Cannot set both `pooling_type` and `seq_pooling_type`"
                )
            if self.tok_pooling_type is not None:
                raise ValueError(
                    "Cannot set both `pooling_type` and `tok_pooling_type`"
                )

View on GitHub (pinned to c794754062)

Solutions

  1. Replace normalize=True with use_activation=True (or just omit it; True is the pooler default).
  2. Replace normalize=False with use_activation=False.
  3. Remove the key entirely if the model default behavior is acceptable.
  4. Grep configs for 'normalize' after upgrading vLLM.

Example fix

# before
pooler_cfg = PoolerConfig(normalize=False, returned_token_ids=[good_id, bad_id])

# after
pooler_cfg = PoolerConfig(use_activation=False, returned_token_ids=[good_id, bad_id])
Defensive patterns

Strategy: validation

Validate before calling

def migrate_pooler_kwargs(kwargs: dict) -> dict:
    kwargs = dict(kwargs)
    if "normalize" in kwargs:
        kwargs["use_activation"] = kwargs.pop("normalize")
    return kwargs

pooler_cfg = PoolerConfig(**migrate_pooler_kwargs(old_kwargs))

Try / catch

try:
    cfg = PoolerConfig(**kwargs)
except ValueError as e:
    if "normalize" in str(e):
        kwargs["use_activation"] = kwargs.pop("normalize")
        cfg = PoolerConfig(**kwargs)
    else:
        raise

Prevention

When it happens

Trigger: Passing override_pooler_config=PoolerConfig(normalize=False) or normalize=True, or via --overrides 'pooler_config.normalize=false' CLI syntax, on a current vLLM version.

Common situations: Scripts written for older vLLM (<= v0.9 era) using normalize for reward models like math-shepherd; upgrading vLLM without migrating config; copied YAML/JSON pooler overrides containing normalize.

Related errors


AI-assisted analysis of vllm-project/vllm@c794754062 (2026-08-14). Data as JSON: /api/errors/4dcd114c871a69c6. Report an issue: GitHub.