blob: 5459e4c285f203d1863767daca72ae2cf2be99b1 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
|
#pragma once
#include "search/v2/search_model.hpp"
#include "std/cstdint.hpp"
namespace search
{
namespace v2
{
struct PreRankingInfo
{
inline size_t GetNumTokens() const { return m_endToken - m_startToken; }
// An abstract distance from the feature to the pivot. Measurement
// units do not matter here.
double m_distanceToPivot = 0;
// Tokens [m_startToken, m_endToken) match to the feature name or
// house number.
size_t m_startToken = 0;
size_t m_endToken = 0;
// Rank of the feature.
uint8_t m_rank = 0;
// Search type for the feature.
SearchModel::SearchType m_searchType = SearchModel::SEARCH_TYPE_COUNT;
};
string DebugPrint(PreRankingInfo const & info);
} // namespace v2
} // namespace search
|