Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
30 commits
Select commit Hold shift + click to select a range
94be61d
Add experimental OnPair string encoding backed by the onpair crate
joseph-isaacs May 29, 2026
383ef64
Clean up onpair encoding: drop dead public API and stale comments
joseph-isaacs May 29, 2026
5d03b9e
fix
joseph-isaacs May 29, 2026
0dc843c
fix
joseph-isaacs May 29, 2026
4ca21b8
fix
joseph-isaacs May 29, 2026
75f735c
fix
joseph-isaacs May 29, 2026
a21ea30
onpair: delegate decompression to the upstream onpair crate
joseph-isaacs May 29, 2026
3c6006a
fix
joseph-isaacs May 29, 2026
9e98f0c
Merge branch 'develop' into onpair-encoding
joseph-isaacs May 29, 2026
72ae5c7
Merge branch 'develop' into onpair-encoding
joseph-isaacs May 29, 2026
5b4b047
onpair: canonicalise offsets children before widening in decode
joseph-isaacs May 29, 2026
6bc07df
onpair: add regression test reproducing the delta dict_offsets panic
joseph-isaacs May 29, 2026
3baf1b9
fastlanes: don't widen Delta in place during cast (root cause of onpa…
joseph-isaacs May 29, 2026
d31e4a7
fix
joseph-isaacs May 29, 2026
467d976
fastlanes: silence unused import after disabling Delta cast rule
joseph-isaacs May 29, 2026
23d714b
Merge remote-tracking branch 'origin/develop' into onpair-encoding
joseph-isaacs May 29, 2026
5a13e8e
fix
joseph-isaacs May 29, 2026
9be635b
fix
joseph-isaacs May 29, 2026
3b3a169
fix
joseph-isaacs May 29, 2026
4de0ec1
fix
joseph-isaacs May 29, 2026
9259c56
fix
joseph-isaacs May 29, 2026
69d801e
fix
joseph-isaacs May 29, 2026
4b7af85
fix
joseph-isaacs May 29, 2026
e5aca42
perf
joseph-isaacs May 29, 2026
080da5b
perf
joseph-isaacs May 29, 2026
99ed3f4
perf
joseph-isaacs May 29, 2026
b173497
perf
joseph-isaacs May 29, 2026
8baa429
fix
joseph-isaacs May 29, 2026
95ee612
fix
joseph-isaacs May 29, 2026
da168c8
fix
joseph-isaacs May 29, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
40 changes: 34 additions & 6 deletions Cargo.lock

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

4 changes: 4 additions & 0 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,8 @@ members = [
"encodings/zstd",
"encodings/bytebool",
"encodings/parquet-variant",
# Experimental encodings
"encodings/experimental/onpair",
# Benchmarks
"benchmarks/lance-bench",
"benchmarks/compress-bench",
Expand Down Expand Up @@ -188,6 +190,7 @@ num_enum = { version = "0.7.3", default-features = false }
object_store = { version = "0.13.1", default-features = false }
once_cell = "1.21"
oneshot = { version = "0.2.0", features = ["async"] }
onpair = { version = "0.0.3", git = "https://github.com/spiraldb/onpair.git", rev = "53e8ca6081d377e9933d999cef286e26bf52e2c7" }
opentelemetry = "0.32.0"
opentelemetry-otlp = "0.32.0"
opentelemetry_sdk = "0.32.0"
Expand Down Expand Up @@ -288,6 +291,7 @@ vortex-ipc = { version = "0.1.0", path = "./vortex-ipc", default-features = fals
vortex-layout = { version = "0.1.0", path = "./vortex-layout", default-features = false }
vortex-mask = { version = "0.1.0", path = "./vortex-mask", default-features = false }
vortex-metrics = { version = "0.1.0", path = "./vortex-metrics", default-features = false }
vortex-onpair = { version = "0.1.0", path = "./encodings/experimental/onpair", default-features = false }
vortex-parquet-variant = { version = "0.1.0", path = "./encodings/parquet-variant" }
vortex-pco = { version = "0.1.0", path = "./encodings/pco", default-features = false }
vortex-proto = { version = "0.1.0", path = "./vortex-proto", default-features = false }
Expand Down
40 changes: 40 additions & 0 deletions encodings/experimental/onpair/Cargo.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
[package]
name = "vortex-onpair"
authors = { workspace = true }
categories = { workspace = true }
description = "Vortex OnPair string array encoding (dict-12, pushdown predicates)"
edition = { workspace = true }
homepage = { workspace = true }
include = { workspace = true }
keywords = { workspace = true }
license = { workspace = true }
readme = "README.md"
repository = { workspace = true }
rust-version = { workspace = true }
version = { workspace = true }

[lints]
workspace = true

[dependencies]
memchr = { workspace = true }
num-traits = { workspace = true }
onpair = { workspace = true }
prost = { workspace = true }
vortex-array = { workspace = true }
vortex-buffer = { workspace = true }
vortex-error = { workspace = true }
vortex-mask = { workspace = true }
vortex-session = { workspace = true }

[features]
_test-harness = ["vortex-array/_test-harness"]

[dev-dependencies]
divan = { workspace = true }
rstest = { workspace = true }
vortex-array = { workspace = true, features = ["_test-harness"] }

[[bench]]
name = "decode"
harness = false
39 changes: 39 additions & 0 deletions encodings/experimental/onpair/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
# Vortex OnPair

A Vortex Encoding for Binary and Utf8 data that uses the
[OnPair][onpair] short-string compression algorithm. OnPair is a
dictionary-based encoder with fast per-row random access.

The trainer / encoder lives in the standalone [`onpair`][onpair-crate]
crate; this crate wraps the resulting column as a Vortex array with
cascading-compressor support on every integer child.

## Compute

Like the FSST encoding, this crate provides `cast` and `filter`
pushdown. Other operators fall back to ordinary decompression.

## Default Configuration

The default training preset is **dict-12**: 12 bits per token,
dictionary capped at 4 096 entries. Token codes are stored as a
`PrimitiveArray<u16>`; downstream `FastLanes::BitPacking` losslessly
narrows the child to exactly `bits`-bit codes on disk.

## Layout

- Buffer 0 — `dict_bytes`: dictionary blob built by the OnPair trainer,
padded with `MAX_TOKEN_SIZE` trailing zero bytes so the over-copy
decoder can read 16 bytes past the last token.
- Slot 0 — `dict_offsets`: `PrimitiveArray<u32>`, len `dict_size + 1`.
- Slot 1 — `codes`: `PrimitiveArray<u16>`, length `total_tokens`.
- Slot 2 — `codes_offsets`: `PrimitiveArray<u32>`, length `num_rows + 1`.
- Slot 3 — `uncompressed_lengths`: integer `PrimitiveArray`, length
`num_rows`.
- Slot 4 — optional validity child.

All four integer slot children flow through the standard cascading
compressor pipeline (FoR / BitPacking / RunEnd / etc.).

[onpair]: https://arxiv.org/abs/2508.02280
[onpair-crate]: https://github.com/spiraldb/onpair
Loading
Loading