Skip to main content
Version: 0.0.7 (stable)

agrag.common.data_models.evidence.EvidenceSearchResult

Bases: BaseModel

The result of one search call.

Attributes:

  • status (EvidenceSearchStatus) – The overall outcome. A failed leg never shows as NO_MATCH.
  • hits (list[EvidenceSearchHit]) – The visible passages, best first. Empty unless status is OK or PARTIAL.
  • truncated (bool) – True when the search reached its candidate ceiling before it found limit visible passages, so more passages may exist.
  • index_state (IndexState | None) – Whether the needed indexes were ready. None when no index was checked, which happens for an empty scope.
  • failures (list[LegFailure]) – Failed legs, and a failed rerank stage. A failed rerank does not change the status.
  • reranked (bool) – True when a reranker reordered the hits. Each hit's score is then the cross-encoder score, whose scale differs from the fused score.

failures​

failures: list[LegFailure] = Field(default_factory=list)

hits​

hits: list[EvidenceSearchHit] = Field(default_factory=list)

index_state​

index_state: IndexState | None = None

reranked​

reranked: bool = False

status​

status: EvidenceSearchStatus

truncated​

truncated: bool = False