/tree-sitter-opensmarts

A Tree-sitter grammar implementing the OpenSmarts specification.

Primary LanguageJavaScriptOtherNOASSERTION

tree-sitter-opensmarts

This is a Tree-sitter grammar implementing the OpenSmarts specification

Notes

The provided grammar includes this bugfix, and a bugfix for "@@" clockwise chirality, so it deviates from the specification.

How to run

git clone https://github.com/0x1d1z3r/tree-sitter-opensmarts
cd tree-sitter-opensmarts

npm install --save-dev tree-sitter-cli				# install Tree-sitter
export PATH=$PATH:./node_modules/.bin 				# set $PATH

treesitter generate                   				# generate parser 

tree-sitter build --wasm					# only needed for playground
treesitter playground                 				# interactive example

Additional Files

A pure BNF (non LL) grammar for OpenSmarts is included in grammar.bnf

It is modified for use in BNFPlayground without EBNF syntax