Cache angle onnx - #1108
Conversation
|
Warning Review limit reached
Next review available in: 21 minutes Enable usage-based reviews in Billing to review now. Otherwise, wait until the next included review is available. How can I continue?After more reviews become available, a review can be triggered using the To avoid repeated limits, reduce automatic review volume by pausing incremental auto-reviews earlier, using label-based review opt-in, excluding WIP or generated PR titles, or requesting reviews manually when the PR is ready. If your team needs uninterrupted high-volume reviews, an organization admin can enable usage-based reviews. How do review limits work?CodeRabbit enforces per-developer PR review limits for each organization. Most developers receive the normal plan review availability. For paid Pro and Pro+ PR reviews, CodeRabbit uses adaptive limits for sustained high-volume activity. When a developer's recent PR review activity reaches the 95th percentile or higher among CodeRabbit users, additional reviews become available more gradually as earlier reviews age out of the rolling window. Please refer docs for additional details. Review details⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Pro Plus Run ID: 📒 Files selected for processing (2)
✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
There was a problem hiding this comment.
Pull request overview
This PR aims to make RL ONNX-based likelihood tests more reliable in CI by avoiding on-demand downloads of the Angle ONNX model and reducing susceptibility to Hugging Face Hub rate limits.
Changes:
- Switched the RL likelihood builder test to load
angle.onnxfrom a checked-in local fixture path instead of a filename that triggers Hugging Face download behavior. - Added a GitHub Actions cache step intended to reuse the Hugging Face cache across CI runs.
Reviewed changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated 1 comment.
| File | Description |
|---|---|
tests/rl/test_rl_likelihood_builder.py |
Loads the Angle ONNX model from tests/fixtures/angle.onnx to keep tests deterministic and avoid network/HF rate limits. |
.github/workflows/run_tests.yml |
Adds caching for Hugging Face cache directories to reduce repeated downloads in CI. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
digicosmos86
left a comment
There was a problem hiding this comment.
I think the test suite share the same issue. Theoretically, we use a huggingface function to download the model, which should cache the file automatically. However, in reality the file is downloaded every time a test is run, especially in slow tests. I think it's worth digging in a bit more
| with: | ||
| python-version: ${{ matrix.python-version }} | ||
|
|
||
| - name: Cache Hugging Face hub |
There was a problem hiding this comment.
I think this is a different caching mechanism here than what we want to achieve. This gets us caching across different runs, so that we don't have to download the onnx files again. However, since the onnx models are so small, I am not sure this is necessary. Can we spend some time looking into why the hf_download call is not cached during testing?
There was a problem hiding this comment.
Sure, we can address this later.
No description provided.