from typing import Optional, List, Dict, Any


class SearcHit[T: Any]:
  id: str
  source: T
  score: Optional[float]


class SuggestOption:
  text: str
  score: Optional[float]


class SearchSuggest:
  text: str
  options: List[SuggestOption]


class SearchResponse[T: Any]:
  total: Optional[int]
  hits: Optional[List[SearcHit[T]]]

  suggest: Optional[Dict[str, List[SearchSuggest]]]
