diff --git a/python/sglang/srt/models/grok.py b/python/sglang/srt/models/grok.py index 9a096cc13079..2f94f3552967 100644 --- a/python/sglang/srt/models/grok.py +++ b/python/sglang/srt/models/grok.py @@ -477,7 +477,9 @@ def __init__( self.layer_id = layer_id self.alt_stream = alt_stream or torch.cuda.Stream() - rope_theta = config.rope_parameters["rope_theta"] + rope_theta = getattr(config, "rope_theta", 10000) + if hasattr(config, "rope_parameters") and config.rope_parameters: + rope_theta = config.rope_parameters.get("rope_theta", rope_theta) self.self_attn = Grok1Attention( config=config, hidden_size=self.hidden_size, diff --git a/test/registered/amd/accuracy/mi30x/test_grok2_eval_amd.py b/test/registered/amd/accuracy/mi30x/test_grok2_eval_amd.py index 192ea78c0c7b..e4d3d1003b66 100644 --- a/test/registered/amd/accuracy/mi30x/test_grok2_eval_amd.py +++ b/test/registered/amd/accuracy/mi30x/test_grok2_eval_amd.py @@ -103,7 +103,7 @@ class TestGrok2EvalAMD(unittest.TestCase): def setUpClass(cls): cls.base_url = DEFAULT_URL_FOR_TEST cls.num_questions = int(os.environ.get("GSM8K_NUM_QUESTIONS", "200")) - cls.accuracy_threshold = 0.915 + cls.accuracy_threshold = 0.90 def test_grok2_accuracy(self): """Test Grok-2 with GSM8K completion benchmark."""