@algolia/recommend 5.46.4 → 5.48.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/worker.d.ts CHANGED
@@ -66,7 +66,7 @@ type InsideBoundingBox = string | Array<Array<number>>;
66
66
  type NumericFilters = Array<NumericFilters> | string;
67
67
 
68
68
  /**
69
- * Filters to promote or demote records in the search results. Optional filters work like facet filters, but they don\'t exclude records from the search results. Records that match the optional filter rank before records that don\'t match. If you\'re using a negative filter `facet:-value`, matching records rank after records that don\'t match. - Optional filters don\'t work on virtual replicas. - Optional filters are applied _after_ sort-by attributes. - Optional filters are applied _before_ custom ranking attributes (in the default [ranking](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria)). - Optional filters don\'t work with numeric attributes.
69
+ * Filters to promote or demote records in the search results. Optional filters work like facet filters, but they don\'t exclude records from the search results. Records that match the optional filter rank before records that don\'t match. If you\'re using a negative filter `facet:-value`, matching records rank after records that don\'t match. - Optional filters are applied _after_ sort-by attributes. - Optional filters are applied _before_ custom ranking attributes (in the default [ranking](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria)). - Optional filters don\'t work with numeric attributes. - On virtual replicas, optional filters are applied _after_ the replica\'s [relevant sort](https://www.algolia.com/doc/guides/managing-results/refine-results/sorting/in-depth/relevant-sort).
70
70
  */
71
71
  type OptionalFilters = Array<OptionalFilters> | string;
72
72
 
@@ -627,15 +627,26 @@ type RelatedQuery = BaseRecommendRequest & RelatedProducts;
627
627
  type TrendingFacetsModel = 'trending-facets';
628
628
 
629
629
  type TrendingFacets = {
630
+ /**
631
+ * Index name (case-sensitive).
632
+ */
633
+ indexName: string;
634
+ /**
635
+ * Minimum score a recommendation must have to be included in the response.
636
+ */
637
+ threshold: number;
638
+ /**
639
+ * Maximum number of recommendations to retrieve. By default, all recommendations are returned and no fallback request is made. Depending on the available recommendations and the other request parameters, the actual number of recommendations may be lower than this value.
640
+ */
641
+ maxRecommendations?: number | undefined;
630
642
  /**
631
643
  * Facet attribute for which to retrieve trending facet values.
632
644
  */
633
645
  facetName: string;
634
646
  model: TrendingFacetsModel;
635
- fallbackParameters?: FallbackParams | undefined;
636
647
  };
637
648
 
638
- type TrendingFacetsQuery = BaseRecommendRequest & TrendingFacets;
649
+ type TrendingFacetsQuery = TrendingFacets;
639
650
 
640
651
  /**
641
652
  * Trending items model. Trending items are determined from the number of conversion events collected on them.
@@ -1412,7 +1423,7 @@ type SearchRecommendRulesProps = {
1412
1423
  searchRecommendRulesParams?: SearchRecommendRulesParams | undefined;
1413
1424
  };
1414
1425
 
1415
- declare const apiClientVersion = "5.46.4";
1426
+ declare const apiClientVersion = "5.48.0";
1416
1427
  declare function createRecommendClient({ appId: appIdOption, apiKey: apiKeyOption, authMode, algoliaAgents, ...options }: CreateClientOptions): {
1417
1428
  transporter: _algolia_client_common.Transporter;
1418
1429
  /**
package/package.json CHANGED
@@ -1,5 +1,5 @@
1
1
  {
2
- "version": "5.46.4",
2
+ "version": "5.48.0",
3
3
  "repository": {
4
4
  "type": "git",
5
5
  "url": "git+https://github.com/algolia/algoliasearch-client-javascript.git"
@@ -49,21 +49,21 @@
49
49
  "index.d.ts"
50
50
  ],
51
51
  "dependencies": {
52
- "@algolia/client-common": "5.46.4",
53
- "@algolia/requester-browser-xhr": "5.46.4",
54
- "@algolia/requester-fetch": "5.46.4",
55
- "@algolia/requester-node-http": "5.46.4"
52
+ "@algolia/client-common": "5.48.0",
53
+ "@algolia/requester-browser-xhr": "5.48.0",
54
+ "@algolia/requester-fetch": "5.48.0",
55
+ "@algolia/requester-node-http": "5.48.0"
56
56
  },
57
57
  "devDependencies": {
58
58
  "@arethetypeswrong/cli": "0.18.2",
59
- "@types/node": "25.0.9",
60
- "publint": "0.3.16",
61
- "rollup": "4.55.1",
59
+ "@types/node": "25.1.0",
60
+ "publint": "0.3.17",
61
+ "rollup": "4.57.1",
62
62
  "tsup": "8.5.1",
63
63
  "typescript": "5.9.3"
64
64
  },
65
65
  "engines": {
66
66
  "node": ">= 14.0.0"
67
67
  },
68
- "gitHead": "4b049770d6e6c0d6336c323e53b29e6d5b3c216f"
68
+ "gitHead": "b39976bd859ef66e65d2db182d69853a91a71139"
69
69
  }