fix(#74): strip phino's xi-free condition in gen-rules.py - #75
Conversation
The rcond check matched the key `xi`, but phino's copy.yaml uses `xi-free`, so the strip never fired and Rules.lean showed `xi-free(𝑒) and nf(𝑒)` for copy, contradicting its own header. Match `xi-free`, fix the header to say `nf(𝑒)` (copy's metavariable), and regenerate Rules.lean from the same phino commit (1f2fada) it was generated from, so copy's condition is now `nf(𝑒)` only. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01XWY8yTGgWJ1HXoFjmLt3AZ
|
The log shows the cause. I don't know of an existing fix. The script needs to read Generated by Claude Code |
|
I reproduced it locally with that binary. It has two layers:
Layer 2 comes down to whether the proof's Generated by Claude Code |
#72 moved rendering into .github/phino_render.py, shared by the display table and the fidelity lock, and stopped tracking Rules.lean. The lock keeps copy's xi-free guard (Step.copy carries xiFree), so the #74 fix becomes a strip_xi flag that only gen-rules.py turns on, with a test. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01XWY8yTGgWJ1HXoFjmLt3AZ
|
Update: my two comments above no longer apply. After merging master (#72: phino pinned to 0.0.0.74, Generated by Claude Code |
Closes #74.
The display table (
PhiConfluence/Rules.lean, generated by.github/gen-rules.py) says it strips phino's ξ-free side-conditions, so thatcopyshows onlynf(𝑒), as in the paper. It never did. The renderer looked for the keyxi, but phino'scopy.yamlusesxi-free, socopywas rendered asxi-free(𝑒) and nf(𝑒).Since #72, the rendering lives in
.github/phino_render.py, which is shared by the display table and the fidelity lock ingen-rule-data.py. The lock deliberately keeps the ξ-free guard, becauseStep.copycarriesxiFreeandLOCK["copy"]expects"xi-free(𝑒) and nf(𝑒)". So the strip has to apply to the display table only.Changes:
phino_render.rcondandphino_render.rulestake astrip_xi=Falseflag. When it is set,xi-freeconditions are dropped. The module docstring now explains who sets it and why.gen-rules.pycallsrendered(res_dir, strip_xi=True). Its docstring now names the right key, and the generated header now sayscopyshowsnf(𝑒), notnf(𝑒1), sincecopy's metavariable is𝑒.test_strips_the_xi_free_condition_of_copyin.github/test_gen_rules.py. It fails without the fix and passes with it.Checked locally:
python3 -m pytest .github: 13 passed.ruff check .github: clean.bash .github/regen-rules.shagainst the pinned phino 0.0.0.74: the fidelity lock still holds, andRules.leannow hascond := "nf(𝑒)"forcopy.🤖 Generated with Claude Code
https://claude.ai/code/session_01XWY8yTGgWJ1HXoFjmLt3AZ