Closed davidweichiang closed 2 years ago
Somehow a commit is missing and I'm not sure if it's because of the Github downtime or my mistake...
(Is this ready to review? Did the previous commit reappear?)
Yes, it reappeared!
One thing about this is that it works best if you create the whole HRG first and then its interpretation. If you try to create them at the same time, the convenience functions may not work. In particular, if you try to add a domain or factor before adding a rule that contains the corresponding node or edge label, then there will be an exception.
In #126 we added some convenience functions to simplify FGG creation, but it wasn't enough; this PR adds more functions and demonstrates them on parser.py.