Python

USearch for Python

pip install usearch 3.0.0-rc.1 · 4c3e5023

Every verb is a batch, and one vector is a one-row matrix, so a memory-mapped dataset reaches the index with no reshape and no copy. They expose dense indexes; the other modalities are declared and raise NotImplementedError until the library ships their engines.

  • usearch.DenseIndex searches equidimensional dense embeddings, and is the one instantiated today.
  • usearch.SequenceIndex searches variable-length sequences.
  • usearch.ShapesIndex searches 3D point clouds of any size.
  • usearch.GeospatialIndex searches space and time.

Topics

InstallationThe wheels carry every dense storage type.
Quickstart
Executors37An executor owns host threads or device streams; an index owns entries.
Keys3Keys are 128 bits wide and render as lowercase dashed UUIDs.
Inputs and Outputs20Every output whose length only the call knows, such as matches, rows, products, monoliths and cursor or stream batches, lands in a usearch.Arena you pass, and the verb answers a view over it without copying.
Metrics42
Residency1
Serialization9Loading creates a handle rather than filling one, its geometry read from the checkpoint's own headers, and a cancelled or failed load creates none.
Filtered SearchA predicate admits keys one at a time.
Refinement6refine re-selects the neighbors of every stored entry against the finished graph, improving edges that were chosen when the graph around them was still incomplete.
Linear Algebra9multiply, maxsim and attend read the walk as arithmetic rather than as retrieval.
Retrieval and Streaming21get for an absent key answers an empty, falsy DenseVectors.
Introspection20capacity, dimensions, connectivity and memoryusage are properties read through describe as well.
Errors19
Platform Notes