Commit Graph
3727 Commits
Author SHA1 Message Date
Gatefixer 085b6f04e0 Merge main and align cosine patch with Lance beta.32 2026-11-24 12:47:34 +00:00
Lance Release 03b861f9a0 Bump version: 0.42.0-beta.28 → 0.42.0-beta.29 v0.42.0-beta.29 2026-11-24 11:46:34 +00:00
LanceDB RobotandBubbleCal c960c6f7ec chore: update lance dependency to v15.0.0-beta.32 (#5188)
Update the Rust workspace and Java lance-core to Lance v15.0.0-beta.32,
and pin the Python test extra to pylance 15.0.0b32. Refresh both
lockfiles for the [Lance
release](https://github.com/lance-format/lance/releases/tag/v15.0.0-beta.32).

The Java artifact finished publishing after the first CI attempt. On
commit `75d11726c`, the Java 11 and Java 17 runners each downloaded the
241 MB `lance-core-15.0.0-beta.32.jar` from the Lance Maven repository
and passed all 37 tests. [Java 11
build](https://github.com/lancedb/lancedb/actions/runs/45372396192/job/138372148863)
· [Java 17
build](https://github.com/lancedb/lancedb/actions/runs/45372396192/job/138372148496)

Co-authored-by: BubbleCal <bubble-cal@outlook.com>
2026-11-24 19:45:16 +08:00
Xuanwo c45a22e73a chore(java): align Log4j test dependencies to 2.25.5 (#5191)
Supersedes #5178 and #5184.

Update `log4j-api`, `log4j-core`, and `log4j-slf4j2-impl` in
`java/lancedb-core/pom.xml` together from `2.25.3` to `2.25.5` via a
module-local `log4j.version` property, avoiding the mixed Log4j versions
from the two partial updates proposed in #5178 and #5184.

All three dependencies remain in `test` scope. The Maven runtime
dependency tree for `lancedb-core` is unchanged, and a downstream
consumer does not inherit Log4j.

Validation:
- Maven `dependency:tree`: runtime tree unchanged; test tree aligned on
`2.25.5`; downstream consumer does not inherit Log4j
- Java 11 and Java 17 clean install: 37 tests passed on each
- Java 8 release-style package with tests skipped: compiled cleanly
2026-11-24 19:12:13 +08:00
Gatefixer b4b98669a6 Merge latest main documentation updates 2026-11-24 10:22:34 +00:00
Gatefixer 3849ab97f4 Merge main and align cosine patch with Lance beta.31 2026-11-24 10:22:21 +00:00
Xuanwo 0fb15fd178 docs: add Mastra integration guide (#5189)
## Summary

Supersedes #2330 and brings the Mastra integration guide onto the
current `docs/web` Mintlify documentation structure with verified
LanceDB Embedded examples against the published `@mastra/lance` release.

Credit to @vishesh-baghel for authoring the original LanceDB Mastra
guide in #2330 and building the merged upstream Mastra storage and
vector adapters in mastra-ai/mastra#3324.

### Changes

- Add `docs/web/integrations/ai/mastra.mdx` covering LanceDB Embedded
usage with `@mastra/lance`:
- Node.js 22.13.0+ requirement and `npm install @mastra/lance
@mastra/core`.
- Runnable local `LanceVectorStore` quickstart (`create`, `createIndex`,
`upsert`, `query`, `close`) with verified nearest-neighbor output
(`lancedb 1`).
- Explanation of the two-step native vector index behavior in
`@mastra/lance` (first `createIndex()` initializes an empty table;
calling `createIndex()` again after upserting at least 256 rows builds
the native index on the `vector` column).
- Pointer to `LanceStorage` noting the published three-argument
`LanceStorage.create(id, name, uri)` signature and linking upstream
Mastra references, without unverified cloud claims.
- Register `integrations/ai/mastra` under **AI Platforms & Frameworks**
in `docs/web/docs.json`.
- Add the TypeScript example snippets to
`docs/web-tests/ts/integrations.ts` and regenerate the corresponding
exports (`TsFrameworksMastraQuickstart`,
`TsFrameworksMastraNativeIndex`) in
`docs/web/snippets/integrations.mdx`.

## Verification

- Verified against published `@mastra/lance@1.6.1` and
`@mastra/core@1.85.0` (resolving `@lancedb/lancedb@0.31.0` and
`apache-arrow@18.1.0`):
  - Two-vector local quickstart returns `lancedb 1`.
- Native `IVF_FLAT` index build after upserting 256 rows reports
`vector_idx` with 256 indexed rows, 0 unindexed rows, and
nearest-neighbor score `1`.
- Confirmed `LanceStorage.create(id, name, uri)` succeeds with three
arguments while the older two-argument call fails.
2026-11-24 18:14:29 +08:00
Lance Release abe829f4a3 Bump version: 0.42.0-beta.27 → 0.42.0-beta.28 v0.42.0-beta.28 2026-11-24 09:20:21 +00:00
Yang Cen c568f150c9 perf(query): avoid opening vector indexes during cosine ANN planning (#5186)
Planning a cosine ANN query opens each distinct index segment to
determine its distance scale. Opening the index loads centroids and
quantizer data even though the planner only needs the physical index
type.

Use Lance's batch physical-type lookup for the segment UUIDs in each ANN
plan. The planner uses those types to select the existing distance
conversion. Query execution still searches the selected segments. The
lookup ships in [Lance
v15.0.0-beta.31](https://github.com/lance-format/lance/releases/tag/v15.0.0-beta.31).
This PR updates the Rust and Java dependencies and the Python test pin
to that release.

The regression test creates an IVF_RQ index, removes its auxiliary
quantizer file, reopens the table in a fresh session, and verifies that
a cosine ANN plan can still be built. Existing tests cover modern and
legacy PQ scores and ordering across mixed tiers.
2026-11-24 17:19:10 +08:00
Gatefixer 9df4326890 Merge main and align cosine patch with Lance beta.29 2026-11-24 08:18:46 +00:00
Lance Release f6bb017535 Bump version: 0.42.0-beta.26 → 0.42.0-beta.27 v0.42.0-beta.27 2026-11-24 07:13:40 +00:00
LanceDB RobotandXuanwo f800758117 chore: update lance dependency to v15.0.0-beta.29 (#5180)
Update the Rust and Java Lance dependencies to v15.0.0-beta.29 and pin
the Python test extra to pylance 15.0.0b29. The Python lockfile includes
all seven published wheels for the [Lance
release](https://github.com/lance-format/lance/releases/tag/v15.0.0-beta.29).

Co-authored-by: Xuanwo <github@xuanwo.io>
2026-11-24 15:11:43 +08:00
Jack Ye df1d3318df feat: add Azure storage account access key support to SDKs (#5177)
Add `azure_storage_account_access_key_secret` to the sync and async
Python storage integration APIs, with a matching Rust constructor. The
SDK sends a Secret reference in SQL and decodes the reference returned
by CREATE and DESCRIBE.

```python
info = db.create_storage_integration(
    "blobs", "az://customer-data/raw/",
    storage_provider="AZURE",
    azure_storage_account="customeraccount",
    azure_storage_account_access_key_secret="azure_key",
)
```

Azure requires a storage account and one authentication mode. The
account access key uses a single Secret. Service principal
authentication uses the existing three Secret references.
2026-11-23 22:49:41 -08:00
Xuanwo a6cca1efb0 feat(python)!: declare streaming Blob outputs for Functions (#5171)
BREAKING CHANGE: Rust callers constructing
`lancedb::function::FunctionOutput` with a struct literal now supply
`blob_writer_paths`. Use `Vec::new()` for an output without
writer-capable fields.

LanceDB Functions that generate large Blob v2 values can declare their
output with `BlobWriter` and write chunks during a computed column
refresh in a compatible LanceDB Enterprise environment. Row-wise and
vectorized callables use the same logical Blob schema. Named and nested
outputs can mark specific leaves with `BlobWriter.field` while retaining
ordinary binary siblings and nullable fields.

The SDK preserves writer requirements through native registration and
computed column binding. A distinct output kind lets earlier Enterprise
versions reject registrations that require a writer. Existing bytes-only
registrations retain their wire format and adapter.

On SDK commit
[`a19e7b87`](https://github.com/lancedb/lancedb/commit/a19e7b873c36aec865f092a368760be8846233ed),
a rebuilt extension preserved nested writer paths through Flight SQL
registration and version readback. Enterprise 1.14.1 rejected the writer
registration before building the Function image. With the compatible
runtime candidate, a real Flight SQL refresh published a 2 GiB + 137
byte value in each Blob layout against Moto. Independent reads verified
length and SHA-256 before and after cleanup of an older version. The run
also confirmed multipart abort and cumulative descriptor accounting.
[Runtime
evidence](https://linear.app/lancedb/issue/ENT-4209#comment-26e69e0e-faad-4aac-b148-3f4591181182)
· [Descriptor
accounting](https://linear.app/lancedb/issue/ENT-4209#comment-4d05e27a-8ff2-4003-804a-8af2f29ce2f4)

This SDK change is part of the coordinated Enterprise delivery.
[ENT-4209](https://linear.app/lancedb/issue/ENT-4209)
2026-11-24 13:53:06 +08:00
Xuanwo f183fe14c3 docs: explain storage reclamation after dropping columns (#5174)
Dropping a column can leave its data in files that the current table
still needs. The schema guide now explains how compaction and retention
determine when cleanup can reclaim those data files and their ordinary
Blob v2 sidecars.
2026-11-24 13:33:47 +08:00
Xuanwo ea7b3d0203 ci: set up Python 3.11 for NodeJS workspace lint (#5181)
The NodeJS lint job runs `cargo clippy --profile ci --all
--all-features` on Ubuntu 22.04, whose default `python3` is 3.10. The
workspace includes the PyO3 bindings, which now require Python 3.11 or
newer, so the build fails in `pyo3-ffi` before Clippy starts:

```
error: cannot set a minimum Python version 3.11 higher than the interpreter version 3.10
```

Select Python 3.11, the SDK's minimum supported interpreter, before Rust
compilation. Workspace, feature, and Node matrix coverage stay
unchanged. The Rust workflow already lints on Ubuntu 24.04 with Python
3.12, so it needs no matching change.

Validation: the workflow parses, and the Python setup step is ordered
before `Lint Rust`; the Node 22/24/26 matrix is unchanged. The hosted
NodeJS Lint run is linked from this PR's checks.
2026-11-24 13:31:36 +08:00
52209f10c3 chore!: drop Python 3.10 support (#5172)
Closes #5106.

Python 3.10 reached end of life on 2026-10-01. This raises the minimum
to 3.11, following #2955 for 3.9. It's marked `chore!:` because it's a
breaking change for 3.10 users.

- `python/pyproject.toml`: `requires-python = ">=3.11"`, and the 3.10
classifier is removed. The `pillow` lower bound in the `clip`, `siglip`
and `embeddings` extras goes up to `>=13.0.0`, the release with the CVE
fixes, which needs 3.11+. The `typing-extensions; python_version <
"3.11"` dev dependency is removed, since it no longer applies.
- `python/Cargo.toml`: pyo3 `abi3-py310` becomes `abi3-py311`, so wheels
are built as `cp311-abi3`.
- `python/lancedb/query.py`: `Self` comes from `typing`, without the
`typing_extensions` fallback.
- CI: the Linux test matrix goes from `["10", "13"]` to `["11", "13"]`,
and the minimum-dependencies job, the release build (`pypi-publish.yml`)
and the docs build move from 3.10 to 3.11.
- `python/uv.lock`: regenerated with `uv lock --extra-index-url
https://pypi.fury.io/lance-format/`. The only changes are the 3.10-only
resolutions going away: all 74 `python_full_version < '3.11'` markers,
`async-timeout`, `backports-asyncio-runner`, `exceptiongroup`, `tomli`,
and the older numpy, scipy, pandas, pyarrow and pillow pins. No package
version changes for 3.11+.

Checks run locally: `ruff check` and `ruff format --check` pass, and
`cargo metadata` succeeds for the workspace. I haven't run the Python
test suite, which needs the native build, so I'm relying on CI for that.

pylance still declares `>=3.10`. As the issue says, lancedb can move
first because pylance is optional.


![Evidence](https://raw.githubusercontent.com/rahulsjha/lancedb/pr-assets/lance5106-evidence.png)

---------

Co-authored-by: Will Jones <willjones127@gmail.com>
Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-23 17:30:18 -08:00
Brendan Clement fe2d2b33fc docs: restore setup in standalone Python examples (#4970)
Eight Python examples on the consistency, insert and merge-insert pages
are presented as complete programs, but the published snippets started
after the imports, temporary directory and connection, so they failed
with NameError when run on their own.

The snippet start markers had been moved below the setup in the test
files. This moves them back above it and regenerates the snippets.
2026-11-23 10:08:43 -08:00
Aiman MalibandClaude Opus 5.5 0f648bbad4 fix: allow BTree indexes on LargeUtf8 columns (#5089)
## What changed

`supported_btree_data_type` in `rust/lancedb/src/utils/mod.rs` now
accepts `LargeUtf8` next to `Utf8`. This is the only code change, one
line.

Python and TypeScript have no BTree type check of their own and call
into this function, so the fix covers all three SDKs. `Index::Auto` also
picks BTree for `LargeUtf8` columns now, locally and in the remote
client.

## Why

Fixes #5088

Lance builds BTree indexes on `LargeUtf8`, but this check in lancedb
rejected them with `A BTree index cannot be created on the field ...
which has data type LargeUtf8`. pandas 3 stores text columns as
`large_string`, so `create_index(col, config=BTree())` and
`create_scalar_index(col)` fail on tables created from a plain
DataFrame. #2297 removed a similar extra check for `FixedSizeBinary`.

`Binary`, `LargeBinary` and `Utf8View` may also be supported by Lance
but are left out of this PR.

## How it was tested

Run in a `rust:1.97.0-bookworm` container with `--profile ci --locked
--features remote`, on `main` at e29ec0e0. The branch is now rebased on
a6d7d02f, which only changes version numbers in
`Cargo.toml`/`Cargo.lock`; the commits are unchanged.

- New test
`table::create_index::tests::test_create_btree_index_on_large_utf8`
creates a BTree index (explicit and `Index::Auto`) on two `LargeUtf8`
columns, checks the index type, and checks that `=`, `>` and `IS NULL`
filters use `ScalarIndexQuery` and return the right row counts.
- On `main` without the fix, the new test fails with `A BTree index
cannot be created on the field ... which has data type LargeUtf8`. The
existing `test_create_zonemap_index_on_wider_scalar_types` and
`test_create_scalar_index` pass.
- With the fix: the new test passes in 5 consecutive runs, and
`create_index::`, `utils::` and `remote::table::` tests pass (559
passed).
- With the one-line fix reverted, the new test fails again and the
zonemap control passes.
- `cargo fmt --all -- --check` and `cargo clippy --features remote -p
lancedb --tests --examples -- -D warnings`: clean.
- Python and TypeScript code is unchanged, so `ruff` and `pnpm` were not
run.

Written with help from Claude Code.

---------

Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-23 08:55:46 -08:00
Lucia CerchieandLucia Cerchie e9319c86bf fix: resolve agent plugin marketplace source (UAX-250) (#5170)
Looks like we have an issue with the plugin config pointing to a
non-existent dir.

Part of UAX-250. Related to UAX-245.

Clicktest, can ask Chat for example to create a fresh disposable config.

<img width="584" height="452" alt="Screenshot 2026-11-23 at 9 38 25 AM"
src="https://github.com/user-attachments/assets/d359f9e2-bd3f-4cb8-993a-7db3b2b20342"
/>

Clicktesting: Use a disposable Claude configuration. Add this checkout
as a marketplace, then install `lancedb@lancedb`. Confirm that
installation fetches `lancedb/lancedb-agent-plugins` and exposes its
skill.

*original prompt:*

"Work on Linear issue UAX-250:\
\
Suggested branch name:
luciacerchie/uax-250-add-enterprise-functions-guidance-to\
\
\<issue identifier="UAX-250">\
\<title>Add Enterprise Functions guidance to the lancedb agent
skill\</title>\
\<description>\
The public \`lancedb\` agent skill (\`lancedb/lancedb-agent-plugins\`,
v0.1.0) has no guidance on LanceDB Enterprise Functions. It also routes
"UDF / backfill" tasks to the Geneva/Ray path, which Functions is meant
to replace. Agents using the skill steer users away from our newest
product.\
\
\## Problem\
\
\* Nothing on \`@function\`, \`create_function\`, computed columns,
\`refresh_column_async\`, secrets, GPU classes, chunkers, or function
failure handling.\
\* The skill description does not trigger on Functions tasks.\
\* Function refresh jobs are not covered. \`remote_jobs.md\` only
describes \`geneva_jobs\`.\
\* \`lancedb/lancedb\` \`.claude-plugin/marketplace.json\` points to
\`./plugins/lancedb\`, which does not exist on main. Only
\`lancedb-agent-plugins\` installs.\
\
\## Proposed fix\
\
A patch is ready (new \`references/functions.md\`, \`SKILL.md\` routing
and description, \`remote_jobs.md\` note). Open a PR against
\`lancedb-agent-plugins\` and fix the marketplace path in
\`lancedb/lancedb\`.\
\
\## Acceptance\
\
\* A Functions prompt (register a function, bind a column, refresh,
retry failed rows) loads \`functions.md\` before Geneva.\
\* Add Functions prompts to the agent eval suite (see \<issue
id="08c7081c-2add-4ae6-b165-c9df1e23f1a5" label="UAX-245"
href="https\://linear.app/lancedb/issue/UAX-245/automated-docs-loop-to-update-skills"
/> for the docs-to-skills loop).\
\* Re-check the reference against each Enterprise release, since
Functions is early access.\
\
\## Related product gaps (for triage, not part of this issue)\
\
Many-to-many transforms (dedup, clustering), multi-GPU per worker,
refresh triggered on writes, per-row function version provenance,
SQL/Python option parity, TypeScript and Rust authoring.\
\
\>>> Agent notes\
\
Source: Enterprise 1.14.0 docs (function-authoring, function-operations,
function-failures, function-secrets, management/function,
create-function, refresh-column, auto-refresh, incremental-refresh,
chunking, sql/ddl/function). Needs the 0.42 preview client; stable 0.41
lacks these APIs. Local clone has the staged patch; no push access to
\`lancedb-agent-plugins\` from the session.\
\
\>>>\
\</description>\
\<team name="UX/AX Engineering"/>\
\<label>LanceDB Functions › UI/UX\</label>\
\<project name="Functions: Next">Functions roadmap and follow-up work
deferred from M3. Includes training integrations, application toolkits
and Ray interoperability requests; these are outside the M3 bug-bash
scope.\</project>\
\<issue-relations>\<related>\<issue-ref identifier="UAX-245"
title="Automated docs loop to update
skills"/>\</related>\</issue-relations>\
\</issue>"

Co-authored-by: Lucia Cerchie <cerchie@Lucias-MacBook-Pro.local>
2026-11-23 09:41:38 -07:00
Lance Release de81c35ba0 Bump version: 0.42.0-beta.25 → 0.42.0-beta.26 v0.42.0-beta.26 2026-11-23 06:14:22 +00:00
wangshun a0e65400a9 fix(java): keep Maven coordinates in sync with release tags (#5151)
Fixes #4937

## Summary

The `v0.42.0-beta.21` release commit retained `0.42.0-beta.20` in both
Java POMs, so its Maven build produced coordinates for the previous
beta. The release bump used a Maven version hook whose final shell
commands could return success after Maven failed, allowing the tag to be
created with stale coordinates. [Issue
#4937](https://github.com/lancedb/lancedb/issues/4937)

Declare both Maven version fields in the shared version-bump
configuration and align the checked-in POMs with the current release
version. Preview and stable release bumps now apply the same version to
the parent POM and the core module's parent reference before tagging.
Package names, dependencies, and publication destinations are preserved.

## Verification

Tests: `/bin/sh -c 'PATH=/tmp/osscout-release-venv/bin:$PATH bash
ci/tests/test_bump_version.sh'`.
Result: PATH=/tmp/osscout-release-venv/bin:$PATH bash
ci/tests/test_bump_version.sh — base exit 1 with the tag/POM mismatch,
patched exit 0 with both preview and stable cases passing.
Result: python -m unittest discover -s ci/tests -v — base, 35 passed.
Result: /tmp/osscout-release-venv/bin/python -m unittest discover -s
ci/tests -v — patched, 35 passed.
Result: bash ci/tests/test_cli_installer.sh — passed.
Result: cd java && ./mvnw --batch-mode test -pl lancedb-core — base, 37
passed on JDK 25.
Result: cd java && JAVA_HOME=/usr/lib/jvm/temurin-17-jdk-amd64 ./mvnw
--batch-mode -Dspotless.skip=true clean test -pl lancedb-core — patched,
37 passed. Surefire XML reports are in
java/lancedb-core/target/surefire-reports/.
Result: osscout_base_work=$(mktemp -d) && git archive HEAD java | tar
-xf - -C "$osscout_base_work" && cd "$osscout_base_work/java" &&
JAVA_HOME=/tmp/osscout-jdk8 ./mvnw --batch-mode -DskipTests
-Dspotless.skip=true clean deploy -pl lancedb-core -am -P deploy-to-fury
-DaltDeploymentRepository=fury::file:///tmp/osscout-fury-base — base
build succeeded and emitted stale 0.42.0-beta.20 artifacts for the
0.42.0-beta.21 release sources.
Result: cd java && JAVA_HOME=/tmp/osscout-jdk8 ./mvnw --batch-mode
-DskipTests -Dspotless.skip=true clean deploy -pl lancedb-core -am -P
deploy-to-fury
-DaltDeploymentRepository=fury::file:///tmp/osscout-fury-deploy —
patched build succeeded and emitted both 0.42.0-beta.21 POMs and the
main, sources and Javadoc JARs.
Regression coverage: `ci/tests/test_bump_version.sh`.
<!-- oss-scout-job:job-d5fa2e08-6a6f-46ca-821c-d3a65d054055 -->

Signed-off-by: wangshun <96341168+xixi-box@users.noreply.github.com>
2026-11-23 14:12:57 +08:00
Gatefixer 48588758bd Merge main into gatekeeper/fix-4911-1 2026-11-23 03:37:08 +00:00
Lance Release b5ec7d6af4 Bump version: 0.42.0-beta.24 → 0.42.0-beta.25 v0.42.0-beta.25 2026-11-23 02:50:01 +00:00
LanceDB Robot e3a55690e8 chore: update lance dependency to v15.0.0-beta.28 (#5163)
Updates the Rust workspace and Java dependencies to [Lance
v15.0.0-beta.28](https://github.com/lance-format/lance/releases/tag/v15.0.0-beta.28).
Pins the Python test extra to pylance 15.0.0b28 and refreshes its
lockfile.
2026-11-23 10:47:17 +08:00
Xuanwo 7c7765c91a fix(rust): validate batch vector column before planning (#5162)
Batch vector queries resolved an explicit vector column with an
infallible schema lookup before the existing vector-column validation
ran. A column that could not be resolved would abort planning instead of
returning the SDK's normal validation error.

Use the resolved column with `get_vector_type` so the batch path reports
the same typed error as ordinary vector queries, while keeping explicit
and inferred columns, multivector and binary routing, namespace
pushdown, and query-plan selection unchanged.

Adds a focused synthetic-schema validation test for the error path.
2026-11-23 08:56:49 +08:00
Lance Release f38d42e9db Bump version: 0.42.0-beta.23 → 0.42.0-beta.24 v0.42.0-beta.24 2026-11-22 21:22:21 +00:00
Xuanwo 59615eafac fix: reject blob request concurrency above semaphore limit (#5160)
## Summary

A `blob_request_concurrency` value above tokio's
`Semaphore::MAX_PERMITS` reached `Semaphore::new` and panicked, aborting
the process instead of reporting a configuration error. The value can
come from explicit client configuration or
`LANCE_CLIENT_BLOB_REQUEST_CONCURRENCY`, with a default of 8.

Resolve the value with the existing precedence, preserve the existing
zero and parse errors, and return `Error::InvalidInput` for values above
`Semaphore::MAX_PERMITS`. The supported range is documented on
`ClientConfig::blob_request_concurrency`.

## Tests

Added a focused resolver test covering the maximum accepted value and
one above it. The test passes an explicit value and does not mutate
environment variables.
2026-11-23 05:20:25 +08:00
Gatefixer a7929d0afb Merge main and align cosine fix with Lance beta.27 2026-11-22 19:30:05 +00:00
Lance Release b654cd42ae Bump version: 0.42.0-beta.22 → 0.42.0-beta.23 v0.42.0-beta.23 2026-11-22 18:55:29 +00:00
LanceDB Robot b37de4edfe chore: update lance dependency to v15.0.0-beta.27 (#5159)
Update the Rust workspace Lance crates and Java `lance-core` to
`15.0.0-beta.27` and pin the Python test extra to `pylance==15.0.0b27`.
The Python lockfile includes the published wheels for the new version.

[Lance v15.0.0-beta.27
release](https://github.com/lance-format/lance/releases/tag/v15.0.0-beta.27)
2026-11-23 02:53:53 +08:00
Gatefixer f9e937234a Merge main and align cosine fix with Lance beta.26 2026-11-22 15:15:33 +00:00
Lance Release 21f074cb02 Bump version: 0.42.0-beta.21 → 0.42.0-beta.22 v0.42.0-beta.22 2026-11-22 14:27:15 +00:00
LanceDB RobotandXuanwo a09cd6fb8c chore: update lance dependency to v15.0.0-beta.26 (#5157)
Update the Rust, Java, and Python dependencies to [Lance
v15.0.0-beta.26](https://github.com/lance-format/lance/releases/tag/v15.0.0-beta.26).
Align the transitive Jieba macro version with Lance’s lockfile and fix
the Clippy diagnostics exposed by workspace validation.

Co-authored-by: Xuanwo <github@xuanwo.io>
2026-11-22 22:25:33 +08:00
Xuanwo b63cec40b4 fix(deps): update url to 2.5.9 for RUSTSEC-2026-0592 (#5158)
Updates the lockfile from `url` 2.5.8 to 2.5.9, the first release
patched for RUSTSEC-2026-0592, and from `form_urlencoded` 1.2.2 to
1.2.3, which `url` 2.5.9 requires (`^1.2.3`).

`main` also locks `url` 2.5.8. The advisory is the cargo-deny failure
currently blocking #5157, whose Lance beta.26 bump leaves the same
lockfile entry in place.

No dependency requirement or advisory ignore changes: `url = "2"`
already permits 2.5.9. `url` 2.5.9 declares MSRV 1.63 and
`form_urlencoded` 1.2.3 declares 1.51, both below the workspace's
1.95.0.

Validation:
- `cargo metadata --locked`
- `cargo tree -i url@2.5.9 --locked`
- `git diff --check`
2026-11-22 20:33:57 +08:00
Yang Cen d9b49e8889 feat: report capacity waits in function refresh job status (#5154)
An Enterprise Function refresh can spend time waiting for execution
workers. Applications polling `job.status()` currently see `running`
during that wait. Return `waiting_for_capacity` when the server reports
that phase for an active Function refresh. The next status request
reports `running` when execution resumes. Applications can use
`job.wait()` to wait through both states until completion.

Rust, Python and Node read the phase from the existing job description
response.

## Validation

Two HTTP regression tests exercise the public job handle. They cover the
wait, work resuming, completion after another wait, a stale phase at
completion, queued and paused refreshes, other job types, and servers
that omit the phase. The Rust CI remote job runs these tests.
2026-11-22 16:00:50 +08:00
Yang Cen 08ddcdb7d7 feat: resume a failed Function refresh from its table (#5153)
LanceDB Enterprise users can resume a failed Function refresh from its
table with `table.resume_refresh(job_id)`. The synchronous and
asynchronous Python APIs return a typed job handle. Waiting on that
handle uses the same table freshness tracking as a newly submitted
refresh.

The request carries the current table identifier and branch to the
server. The server decides whether the original attempt can be resumed
and supplies the reason when it cannot. The Python refresh methods also
accept a positive `max_job_attempts` option for automatic recovery.
These features require server support for Function refresh recovery.

The PR adds remote request, branch, error propagation, and typed result
tests. Python and Rust validation runs in PR CI.
2026-11-22 15:40:22 +08:00
Jack Ye 2b1b2a29dd feat!: layer GPU settings and total execution limits (#5146)
BREAKING CHANGE: Resource inputs use the same names at Function
registration, column/MV creation, and refresh. Use total_cpu_millis,
total_memory_bytes, and total_gpu_count for execution-wide worker
budgets, plus gpu_class and positive gpu_count for each worker. Replace
budget dictionary inputs and unprefixed aggregate limits with these
fields. Move existing refresh gpu_count caps to total_gpu_count;
gpu_count now selects devices per worker.

Each setting resolves independently: refresh > column/MV creation >
Function annotation > deployment. Creation settings also apply to
initial MV population and automatic refresh. MVs sum total budgets
across distinct pinned Function versions; per-worker GPU counts use the
largest Function default unless overridden. An unset GPU class resolves
to gpu_class="any" after inheritance; an explicit "any" overrides a
registered concrete class. Use gpu_class="default" to pin the default
pool explicitly.

```python
@function(
    gpu=True, gpu_class="h100", gpu_count=2,
    total_cpu_millis=8000,
    total_memory_bytes=16 * 1024**3,
    total_gpu_count=4,
)
def embed(text: str) -> list[float]: ...

version = db.create_function(embed)
table.add_columns(
    {"embedding": version(text=col("text"))},
    gpu_class="any", gpu_count=1, total_gpu_count=8,
)
table.refresh_column_async(
    "embedding", gpu_class="h100", gpu_count=4, total_gpu_count=8,
)

mv = db.create_materialized_view(
    "embeddings", query="SELECT embed(text) AS embedding FROM documents",
    gpu_class="any", gpu_count=2, total_gpu_count=8,
)
mv.refresh(gpu_count=4, total_gpu_count=8)
```

```mermaid
flowchart TD
    R["Refresh settings"] --> E["Effective settings, resolved per field"]
    D["Column or MV creation settings"] --> E
    F["Function settings"] --> E
    C["Deployment defaults"] --> E
    E --> W["GPU class and device count per worker"]
    E --> T["Total CPU, memory and GPU ceilings"]
```

Pinned Function images retain their identity. Registration GPU counts
are defaults; execution overrides determine worker allocation. Admission
rejects GPU counts below an image's minimum requirement or above the
total budget. Python, Rust, SQL/REST and supported TypeScript operations
use the same resource model.

No local builds or tests, as requested; regression coverage runs in CI.
2026-11-21 15:04:34 -08:00
Jack Ye e3e55844bc fix: add SQL query timeout and cancellation controls
Add per-query SQL deadlines, read timeouts, and drop cancellation controls for Rust and Python.
2026-11-21 14:35:04 -08:00
Bruno Ramirez 7970d3075c docs: install the public CLI from the hosted script (#5139)
Installing the CLI from the guide previously required a repository
checkout or a manual download. The installer is available directly from
the downloads site. This updates the guide and quickstart for the
v0.42.0 stable release.
2026-11-21 13:52:49 -08:00
Xuanwo 564f8f93d4 test(python): cover embedded plans over enterprise bases (#5150)
## Summary

Clarify in the persistence guide and `persist` docstring that only the
plan destination must be Embedded. The base table can be Embedded or
Enterprise; an Enterprise base is pinned through the plan's recorded
base branch/version.

Add a focused loopback regression that persists a plan from a mock
remote base into an Embedded database, reopens the plan by destination
with `db.open_table`, advances the mock base's latest version to v2, and
verifies a fresh remote handle observes v2 while `Permutation` still
reads the plan's recorded main/v1 coordinates. Sequential iteration and
duplicate/unsorted offsets follow the stored plan order, and the mock
records nonempty v1 scan/gather requests.

## Verification

- Focused test plus affected remote mock tests: 3 passed.
- `ruff format --check` and `ruff check` passed.
- `git diff --check` passed.

This is a docs/test-only follow-up. It does not add Enterprise-resident
plan persistence or change plan ordering.
2026-11-21 17:09:53 +08:00
Lance Release b35cce60d6 Bump version: 0.42.0-beta.20 → 0.42.0-beta.21 v0.42.0-beta.21 2026-11-21 08:53:41 +00:00
Jack Ye 0511aed6e9 feat: profile Enterprise Function workers from official clients 2026-11-21 00:51:08 -08:00
Jack Ye 49dedd4329 fix: expose Function metadata in SDK job listings (#5096)
Expose affected columns, pinned Function name/version, completion time,
duration and failure summaries on `JobInfo` in the Rust, Python and
TypeScript SDKs. Values come from the listing response, so callers can
inspect recent computed column refreshes without opening every job.
Older servers keep optional values absent; measured zero durations stay
zero.

```python
latest = next((info for info in db.list_jobs(table="events", job_type="function_refresh") if "embedding" in info.columns), None)
if latest is not None:
    print(latest.function_name, latest.function_version, latest.duration_millis)
    if latest.failure is not None:
        print(latest.failure.message)
```

Duration is creation-to-completion wall time, including queueing and
pauses. Adds listing response coverage across SDKs and documents the
metadata contract, including SQL `SHOW JOBS EXTENDED` for the expanded
listing. Plain `SHOW JOBS` preserves its original columns. Local builds
and tests were skipped as requested.

The dependency advisory check also fails on current main because
`libsais-rs 0.2.0` is yanked ([main
job](https://github.com/lancedb/lancedb/actions/runs/44470513618/job/135378545456));
this PR does not change dependencies.

This changes the public shape of Rust and TypeScript `JobInfo`: callers
constructing summaries must supply the added fields (including
TypeScript `columns`). TypeScript table filtering remains a separate
concern; the guide now shows its client-side selection and namespace
limitation alongside Python and Rust server-side filters.

Refs ENT-3903.
2026-11-21 00:18:29 -08:00
Xuanwo 6a7a2c4ec0 feat(nodejs): add table delta streams (#5149)
Adds the Embedded `Table.delta` API to the Node.js bindings, matching
the Rust/Python contract from #5135. `Table.delta(fromVersion,
toVersion?)` accepts a positive safe-integer number, a positive lossless
u64 `bigint`, or a same-branch tag string. `TableDelta` exposes
`beginVersion`/`endVersion` as `bigint`, streaming `insertedRows()`,
`updatedRows()`, `upsertedRows()`, `deletedRowIds()`, and
`listTransactions()` with `readVersion` as `bigint`.

Readers reuse the existing native Arrow IPC iterator adapter. They are
lazy, single-use, serialize pulls, capture/cache the schema before
polling, and release the native stream on completion, break, or error.
Row readers retain the Rust contract: equal endpoints return empty
streams with schemas, invalid/reversed/missing endpoints and
cross-branch tags are rejected, and Restore or incomplete transaction
history fail closed with full-rescan and range-end checkpoint guidance.
Enterprise tables remain unsupported through the native Rust default.

The abstract `Table` keeps a concrete unsupported `delta` default for
custom subclasses; `LocalTable` overrides it. TypeDoc API docs and
focused Node tests cover pinned targets, typed bigint values,
transaction listing, lazy rejected readers, schema/decode failures,
aliasing, and early drop.

Refs OSS-2860
2026-11-21 15:43:16 +08:00
Jack Ye b44807e4db fix!: preserve job attempt lineage, retries, and lifecycle states
BREAKING CHANGE: JobDescription, JobEventsRequest, FunctionErrorsRequest, and FunctionErrors gain optional Rust metadata/cursor fields. Existing struct literals must initialize them; use None when unavailable.

Preserve typed attempt state, pinned retry lineage, result decoders and freshness fences, and retained diagnostic paging across SDKs. Keep Python job data access method-only.
2026-11-20 20:35:59 -08:00
Jack Ye bfb55c72e9 feat(python)!: make job data access method-only (#5095)
Make all Python `Job` and `AsyncJob` data access method-only. Cached
property accessors are private and underscore-prefixed; public reads use
`id()`, `state()`, `job_type()`, `creation_ms()`, `spec()`, `result()`
and `failure()`. `checkout_latest()` refreshes the complete cached
registry record in place and returns `None`.

```python
job.checkout_latest()
print(job.state(), job.result(), job.failure())
print(job.id(), job.job_type(), job.creation_ms(), job.spec())
```

Cached read methods are synchronous on both handle types. Async handles
use `await job.checkout_latest()` for the live refresh; event history
remains a separate request through `events()`. Update Python SDK
callers, tests and guides to use method calls, including
progress/timeout handling and bounded repr. Cover method-only visibility
and holistic snapshot freshness through both sync and async clients.

BREAKING CHANGE: Python job data access now requires method calls, such
as `job.state()` instead of `job.state`. No property compatibility
aliases remain.

Fixes
https://linear.app/lancedb/issue/ENT-3902/sdk-make-cached-versus-live-job-accessors-unambiguous
2026-11-20 17:37:12 -08:00
Brendan Clement 8b814731c3 docs: use function instead of deprecated udf in examples (#5027)
`lancedb.udf` is a deprecated alias of `lancedb.function` and emits a
`DeprecationWarning`. This switches the quickstart and the curation
examples to `function`, so readers who copy them no longer see the
warning. The quickstart snippet is regenerated from its test.
2026-11-20 16:11:29 -08:00
Xuanwo 61cabf1ccb feat(nodejs): add tag-based branch creation and default tag versions (#5145)
Node.js did not provide parity with the Python tag fixes in #5136.
`tags.create()` required an explicit version, and `branches.create()`
could not fork from a tag without resolving a numeric version that loses
the tag's branch identity.

This adds Node.js parity:

- `tags.create(tag, version?)` defaults an omitted version to the
version visible to the table handle, including checked-out and
time-travel handles. Explicit versions are unchanged.
- `branches.create(name, { fromTag })` forks through `Ref::Tag`,
preserving the tag's branch and version. Existing `create(name,
fromRef?, fromVersion?)` calls are unchanged. Mixing `fromTag` with
another source is rejected before `main` normalization.
- A missing Embedded branch keeps its original error and now includes
the actual `branches.create(..., { fromTag: ... })` call as guidance.
Enterprise 404s keep their original error without guessing from the
message.
- Enterprise uses the existing tag resolution and branch-create wire
contract; no wire changes.

The released web guide remains on the published package examples. The
new API is documented in the TypeScript API reference and source, with
Node regression coverage.
2026-11-21 06:53:10 +08:00
Xuanwo 8dc03bd288 feat: add table.delta for version-to-version row changes (#5135)
Adds native `Table::delta(from_version, to_version=None)` and Python
sync/async `table.delta(...)` for version-to-version row changes.
`TableDelta` exposes streaming `inserted_rows()`, `updated_rows()`,
`upserted_rows()`, `deleted_row_ids()`, and `list_transactions()`.

Endpoints are resolved once on independent dataset handles.
`to_version=None` uses the table handle's visible snapshot, and the
handle's checkout is not changed. Only versions `>= 1` and tags on the
current branch are accepted; cross-branch tags, reversed ranges, version
0, and missing endpoints are rejected. Equal valid endpoints return
empty readers with the same schemas.

Row-level readers require stable row ids at both endpoints and report
the `storage_options={"new_table_enable_stable_row_ids": "true"}`
creation guidance when they are absent. `list_transactions()` does not
require stable row ids.

Row-level readers also fail closed when the range contains a `Restore`,
or when transaction history cannot prove the range is restore-free,
because restored rows can retain older row-version metadata that the
delta readers omit. The error directs consumers to a full rescan and
reinitializing the checkpoint at the range end version.
`list_transactions()` remains available for readable history. The
Versioning guide includes Python and Rust checkpoint-delta examples with
stable-row-ID setup and this Embedded limitation.

Embedded `branches.diff()` remains a separate API.

Refs OSS-2860
2026-11-21 06:41:38 +08:00