vllm.model_executor.layers.pooler
¶
Modules:
-
abstract– -
common– -
seqwise–Poolers that produce an output aggregating all tokens in the sequence.
-
special– -
tokwise–Poolers that produce an output for each token in the sequence.
Classes:
-
BOSEOSFilter–Filters the BOS and EOS token results from outputs.
-
DispatchPooler–Dispatches calls to a sub-pooler based on the pooling task.
-
Pooler–The interface required for all poolers used in pooling models in vLLM.
-
PoolingParamsUpdate–
DispatchPooler
¶
Bases: Pooler
Dispatches calls to a sub-pooler based on the pooling task.
Methods:
-
replace_classifier–Replaces the classifier to the LoRA-wrapped version.
replace_classifier(new_classifier)
¶
Replaces the classifier to the LoRA-wrapped version.
Pooler
¶
The interface required for all poolers used in pooling models in vLLM.
Methods:
-
get_pooling_updates–Construct the updated pooling parameters to use for a supported task.
-
get_supported_tasks–Determine which pooling tasks are supported.
PoolingParamsUpdate
dataclass
¶
Attributes:
-
requires_token_ids(bool) –Set this flag to enable CPU prompt token IDs for your pooler.
requires_token_ids = False
class-attribute
instance-attribute
¶
Set this flag to enable CPU prompt token IDs for your pooler.