Skip to content

Customization

Customizing the parser

Parsing and translating the COOM files is done via the Python target of ANTLR v4. - To get started have a look at the COOM grammar - You can customize the translation by modifying the ASP Visitor

Tip

More information on the Python target of ANTLR v4 can be found here.

Add encodings

Warning

If using a different fact format, you might have to modify the preprocessing encoding located in the Encodings folder as well.

Generate ANTLR4 Python files

These files are used by the parser. To generate them from an ANTLR4 grammar, navigate to the corresponding folder and run (possibly replacing the version number and grammar file name)

antlr4 -v 4.9.3 -Dlanguage=Python3 Grammar.g4 -visitor

Contributing

If you want to contribute to the COOM Suite, check out the following guidelines.