Skip to content

feat: add support for disproofs#16

Open
Paul-Lez wants to merge 2 commits intoGasStationManager:mainfrom
Paul-Lez:disproofs
Open

feat: add support for disproofs#16
Paul-Lez wants to merge 2 commits intoGasStationManager:mainfrom
Paul-Lez:disproofs

Conversation

@Paul-Lez
Copy link
Contributor

@Paul-Lez Paul-Lez commented Feb 24, 2026

This PR adds support for disproof submissions: when a target file contains a theorem foo, a submission file may instead provide foo.disproof (a proof of the negation of foo's statement) rather than a proof of foo itself.

This is useful in challenge settings where the target statement may be false and contestants should demonstrate this by proving its negation.

More specifically this does the following:

  • Adds a --disproofs CLI flag to opt in to disproof checking
  • Adds allowDisproofs : Bool to Settings and env : Environment to Decls (needed to run the negation check)
  • Adds checkNegatedTheorem in Util.lean, which uses push_neg + kernel type-checking to verify that a submission's type is definitionally equal to the negation of the target's type
  • checkTargets now looks for a foo.disproof entry in the submission when allowDisproofs is set, and routes it through the negation check instead of the standard type-equality check

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.

1 participant