Rag Request
data class RagRequest(val query: String, val similarityThreshold: <Error class: unknown class> = 0.8, val topK: Int = 8, val hyDE: HyDE? = null, val desiredMaxLatency: Duration = Duration.ofMillis(5000), val compressionConfig: CompressionConfig = CompressionConfig(), val contentElementSearch: ContentElementSearch = ContentElementSearch.CHUNKS_ONLY, val entitySearch: EntitySearch? = null, val timestamp: Instant = Instant.now()) : RagRequestRefinement<RagRequest>
RAG request. Contains a query and parameters for similarity search.
Parameters
query
the query string to search for
similarity Threshold
the minimum similarity score for results (default is 0.8)
top K
the maximum number of results to return (default is 8) If set, only the given entities will be searched for.
Constructors
Link copied to clipboard
constructor(query: String, similarityThreshold: <Error class: unknown class> = 0.8, topK: Int = 8, hyDE: HyDE? = null, desiredMaxLatency: Duration = Duration.ofMillis(5000), compressionConfig: CompressionConfig = CompressionConfig(), contentElementSearch: ContentElementSearch = ContentElementSearch.CHUNKS_ONLY, entitySearch: EntitySearch? = null, timestamp: Instant = Instant.now())
Properties
Functions
Link copied to clipboard
Create a RagRequest from this refinement and a query.
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
open override fun withSimilarityThreshold(similarityThreshold: <Error class: unknown class>): RagRequest
Link copied to clipboard