fix(triviaqa): update dataset loading path to use correct repository - #1104
fix(triviaqa): update dataset loading path to use correct repository#1104cris96spa wants to merge 1 commit into
Conversation
📝 WalkthroughWalkthroughThe Hugging Face dataset identifier used in TriviaQA loading is changed from ChangesTriviaQA loader update
Estimated code review effort: 1 (Trivial) | ~2 minutes 🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✨ Finishing Touches🧪 Generate unit tests (beta)
Comment |
Signed-off-by: Cristian Spagnuolo <cristian.spagnuolo@artificialy.com>
acc5cac to
88e99a7
Compare
There was a problem hiding this comment.
Actionable comments posted: 1
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Inline comments:
In `@src/nemo_evaluator/benchmarks/triviaqa.py`:
- Line 33: Pin the TriviaQA dataset load in triviaqa.py for reproducibility by
adding a fixed revision to the load_dataset call in the benchmark setup. Update
the ds assignment in the TriviaQA evaluator so the dataset source is tied to a
specific revision hash rather than the floating default, keeping future runs
stable even if mandarjoshi/trivia_qa changes upstream.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Path: .coderabbit.yaml
Review profile: ASSERTIVE
Plan: Enterprise
Run ID: ac7b846e-da00-4fbe-a793-816641beaad2
📒 Files selected for processing (1)
src/nemo_evaluator/benchmarks/triviaqa.py
| from datasets import load_dataset | ||
|
|
||
| ds = load_dataset("trivia_qa", "rc.nocontext", split="validation") | ||
| ds = load_dataset("mandarjoshi/trivia_qa", "rc.nocontext", split="validation") |
There was a problem hiding this comment.
🗄️ Data Integrity & Integration | 🔵 Trivial | ⚡ Quick win
Consider pinning a dataset revision for reproducibility.
Without a pinned revision, future upstream changes to mandarjoshi/trivia_qa (re-uploads, config renames) could silently change eval results between runs.
♻️ Pin a revision hash
- ds = load_dataset("mandarjoshi/trivia_qa", "rc.nocontext", split="validation")
+ ds = load_dataset("mandarjoshi/trivia_qa", "rc.nocontext", split="validation", revision="<commit_hash>")🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
In `@src/nemo_evaluator/benchmarks/triviaqa.py` at line 33, Pin the TriviaQA
dataset load in triviaqa.py for reproducibility by adding a fixed revision to
the load_dataset call in the benchmark setup. Update the ds assignment in the
TriviaQA evaluator so the dataset source is tied to a specific revision hash
rather than the floating default, keeping future runs stable even if
mandarjoshi/trivia_qa changes upstream.
|
Closes #1111 |
Summary
Fix TriviaQA dataset loading by switching from the legacy dataset identifier to the current namespaced Hugging Face repository ID.
Problem
The loader currently uses
load_dataset("trivia_qa", ...). Hugging Face Hub now enforcesnamespace/namerepository IDs, so this fails with repository ID validation errors.Change
trivia_qatomandarjoshi/trivia_qa.Impact
Validation
mandarjoshi/trivia_qa.make testmake lintSummary by CodeRabbit