openai / lean-gym

Apache License 2.0
150 stars 31 forks source link

Shrink #18

Closed dselsam closed 2 years ago

dselsam commented 2 years ago

Strip unused have statements (and their proofs) from proofs. Note: only lightly tested.

spolu commented 2 years ago

@dselsam Thinking more about using that for real. We'll need the sequence of tactic state on top of the sequence of tactics to be able to fully reconstruct the data we need.

Any chance this is easy to add?

dselsam commented 2 years ago

@dselsam Thinking more about using that for real. We'll need the sequence of tactic state on top of the sequence of tactics to be able to fully reconstruct the data we need.

Any chance this is easy to add?

@spolu Sure, I am literally throwing out this information at the very end: https://github.com/dselsam/lean3-gym/blob/shrink/src/repl.lean#L334 What format do you want specifically? The representation I am using ([(ts1, action, ts2)]) duplicates the tactic-states, which is fine with reference-counting but bad when converting to string.

spolu commented 2 years ago

I think we can simply do [(TacticState, Tactic)] and have as a convention that the last TacticState (omitted) is assumed to be no goals?

spolu commented 2 years ago

This all looks great \o/

Two comments before merge: