apache / apache/lucene

Specialize arc store for continuous label in FST

Open
#12,701 2 comments 0 reactions 0 assignees View on GitHub
type:enhancement
Dominant language
Java
Stars
3.6k
Forks
1.4k
Avg merge
2d 11h
Merged PRs (30d)
88

Description

### Description

Today we pos arcs with three strategies:

* **Direct addressing**: pos arc with bit count
* **Binary search**: pos arc with binary search
* **Linear search**: pos arc with linear search

I wonder if we can specialize the dealing the continuous label (`max_label - min_label + 1 == arc_count`) so we can pos the arc directly with `label_to_pos - min_label` ? This may be a common case for increment numeric ids or so.

Contributor guide

Open the contributing guide

Research direction

Start by locating the FST arc-storage implementation and the existing direct-addressing, binary-search, and linear-search strategies described in the issue. Compare how continuous labels are detected and positioned, then validate the specialized path against the existing behavior and relevant FST tests or benchmarks.

Written by the indexing model from the issue text.

Assessment

Tech stack
java
Domain
search
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
38/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.