-
Notifications
You must be signed in to change notification settings - Fork 20
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Save proofs #187
Save proofs #187
Conversation
- Multiple theorems in one file. - Finish justification mappings. - Recreate theorems. - Optionally recompute theorems and cache, recompute but not cache, or use cache (sbt tasks?). - Evaluate.
… including some from the library with imports. theorems get fully reconstructed. Now, integrate.
… Can now create a high level THM directly from a kernel theorem. Left to do: Apply that to proof files. Options to run with cache, without cache without creating it and without cache and create it. Need to detect changes in statements. POssibly, do hashconsing before storing
…whether serialization is activated to constructors? How to construct theorems in a good order?
…y successful. Running Recursion.scala (i.e. everything) takes around 19s instead of 24s
|
@@ -30,6 +30,8 @@ abstract class Library extends lisa.prooflib.WithTheorems with lisa.prooflib.Pro | |||
|
|||
var last: Option[JUSTIFICATION] = None | |||
|
|||
var _withCache: Boolean = false |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We should probably wrap this up in a settings interface. Eg: Settings.runWithCache(true)
in the relevant file
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Not in this PR necessarily, but going forward.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Good idea, I'll do that somewhat soon, probably in the next PR
@@ -19,7 +19,7 @@ private[settheory] trait SetTheoryZAxioms extends SetTheoryDefinitions { | |||
* | |||
* `() |- (x = y) ⇔ ∀ z. z ∈ x ⇔ z ∈ y` | |||
*/ | |||
final val extensionalityAxiom: this.AXIOM = Axiom("extensionalityAxiom", forall(z, in(z, x) <=> in(z, y)) <=> (x === y)) | |||
final val extensionalityAxiom: this.AXIOM = Axiom(forall(z, in(z, x) <=> in(z, y)) <=> (x === y)) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
final val extensionalityAxiom: this.AXIOM = Axiom(forall(z, in(z, x) <=> in(z, y)) <=> (x === y)) | |
final val extensionalityAxiom: AXIOM = Axiom(forall(z, in(z, x) <=> in(z, y)) <=> (x === y)) |
The type annotations in this file are slightly inconsistent, with just this one being different afaict
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks great overall. Minor optional changes as above ^^
Thanks for adding tests and documentation for adjacent files as well.
inline def rightSubstIff: Byte = 26 | ||
inline def instSchema: Byte = 27 | ||
inline def scSubproof: Byte = 28 | ||
inline def sorry: Byte = 29 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Wouldn't it be better to have a toByte
with pattern matching? That way we have pattern match exhaustivity checking?
Tool to export proofs of theorems to binary files and back.