@findlane/server 0.13.0 → 0.14.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.d.cts +16 -8
- package/dist/index.d.ts +16 -8
- package/package.json +1 -1
package/dist/index.d.cts
CHANGED
|
@@ -57,6 +57,12 @@ export type IndexSettings = {
|
|
|
57
57
|
/** Searches say which words typo tolerance corrected, and `suggest()` offers a corrected query for a
|
|
58
58
|
* search that finds nothing. Off by default. */
|
|
59
59
|
didYouMean?: boolean;
|
|
60
|
+
/** Compound words find each other written as one word or apart, in any language: a query word that the
|
|
61
|
+
* index's words show is a compound also matches its parts written apart ("sjóræningjabúningur" finds
|
|
62
|
+
* "Sjóræningja búningur"), and neighbouring query words the word they make ("face paint" finds "facepaint").
|
|
63
|
+
* Exact matches rank first. Searches use it once the index's word list is built, a minute or so after it's
|
|
64
|
+
* turned on. Off by default. */
|
|
65
|
+
compoundWords?: boolean;
|
|
60
66
|
normalizationProfile?: "default-v2" | "default-v1" | "icelandic-ascii-v1";
|
|
61
67
|
/** An object field of lat and lng numbers, such as `_geoloc`, that `near` and `within` search; null for none. */
|
|
62
68
|
locationField?: string | null;
|
|
@@ -217,14 +223,16 @@ export type GeoBox = {
|
|
|
217
223
|
east: number;
|
|
218
224
|
west: number;
|
|
219
225
|
};
|
|
220
|
-
/** How a query word matched: as itself, as the start of a longer word, within its typos, through a synonym,
|
|
221
|
-
* as another form of the word in the index's languages (a plural or another spelling)
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
*
|
|
227
|
-
*
|
|
226
|
+
/** How a query word matched: as itself, as the start of a longer word, within its typos, through a synonym,
|
|
227
|
+
* as another form of the word in the index's languages (a plural or another spelling), or, with the
|
|
228
|
+
* `compoundWords` setting, as a compound: its parts written apart, or the word it makes with a neighbouring
|
|
229
|
+
* query word. */
|
|
230
|
+
export type MatchKind = "exact" | "prefix" | "typo" | "synonym" | "form" | "compound";
|
|
231
|
+
/** A query word's best match in one searchable field. `word` is the matched word (or a synonym's phrase, or a
|
|
232
|
+
* compound's parts) as the record writes it. `weight` is what that kind of match weighs in the search: the
|
|
233
|
+
* field's weight times 1 for exact, 0.8 for a synonym or word form, 0.4 for a compound, 0.2 for a prefix, and
|
|
234
|
+
* 0.1 for a typo. A typo has `edits`, or `firstLetter` when the first letter differs (tried only when nothing
|
|
235
|
+
* matched without); a synonym has the `synonym` that matched. */
|
|
228
236
|
export type FieldMatch = {
|
|
229
237
|
field: string;
|
|
230
238
|
word: string;
|
package/dist/index.d.ts
CHANGED
|
@@ -57,6 +57,12 @@ export type IndexSettings = {
|
|
|
57
57
|
/** Searches say which words typo tolerance corrected, and `suggest()` offers a corrected query for a
|
|
58
58
|
* search that finds nothing. Off by default. */
|
|
59
59
|
didYouMean?: boolean;
|
|
60
|
+
/** Compound words find each other written as one word or apart, in any language: a query word that the
|
|
61
|
+
* index's words show is a compound also matches its parts written apart ("sjóræningjabúningur" finds
|
|
62
|
+
* "Sjóræningja búningur"), and neighbouring query words the word they make ("face paint" finds "facepaint").
|
|
63
|
+
* Exact matches rank first. Searches use it once the index's word list is built, a minute or so after it's
|
|
64
|
+
* turned on. Off by default. */
|
|
65
|
+
compoundWords?: boolean;
|
|
60
66
|
normalizationProfile?: "default-v2" | "default-v1" | "icelandic-ascii-v1";
|
|
61
67
|
/** An object field of lat and lng numbers, such as `_geoloc`, that `near` and `within` search; null for none. */
|
|
62
68
|
locationField?: string | null;
|
|
@@ -217,14 +223,16 @@ export type GeoBox = {
|
|
|
217
223
|
east: number;
|
|
218
224
|
west: number;
|
|
219
225
|
};
|
|
220
|
-
/** How a query word matched: as itself, as the start of a longer word, within its typos, through a synonym,
|
|
221
|
-
* as another form of the word in the index's languages (a plural or another spelling)
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
*
|
|
227
|
-
*
|
|
226
|
+
/** How a query word matched: as itself, as the start of a longer word, within its typos, through a synonym,
|
|
227
|
+
* as another form of the word in the index's languages (a plural or another spelling), or, with the
|
|
228
|
+
* `compoundWords` setting, as a compound: its parts written apart, or the word it makes with a neighbouring
|
|
229
|
+
* query word. */
|
|
230
|
+
export type MatchKind = "exact" | "prefix" | "typo" | "synonym" | "form" | "compound";
|
|
231
|
+
/** A query word's best match in one searchable field. `word` is the matched word (or a synonym's phrase, or a
|
|
232
|
+
* compound's parts) as the record writes it. `weight` is what that kind of match weighs in the search: the
|
|
233
|
+
* field's weight times 1 for exact, 0.8 for a synonym or word form, 0.4 for a compound, 0.2 for a prefix, and
|
|
234
|
+
* 0.1 for a typo. A typo has `edits`, or `firstLetter` when the first letter differs (tried only when nothing
|
|
235
|
+
* matched without); a synonym has the `synonym` that matched. */
|
|
228
236
|
export type FieldMatch = {
|
|
229
237
|
field: string;
|
|
230
238
|
word: string;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@findlane/server",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.14.0",
|
|
4
4
|
"description": "Findlane server SDK: upload catalogs, manage index settings, and search with a secret workspace API key.",
|
|
5
5
|
"keywords": ["findlane", "search", "full-text search", "typo tolerance", "ecommerce search", "search api", "sdk"],
|
|
6
6
|
"license": "MIT",
|