Skip to content

convert test_deterministic into unit tests#11095

Merged
Fridge003 merged 10 commits intosgl-project:mainfrom
skyzh:skyzh/det-test
Oct 7, 2025
Merged

convert test_deterministic into unit tests#11095
Fridge003 merged 10 commits intosgl-project:mainfrom
skyzh:skyzh/det-test

Conversation

@skyzh
Copy link
Contributor

@skyzh skyzh commented Sep 30, 2025

Motivation

Part of #10278

Modifications

The patch converts the deterministic test into unit tests so that it's easier to detect issues in CI and avoid regression.

  • add n_start parameter so that we can start with 10+ size batch, saving some time
  • avoid supplying sampling seed as None as it would cause sglang server to stop (a bug to be fixed in the server?)
  • add return value for test_deterministic: an array of unique responses for each prompt

Accuracy Tests

Benchmarking and Profiling

Checklist

Signed-off-by: Alex Chi Z <iskyzh@gmail.com>
Signed-off-by: Alex Chi Z <iskyzh@gmail.com>
Signed-off-by: Alex Chi Z <iskyzh@gmail.com>
@merrymercy
Copy link
Contributor

the test code is wrong https://github.com/sgl-project/sglang/actions/runs/18264854581/job/52013897713?pr=11095#step:5:1635

@Fridge003
Copy link
Collaborator

Copy link
Collaborator

@Fridge003 Fridge003 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@Fridge003 Fridge003 merged commit 9b4c449 into sgl-project:main Oct 7, 2025
185 of 200 checks passed
ch-tiger1 pushed a commit to ch-tiger1/sglang that referenced this pull request Oct 9, 2025
Signed-off-by: Alex Chi Z <iskyzh@gmail.com>
Co-authored-by: Baizhou Zhang <sobereddiezhang@gmail.com>
@skyzh
Copy link
Contributor Author

skyzh commented Oct 13, 2025

Thanks for following up :) Did not have my personal laptop with me last week 😂

@skyzh skyzh deleted the skyzh/det-test branch October 13, 2025 22:55
lpc0220 pushed a commit to lpc0220/sglang that referenced this pull request Oct 29, 2025
Signed-off-by: Alex Chi Z <iskyzh@gmail.com>
Co-authored-by: Baizhou Zhang <sobereddiezhang@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants

Comments