Co-authored-by: Ying Sheng <sqy1415@gmail.com>
This commit is contained in:
@@ -125,7 +125,7 @@ class CompiledFunction:
|
||||
def run(
|
||||
self,
|
||||
*,
|
||||
max_new_tokens: int = 16,
|
||||
max_new_tokens: int = 128,
|
||||
stop: Union[str, List[str]] = (),
|
||||
temperature: float = 1.0,
|
||||
top_p: float = 1.0,
|
||||
@@ -155,7 +155,7 @@ class CompiledFunction:
|
||||
self,
|
||||
batch_kwargs,
|
||||
*,
|
||||
max_new_tokens: int = 16,
|
||||
max_new_tokens: int = 128,
|
||||
stop: Union[str, List[str]] = (),
|
||||
temperature: float = 1.0,
|
||||
top_p: float = 1.0,
|
||||
|
||||
@@ -16,7 +16,7 @@ REGEX_STRING = r"\"[\w\d\s]*\"" # bugs with regex r"\".*\"" in interegular pkg
|
||||
|
||||
@dataclasses.dataclass
|
||||
class SglSamplingParams:
|
||||
max_new_tokens: int = 16
|
||||
max_new_tokens: int = 128
|
||||
stop: Union[str, List[str]] = ()
|
||||
temperature: float = 1.0
|
||||
top_p: float = 1.0
|
||||
@@ -140,7 +140,7 @@ class SglFunction:
|
||||
def run(
|
||||
self,
|
||||
*args,
|
||||
max_new_tokens: int = 16,
|
||||
max_new_tokens: int = 128,
|
||||
stop: Union[str, List[str]] = (),
|
||||
temperature: float = 1.0,
|
||||
top_p: float = 1.0,
|
||||
@@ -179,7 +179,7 @@ class SglFunction:
|
||||
self,
|
||||
batch_kwargs,
|
||||
*,
|
||||
max_new_tokens: int = 16,
|
||||
max_new_tokens: int = 128,
|
||||
stop: Union[str, List[str]] = (),
|
||||
temperature: float = 1.0,
|
||||
top_p: float = 1.0,
|
||||
|
||||
@@ -23,7 +23,7 @@ _SAMPLING_EPS = 1e-6
|
||||
class SamplingParams:
|
||||
def __init__(
|
||||
self,
|
||||
max_new_tokens: int = 16,
|
||||
max_new_tokens: int = 128,
|
||||
stop: Optional[Union[str, List[str]]] = None,
|
||||
temperature: float = 1.0,
|
||||
top_p: float = 1.0,
|
||||
|
||||
Reference in New Issue
Block a user