diff options
Diffstat (limited to 'README.md')
-rw-r--r-- | README.md | 29 |
1 files changed, 29 insertions, 0 deletions
diff --git a/README.md b/README.md new file mode 100644 index 0000000..824a977 --- /dev/null +++ b/README.md @@ -0,0 +1,29 @@ +# zhsh + +An implementation of the [Zhang-Shasha]() algorithm for calculating +tree edit distance. + +Here trees are s-expressions with NON-NULL leaves. + +I.e. Leaves are `(and leaf (atom leaf))` + +## Examples: + + ZHSH> (treedist '((the cat) (sat (on (the mat)))) + '((the cat) (sat (on (the mat ))))) + 0 + + ZHSH> (treedist '((the cat) (sat (on (the mat)))) + '((the cat) (sat (on (a mat ))))) + 11 + + ZHSH> (treedist '((the cat) (sat (on (the mat)))) + '((the ordinary cats) (sit (on (a simple chair ))))) + 21 + + ZHSH> (treedist '((the cat) (sat (on (the mat)) (for (an hour)))) + '((the ordinary cats) (sit (on (a simple chair))))) + 26 + + + |