--- warning: DO NOT CHANGE THIS MANUALLY, THIS IS GENERATED BY https://github.com/duckdb/community-extensions repository, check README there title: apart excerpt: | DuckDB Community Extensions Evaluate affine decision trees in SQL extension: name: apart description: Evaluate affine decision trees in SQL version: 0.3.0 language: C++ build: cmake license: MIT opt_in_platforms: "osx_amd64" maintainers: - jokasimr repo: github: jokasimr/apart ref: 4a70fcba4cee657bcd5217638d62d838d3762748 variegata: 0b216f8d1604ba731f21b20aad72ab4614370634 docs: hello_world: | LOAD apart; -- Split on x + y = 1, then on x - y = 0. SELECT x, y, decision_tree( { weights: [ [1.0, 1.0], [1.0, -1.0], [1.0, -1.0] ], thresholds: [1.0, 0.0, 0.0], children: [[2, 3], [-1, -2], [-4, -3]], values: ['A', 'B', 'C', 'D'] }, x, y ) AS region FROM (VALUES (1, 0), (0, 1), (-1, 0), (0, -1)) AS points(x, y); extended_description: | `apart` evaluates affine decision trees. Each node compares a weighted sum of the inputs with a threshold, and each leaf supplies a result. The tree stays constant for the query while the inputs vary by row. Inputs can be separate columns or a fixed-size array. Leaf values can use any DuckDB type, including lists and structs. See the [documentation](https://github.com/jokasimr/apart#readme) and [example use cases](https://github.com/jokasimr/apart/tree/main/examples). extension_star_count: 1 extension_star_count_pretty: 1 extension_download_count: 845 extension_download_count_pretty: 845 image: '/images/community_extensions/social_preview/preview_community_extension_apart.png' layout: community_extension_doc --- ### Compatibility Matrix This table covers all DuckDB releases that have not reached [end-of-life](https://duckdb.org/release_calendar), including LTS releases, and shows the 2 most recent patch releases of each. Older patch releases are not listed, but the extension may be available for them as well.
| Platform | 1.4.4 | 1.4.5 | 1.5.5 | 1.5.6 | 2.0.0 | | :--- | :---: | :---: | :---: | :---: | :---: | | Linux AMD64 | ❌ | ❌ | ✅ | ✅ | ✅ | | Linux ARM64 | ❌ | ❌ | ✅ | ✅ | ✅ | | macOS AMD64 | ❌ | ❌ | ✅ | ✅ | ✅ | | macOS ARM64 | ❌ | ❌ | ✅ | ✅ | ✅ | | Windows AMD64 | ❌ | ❌ | ✅ | ✅ | ✅ | | Windows ARM64 | ❌ | ❌ | ❌ | ❌ | ❌ | | WebAssembly | ❌ | ❌ | ✅ | ✅ | ✅ | ### Installing and Loading ```sql INSTALL {{ page.extension.name }} FROM community; LOAD {{ page.extension.name }}; ``` {% if page.docs.hello_world %} ### Example ```sql {{ page.docs.hello_world }}``` {% endif %} {% if page.docs.extended_description %} ### About {{ page.extension.name }} {{ page.docs.extended_description }} {% endif %} ### Added Functions | function_name | function_type | description | comment | examples | |---------------|---------------|-------------|---------|----------| | decision_tree | scalar | NULL | NULL | | | fixed_depth | scalar | NULL | NULL | | ### Overloaded Functions This extension does not add any function overloads. ### Added Types This extension does not add any types. ### Added Settings | name | description | input_type | scope | aliases | typed_value | |----------------|---------------------------------------------------------|------------|--------|---------|-------------| | temp_directory | Set the directory to which temporary files are written. | VARCHAR | GLOBAL | [] | post.db.tmp |