Skip to content

fix(ontology): re-validate YD 87:7 — Q015 encoding fix + full QA suite - #255

Merged
RNekhoda merged 4 commits into
mainfrom
session/RNekhoda/yd_87-7_validation
Jun 2, 2026
Merged

fix(ontology): re-validate YD 87:7 — Q015 encoding fix + full QA suite#255
RNekhoda merged 4 commits into
mainfrom
session/RNekhoda/yd_87-7_validation

Conversation

@levi770

@levi770 levi770 commented Jun 2, 2026

Copy link
Copy Markdown
Contributor

Summary

  • Q015 encoding fix: added not is_special_skin_chalav_mixture(M) guard to three heter hanaah rules (mechaber/rema/ashk_ah) — prevents simultaneous holds(heter(hanaah)) + holds(issur(hanaah,d_oraita)) for special skins (or_shlil, or_tachat_alya, or_beit_haboshet); decision ref: ED-87-7-004b
  • 15-question QA exam: qa-set/run/translation/review artifacts, all 15 questions pass, archived to permanent corpus
  • Tech health suite: tests/engine/test_tech_health_yd_87_7.py (4 tests: source exists, compiled lp exists, rule directives, compiled metadata)

Sources

  • Primary: SA YD 87:7
  • Commentaries: Shach (Siftei Kohen) §22, Peri Megadim Siftei Da'at §22, Pitchei Teshuva §15

Encoding Decisions

8 total (4 definitive / 2 probable / 2 debatable) — see mistaber/corpus/yoreh_deah/siman_87/seif_7/encoding-decisions.yaml

Test plan

  • 33-test corpus suite: 33/33 passed (no regressions from fix)
  • Tech health: 4/4 passed
  • Full pytest suite: 842/842 passed
  • ruff check + format: clean
  • mypy: 60 files, no issues
  • Review phase approved by RNekhoda

Generated by Mistaber Code — Computational Halacha Encoding Agent

Mistaber Code added 3 commits June 2, 2026 17:14
Re-validation of YD 87:7 (Shlil and Exempt Animal Parts) via session
e9c4ac26 (RNekhoda). Found and fixed a halachic encoding bug discovered
during the 15-question QA exam.

Encoding Fix (Q015 — encoding_wrong):
  r_non_basar_part_heter_hanaah (mechaber/rema/ashk_ah): added guard
  `not is_special_skin_chalav_mixture(M)` to prevent simultaneous
  holds(heter(hanaah)) + holds(issur(hanaah,d_oraita)) for special
  skins (or_shlil, or_tachat_alya, or_beit_haboshet).
  Decision ref: ED-87-7-004b (debatable, PMG/PT/AH all tzarich iyun).

New Artifacts:
  - QA exam: 15 questions, all pass (qa-set/run/translation/review)
  - 15 HLL scenario files (q001–q015) archived to corpus
  - tests/engine/test_tech_health_yd_87_7.py (4 tech health tests)
  - Updated validation-report, review-package with full checklist

Test Results:
  - 33-test corpus suite: 33/33 passed (no regressions from fix)
  - Tech health: 4/4 passed
  - Full suite: 842/842 passed

Sources:
- Primary: SA YD 87:7
- Commentaries: Shach (Siftei Kohen) §22, Peri Megadim Siftei Da'at §22, Pitchei Teshuva §15

Encoding Decisions: 8 total (4 definitive / 2 probable / 2 debatable)

Reviewed-by: RNekhoda

Co-authored-by: Mistaber Code <code@mistaber.ai>
Co-authored-by: Mistaber Code <code@mistaber.ai>
Update commit_hash to reflect amended commit 612bcd7
(added Sources and Encoding Decisions sections to message).

Co-authored-by: Mistaber Code <code@mistaber.ai>
Copilot AI review requested due to automatic review settings June 2, 2026 17:21

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Pull request overview

