Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Model] Add user-configurable task for models that support both generation and embedding #9424

Merged
merged 20 commits into from
Oct 18, 2024
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Merge branch 'main' into model-task
  • Loading branch information
DarkLight1337 committed Oct 17, 2024
commit 20d7ab6179a5de1b2f5caafb281fffcf0e32d816
5 changes: 3 additions & 2 deletions vllm/engine/arg_utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
import json
from dataclasses import dataclass
from typing import (TYPE_CHECKING, Any, Dict, List, Literal, Mapping, Optional,
Tuple, Type, Union, get_args)
Tuple, Type, Union, cast, get_args)

import torch

Expand Down Expand Up @@ -848,7 +848,8 @@ def create_model_config(self) -> ModelConfig:
return ModelConfig(
model=self.model,
task=self.task,
tokenizer=self.tokenizer,
# We know this is not None because we set it in __post_init__
tokenizer=cast(str, self.tokenizer),
tokenizer_mode=self.tokenizer_mode,
trust_remote_code=self.trust_remote_code,
dtype=self.dtype,
Expand Down
You are viewing a condensed version of this merge commit. You can view the full changes here.