Table of Contents

Property RrfK

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

RrfK

Gets or sets the RRF smoothing constant that controls the influence of rank position in the fusion score.

public int RrfK { get; set; }

Property Value

int

A positive integer. Default is 60.

Examples

var hybrid = new HybridRetrievalStrategy
{
    // Lower RrfK amplifies the advantage of top-ranked results.
    RrfK = 30
};

ragEngine.RetrievalStrategy = hybrid;

Remarks

Higher values reduce the difference between high-ranked and low-ranked results, favoring documents that appear in both sub-strategy lists over documents that rank very high in only one list. Lower values amplify the advantage of top-ranked results. The standard value of 60 works well for most use cases.

Exceptions

ArgumentOutOfRangeException

Thrown if set to a value less than 1.

Share