"tests/vscode:/vscode.git/clone" did not exist on "3d886c32d513c14ae6f178e1daa79f5952334881"
Unverified Commit f3b67602 authored by Lianmin Zheng's avatar Lianmin Zheng Committed by GitHub
Browse files

[Auto Sync] Update server_args.py (20250906) (#10117)


Co-authored-by: default avatargithub-actions[bot] <github-actions[bot]@users.noreply.github.com>
Co-authored-by: default avatarHanming Lu <69857889+hanming-lu@users.noreply.github.com>
parent 9eb50ecc
......@@ -104,6 +104,8 @@ ATTENTION_BACKEND_CHOICES = [
DISAGG_TRANSFER_BACKEND_CHOICES = ["mooncake", "nixl", "ascend", "fake"]
GRAMMAR_BACKEND_CHOICES = ["xgrammar", "outlines", "llguidance", "none"]
# Allow external code to add more choices
def add_load_format_choices(choices):
......@@ -122,6 +124,10 @@ def add_disagg_transfer_backend_choices(choices):
DISAGG_TRANSFER_BACKEND_CHOICES.extend(choices)
def add_grammar_backend_choices(choices):
GRAMMAR_BACKEND_CHOICES.extend(choices)
@dataclasses.dataclass
class ServerArgs:
# Model and tokenizer
......@@ -1475,7 +1481,7 @@ class ServerArgs:
parser.add_argument(
"--grammar-backend",
type=str,
choices=["xgrammar", "outlines", "llguidance", "none"],
choices=GRAMMAR_BACKEND_CHOICES,
default=ServerArgs.grammar_backend,
help="Choose the backend for grammar-guided decoding.",
)
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment