lance-format / lance-format/lance

Redesign `index_statistics`

Open
#6,481 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

needs-info
Dominant language
Rust
Stars
7.1k
Forks
852
Avg merge
3d 18h
Merged PRs (30d)
272

Description

Right now, index_statistics is too heavy. It's return value is a JSON String, and may contain gigabytes of information. The IVF centroids are the worst known offender.

The two key problems are:

  • No type safety
  • Heavy memory use and resource use

We should redesign the API to improve it.

Might be something like:

struct IndexStatistics {
    general_stats: GeneralIndexStats,
    specific_stats: Box<dyn Any + Send + Sync>,
}

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by locating the existing index_statistics entry point and reviewing the proposed IndexStatistics shape in the issue. The work is complete when the API provides type safety and avoids returning excessively large statistics such as IVF centroids, with the resulting design documented and validated by the relevant project checks.

Written by the indexing model from the issue text.

Assessment

Tech stack
rust
Domain
backend-api-design, machine-learning
Issue type
Refactor
Difficulty
5/5
Estimated time
Over a week
Activity status
Quiet
Clarity
Needs clarification
Newbie friendliness
30/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.