Hex package · Documentation
Added
- Direct Arrow <-> BEAM term codecs (
term_codec) eliminating JSON text and
hex-encoding round-trips on both reads and writes, and eliminating redundant
validation passes for BEAM-built batches.
- Single-shot
Query.all/1 fast path (query_all NIF) encoding results
directly into the reply's owned BEAM environment in one native round-trip,
and single-shot Table.add/3 fast path (ingest_add_batch) for single-batch
commit: :once and per-batch commit: :batch writes, plus skip unnecessary
ingest_abort after successful ingest_finish and increase streaming writer
channel capacity to 4.
- Columnar
LanceDB.Batch.to_columns/2 (with optional packed_vectors: true
emitting native-endian vector binaries), its companion
LanceDB.Batch.from_columns/2 (supporting per-row or flat contiguous
{:binary, bytes} vector columns such as 2D Nx tensors), and
{:binary, bytes} packed native-endian vector input across
Batch.from_rows/2, Batch.from_columns/2, explicit-schema row writes
(Connection.create_table/4, Table.add/3, Table.upsert/3, Table.merge/3,
and column backfills), and vector/batch/multivector/hybrid/Hamming queries.
- Paired throughput benchmark (
benchmarks/throughput.exs) documenting 10×–106×
batch codec speedups, 12.8× Query.all/1 (100 rows) speedup, and 7.8×
row-write speedup versus v0.5.1.
Changed
- Upgrade to LanceDB SDK 0.41.0 and Lance 14.0.2 (Arrow 58.4.0, Rustls 0.23.46)
and bump the Rust toolchain to 1.100.1. Remove the obsolete remote Cargo
feature workaround (upstream #4142 fixed) and the compat/ngram.rs SQL rewrite
workaround (fixed in Lance 14.0.2). Support 0.41.0's 4-field blob storage
layout alongside legacy 2-field tables.
- Simplify the internal native/backend NIF dispatch layer to direct static calls
(removing apply/3 indirection), retire the legacy Elixir record-staging
module, and use pre-interned static atoms in wire.rs.
Fixed
- Reject nulls on writes targeting Lance
"legacy" (0.1) storage format where
the v1 plain encoder would otherwise silently replace nulls with zero/false
values, preserving prior rows and table versions.
- Support non-Latin-1 UTF-8 atom keys across row, columnar, struct, Arrow map,
and JSON object inputs, including duplicate-key collision detection.
- Keep read admission permits and caller-death cancellation active through
Query.all/1 row conversion before releasing and delivering replies.
- Encode Arrow
Null output columns (such as select: [value: "NULL"]) as
nil, propagate packed_vectors: true into nested list and struct vector
columns, and quote nested field paths properly in singleton batch_search/3
projections.
Removed (Breaking)
- Remove upstream-experimental SQL computed columns and refresh jobs
(SchemaEvolution.add_computed_columns/2, Table.write_schema/1,
Table.refresh_column/2, Table.refresh_column_async/2,
LanceDB.RefreshResult), which LanceDB 0.41.0 moved behind its
experimental-functions feature.
- Remove bespoke non-SDK features to align strictly with LanceDB's core SDK:
LanceDB.TableCache, LanceDB.FTS.prepare/2-3 / LanceDB.FTS.Prepared,
custom Elixir hybrid reranker callbacks (LanceDB.Reranker, :reranker,
:normalize — native RRF via :rrf_k remains), and legacy capability-gating
test probes.
Migration from 0.5.1
TableCache: Retain a LanceDB.Connection (configured with
:index_cache_size_bytes and :metadata_cache_size_bytes) in your
application state, open tables with Connection.open_table/3, and warm
indexes explicitly with Index.prewarm/2.
FTS.prepare/2-3: Tokenize text with Tokenizer.tokenize/2-3 and compose
clauses with FTS.match/2 and FTS.boolean/1.
- Custom hybrid rerankers (
:reranker / :normalize): Use native RRF via
:rrf_k, or run Query.search/3 and Query.full_text_search/3 with
with_row_id: true and fuse results in Elixir.
- SQL computed columns: Use
SchemaEvolution.add_columns/2 or
SchemaEvolution.backfill_columns/3 for materialized derived columns and
Table.schema/1 for table schemas.
Source