Verdict: CHANGES REQUESTED
Counts: [CRITICAL] 1 · [IMPORTANT] 3 · [NIT] 0
Scope detected: encoding-session
Highlights:

  • [CRITICAL] mistaber/corpus/yoreh_deah/siman_87/seif_7/qa-run.yaml does not conform to the validate skill’s QA-run schema (missing required keys; inconsistent .mistaber-artifacts/... paths), risking downstream validator/tooling behavior.
  • [IMPORTANT] validation-report.md artifact pointers don’t match the actually archived filenames/paths (and reference untracked qa-runs/* sidecars).
  • [IMPORTANT] corpus-manifest.yaml references a non-existent qa-review-YD-87-7.yaml filename.

This PR updates the YD 87:7 encoding to prevent contradictory hanaah outcomes for “special skins” mixtures, and archives an expanded QA exam + re-validation artifacts into the permanent corpus package.

Changes:

  • Add a not is_special_skin_chalav_mixture(M) guard to the exempt-parts hanaah heter rules (mechaber/rema/ashk_ah) to prevent heter(hanaah) alongside issur(hanaah,d_oraita) for special skins.
  • Add/refresh validation + review package artifacts for YD 87:7, including a 15-question QA scenario set.
  • Add per-seif tech-health pytest overlay for YD 87:7.

Reviewed changes

Copilot reviewed 27 out of 27 changed files in this pull request and generated 4 comments.

Show a summary per file
File Description
tests/engine/test_tech_health_yd_87_7.py Adds per-seif “tech health” overlay checks for presence/metadata of YD 87:7 source + compiled artifacts.
mistaber/ontology/corpus/yd_87/seif_7.lp Regenerates compiled LP to include the special-skins guard on heter hanaah rules.
mistaber/dsl/corpus/yd_87/seif_7.hll Adds the NAF guard to hanaah heter rules and an ED-linked encoding note for the fix.
mistaber/corpus/yoreh_deah/siman_87/seif_7/validation-report.md Rewrites validate report into a concise checklist-style summary (artifact pointers need correction).
mistaber/corpus/yoreh_deah/siman_87/seif_7/validation-report-validate.md Updates validate-phase validator output into structured “items” format.
mistaber/corpus/yoreh_deah/siman_87/seif_7/validation-report-review.md Updates review-phase validator output into structured “items” format.
mistaber/corpus/yoreh_deah/siman_87/seif_7/review-package.md Updates the archived review package with QA + revalidation details and checklists.
mistaber/corpus/yoreh_deah/siman_87/seif_7/qa-set.yaml Adds the 15-question QA exam definition (approved/attested).
mistaber/corpus/yoreh_deah/siman_87/seif_7/qa-run.yaml Adds QA run results with selected atoms/traces (schema/path issues to fix).
mistaber/corpus/yoreh_deah/siman_87/seif_7/qa-translation.yaml Adds natural-language translations grounded in atoms/traces.
mistaber/corpus/yoreh_deah/siman_87/seif_7/qa-review.yaml Adds the human review verdicts for the 15 QA questions.
mistaber/corpus/yoreh_deah/siman_87/seif_7/tests/scenarios/scenario_q001_87_7.hll Adds QA scenario Q001 for shlil + chalav d’oraita.
mistaber/corpus/yoreh_deah/siman_87/seif_7/tests/scenarios/scenario_q002_87_7.hll Adds QA scenario Q002 for shilya + chalav d’rabanan-only.
mistaber/corpus/yoreh_deah/siman_87/seif_7/tests/scenarios/scenario_q003_87_7.hll Adds QA scenario Q003 for atzamot + chalav d’rabanan-only.
mistaber/corpus/yoreh_deah/siman_87/seif_7/tests/scenarios/scenario_q004_87_7.hll Adds QA scenario Q004 for ben pekua (ashk_ah) machloket case.
mistaber/corpus/yoreh_deah/siman_87/seif_7/tests/scenarios/scenario_q005_87_7.hll Adds QA scenario Q005 for special skins safek d’oraita.
mistaber/corpus/yoreh_deah/siman_87/seif_7/tests/scenarios/scenario_q006_87_7.hll Adds QA scenario Q006 for hollow bone + marrow safek d’oraita.
mistaber/corpus/yoreh_deah/siman_87/seif_7/tests/scenarios/scenario_q007_87_7.hll Adds QA scenario Q007 for explicit moach d’oraita.
mistaber/corpus/yoreh_deah/siman_87/seif_7/tests/scenarios/scenario_q008_87_7.hll Adds QA scenario Q008 for soft bone shishim requirement (ashk_ah).
mistaber/corpus/yoreh_deah/siman_87/seif_7/tests/scenarios/scenario_q009_87_7.hll Adds QA scenario Q009 for mechaber/rema agreement (rema world).
mistaber/corpus/yoreh_deah/siman_87/seif_7/tests/scenarios/scenario_q010_87_7.hll Adds QA scenario Q010 for non-hollow hard bone negative case.
mistaber/corpus/yoreh_deah/siman_87/seif_7/tests/scenarios/scenario_q011_87_7.hll Adds QA scenario Q011 for ashk_mb inheritance case.
mistaber/corpus/yoreh_deah/siman_87/seif_7/tests/scenarios/scenario_q012_87_7.hll Adds QA scenario Q012 for Shach §22 d’rabanan clarification.
mistaber/corpus/yoreh_deah/siman_87/seif_7/tests/scenarios/scenario_q013_87_7.hll Adds QA scenario Q013 for moach vs etzem distinction.
mistaber/corpus/yoreh_deah/siman_87/seif_7/tests/scenarios/scenario_q014_87_7.hll Adds QA scenario Q014 for kashe vs rakh bones bitul distinction.
mistaber/corpus/yoreh_deah/siman_87/seif_7/tests/scenarios/scenario_q015_87_7.hll Adds QA scenario Q015 that exercises the special-skins hanaah contradiction fix.
mistaber/corpus/corpus-manifest.yaml Updates the corpus manifest entry for YD 87:7 (one referenced artifact filename needs correction).

Comment thread mistaber/corpus/yoreh_deah/siman_87/seif_7/qa-run.yaml Outdated
Comment thread mistaber/corpus/yoreh_deah/siman_87/seif_7/validation-report.md Outdated
Comment thread mistaber/corpus/yoreh_deah/siman_87/seif_7/validation-report.md Outdated
Comment thread mistaber/corpus/corpus-manifest.yaml Outdated
- qa-run.yaml: add dot-prefix to all mistaber-artifacts/ paths,
  add command and xclingo_failure fields per qa-run template schema
- validation-report.md: fix artifact filenames (remove -YD-87-7 suffix,
  use tests/scenarios/ path, remove untracked qa-runs/ sidecars)
- corpus-manifest.yaml: fix detected_in reference
  (qa-review-YD-87-7.yaml → qa-review.yaml)

Fixes: #3343166507 (CRITICAL), #3343166591 (IMPORTANT),
       #3343166625 (IMPORTANT), #3343166662 (IMPORTANT)

Co-authored-by: Mistaber Code <code@mistaber.ai>
@levi770

levi770 commented Jun 2, 2026

Copy link
Copy Markdown
Contributor Author

Resolved Copilot review findings in 802c559:

  • [CRITICAL] #3343166507qa-run.yaml: added dot-prefix to all mistaber-artifacts/ paths, added command and xclingo_failure: false fields per QA-run template schema.
  • [IMPORTANT] #3343166591validation-report.md: artifact filenames corrected (removed -YD-87-7 suffix, replaced qa-runs/* sidecars with tests/scenarios/ paths).
  • [IMPORTANT] #3343166625validation-report.md: removed references to untracked qa-runs/* sidecars.
  • [IMPORTANT] #3343166662corpus-manifest.yaml: detected_in updated from qa-review-YD-87-7.yamlqa-review.yaml.

@RNekhoda
RNekhoda merged commit 4e4f93b into main Jun 2, 2026
7 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants