-
Notifications
You must be signed in to change notification settings - Fork 3.1k
[CI] Add CI test for DeepSeek V3.2 MTP #11835
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
base: main
Are you sure you want to change the base?
Conversation
Summary of ChangesHello @Fridge003, I'm Gemini Code Assist1! I'm currently reviewing this pull request and will post my feedback shortly. In the meantime, here's a summary to help you and other reviewers quickly get up to speed! This pull request introduces a new Continuous Integration (CI) test for the DeepSeek V3.2 MTP (Multi-Turn Prediction) model. The primary goal is to establish automated validation for this model, specifically focusing on its performance and accuracy when utilizing advanced speculative decoding techniques like the EAGLE algorithm. This ensures that future changes do not negatively impact the model's behavior under these optimized configurations, thereby maintaining the reliability and efficiency of the DeepSeek V3.2 MTP integration. Highlights
Using Gemini Code AssistThe full guide for Gemini Code Assist can be found on our documentation page, here are some quick tips. Invoking Gemini You can request assistance from Gemini at any point by creating a comment using either
Customization To customize Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a Limitations & Feedback Gemini Code Assist may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counter productive. You can react with 👍 and 👎 on @gemini-code-assist comments. If you're interested in giving your feedback about your experience with Gemini Code Assist for Github and other Google products, sign up here. You can also get AI-powered code generation, chat, as well as code reviews directly in the IDE at no cost with the Gemini Code Assist IDE Extension. Footnotes
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Code Review
This pull request adds a new CI test for DeepSeek V3.2 with MTP. The changes include adding the new test file test_deepseek_v32_mtp.py
, updating run_suite.py
to include it in the CI, and fixing some typos in the existing test_deepseek_v32_basic.py
.
The implementation is straightforward, but the new test file introduces significant code duplication with test_deepseek_v32_basic.py
. My review includes suggestions to refactor the duplicated code to improve maintainability, such as using a shared constant for the model path and creating a base test class for common logic. These changes will make the test suite cleaner and easier to manage in the future.
FULL_DEEPSEEK_V3_MODEL_PATH = "deepseek-ai/DeepSeek-V3.2-Exp" | ||
|
||
|
||
class TestDeepseekV32MTP(CustomTestCase): | ||
@classmethod | ||
def setUpClass(cls): | ||
cls.model = FULL_DEEPSEEK_V3_MODEL_PATH |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The constant FULL_DEEPSEEK_V3_MODEL_PATH
has the same value as DEEPSEEK_V32_MODEL_PATH
in test_deepseek_v32_basic.py
. To maintain consistency and avoid confusion, it's better to use the same name. The FULL_
prefix is also redundant.
Ideally, this constant should be defined once in a shared location and imported where needed to adhere to the DRY (Don't Repeat Yourself) principle.
FULL_DEEPSEEK_V3_MODEL_PATH = "deepseek-ai/DeepSeek-V3.2-Exp" | |
class TestDeepseekV32MTP(CustomTestCase): | |
@classmethod | |
def setUpClass(cls): | |
cls.model = FULL_DEEPSEEK_V3_MODEL_PATH | |
DEEPSEEK_V32_MODEL_PATH = "deepseek-ai/DeepSeek-V3.2-Exp" | |
class TestDeepseekV32MTP(CustomTestCase): | |
@classmethod | |
def setUpClass(cls): | |
cls.model = DEEPSEEK_V32_MODEL_PATH |
FULL_DEEPSEEK_V3_MODEL_PATH = "deepseek-ai/DeepSeek-V3.2-Exp" | ||
|
||
|
||
class TestDeepseekV32MTP(CustomTestCase): |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This test class shares a lot of duplicate code with TestDeepseekV32Basic
in test/srt/test_deepseek_v32_basic.py
. For example, the tearDownClass
method and large parts of the test methods (test_a_gsm8k
, test_bs_1_speed
) are identical or very similar.
To improve maintainability and follow the DRY (Don't Repeat Yourself) principle, consider refactoring the common code into a base test class. The subclasses (TestDeepseekV32Basic
and TestDeepseekV32MTP
) would then only need to define their specific configurations (e.g., other_args
in setUpClass
) and any specific assertions.
A possible structure could be:
# In a shared location, e.g., a new base test file
class TestDeepseekV32Base(CustomTestCase):
model = "deepseek-ai/DeepSeek-V3.2-Exp"
base_url = DEFAULT_URL_FOR_TEST
process = None
other_args = []
@classmethod
def setUpClass(cls):
cls.process = popen_launch_server(
cls.model,
cls.base_url,
timeout=DEFAULT_TIMEOUT_FOR_SERVER_LAUNCH,
other_args=cls.other_args,
)
@classmethod
def tearDownClass(cls):
if cls.process:
kill_process_tree(cls.process.pid)
# ... common test logic can be extracted into helper methods ...
This would make the tests cleaner and easier to maintain in the long run.
Motivation
Modifications
Accuracy Tests
Benchmarking and Profiling
Checklist