vllm.model_executor.layers.pooler.tokwise
¶
Poolers that produce an output for each token in the sequence.
Modules:
Classes:
-
TokenEmbeddingPoolerHead– -
TokenPooler–A layer that pools specific information from hidden states.
TokenEmbeddingPoolerHead
¶
Bases: TokenPoolerHead
Methods:
-
forward_batched–Batch projection, splitting only when finishing needs per-request options.
_finish(embeddings, pooling_param)
¶
Slice/normalize [num_rows, embedding_size] to [num_rows, output_size].
_project(hidden_states)
¶
Project [num_rows, hidden_size] to [num_rows, embedding_size].
forward_batched(hidden_states, pooling_params, split)
¶
Batch projection, splitting only when finishing needs per-request options.
Keep eligibility checks in sync with PoolingParams fields read by forward_chunk.