Skip to content

Docs: native find_nearest sends the query as one float32 buffer (#203) - #250

Merged
tae898 merged 1 commit into
mainfrom
docs/find-nearest-float32-query
Nov 5, 2026
Merged

tae898 merged 1 commit into
mainfrom
docs/find-nearest-float32-query

Conversation

@tae898

@tae898 tae898 commented Nov 4, 2026

Copy link
Copy Markdown
Collaborator

Closes #249

Documents what #203 changed: on the native package VectorIndex.find_nearest sends the query vector as one float32 buffer whatever its form (list, float64 array, float32 array).

  • how-to/vectors.adoc: a paragraph after the find_nearest signature sentence and a table of median latency, with the change over without it (95% interval). Measured on the native wheel 26.11.1.dev0 on one Linux x86_64 laptop, 11 to 12 clean pairs per figure, the wheel built before the change as the baseline. At 1536 dimensions a float32 array is 0.951 [0.945, 0.954], a float64 array 0.616 [0.614, 0.621] and a list of Python floats 0.631 [0.627, 0.635]; at 256 dimensions 0.952 [0.942, 0.96], 0.777 [0.774, 0.781] and 0.792 [0.787, 0.798]. The vectorNeighbors statement path did not change (1.003 [0.995, 1.014] and 1.004 [0.991, 1.006]). The figures were copied from the study's score file by script. The section also gets an explicit [[find-nearest]] anchor.
  • how-to/databases-and-queries.adoc: the "A query vector" section says it is about statements and links to the find_nearest section. The float32 advice for statements stays.
  • src/arcadedb/vector.py: the find_nearest query_vector Args line says the native build converts any of the forms to one float32 buffer. find_nearest_approximate is left alone because its native path does not use the buffer.
  • which-package.adoc: the native-versus-JVM query medians are kept and labelled as measured before Native find_nearest: send the query vector as one float32 array, not a Python list #203. They were not re-measured, so there are no new numbers there.

The sentence with the find_nearest signature is untouched, so the include_vector PR (#204) can rebase on this one. Checks run: compile and pyflakes on vector.py, pre-commit on the changed files, no pip install or em dash in the diff, and the new find-nearest anchor exists. Not run on this machine: the Antora docs build (the docs.yml check does that) and the test suite.

🤖 Generated with Claude Code

Describe the #203 behavior where users read about find_nearest: a paragraph and the A/B table in vectors.adoc (figures copied by script from the study's score file, p50 B/A with 95% intervals), a pointer from the statement-only "A query vector" section, and the query_vector Args text of find_nearest. The find_nearest_approximate Args stay as they are: its native path (_run_approximate) does not use the float32 buffer. The which-package vector-search medians predate #203, so they are labelled as measured before it instead of being replaced by numbers that were not re-measured. The sentence with the find_nearest signature is untouched so the include_vector change (#204) rebases cleanly.

Closes #249

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@tae898 tae898 added this to the 26.11.1 milestone Nov 5, 2026
@tae898 tae898 added documentation Improvements or additions to documentation native The arcadedb package (native library build) vector Vector indexes and find_nearest labels Nov 5, 2026
@tae898
tae898 merged commit 5d6e47c into main Nov 5, 2026
39 checks passed
@tae898
tae898 deleted the docs/find-nearest-float32-query branch November 5, 2026 02:31
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

documentation Improvements or additions to documentation native The arcadedb package (native library build) vector Vector indexes and find_nearest

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Docs: find_nearest pages still describe the list query path after #203

1 participant