#diff #tree #distance #levenshtein #lcs

tree-edit-distance

Find the lowest cost sequence of edits between two trees

3 releases (breaking)

0.3.0 Oct 24, 2021
0.2.0 Sep 2, 2021
0.1.0 May 9, 2020

#595 in Algorithms

MIT license

20KB
399 lines

TreeEditDistance docs.badge codecov.badge

This crate provides an algorithm to compute the lowest cost sequence of edits between two trees. It is based on a recursive generalized version of the Levenshtein distance for arbitrary sequences, where inserting/deleting nodes may have an arbitrary user-defined cost.

Using TreeEditDistance

TreeEditDistance is available on crates.io, simply add it as a dependency in your Cargo.toml:

[dependencies]
tree-edit-distance = "0.3"

The full API documentation is available on docs.rs

Contribution

TreeEditDistance is an open source project and you're very welcome to contribute to this project by opening issues and/or pull requests, see CONTRIBUTING for general guidelines.

License

TreeEditDistance is distributed under the terms of the MIT license, see LICENSE for details.

Dependencies

~1.4–2MB
~43K SLoC

öƒua