[Misc] Added missing return type annotations to improve mypy and IDE tooling (#43383)

Signed-off-by: Taneem Ibrahim <taneem.ibrahim@gmail.com>
This commit is contained in:
Taneem Ibrahim
2026-05-23 13:28:22 +08:00
committed by GitHub
parent a7be0f342d
commit 3a1c062151
4 changed files with 14 additions and 11 deletions
@@ -108,7 +108,9 @@ class MeanPool(SequencePoolingMethod):
return segment_sums / prompt_lens.unsqueeze(1)
def get_seq_pooling_method(pooling_type: SequencePoolingType | str):
def get_seq_pooling_method(
pooling_type: SequencePoolingType | str,
) -> SequencePoolingMethod:
if pooling_type == "CLS":
return CLSPool()
if pooling_type == "LAST":