feat: examples + output_shape on Lesson schema (#129)#159
Conversation
Closes #129. Adds optional Lesson.examples (list[Example{good,bad}]) and Lesson.output_shape (str|None). Round-trip preserved in markdown serializer. Rule injection emits <rule><goal/><shape/><good/><bad/></rule> XML when populated, falls back to legacy bullet otherwise. capture_example_from_correction populates examples list during graduation.
There was a problem hiding this comment.
Your free trial has ended. If you'd like to continue receiving code reviews, you can add a payment method here.
|
Caution Review failedPull request was closed or merged during review 📝 Walkthrough
WalkthroughThis PR implements issue Changes
Estimated code review effort🎯 3 (Moderate) | ⏱️ ~20 minutes Possibly related PRs
Suggested labels
🚥 Pre-merge checks | ✅ 4 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (4 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches📝 Generate docstrings
🧪 Generate unit tests (beta)
⚔️ Resolve merge conflicts
Review rate limit: 2/5 reviews remaining, refill in 24 minutes and 16 seconds. Comment |
Closes #129.
Changes
Exampledataclass withgood/badfieldsLesson:examples: list[Example],output_shape: str | None<rule><goal/><shape/><good/><bad/></rule>XML when populatedcapture_example_from_correctionpopulates examples on graduation (de-duped, cap=3)Test plan
pytest tests/test_lesson_examples.py -xvs— 4/4 passtest_doctor_runs_on_brain, fixed in fix(test): de-flake test_doctor_runs_on_brain #157)Layering check
No Layer 0 -> 2 imports introduced.