feat(rag): chunk evidence identity, dedup, and search port
Preserve same-document multi-chunk evidence with evidenceKey identity, per-document caps, retrieve-k/return-n split, and a dense KnowledgeSearchPort. Archives Delivery 1 OpenSpec change as the foundation for hybrid retrieval.
This commit is contained in:
@@ -0,0 +1,24 @@
|
||||
package com.superbiz.agent.service.retrieval;
|
||||
|
||||
import java.util.Map;
|
||||
|
||||
/**
|
||||
* Normalized search hit returned by {@link KnowledgeSearchPort}.
|
||||
*/
|
||||
public record KnowledgeSearchHit(
|
||||
String id,
|
||||
String content,
|
||||
Double score,
|
||||
Double rawScore,
|
||||
String scoreLabel,
|
||||
String metadataJson,
|
||||
Map<String, String> metadata,
|
||||
String docId,
|
||||
Integer chunkIndex,
|
||||
String evidenceKey,
|
||||
String source,
|
||||
String title,
|
||||
String breadcrumb,
|
||||
int originalRank
|
||||
) {
|
||||
}
|
||||
Reference in New Issue
Block a user