--- id: zss version: "1.2.0" license: unclear license_treatment: unclear maintenance: abandoned --- # zss — Tree edit distance using the Zhang Shasha algorithm License: unclear · Maintenance: abandoned · Downloads: 306.7K/mo ## What it is and what it does zss implements the Zhang-Shasha algorithm for computing tree edit distance—a measure of how many insertions, deletions, and relabelings are needed to transform one tree into another. It provides a default Node class and edit distance function for convenience, but also accepts custom tree formats and distance metrics via callback functions. The package is designed for comparing hierarchical structures where you need a numeric similarity or difference score. It has no runtime dependencies by default, though optional dependencies (editdist for string-based label comparison, numpy for performance) can be installed. However, the package has been abandoned since 2018 and is no longer maintained, creating risk around compatibility with modern Python and dependency versions. Use it for: - Compare abstract syntax trees (ASTs) from different code versions to measure structural changes - Measure similarity between XML or JSON document structures for data reconciliation - Detect structural differences in parse trees for natural language processing tasks - Quantify changes in hierarchical data models or organizational structures over time ## Worth the install? AI-flagged interpretation of the facts above — verify before relying. Computes the edit distance between two tree structures using the Zhang-Shasha algorithm, with support for custom node formats and distance metrics. No. The package is abandoned (last release 2018, last commit 2020) with unclear licensing and unspecified Python support. While the algorithm is sound and there are no known vulnerabilities, the lack of maintenance creates compatibility risk with modern Python versions and dependency ecosystems. Consider maintained alternatives or implementing Zhang-Shasha directly if tree edit distance is critical to your project. ## Install pip install zss uv add zss poetry add zss ## Installing zss Before you install: High install friction: the package is abandoned (last release March 2018, last commit October 2020) with no declared runtime dependencies but requires compilation from source. No active maintenance. License in practice: License status is unclear—no SPDX identifier or raw license text provided. Verify licensing terms before use in proprietary or copyleft-sensitive projects. Quickstart: from zss import simple_distance, Node A = Node("f").addkid(Node("a")).addkid(Node("e")) B = Node("f").addkid(Node("a")).addkid(Node("e")) dist = simple_distance(A, B) print(dist) Package is abandoned with no active maintenance; Python version support is unspecified and may not work on modern Python versions. Verify before relying: - Compatibility with Python 3.10+ and current NumPy/editdist versions - Whether optional dependencies (editdist, numpy >= 1.7) are still installable and functional - Actual license terms (no SPDX or raw license text in metadata) ## Package facts - License: not declared (unclear) - Python support: unspecified - Install friction: high - Maintenance: abandoned - Downloads: 306.7K/month (top 15,000 on PyPI) - Known vulnerabilities: none known ## Tags tree edit distance, zhang shasha algorithm, tree comparison distance, tree similarity metric, structural tree diff, tree alignment distance, node-based tree metrics, tree-algorithms, edit-distance, abandoned [View on SkillFed](https://skillfed.io/packages/zss) · [View on PyPI](https://pypi.org/project/zss/)