Table of Contents

Method InvalidateIndex

Namespace
LMKit.Retrieval.Bm25
Assembly
LM-Kit.NET.dll

InvalidateIndex()

Explicitly invalidates the cached BM25 index, forcing a rebuild on the next query.

public void InvalidateIndex()

Examples

var bm25 = new Bm25RetrievalStrategy();
ragEngine.RetrievalStrategy = bm25;

// After modifying partition content in place, force a re-index.
bm25.InvalidateIndex();

Remarks

The index is automatically rebuilt when the partition count changes. Call this method when partitions have been modified in place without changing the total count.

Share