Good Prompts

Recover the minimal semantic model

Async behavior, duplicated state, or refactors need semantic analysis.

Added
Scope
State machines and semantics · runs in a repo
  • 1.1Klikes
  • 10replies
  • 42shares
  • 35.4Kviews

prompt

Recover my program's minimal semantic model.

1. State: every value that changes what the user sees
2. Transitions: what commutes, what's idempotent, what's order-dependent
3. Dependencies: what must be true before each effect fires

Then find:
→ nondeterminism in awaits, retries and event order
→ invariants enforced by hope
→ one fact stored in two places, drifting
→ work that never reaches the screen

Last, split my refactors into "provably equivalent" and "trust me". For each "trust me", give the smallest input that breaks it.

verified·fix it on github