@photostructure/sqlite-diskann
    Preparing search index...

    Interface NearestNeighborResult

    Result from a nearest neighbor search

    interface NearestNeighborResult {
        distance: number;
        rowid: number;
        [key: string]: unknown;
    }

    Indexable

    • [key: string]: unknown

      Metadata columns (if defined in index) Property names match column names from CREATE VIRTUAL TABLE

    Index

    Properties

    Properties

    distance: number

    Distance to query vector (lower is closer for cosine/euclidean) Interpretation depends on metric:

    • cosine: 0 = identical, 2 = opposite
    • euclidean: 0 = identical, higher = further
    • dot: higher = more similar (NOT a distance)
    rowid: number

    Row ID from the index (SQLite rowid)