[PR #1507] [MERGED] fix(lab04): remove answer spoilers from prediction prompts in lab_04_data_engr #7374

Closed
opened 2026-04-24 17:27:18 -05:00 by GiteaMirror · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/harvard-edge/cs249r_book/pull/1507
Author: @octo-patch
Created: 4/24/2026
Status: Merged
Merged: 4/24/2026
Merged by: @profvjreddi

Base: devHead: iss1417-fix-prediction-spoiler-in-lab04


📝 Commits (1)

  • 754f056 fix(lab04): remove answer spoilers from prediction prompts in lab_04_data_engr

📊 Changes

1 file changed (+5 additions, -9 deletions)

View changed files

📝 labs/vol1/lab_04_data_engr.py (+5 -9)

📄 Description

Fixes #1417

Problem

Parts B and C of labs/vol1/lab_04_data_engr.py showed the numerical answer directly above the prediction radio button, allowing learners to read the answer before making their prediction:

  • Part B: The pre-prediction text included Transfer time = Dataset / Bandwidth = 50 TB / 10 Gbps = ~11 hours — the exact value of answer option C.
  • Part C: The pre-prediction text included error = 0.02 * 1.4^5 = 0.02 * 5.38 = 10.8% — giving away the ~15% answer.

Solution

Remove the worked numerical examples from the context shown before the prediction radio button in Parts B and C. Replace with formula-only scaffolding so learners apply the formula themselves.

The full worked calculations remain available after the prediction is submitted:

  • Interactive calculator (sliders)
  • Feedback callout with the correct value
  • Math Peek accordion with the derivation

Part A and Part D are not changed — Part A only shows the formula structure (not the numerical GPU utilization), and Part D shows that 99% is insufficient without revealing the required precision level.

Testing

Visually verified the diff: prediction radio buttons now appear before any numerical answer for Parts B and C. The post-prediction sections are unchanged.


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/harvard-edge/cs249r_book/pull/1507 **Author:** [@octo-patch](https://github.com/octo-patch) **Created:** 4/24/2026 **Status:** ✅ Merged **Merged:** 4/24/2026 **Merged by:** [@profvjreddi](https://github.com/profvjreddi) **Base:** `dev` ← **Head:** `iss1417-fix-prediction-spoiler-in-lab04` --- ### 📝 Commits (1) - [`754f056`](https://github.com/harvard-edge/cs249r_book/commit/754f056fab5e6d22f51a33a1c17eb27ddd9e82ab) fix(lab04): remove answer spoilers from prediction prompts in lab_04_data_engr ### 📊 Changes **1 file changed** (+5 additions, -9 deletions) <details> <summary>View changed files</summary> 📝 `labs/vol1/lab_04_data_engr.py` (+5 -9) </details> ### 📄 Description Fixes #1417 ## Problem Parts B and C of `labs/vol1/lab_04_data_engr.py` showed the numerical answer directly above the prediction radio button, allowing learners to read the answer before making their prediction: - **Part B**: The pre-prediction text included `Transfer time = Dataset / Bandwidth = 50 TB / 10 Gbps = ~11 hours` — the exact value of answer option C. - **Part C**: The pre-prediction text included `error = 0.02 * 1.4^5 = 0.02 * 5.38 = 10.8%` — giving away the ~15% answer. ## Solution Remove the worked numerical examples from the context shown **before** the prediction radio button in Parts B and C. Replace with formula-only scaffolding so learners apply the formula themselves. The full worked calculations remain available after the prediction is submitted: - Interactive calculator (sliders) - Feedback callout with the correct value - Math Peek accordion with the derivation Part A and Part D are not changed — Part A only shows the formula structure (not the numerical GPU utilization), and Part D shows that 99% is insufficient without revealing the required precision level. ## Testing Visually verified the diff: prediction radio buttons now appear before any numerical answer for Parts B and C. The post-prediction sections are unchanged. --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
GiteaMirror added the pull-request label 2026-04-24 17:27:18 -05:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github-starred/cs249r_book#7374