Skip to content

Add wishlist-synthesis pattern to KeyValueStore example#41

Open
segevem wants to merge 1 commit into
mainfrom
kvstore-wishlist-synthesis
Open

Add wishlist-synthesis pattern to KeyValueStore example#41
segevem wants to merge 1 commit into
mainfrom
kvstore-wishlist-synthesis

Conversation

@segevem

@segevem segevem commented Jun 24, 2026

Copy link
Copy Markdown
Collaborator

Summary

  • Introduces success-only generation via WishOp + SetupForOp + ExecWishOp relations
  • Callers specify desired operations without worrying about preconditions; the framework synthesizes setup calls automatically
  • Simplifies ANil constructor (removes redundant reflexivity hypotheses)
  • Updates test file with derivations for the new relations

Test plan

  • lake env lean passes on both KeyValueStore.lean and TestKeyValueStoreCheckerGenerators.lean
  • Derived generators produce samples successfully

@segevem segevem force-pushed the kvstore-wishlist-synthesis branch from b25b57b to 3f9b448 Compare June 24, 2026 17:11
Introduces a "success-only generation" approach: callers specify
WishOp operations they want to perform (Get, Copy, Delete, etc.)
without worrying about preconditions. SetupForOp synthesizes the
necessary Set calls to satisfy each op's preconditions, and
ExecWishOp executes the op on the prepared state.

This demonstrates a generate-then-satisfy pattern where the test
harness never produces failing API calls by construction, improving
generator throughput for stateful protocol testing.

Also simplifies the ANil constructor (removes redundant reflexivity
hypotheses) and updates the test file accordingly.
@segevem segevem force-pushed the kvstore-wishlist-synthesis branch from 3f9b448 to aee3fd2 Compare June 24, 2026 20:46
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