A feature set is a named collection of features that a search engine uses to represent documents and queries for learning-to-rank (LTR). Keeping training features consistent with production execution helps the trained model receive the signals it expects. section 10.3.1
Features can encode text relevance or document values. A practical set might score query matches in title and overview fields with BM25, then expose release_year as a numeric signal that can favor newer movies. section 10.3.1
Movie-search feature set
A Python configuration creates title_bm25, overview_bm25, and release_year, then uploads the collection to a movie model. The first two features use the query keywords against separate fields; the third reads a field value.
Feature selection changes what relevance the model can learn. Fuzzy name matching, bigram matching, and description matching can improve text relevance, while explicit promotion features can expose blind spots in training data and support exploration. section 12.2.1 section 12.3.1
Listing 10.4 Creating three features for LTR
feature_set = [
ltr.generate_query_feature(feature_name="title_bm25",
field_name="title"),
ltr.generate_query_feature(feature_name="overview_bm25",
field_name="overview"),
ltr.generate_field_value_feature(feature_name="release_year",
field_name="release_year")]
ltr.upload_features(features=feature_set, model_name="movie_model")
display(feature_set)
Inspect the complete feature-generation and upload example for a concrete LTR feature set. section 10.3.1
