Pantograph/pantograph/compiler.py

18 lines
466 B
Python
Raw Normal View History

2024-05-31 17:09:12 -07:00
from dataclasses import dataclass
@dataclass(frozen=True)
class TacticInvocation:
2024-10-20 09:52:12 -07:00
"""
One tactic invocation with the before/after goals extracted from Lean source
code.
"""
2024-05-31 17:09:12 -07:00
before: str
after: str
tactic: str
@staticmethod
def parse(payload: dict):
return TacticInvocation(before=payload["goalBefore"],
after=payload["goalAfter"],
tactic=payload["tactic"])