Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
2 changes: 2 additions & 0 deletions AGENTS.md
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,8 @@ documentation in `docs/`, and benchmark tooling in `vortex-bench/` and `benchmar
- `vortex-array` contains the core `Array` trait and the base encodings, including most
Apache Arrow-style encodings.
- `encodings/*` contains more specialized compressed encodings.
- `vortex-expr` contains expression trees, their optimizer, and the analyses and rewrites built on
them. `vortex-functions` contains the scalar functions that `vortex-array` itself is not built on.
- `vortex-file` implements file IO. It uses `LayoutReader` from `vortex-layout`.
- `vortex-io` holds the core async and blocking IO traits, plus the generic `object_store`
adapters that implement them.
Expand Down
15 changes: 14 additions & 1 deletion Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 4 additions & 2 deletions docs/concepts/expressions.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,10 @@ to the returned data.
Expressions are defined as abstract scalar functions. These vtables define the signature of the function, properties
such as whether the function is strict, and the actual logic for executing the function over input arrays.

The built-in scalar functions can be found in the `vortex-array::expr` module, with additional use-case specific
functions provided by integration and plugin crates.
The scalar function framework and the handful of functions the array crate itself is built on live in
`vortex_array::scalar_fn`; expression trees, their optimizer and the analyses built on them live in the
`vortex-expr` crate; `vortex-functions` holds the rest of the built-in scalar functions, with additional
use-case specific functions provided by integration and plugin crates.

In the future, we plan to add full support for spatial functions, date-time functions, and more.

Expand Down
4 changes: 2 additions & 2 deletions encodings/datetime-parts/src/compute/take.rs
Original file line number Diff line number Diff line change
Expand Up @@ -9,9 +9,9 @@ use vortex_array::arrays::PrimitiveArray;
use vortex_array::arrays::dict::TakeExecute;
use vortex_array::builtins::ArrayBuiltins;
use vortex_array::dtype::Nullability;
use vortex_array::expr::stats::Stat;
use vortex_array::expr::stats::StatsProvider;
use vortex_array::scalar::Scalar;
use vortex_array::stats::Stat;
use vortex_array::stats::StatsProvider;
use vortex_error::VortexResult;
use vortex_error::vortex_panic;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,10 +23,10 @@ use vortex_array::arrays::PrimitiveArray;
use vortex_array::arrays::WidenArray;
use vortex_array::dtype::DType;
use vortex_array::dtype::DecimalType;
use vortex_array::expr::stats::Stat;
use vortex_array::match_each_signed_integer_ptype;
use vortex_array::scalar::DecimalValue;
use vortex_array::scalar::Scalar;
use vortex_array::stats::Stat;
use vortex_error::VortexExpect;
use vortex_error::VortexResult;
use vortex_mask::Mask;
Expand Down
4 changes: 2 additions & 2 deletions encodings/elias-fano/src/unary/tests.rs
Original file line number Diff line number Diff line change
Expand Up @@ -33,12 +33,12 @@ use vortex_array::compute::conformance::consistency::test_array_consistency;
use vortex_array::dtype::DType;
use vortex_array::dtype::Nullability::NonNullable;
use vortex_array::dtype::PType;
use vortex_array::expr::stats::Precision;
use vortex_array::expr::stats::Stat;
use vortex_array::match_each_unsigned_integer_ptype;
use vortex_array::scalar::ScalarValue;
use vortex_array::serde::SerializeOptions;
use vortex_array::serde::SerializedArray;
use vortex_array::stats::Precision;
use vortex_array::stats::Stat;
use vortex_array::test_harness::check_metadata;
use vortex_array::validity::Validity;
use vortex_array::vtable::VTable;
Expand Down
4 changes: 2 additions & 2 deletions encodings/fastlanes/src/for_/array/for_compress.rs
Original file line number Diff line number Diff line change
Expand Up @@ -14,10 +14,10 @@ use vortex_array::arrays::PrimitiveArray;
use vortex_array::arrays::primitive::PrimitiveArrayExt;
use vortex_array::dtype::NativePType;
use vortex_array::dtype::Nullability;
use vortex_array::expr::stats::Stat;
use vortex_array::match_each_integer_ptype;
use vortex_array::scalar::PValue;
use vortex_array::scalar::Scalar;
use vortex_array::stats::Stat;
use vortex_array::validity::Validity;
use vortex_buffer::BitBuffer;
use vortex_buffer::BitBufferView;
Expand Down Expand Up @@ -230,8 +230,8 @@ mod test {
use vortex_array::arrays::primitive::PrimitiveArrayExt;
use vortex_array::assert_arrays_eq;
use vortex_array::dtype::PType;
use vortex_array::expr::stats::StatsProvider;
use vortex_array::scalar::Scalar;
use vortex_array::stats::StatsProvider;
use vortex_array::validity::Validity;
use vortex_buffer::Buffer;
use vortex_buffer::buffer;
Expand Down
2 changes: 2 additions & 0 deletions encodings/fsst/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@ rand = { workspace = true, optional = true }
vortex-array = { workspace = true }
vortex-buffer = { workspace = true }
vortex-error = { workspace = true }
vortex-expr = { workspace = true }
vortex-functions = { workspace = true }
vortex-mask = { workspace = true }
vortex-session = { workspace = true }
Expand All @@ -36,6 +37,7 @@ rand = { workspace = true }
rstest = { workspace = true }
test-with = { workspace = true }
vortex-array = { workspace = true, features = ["_test-harness"] }
vortex-expr = { workspace = true }

[[bench]]
name = "fsst_compress"
Expand Down
5 changes: 3 additions & 2 deletions encodings/fsst/benches/fsst_url_compare.rs
Original file line number Diff line number Diff line change
Expand Up @@ -16,14 +16,15 @@ use vortex_array::arrays::VarBinArray;
use vortex_array::arrays::VarBinViewArray;
use vortex_array::arrays::varbin::VarBinArrayExt;
use vortex_array::builtins::ArrayBuiltins;
use vortex_array::expr::lit;
use vortex_array::expr::root;
use vortex_array::memory::MemorySession;
use vortex_array::optimizer::kernels::KernelSession;
use vortex_array::scalar::Scalar;
use vortex_array::scalar_fn::builtin::operators::Operator;
use vortex_array::session::ArraySession;
use vortex_array::test_harness::mark_optimized;
use vortex_expr::ArrayExprExt;
use vortex_expr::lit;
use vortex_expr::root;
use vortex_fsst::fsst_compress;
use vortex_fsst::fsst_train_compressor;
use vortex_fsst::test_utils::HIGH_MATCH_DOMAIN;
Expand Down
4 changes: 2 additions & 2 deletions encodings/fsst/src/compress.rs
Original file line number Diff line number Diff line change
Expand Up @@ -26,9 +26,9 @@ use vortex_array::buffer::BufferHandle;
use vortex_array::dtype::DType;
use vortex_array::dtype::IntegerPType;
use vortex_array::dtype::OffsetBuilderPType;
use vortex_array::expr::stats::Precision;
use vortex_array::expr::stats::Stat;
use vortex_array::match_each_integer_ptype;
use vortex_array::stats::Precision;
use vortex_array::stats::Stat;
use vortex_array::validity::Validity;
use vortex_buffer::Alignment;
use vortex_buffer::BufferAllocatorRef;
Expand Down
8 changes: 4 additions & 4 deletions encodings/fsst/src/compute/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -20,11 +20,11 @@ use vortex_array::arrays::primitive::PrimitiveArrayExt;
use vortex_array::arrays::varbin::take_varbin;
use vortex_array::builtins::ArrayBuiltins;
use vortex_array::dtype::IntegerPType;
use vortex_array::expr::stats::Stat;
use vortex_array::expr::stats::StatsProviderExt;
use vortex_array::match_each_integer_ptype;
use vortex_array::match_each_unsigned_integer_ptype;
use vortex_array::scalar::Scalar;
use vortex_array::stats::Stat;
use vortex_array::stats::StatsProviderExt;
use vortex_error::VortexResult;
use vortex_mask::AllOr;

Expand Down Expand Up @@ -174,9 +174,9 @@ mod tests {
use vortex_array::compute::conformance::take::test_take_conformance;
use vortex_array::dtype::DType;
use vortex_array::dtype::Nullability;
use vortex_array::expr::stats::Precision;
use vortex_array::expr::stats::Stat;
use vortex_array::optimizer::ArrayOptimizer;
use vortex_array::stats::Precision;
use vortex_array::stats::Stat;
use vortex_array::validity::Validity;
use vortex_buffer::buffer;
use vortex_error::VortexResult;
Expand Down
3 changes: 2 additions & 1 deletion encodings/fsst/src/kernel.rs
Original file line number Diff line number Diff line change
Expand Up @@ -44,8 +44,9 @@ mod tests {
use vortex_array::assert_arrays_eq;
use vortex_array::dtype::DType;
use vortex_array::dtype::Nullability;
use vortex_array::expr::root;
use vortex_error::VortexResult;
use vortex_expr::ArrayExprExt;
use vortex_expr::root;
use vortex_functions::expr::byte_length;
use vortex_mask::Mask;
use vortex_session::VortexSession;
Expand Down
1 change: 1 addition & 0 deletions encodings/parquet-variant/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,7 @@ rstest = { workspace = true }
tokio = { workspace = true, features = ["full"] }
vortex-array = { workspace = true, features = ["_test-harness"] }
vortex-arrow = { workspace = true, features = ["_test-harness-hegel"] }
vortex-expr = { workspace = true }
vortex-file = { workspace = true, features = ["tokio"] }
vortex-io = { workspace = true, features = ["tokio"] }
vortex-layout = { workspace = true }
Expand Down
1 change: 1 addition & 0 deletions encodings/parquet-variant/src/arrow.rs
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,7 @@ use vortex_arrow::to_arrow_null_buffer;
use vortex_error::VortexResult;
use vortex_error::vortex_bail;
use vortex_error::vortex_ensure;
use vortex_functions::builtins::ArrayFunctions;
use vortex_session::registry::CachedId;
use vortex_session::registry::Id;

Expand Down
3 changes: 2 additions & 1 deletion encodings/parquet-variant/src/json_to_variant_tests.rs
Original file line number Diff line number Diff line change
Expand Up @@ -26,10 +26,11 @@ use vortex_array::assert_nth_scalar_is_null;
use vortex_array::dtype::DType;
use vortex_array::dtype::Nullability;
use vortex_array::dtype::PType;
use vortex_array::expr::root;
use vortex_error::VortexResult;
use vortex_error::vortex_bail;
use vortex_error::vortex_err;
use vortex_expr::ArrayExprExt;
use vortex_expr::root;
use vortex_functions::expr::variant_get;
use vortex_functions::variant_get::VariantPath;
use vortex_json::Json;
Expand Down
3 changes: 2 additions & 1 deletion encodings/parquet-variant/src/kernel.rs
Original file line number Diff line number Diff line change
Expand Up @@ -326,14 +326,15 @@ mod tests {
use vortex_array::dtype::DType as VortexDType;
use vortex_array::dtype::Nullability;
use vortex_array::dtype::PType;
use vortex_array::expr::root;
use vortex_array::optimizer::ArrayOptimizer;
use vortex_array::validity::Validity;
use vortex_arrow::ArrowSessionExt;
use vortex_error::VortexResult;
use vortex_error::vortex_bail;
use vortex_error::vortex_ensure;
use vortex_error::vortex_err;
use vortex_expr::ArrayExprExt;
use vortex_expr::root;
use vortex_functions::expr::variant_get;
use vortex_functions::variant_get::VariantPath;
use vortex_functions::variant_get::VariantPathElement;
Expand Down
1 change: 1 addition & 0 deletions encodings/sequence/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ vortex-array = { workspace = true }
vortex-buffer = { workspace = true }
vortex-compute = { workspace = true }
vortex-error = { workspace = true }
vortex-expr = { workspace = true }
vortex-functions = { workspace = true }
vortex-mask = { workspace = true }
vortex-session = { workspace = true }
Expand Down
10 changes: 5 additions & 5 deletions encodings/sequence/src/array/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -26,14 +26,14 @@ use vortex_array::dtype::DType;
use vortex_array::dtype::NativePType;
use vortex_array::dtype::Nullability;
use vortex_array::dtype::PType;
use vortex_array::expr::stats::Precision as StatPrecision;
use vortex_array::expr::stats::Stat;
use vortex_array::match_each_integer_ptype;
use vortex_array::match_each_pvalue;
use vortex_array::proto::scalar::ScalarValue as ProtoScalarValue;
use vortex_array::scalar::PValue;
use vortex_array::scalar::Scalar;
use vortex_array::scalar::ScalarValue;
use vortex_array::stats::Precision as StatPrecision;
use vortex_array::stats::Stat;
use vortex_array::stats::StatsSet;
use vortex_array::validity::Validity;
use vortex_array::vtable::OperationsVTable;
Expand Down Expand Up @@ -518,14 +518,14 @@ mod tests {
use vortex_array::dtype::DType;
use vortex_array::dtype::Nullability;
use vortex_array::dtype::PType;
use vortex_array::expr::stats::Precision as StatPrecision;
use vortex_array::expr::stats::Stat;
use vortex_array::expr::stats::StatsProviderExt;
use vortex_array::optimizer::ArrayOptimizer;
use vortex_array::scalar::PValue;
use vortex_array::scalar::Scalar;
use vortex_array::serde::SerializeOptions;
use vortex_array::serde::SerializedArray;
use vortex_array::stats::Precision as StatPrecision;
use vortex_array::stats::Stat;
use vortex_array::stats::StatsProviderExt;
use vortex_buffer::ByteBufferMut;
use vortex_error::VortexResult;
use vortex_error::vortex_err;
Expand Down
5 changes: 3 additions & 2 deletions encodings/sequence/src/compute/list_contains.rs
Original file line number Diff line number Diff line change
Expand Up @@ -97,11 +97,12 @@ mod tests {
use vortex_array::dtype::DType;
use vortex_array::dtype::Nullability;
use vortex_array::dtype::PType::I32;
use vortex_array::expr::lit;
use vortex_array::expr::root;
use vortex_array::optimizer::ArrayOptimizer;
use vortex_array::scalar::Scalar;
use vortex_error::VortexResult;
use vortex_expr::ArrayExprExt;
use vortex_expr::lit;
use vortex_expr::root;
use vortex_functions::expr::list_contains;
use vortex_functions::expr::list_contains_opts;
use vortex_functions::list_contains::ListContainsOptions;
Expand Down
6 changes: 3 additions & 3 deletions encodings/zstd/src/zstd_buffers/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -580,12 +580,12 @@ mod tests {
use vortex_array::arrays::PrimitiveArray;
use vortex_array::arrays::VarBinViewArray;
use vortex_array::assert_arrays_eq;
use vortex_array::expr::stats::Precision;
use vortex_array::expr::stats::Stat;
use vortex_array::expr::stats::StatsProvider;
use vortex_array::serde::SerializeOptions;
use vortex_array::serde::SerializedArray;
use vortex_array::session::ArraySessionExt;
use vortex_array::stats::Precision;
use vortex_array::stats::Stat;
use vortex_array::stats::StatsProvider;
use vortex_buffer::ByteBufferMut;
use vortex_error::VortexExpect;
use vortex_error::VortexResult;
Expand Down
1 change: 1 addition & 0 deletions fuzz/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,7 @@ vortex-array = { workspace = true, features = ["arbitrary", "_test-harness"] }
vortex-btrblocks = { workspace = true }
vortex-buffer = { workspace = true }
vortex-error = { workspace = true }
vortex-expr = { workspace = true, features = ["arbitrary"] }
vortex-fsst = { workspace = true, features = ["_test-harness"] }
vortex-functions = { workspace = true }
vortex-io = { workspace = true, features = ["wasm-bindgen"] }
Expand Down
5 changes: 3 additions & 2 deletions fuzz/fuzz_targets/file_io.rs
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,8 @@
use itertools::Itertools;
use libfuzzer_sys::Corpus;
use libfuzzer_sys::fuzz_target;
use vortex::expr::lit;
use vortex::expr::root;
use vortex_array::Canonical;
use vortex_array::IntoArray;
use vortex_array::VortexSessionExecute;
Expand All @@ -15,10 +17,9 @@ use vortex_array::arrays::bool::BoolArrayExt;
use vortex_array::assert_arrays_eq;
use vortex_array::dtype::DType;
use vortex_array::dtype::StructFields;
use vortex_array::expr::lit;
use vortex_array::expr::root;
use vortex_btrblocks::BtrBlocksCompressorBuilder;
use vortex_error::VortexExpect;
use vortex_expr::ArrayExprExt;
use vortex_file::OpenOptionsSessionExt;
use vortex_file::WriteOptionsSessionExt;
use vortex_file::WriteStrategyBuilder;
Expand Down
Loading
Loading