Reference · Glossary
Glossary
Canonical definitions for this course. When a term is defined here, lessons use it exactly this way.
Living documentGrows with each lesson
- query context
- Evaluation mode that asks “how well does this document match?” and produces a relevance
_score. Clauses in must and should run here.
— intro'd in lesson 0001
- filter context
- Evaluation mode that asks “does this document match, yes or no?” — no score is computed. Cacheable. Clauses in
filter and must_not run here.
— intro'd in lesson 0001
- _score
- A non-negative float ranking how well a document matched the query. Higher = more relevant. Only produced in query context; default scoring is BM25.
— intro'd in lesson 0001
- bool query
- The primary compound query. Combines clauses under four keys:
must, should, filter, must_not.
— intro'd in lesson 0001
- minimum_should_match
- How many
should clauses a document must satisfy. Defaults to 1 when the bool has no must/filter, and to 0 when it does.
— intro'd in lesson 0001
- node query cache (filter cache)
- A per-node LRU cache holding bitsets of which documents match reused filter-context clauses. Why filters are cheap on repeat queries.
— intro'd in lesson 0001
- constant_score
- A query that wraps a filter and assigns every matching document the same fixed score (default 1.0), skipping relevance computation entirely.
— intro'd in lesson 0001
- BM25
- Best Match 25 — the default similarity (since ES 5.0), replacing classic TF/IDF. Scores each query term as
IDF · [saturated TF, length-normalized], summed over terms.
— intro'd in lesson 0001, derived in 0002
- IDF (inverse document frequency)
- Weights a term by rarity:
ln(1 + (N − n + 0.5)/(n + 0.5)), where N = total docs and n = docs containing the term. Rarer term → higher weight.
— intro'd in lesson 0002
- TF saturation
- BM25's property that repeated occurrences of a term add ever less to the score, approaching a ceiling of
IDF · (k1+1). The fix for raw TF/IDF's unbounded growth.
— intro'd in lesson 0002
- k1
- BM25 knob for TF saturation rate. Default 1.2.
0 ignores term frequency; higher values saturate more slowly.
— intro'd in lesson 0002
- b
- BM25 knob for field-length normalization, range 0–1, default 0.75.
0 ignores length; 1 applies the full long-field penalty via |D|/avgdl.
— intro'd in lesson 0002
- dfs_query_then_fetch
- A search type that gathers global term statistics across shards before scoring, so per-shard IDF differences don't skew results. Useful for small or test indices.
— intro'd in lesson 0002
- analysis
- The process of turning a text value into a stream of terms via an analyzer. Runs at index time (on field values) and search time (on the query string). Mismatched runs cause silent zero-hit failures.
— intro'd in lesson 0003
- analyzer
- The pipeline that performs analysis, always in three stages: char filters → tokenizer → token filters. The default
standard analyzer = standard tokenizer + lowercase filter.
— intro'd in lesson 0003
- term (token)
- The atomic unit stored in and searched against the inverted index — the output of analysis. BM25 scores per term. What counts as a term is decided by the analyzer, not the query.
— intro'd in lesson 0003
- tokenizer
- The single mandatory analyzer stage that splits a character stream into tokens (e.g.
standard breaks on word boundaries). Preceded by char filters, followed by token filters.
— intro'd in lesson 0003
- token filter
- An analyzer stage that adds, removes, or rewrites tokens after the tokenizer — e.g.
lowercase, stop, stemmer, synonym. Zero or more per analyzer.
— intro'd in lesson 0003
- character filter
- An analyzer stage that rewrites the raw character stream before tokenizing — e.g.
html_strip, character mapping. Zero or more per analyzer.
— intro'd in lesson 0003
- text field
- A mapping type that is analyzed: its value becomes many terms, powering full-text
match queries. Not suitable for sorting or aggregations.
— intro'd in lesson 0003
- keyword field
- A mapping type that is not analyzed: the whole value is stored verbatim as one exact term. Used for exact match, sorting, and aggregations. Dynamic strings map to both a
text field and a .keyword sub-field.
— intro'd in lesson 0003
- _analyze API
- Endpoint that returns the token stream an analyzer (or a mapped field) produces for a given text — the ground truth of what lands in the index. The primary tool for diagnosing the term-mismatch trap.
— intro'd in lesson 0003
← lesson 0001 · lesson 0003 →