#boolean-expression #tree #subscription #event-filtering

a-tree

A dynamic data structure for efficiently indexing arbitrary boolean expressions

6 releases (breaking)

new 0.5.0 Jan 16, 2025
0.4.1 Jan 9, 2025
0.3.0 Dec 20, 2024
0.2.0 Dec 18, 2024
0.1.0 Dec 16, 2024

#489 in Data structures

Download history 352/week @ 2024-12-15 43/week @ 2024-12-22 11/week @ 2024-12-29 250/week @ 2025-01-05 213/week @ 2025-01-12

572 downloads per month

MIT/Apache

205KB
5K SLoC

a-tree

Rust Latest version Documentation Code Coverage

This is an implementation of the A-Tree: A Dynamic Data Structure for Efficiently Indexing Arbitrary Boolean Expressions paper.

The A-Tree data structure is used to evaluate a large amount of boolean expressions as fast as possible. To achieve this, the data structure tries to reuse the intermediary nodes of the incoming expressions to minimize the amount of expressions that have to be evaluated.

Features

This crate supports the following features:

  • Insertion of arbitrary boolean expressions via a domain specific language;
  • Deletion of subscriptions;
  • Export to Graphviz format;
  • Search with events for matching arbitrary boolean expressions.

Documentation

The documentation is available on doc.rs.

License

This project is licensed under the Apache 2.0 and the MIT License.

Dependencies

~5.5–8.5MB
~125K SLoC