You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: guides/relevancy/ordering_ranking_rules.mdx
+2-2Lines changed: 2 additions & 2 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -78,7 +78,7 @@ Ranking rules:
78
78
"proximity",
79
79
"attributeRank",
80
80
"sort", // "price:asc" "author:desc" gets swapped in here
81
-
"attributePosition",
81
+
"wordPosition",
82
82
"exactness",
83
83
"release_date:asc",
84
84
"movie_ranking:desc"
@@ -116,7 +116,7 @@ Place custom ranking rules at the end of your sequence. They work best for addin
116
116
Each ranking rule has its own settings you can fine-tune beyond just ordering. For example, you can adjust which fields take priority in attribute ranking, or configure how aggressively typo tolerance matches similar words. If you want to dig into the specifics:
117
117
118
118
-[Built-in ranking rules](https://www.meilisearch.com/docs/learn/relevancy/ranking_rules#list-of-built-in-ranking-rules) — how each rule works and what it evaluates
119
-
-[Attribute ranking order](https://www.meilisearch.com/docs/learn/relevancy/attribute_ranking_order) — controlling which fields matter most with `attributeRank` and `attributePosition`
119
+
-[Attribute ranking order](https://www.meilisearch.com/docs/learn/relevancy/attribute_ranking_order) — controlling which fields matter most with `attributeRank` and `wordPosition`
120
120
-[Typo tolerance settings](https://www.meilisearch.com/docs/learn/relevancy/typo_tolerance_settings) — adjusting how flexible matching behaves
121
121
122
122
**Want to see these rules in action?** In our next guide, [How Do I Interpret Ranking Score Details?](/guides/relevancy/interpreting_ranking_scores), we walk through a real example showing exactly how Meilisearch evaluates each rule — and how moving Sort one position can flip your results.
Copy file name to clipboardExpand all lines: learn/relevancy/attribute_ranking_order.mdx
+2-2Lines changed: 2 additions & 2 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -38,7 +38,7 @@ By default, nested fields share the same weight as their parent attribute. Use d
38
38
With the above ranking order, `review.critic` becomes more important than its sibling `review.user` when calculating a document's ranking score.
39
39
40
40
<Note>
41
-
The `attributeRank` and `attributePosition` rules' positions in [`rankingRules`](/learn/relevancy/ranking_rules) determine how the results are sorted. Meaning, **if `attributeRank` is at the bottom of the ranking rules list, it will have almost no impact on your search results.**
41
+
The `attributeRank` and `wordPosition` rules' positions in [`rankingRules`](/learn/relevancy/ranking_rules) determine how the results are sorted. Meaning, **if `attributeRank` is at the bottom of the ranking rules list, it will have almost no impact on your search results.**
42
42
43
-
The legacy `attribute` rule combines both `attributeRank` and `attributePosition`. If you use `attribute`, its position determines the impact of both attribute ranking order and position within attributes.
43
+
The legacy `attribute` rule combines both `attributeRank` and `wordPosition`. If you use `attribute`, its position determines the impact of both attribute ranking order and position within attributes.
Copy file name to clipboardExpand all lines: learn/relevancy/ranking_rules.mdx
+4-4Lines changed: 4 additions & 4 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -19,7 +19,7 @@ Meilisearch contains seven built-in ranking rules in the following order:
19
19
"proximity",
20
20
"attributeRank",
21
21
"sort",
22
-
"attributePosition",
22
+
"wordPosition",
23
23
"exactness"
24
24
]
25
25
```
@@ -62,13 +62,13 @@ This rule evaluates only the position of matched words within attributes and doe
62
62
63
63
## Attribute
64
64
65
-
`attribute` is an older built-in ranking rule equivalent to using both `attributeRank` and `attributePosition` together. When you use `attribute`, Meilisearch first sorts results by the attribute ranking order, then uses the position within attributes as a tiebreaker.
65
+
`attribute` is an older built-in ranking rule equivalent to using both `attributeRank` and `wordPosition` together. When you use `attribute`, Meilisearch first sorts results by the attribute ranking order, then uses the position within attributes as a tiebreaker.
66
66
67
67
<Warning>
68
-
You cannot use `attribute` together with `attributeRank` or `attributePosition`. If you try to configure ranking rules with both, Meilisearch will return an error. We recommend using a combination of the `attributeRank` and `attributePosition` rules.
68
+
You cannot use `attribute` together with `attributeRank` or `wordPosition`. If you try to configure ranking rules with both, Meilisearch will return an error. We recommend using a combination of the `attributeRank` and `wordPosition` rules.
69
69
</Warning>
70
70
71
-
For most use-cases, we recommend using `attributeRank` and `attributePosition` separately. This gives you more control over result ordering by allowing you to place other ranking rules (like `sort` or custom ranking rules) between them.
71
+
For most use-cases, we recommend using `attributeRank` and `wordPosition` separately. This gives you more control over result ordering by allowing you to place other ranking rules (like `sort` or custom ranking rules) between them.
Copy file name to clipboardExpand all lines: learn/relevancy/ranking_score.mdx
+2-2Lines changed: 2 additions & 2 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -6,7 +6,7 @@ description: This article explains how the order of attributes in the `searchabl
6
6
7
7
When using the [`showRankingScore` search parameter](/reference/api/search#ranking-score), Meilisearch adds a global ranking score field, `_rankingScore`, to each document. The `_rankingScore` is between `0.0` and `1.0`. The higher the ranking score, the more relevant the document.
8
8
9
-
Ranking rules sort documents either by relevancy (`words`, `typo`, `proximity`, `exactness`, `attributeRank`, `attributePosition`) or by the value of a field (`sort`). Since `sort` doesn't rank documents by relevancy, it does not influence the `_rankingScore`.
9
+
Ranking rules sort documents either by relevancy (`words`, `typo`, `proximity`, `exactness`, `attributeRank`, `wordPosition`) or by the value of a field (`sort`). Since `sort` doesn't rank documents by relevancy, it does not influence the `_rankingScore`.
10
10
11
11
<Note>
12
12
A document's ranking score does not change based on the scores of other documents in the same index.
@@ -19,7 +19,7 @@ The table below details all the index settings that can influence the `_rankingS
|`searchableAttributes`| The `attributeRank` ranking rule is used | The `attributeRank` ranking rule rates the document depending on the attribute in which the query terms show up. The order is determined by `searchableAttributes`|
22
-
|`searchableAttributes`| The `attributePosition` ranking rule is used | The `attributePosition` ranking rule rates the document based on the position of query terms within attributes |
22
+
|`searchableAttributes`| The `wordPosition` ranking rule is used | The `wordPosition` ranking rule rates the document based on the position of query terms within attributes |
23
23
|`rankingRules`| Always | The score is computed by computing the subscore of each ranking rule with a weight that depends on their order |
24
24
|`stopWords`| Always | Stop words influence the `words` ranking rule, which is almost always used |
25
25
|`synonyms`| Always | Synonyms influence the `words` ranking rule, which is almost always used |
Copy file name to clipboardExpand all lines: reference/api/settings.mdx
+7-7Lines changed: 7 additions & 7 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -102,7 +102,7 @@ By default, the settings object looks like this. All fields are modifiable.
102
102
"proximity",
103
103
"attributeRank",
104
104
"sort",
105
-
"attributePosition",
105
+
"wordPosition",
106
106
"exactness"
107
107
],
108
108
"stopWords": [],
@@ -239,7 +239,7 @@ If the provided index does not exist, it will be created.
239
239
|**[`proximityPrecision`](#proximity-precision)**| String |`"byWord"`| Precision level when calculating the proximity ranking rule |
240
240
|**[`facetSearch`](#facet-search)**| Boolean |`true`| Enable or disable [facet search](/reference/api/facet_search) functionality |
241
241
|**[`prefixSearch`](#prefix-search)**| String |`"indexingTime"`| When Meilisearch should return results only matching the beginning of query |
242
-
|**[`rankingRules`](#ranking-rules)**| Array of strings |`["words",`<br />`"typo",`<br />`"proximity",`<br />`"attributeRank",`<br />`"sort",`<br />`"attributePosition",`<br />`"exactness"]`| List of ranking rules in order of importance |
242
+
|**[`rankingRules`](#ranking-rules)**| Array of strings |`["words",`<br />`"typo",`<br />`"proximity",`<br />`"attributeRank",`<br />`"sort",`<br />`"wordPosition",`<br />`"exactness"]`| List of ranking rules in order of importance |
243
243
|**[`searchableAttributes`](#searchable-attributes)**| Array of strings | All attributes: `["*"]`| Fields in which to search for matching query words sorted by order of importance |
244
244
|**[`searchCutoffMs`](#search-cutoff)**| Integer |`null`, or 1500ms | Maximum duration of a search query |
245
245
|**[`separatorTokens`](#separator-tokens)**| Array of strings | Empty | List of characters delimiting where one term begins and ends |
@@ -1474,8 +1474,8 @@ Ranking rules are built-in rules that rank search results according to certain c
1474
1474
|**`"typo"`**| Sorts results by increasing number of typos |
1475
1475
|**`"proximity"`**| Sorts results by increasing distance between matched query terms |
1476
1476
|**`"attributeRank"`**| Sorts results by the attribute rank of the query terms within attributes |
1477
-
|**`"attributePosition"`**| Sorts results by the position of query terms within attributes |
1478
-
|**`"attribute"`**| Legacy rule combining `attributeRank` and `attributePosition`|
1477
+
|**`"wordPosition"`**| Sorts results by the position of query terms within attributes |
1478
+
|**`"attribute"`**| Legacy rule combining `attributeRank` and `wordPosition`|
1479
1479
|**`"sort"`**| Sorts results based on parameters decided at query time |
1480
1480
|**`"exactness"`**| Sorts results based on the similarity of the matched words with the query words |
1481
1481
@@ -1488,7 +1488,7 @@ Ranking rules are built-in rules that rank search results according to certain c
1488
1488
"proximity",
1489
1489
"attributeRank",
1490
1490
"sort",
1491
-
"attributePosition",
1491
+
"wordPosition",
1492
1492
"exactness"
1493
1493
]
1494
1494
```
@@ -1518,7 +1518,7 @@ Get the ranking rules of an index.
1518
1518
"proximity",
1519
1519
"attributeRank",
1520
1520
"sort",
1521
-
"attributePosition",
1521
+
"wordPosition",
1522
1522
"exactness",
1523
1523
"release_date:desc"
1524
1524
]
@@ -1554,7 +1554,7 @@ If some documents do not contain the attribute defined in a custom ranking rule,
1554
1554
1555
1555
Make sure that any attribute used in a custom ranking rule is present in all of your documents. For example, if you set the custom ranking rule `desc(year)`, make sure that all your documents contain the attribute `year`.
1556
1556
1557
-
You cannot use the `attribute` ranking rule together with `attributeRank` or `attributePosition`. If you try to configure ranking rules with both, Meilisearch will return an error. We recommend using a combination of the `attributeRank` and `attributePosition` rules.
1557
+
You cannot use the `attribute` ranking rule together with `attributeRank` or `wordPosition`. If you try to configure ranking rules with both, Meilisearch will return an error. We recommend using a combination of the `attributeRank` and `wordPosition` rules.
1558
1558
</Warning>
1559
1559
1560
1560
[To learn more about ranking rules, refer to our dedicated guide.](/learn/relevancy/ranking_rules)
0 commit comments