@fast-simon/dashboard-utilities 1.0.167-beta.0 → 1.0.167-beta.2
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/@types/autocomplete.d.ts +7 -0
- package/dist/@types/autocomplete.js.map +1 -1
- package/dist/@types/categories.d.ts +2 -0
- package/dist/@types/categories.js.map +1 -1
- package/dist/@types/product.d.ts +1 -1
- package/dist/@types/product.js.map +1 -1
- package/dist/@types/results.d.ts +2 -0
- package/dist/@types/results.js.map +1 -1
- package/dist/components/FastSimonApi/reducer.d.ts +16 -0
- package/package.json +1 -1
|
@@ -63,4 +63,11 @@ export interface AutocompleteReasoningResponse {
|
|
|
63
63
|
query_understanding?: QueryUnderstanding;
|
|
64
64
|
reformulation_source?: string;
|
|
65
65
|
request_url?: string;
|
|
66
|
+
rpi_methodology_assigned?: string | null;
|
|
67
|
+
rpi_methodology_preview_requested?: boolean;
|
|
68
|
+
rpi_methodology_effective?: string | null;
|
|
69
|
+
rpi_methodology_fallback_reason?: string | null;
|
|
70
|
+
rpi_candidate_available?: boolean;
|
|
71
|
+
rpi_candidate_unavailable_reason?: string | null;
|
|
72
|
+
rpi_candidate_readiness_status?: string | null;
|
|
66
73
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"autocomplete.js","sourceRoot":"","sources":["../../src/@types/autocomplete.ts"],"names":[],"mappings":"","sourcesContent":["import {ServerProduct} from \"./product\";\nimport {Facet, FastCategory, FastTurbolinks} from \"./facets\";\nimport {PopularSearch, ContextFilteringData, QueryUnderstanding} from \"./results\";\nimport {SortBy} from \"./sortBy\";\n\n\n\nexport interface AutocompleteResults {\n totalResults: number,\n categories?: FastCategory[],\n products: ServerProduct[]\n turbolinks?: FastTurbolinks[]\n popularSearches: PopularSearch[]\n query: string\n}\n\nexport interface autocompleteProps {\n storeID: number\n uuid: string\n siteKey?:string\n cdn?: number\n term: string,\n userToken: string,\n sessionStart: number,\n withAttributes?: boolean\n segments?: string[],\n hasShopifyMarkets?: boolean,\n disable_turbolinks?:boolean\n disable_strategies?:boolean\n disable_merchandising?:boolean\n disable_semantics?:boolean\n disable_merchandising_rules?:boolean\n disable_antonyms?:boolean\n market_context?: string | null // Region code for market-specific filtering (e.g., \"US\", \"CA\", \"UK\")\n variation_id?: string | null // A/B test variation ID for reasoning/experiment tracking\n force_and?: boolean\n ps?: 'new' | 'returning' | null\n spv?: string | null // Session Product Views JSON for personalization preview\n personalization?: string | null // Comma-separated personalization types to enable (e.g., 'gender')\n}\nexport interface AutocompleteReasoningResponse {\n auto_facets?: boolean\n isp_quick_view_mode?: number\n products: ServerProduct[]\n merch: {\n prorduct:any,\n rules:any,\n strategy:any,\n visual:any\n }\n personalized_products:any[]\n term:string\n totalResults: number\n uuid:string\n\n antonyms?: Record<string, number[]>\n\n //all bellow wont be never field but to keep consistent with all the AIExplainer implementation\n sortBy?:SortBy\n within_search_results_for?: string,\n isNoResults?:any,\n pageCount?:number,\n narrow?: [string, string, string][],\n facets?: Facet[],\n page?: number,\n results_for?: string,\n id_list?:number[]\n turbolink?: string\n context?: ContextFilteringData // Context-based filtering data (market contexts)\n query_understanding?: QueryUnderstanding\n reformulation_source?: string\n request_url?: string // Full URL with all params that was executed (for debugging)\n}"]}
|
|
1
|
+
{"version":3,"file":"autocomplete.js","sourceRoot":"","sources":["../../src/@types/autocomplete.ts"],"names":[],"mappings":"","sourcesContent":["import {ServerProduct} from \"./product\";\nimport {Facet, FastCategory, FastTurbolinks} from \"./facets\";\nimport {PopularSearch, ContextFilteringData, QueryUnderstanding} from \"./results\";\nimport {SortBy} from \"./sortBy\";\n\n\n\nexport interface AutocompleteResults {\n totalResults: number,\n categories?: FastCategory[],\n products: ServerProduct[]\n turbolinks?: FastTurbolinks[]\n popularSearches: PopularSearch[]\n query: string\n}\n\nexport interface autocompleteProps {\n storeID: number\n uuid: string\n siteKey?:string\n cdn?: number\n term: string,\n userToken: string,\n sessionStart: number,\n withAttributes?: boolean\n segments?: string[],\n hasShopifyMarkets?: boolean,\n disable_turbolinks?:boolean\n disable_strategies?:boolean\n disable_merchandising?:boolean\n disable_semantics?:boolean\n disable_merchandising_rules?:boolean\n disable_antonyms?:boolean\n market_context?: string | null // Region code for market-specific filtering (e.g., \"US\", \"CA\", \"UK\")\n variation_id?: string | null // A/B test variation ID for reasoning/experiment tracking\n force_and?: boolean\n ps?: 'new' | 'returning' | null\n spv?: string | null // Session Product Views JSON for personalization preview\n personalization?: string | null // Comma-separated personalization types to enable (e.g., 'gender')\n}\nexport interface AutocompleteReasoningResponse {\n auto_facets?: boolean\n isp_quick_view_mode?: number\n products: ServerProduct[]\n merch: {\n prorduct:any,\n rules:any,\n strategy:any,\n visual:any\n }\n personalized_products:any[]\n term:string\n totalResults: number\n uuid:string\n\n antonyms?: Record<string, number[]>\n\n //all bellow wont be never field but to keep consistent with all the AIExplainer implementation\n sortBy?:SortBy\n within_search_results_for?: string,\n isNoResults?:any,\n pageCount?:number,\n narrow?: [string, string, string][],\n facets?: Facet[],\n page?: number,\n results_for?: string,\n id_list?:number[]\n turbolink?: string\n context?: ContextFilteringData // Context-based filtering data (market contexts)\n query_understanding?: QueryUnderstanding\n reformulation_source?: string\n request_url?: string // Full URL with all params that was executed (for debugging)\n rpi_methodology_assigned?: string | null\n rpi_methodology_preview_requested?: boolean\n rpi_methodology_effective?: string | null\n rpi_methodology_fallback_reason?: string | null\n rpi_candidate_available?: boolean\n rpi_candidate_unavailable_reason?: string | null\n rpi_candidate_readiness_status?: string | null\n}\n"]}
|
|
@@ -115,12 +115,14 @@ export interface smartCollectionsResults {
|
|
|
115
115
|
reformulation_source?: string;
|
|
116
116
|
request_url?: string;
|
|
117
117
|
rpi_methodology_assigned?: string | null;
|
|
118
|
+
rpi_methodology_preview_requested?: boolean;
|
|
118
119
|
rpi_methodology_effective?: string | null;
|
|
119
120
|
rpi_methodology_fallback_reason?: string | null;
|
|
120
121
|
rpi_snapshot_computed_at?: string | null;
|
|
121
122
|
rpi_snapshot_covered_until?: string | null;
|
|
122
123
|
rpi_candidate_available?: boolean;
|
|
123
124
|
rpi_candidate_unavailable_reason?: string | null;
|
|
125
|
+
rpi_candidate_readiness_status?: string | null;
|
|
124
126
|
}
|
|
125
127
|
export type inventoryCallback = ({}: {
|
|
126
128
|
action: "products inventory";
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"categories.js","sourceRoot":"","sources":["../../src/@types/categories.ts"],"names":[],"mappings":"","sourcesContent":["import {SortBy} from \"./sortBy\";\nimport {Narrow, ServerNarrow} from \"./narrow\";\nimport { ServerProduct} from \"./product\";\nimport {ServerFacet} from \"./facets\";\nimport {ContextFilteringData, QueryUnderstanding} from \"./results\";\n\n\nexport type AncestorCategory = [string, string, string] // category_id, category_name, category_url\nexport interface RelatedCategory {\n id: string\n l: string\n t: string\n u: string\n}\nexport type CategoryAncestor = [string, string, string]\nexport interface Category {\n d: string\n id: string\n l: string\n p_id: string\n t: string\n u: string\n parent_name?: string\n}\nexport interface FastCategory {\n d: string\n id: string\n l: string\n p_id: string\n t: string\n u: string\n parent_name?: string\n}\nexport interface smartCollectionsProps {\n storeID: number\n uuid: string\n siteKey?:string\n cdn: number\n categoryID: string,\n userToken: string,\n sessionStart: number,\n page?: number\n productsPerPage?: number\n sortBy?: SortBy\n narrowBy?: ServerNarrow[]\n facetRequired?: FacetRequired\n withAttributes?: boolean\n recent?: string\n rec?: boolean\n searchWithinSearch?: string,\n segments?: string[],\n hasShopifyMarkets?: boolean,\n disable_turbolinks?:boolean\n disable_strategies?:boolean\n disable_merchandising?:boolean\n disable_semantics?:boolean\n disable_merchandising_rules?:boolean\n disable_antonyms?:boolean\n custom_sort_settings?:{personalization_rank: number, creation_date: number, popularity: number, inventory: number}\n with_product_analytics?:boolean\n market_context?: string | null // Region code for market-specific filtering (e.g., \"US\", \"CA\", \"UK\")\n variation_id?: string | null // A/B test variation ID for reasoning/experiment tracking\n ps?: 'new' | 'returning' | null // Personalization segment for user segment coefficient preview (new/returning user)\n spv?: string | null // Session Product Views JSON for personalization preview (e.g., '{\"pid1\":ts,\"pid2\":ts}')\n spc?: string | null // Session Product Cart-adds JSON for size personalization preview (e.g., '{\"pid::vid\":ts}'); collection-only\n personalization?: string | null // Comma-separated personalization types to enable (e.g., 'gender')\n force_and?: boolean\n session_token?: string // Session token override for AI Explainer (sent as st param)\n}\nexport type FacetRequired = 0 | 1 | 2\nexport type smartCollectionsCallback = ({}: {\n action: \"products\" | \"facets and products\"\n payload: smartCollectionsResults\n}) => void\nexport interface smartCollectionsResults {\n ancestors: CategoryAncestor[]\n categoryID: string\n name: string\n category_name: string\n products: ServerProduct[]\n facets?: ServerFacet[]\n totalResults: number\n sortBy?: SortBy,\n narrow?: Narrow[],\n isNoResults?: boolean\n page?: number\n pageCount?: number\n avoidPrefixList?: string[]\n antonyms?: Record<string, number[]>\n merch?: any\n bannerHTML?: string\n turbolink?:string\n hiddenProducts?:ServerProduct[]\n within_search_results_for?:string\n results_for?: string\n id_list?:number[]\n personalized_products?: number[] // Product IDs affected by RPI personalization\n context?: ContextFilteringData // Context-based filtering data (market contexts)\n analytics?: {\n badges?: {\n winners?: Record<string, string> // Product ID -> tooltip message\n overexposed?: Record<string, string> // Product ID -> tooltip message\n new_arrivals?: string[]\n }\n key_hidden_winners?: string\n key_overexposed?: string\n }\n matching_sets?: Record<string, string> // Product ID -> set name\n group_strategy?: Record<string, string> // Product ID -> group name\n variety_strategy?: number[] // Product IDs affected by variety strategy\n query_understanding?: QueryUnderstanding\n reformulation_source?: string\n request_url?: string // Full URL with all params that was executed (for debugging)\n rpi_methodology_assigned?: string | null\n rpi_methodology_effective?: string | null\n rpi_methodology_fallback_reason?: string | null\n rpi_snapshot_computed_at?: string | null\n rpi_snapshot_covered_until?: string | null\n rpi_candidate_available?: boolean\n rpi_candidate_unavailable_reason?: string | null\n\n}\nexport type inventoryCallback = ({}: {\n action: \"products inventory\"\n payload: {productsInventory: productsInventoryResults[]}\n}) => void\nexport interface productsInventoryResults {\n id: string;\n totalInventory: number;\n}\n"]}
|
|
1
|
+
{"version":3,"file":"categories.js","sourceRoot":"","sources":["../../src/@types/categories.ts"],"names":[],"mappings":"","sourcesContent":["import {SortBy} from \"./sortBy\";\nimport {Narrow, ServerNarrow} from \"./narrow\";\nimport { ServerProduct} from \"./product\";\nimport {ServerFacet} from \"./facets\";\nimport {ContextFilteringData, QueryUnderstanding} from \"./results\";\n\n\nexport type AncestorCategory = [string, string, string] // category_id, category_name, category_url\nexport interface RelatedCategory {\n id: string\n l: string\n t: string\n u: string\n}\nexport type CategoryAncestor = [string, string, string]\nexport interface Category {\n d: string\n id: string\n l: string\n p_id: string\n t: string\n u: string\n parent_name?: string\n}\nexport interface FastCategory {\n d: string\n id: string\n l: string\n p_id: string\n t: string\n u: string\n parent_name?: string\n}\nexport interface smartCollectionsProps {\n storeID: number\n uuid: string\n siteKey?:string\n cdn: number\n categoryID: string,\n userToken: string,\n sessionStart: number,\n page?: number\n productsPerPage?: number\n sortBy?: SortBy\n narrowBy?: ServerNarrow[]\n facetRequired?: FacetRequired\n withAttributes?: boolean\n recent?: string\n rec?: boolean\n searchWithinSearch?: string,\n segments?: string[],\n hasShopifyMarkets?: boolean,\n disable_turbolinks?:boolean\n disable_strategies?:boolean\n disable_merchandising?:boolean\n disable_semantics?:boolean\n disable_merchandising_rules?:boolean\n disable_antonyms?:boolean\n custom_sort_settings?:{personalization_rank: number, creation_date: number, popularity: number, inventory: number}\n with_product_analytics?:boolean\n market_context?: string | null // Region code for market-specific filtering (e.g., \"US\", \"CA\", \"UK\")\n variation_id?: string | null // A/B test variation ID for reasoning/experiment tracking\n ps?: 'new' | 'returning' | null // Personalization segment for user segment coefficient preview (new/returning user)\n spv?: string | null // Session Product Views JSON for personalization preview (e.g., '{\"pid1\":ts,\"pid2\":ts}')\n spc?: string | null // Session Product Cart-adds JSON for size personalization preview (e.g., '{\"pid::vid\":ts}'); collection-only\n personalization?: string | null // Comma-separated personalization types to enable (e.g., 'gender')\n force_and?: boolean\n session_token?: string // Session token override for AI Explainer (sent as st param)\n}\nexport type FacetRequired = 0 | 1 | 2\nexport type smartCollectionsCallback = ({}: {\n action: \"products\" | \"facets and products\"\n payload: smartCollectionsResults\n}) => void\nexport interface smartCollectionsResults {\n ancestors: CategoryAncestor[]\n categoryID: string\n name: string\n category_name: string\n products: ServerProduct[]\n facets?: ServerFacet[]\n totalResults: number\n sortBy?: SortBy,\n narrow?: Narrow[],\n isNoResults?: boolean\n page?: number\n pageCount?: number\n avoidPrefixList?: string[]\n antonyms?: Record<string, number[]>\n merch?: any\n bannerHTML?: string\n turbolink?:string\n hiddenProducts?:ServerProduct[]\n within_search_results_for?:string\n results_for?: string\n id_list?:number[]\n personalized_products?: number[] // Product IDs affected by RPI personalization\n context?: ContextFilteringData // Context-based filtering data (market contexts)\n analytics?: {\n badges?: {\n winners?: Record<string, string> // Product ID -> tooltip message\n overexposed?: Record<string, string> // Product ID -> tooltip message\n new_arrivals?: string[]\n }\n key_hidden_winners?: string\n key_overexposed?: string\n }\n matching_sets?: Record<string, string> // Product ID -> set name\n group_strategy?: Record<string, string> // Product ID -> group name\n variety_strategy?: number[] // Product IDs affected by variety strategy\n query_understanding?: QueryUnderstanding\n reformulation_source?: string\n request_url?: string // Full URL with all params that was executed (for debugging)\n rpi_methodology_assigned?: string | null\n rpi_methodology_preview_requested?: boolean\n rpi_methodology_effective?: string | null\n rpi_methodology_fallback_reason?: string | null\n rpi_snapshot_computed_at?: string | null\n rpi_snapshot_covered_until?: string | null\n rpi_candidate_available?: boolean\n rpi_candidate_unavailable_reason?: string | null\n rpi_candidate_readiness_status?: string | null\n\n}\nexport type inventoryCallback = ({}: {\n action: \"products inventory\"\n payload: {productsInventory: productsInventoryResults[]}\n}) => void\nexport interface productsInventoryResults {\n id: string;\n totalInventory: number;\n}\n"]}
|
package/dist/@types/product.d.ts
CHANGED
|
@@ -37,7 +37,7 @@ export interface ProductPersonalizationCoefficients {
|
|
|
37
37
|
final: number;
|
|
38
38
|
global_rpi?: number;
|
|
39
39
|
global_cpi?: number;
|
|
40
|
-
primary?: '
|
|
40
|
+
primary?: 'local' | 'global_rpi' | 'global_cpi';
|
|
41
41
|
};
|
|
42
42
|
user_segment_coef?: number;
|
|
43
43
|
sales_speed_coef?: number;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"product.js","sourceRoot":"","sources":["../../src/@types/product.ts"],"names":[],"mappings":"AAuEA,MAAM,CAAN,IAAY,eAKX;AALD,WAAY,eAAe;IACvB,6EAAgB,CAAA;IAChB,yFAAsB,CAAA;IACtB,qFAAoB,CAAA;IACpB,mFAAmB,CAAA;AACvB,CAAC,EALW,eAAe,KAAf,eAAe,QAK1B","sourcesContent":["import type {Currency} from \"./currency\";\nimport {PromoTileConfig} from \"./promoTile\";\n\nexport interface ProductAnalytics {\n global_impressions?: string\n context_impressions?: string\n global_cpi?: string\n context_cpi?: string\n global_rpi?: string\n context_rpi?: string\n global_rpi_corrected?: number\n context_rpi_corrected?: number\n global_rpi_cp_lower?: number\n context_rpi_cp_lower?: number\n global_rpi_corrected_cp_lower?: number\n context_rpi_corrected_cp_lower?: number\n beta_alpha_post_local?: number\n beta_beta_post_local?: number\n aov_for_cdf_local?: number\n sales_days?: number[]\n sales_weeks?: number[]\n sales_months?: number[]\n is_hidden_winner?: boolean\n is_overexposed?: boolean\n explanation?: string\n}\n\nexport interface FilterCoefEntry {\n raw: number;\n power?: number;\n effective?: number;\n pair?: string;\n pair_index?: number;\n}\n\nexport interface ProductPersonalizationCoefficients {\n rpi?: {\n baseline: number;\n coefficient: number;\n final: number;\n global_rpi?: number;\n global_cpi?: number;\n primary?: '
|
|
1
|
+
{"version":3,"file":"product.js","sourceRoot":"","sources":["../../src/@types/product.ts"],"names":[],"mappings":"AAuEA,MAAM,CAAN,IAAY,eAKX;AALD,WAAY,eAAe;IACvB,6EAAgB,CAAA;IAChB,yFAAsB,CAAA;IACtB,qFAAoB,CAAA;IACpB,mFAAmB,CAAA;AACvB,CAAC,EALW,eAAe,KAAf,eAAe,QAK1B","sourcesContent":["import type {Currency} from \"./currency\";\nimport {PromoTileConfig} from \"./promoTile\";\n\nexport interface ProductAnalytics {\n global_impressions?: string\n context_impressions?: string\n global_cpi?: string\n context_cpi?: string\n global_rpi?: string\n context_rpi?: string\n global_rpi_corrected?: number\n context_rpi_corrected?: number\n global_rpi_cp_lower?: number\n context_rpi_cp_lower?: number\n global_rpi_corrected_cp_lower?: number\n context_rpi_corrected_cp_lower?: number\n beta_alpha_post_local?: number\n beta_beta_post_local?: number\n aov_for_cdf_local?: number\n sales_days?: number[]\n sales_weeks?: number[]\n sales_months?: number[]\n is_hidden_winner?: boolean\n is_overexposed?: boolean\n explanation?: string\n}\n\nexport interface FilterCoefEntry {\n raw: number;\n power?: number;\n effective?: number;\n pair?: string;\n pair_index?: number;\n}\n\nexport interface ProductPersonalizationCoefficients {\n rpi?: {\n baseline: number;\n coefficient: number;\n final: number;\n global_rpi?: number;\n global_cpi?: number;\n primary?: 'local' | 'global_rpi' | 'global_cpi';\n };\n user_segment_coef?: number;\n sales_speed_coef?: number; // ranking multiplier (neutral = 1.0; methodology defines its time windows)\n size_availability?: number; // size-availability ranking multiplier in [0,1] (from cart-adds / spc)\n price_discrimination?: number; // price-band ranking multiplier (p/pi around 1.0, from clicked products)\n price_discrimination_band?: string; // the product's synthetic band label, e.g. \"dresses_3\"\n filter_coefs?: Record<string, FilterCoefEntry | number>;\n}\n\nexport type PillarKind =\n | 'shopper_intent'\n | 'style_affinity'\n | 'collection_standout'\n | 'audience_demand'\n | 'price_discrimination';\n\nexport type PersonalizationConfidence = 'high' | 'medium' | 'low';\n\nexport interface Pillar {\n kind: PillarKind;\n label: string;\n}\n\nexport interface PersonalizationStory {\n confidence: PersonalizationConfidence;\n pillars: Pillar[];\n}\n\nexport enum FeaturedRanking {\n FEATURED_RANK_NO,\n FEATURED_RANK_ON_MATCH,\n FEATURED_RANK_ALWAYS,\n FEATURED_RANK_NEVER,\n}\n\nexport interface ServerProduct {\n c: Currency\n d: string\n f: FeaturedRanking\n id: productID\n iso: boolean\n l: string\n p: string\n p_c: string\n p_max: string\n p_max_c: string\n p_min: string\n p_min_c: string\n p_spl: number\n p_spl_id?: string\n review?: number\n reviews_count?: number\n s: string\n sku: string\n skus: string[]\n t: string\n t2: string\n u: string\n v_c: number\n v: string\n vra: ServerVariant[]\n vrc: object\n att?: Attribute[]\n real_sku?: string\n image_id?: string\n alt?: AlternativeColor[]\n inventory_lvl?: number\n promotile?: boolean\n imageID?: string\n rec_src?: number\n analytics?: ProductAnalytics\n personalization_coefs?: ProductPersonalizationCoefficients\n personalization_story?: PersonalizationStory\n}\n\nexport type ServerVariant = [number, VariantData[]]\nexport type VariantData = [string, string[]]\n\nexport type Attribute = [string, AttributeData[]]\nexport type AttributeData = string[] | string[][]\n\nexport interface ServerAltProductVariant {\n sellable: boolean;\n size: string;\n v_id: number;\n}\n\nexport interface ServerAltProductData {\n l: string;\n p: string;\n p_c: string;\n p_spl: number;\n p_spl_id?: number;\n sku?: string;\n t: string[];\n vra: ServerAltProductVariant[];\n review?: number;\n reviews_count?: number;\n att?: any[];\n s?: string;\n p_min: string;\n p_max: string;\n}\n\nexport type AlternativeColor = [AlternativeColorName, AlternativeColorURL, productID?, ServerAltProductData?]\n\ntype AlternativeColorName = string\ntype AlternativeColorURL = string\ntype productID = number\n\nexport interface Badge {\n tag: string;\n url: string;\n}\n\nexport interface TextBadge {\n badgeText: string;\n tag: string;\n badgeStyle: {\n backgroundColor: string;\n borderColor: string;\n borderRadius: number;\n horizontal: string;\n vertical: string;\n size: number;\n textColor: string;\n }\n}\n\nexport interface Products {\n [id: string]: Product\n}\n\nexport interface Product {\n currency: Currency\n id: string\n title: string\n description: string\n variants: Variants\n isSoldOut: boolean\n price: number\n minPrice: number\n maxPrice: number\n maxCompare: number\n comparePrice: number\n maxFormattedCompare: string;\n reviewScore: number | undefined\n reviewCount: number | undefined\n imageURL: string\n imageURL2: string\n optimizedURL?: string;\n formattedPrice: string\n formattedCompare: string | undefined\n vendor: string\n sku: string\n s: string\n inventory_lvl?: number\n imagesSrcset: string\n productURL: string\n productBadges: Badge[]\n productTextBadges?: TextBadge[]\n alternativeProducts?: AlternativeProduct[]\n tags?: string[]\n promoTileConfig?: PromoTileConfig\n attributes?: Attribute[]\n p_spl?: number\n p_spl_id?: string\n isIspNoPrice?: boolean\n imageID?: string\n vrc?: object\n analytics?: ProductAnalytics\n personalization_coefs?: ProductPersonalizationCoefficients\n personalization_story?: PersonalizationStory\n}\n\nexport interface Variant {\n id: number,\n attributes: {\n [key: string]: VariantsAttribute\n }\n}\n\nexport type Variants = Variant[]\n\nexport type VariantsAttribute = string | number | boolean | string[] | undefined\n\nexport interface AlternativeProduct {\n color: string,\n url: string,\n id: string,\n variants?: Variants,\n s?: string,\n price: number\n comparePrice: number,\n formattedCompare?: string,\n formattedPrice?: string,\n attributes?: Attribute[] | undefined\n}\n\nexport interface ServerPromotile {\n height: number;\n id: string;\n image: string;\n link: string;\n width: number;\n title: string;\n}\n"]}
|
package/dist/@types/results.d.ts
CHANGED
|
@@ -151,11 +151,13 @@ export interface FullTextServerResponseAll extends fullTextSearchResponse {
|
|
|
151
151
|
reformulation_source?: string;
|
|
152
152
|
request_url?: string;
|
|
153
153
|
rpi_methodology_assigned?: string | null;
|
|
154
|
+
rpi_methodology_preview_requested?: boolean;
|
|
154
155
|
rpi_methodology_effective?: string | null;
|
|
155
156
|
rpi_methodology_fallback_reason?: string | null;
|
|
156
157
|
rpi_snapshot_computed_at?: string | null;
|
|
157
158
|
rpi_snapshot_covered_until?: string | null;
|
|
158
159
|
rpi_candidate_available?: boolean;
|
|
159
160
|
rpi_candidate_unavailable_reason?: string | null;
|
|
161
|
+
rpi_candidate_readiness_status?: string | null;
|
|
160
162
|
}
|
|
161
163
|
export {};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"results.js","sourceRoot":"","sources":["../../src/@types/results.ts"],"names":[],"mappings":"","sourcesContent":["import type {Narrow, ServerNarrow} from \"./narrow\";\nimport type {SortBy} from \"./sortBy\";\n\nimport type { Facet} from \"./facets\";\nimport {AncestorCategory, RelatedCategory} from \"./categories\";\n\nimport {Product, ServerProduct} from \"./product\";\n\nexport interface PopularSearch {\n label: string\n type: \"p\"\n}\ninterface Base {\n narrow: Narrow,\n sortBy: SortBy,\n totalResults: number,\n page: number,\n totalPages: number,\n products: Product[],\n facets: Facet[],\n avoidTagPrefixes: string[],\n sort: SortBy,\n productIDS: string[],\n bannerHTML: string,\n bannerHTMLMobile: string,\n // ancestors: Ancestor[]\n}\n\nexport interface SearchResults extends Base {\n query: string,\n totalCMS: number,\n didYouMean?: string[],\n personalizedProductIds: number[],\n sessionProductIds: number[],\n resultsFor?: string,\n isRelatedResults?: boolean\n relatedSearch?: string[]\n}\n\nexport interface CategoryResults extends Base {\n categoryID: string,\n categoryName: string,\n personalizationRecencyLimit?: number,\n personalizedProductIds: number[],\n sessionProductIds: number[],\n relatedCategories: RelatedCategory[],\n}\n\nexport interface LandingPageResults extends Base {\n lpSlug: string,\n title: string,\n indexPage: number\n}\n\nexport type FacetRequired = 0 | 1 | 2\nexport type CategoryAncestor = [string, string, string]\n\nexport interface fullTextSearchProps {\n term: string\n storeID: number\n siteKey?:string\n uuid: string\n cdn?: number\n userToken: string,\n sessionStart: number,\n page?: number\n productsPerPage?: number\n sortBy?: SortBy\n narrowBy?: ServerNarrow[]\n facetRequired?: FacetRequired\n withAttributes?: boolean\n recent?: string\n searchWithinSearch?: string,\n segments?: string[]\n hasShopifyMarkets?: boolean\n disable_turbolinks?:boolean\n disable_strategies?:boolean\n disable_merchandising?:boolean\n disable_semantics?:boolean\n disable_merchandising_rules?:boolean\n disable_antonyms?:boolean\n custom_sort_settings?:{personalization_rank: number, creation_date: number, popularity: number, inventory: number}\n with_product_analytics?:boolean\n market_context?: string | null // Region code for market-specific filtering (e.g., \"US\", \"CA\", \"UK\")\n variation_id?: string | null // A/B test variation ID for reasoning/experiment tracking\n force_and?: boolean\n ps?: 'new' | 'returning' | null // Personalization segment for user segment coefficient preview (new/returning user)\n spv?: string | null // Session Product Views JSON for personalization preview (e.g., '{\"pid1\":ts,\"pid2\":ts}')\n personalization?: string | null // Comma-separated personalization types to enable (e.g., 'gender')\n session_token?: string // Session token override for AI Explainer (sent as st param)\n}\nexport interface ContextFilteringData {\n hidden: number[] // Product IDs hidden by context filtering\n unpublished: Record<number, string> // product_id -> region_code (e.g., \"US\", \"CA\")\n unsellable: Record<number, string> // product_id -> region_code (e.g., \"UK\", \"FR\")\n}\n\nexport interface fullTextSearchResponse {\n products: ServerProduct[]\n facets: Facet[]\n total_results: number\n facets_completed?: boolean\n sortBy?: SortBy,\n narrow: [string, string, string][]\n pop_products_no_results?: boolean\n page: number\n total_p: number\n personalized_products?: number[],\n ancestor_categories?: CategoryAncestor[]\n avoid_tag_prefixes?: string\n merch?: any\n}\nexport interface QueryUnderstanding {\n query: string\n has_ai_enrichment: boolean\n structured_attributes: Record<string, string[]>\n social_attributes: Record<string, string[]>\n intent_mapping: string[]\n}\n\nexport interface FullTextServerResponseAll extends fullTextSearchResponse{\n alternatives?: string[]\n term: string\n cms_number_found?: number\n within_search_results_for?: string\n banner_html: string\n banner_html_mobile: string\n turbolink?: string\n personalized_products?: number[]\n session_products?: number[]\n results_for?: string\n related_results?: boolean,\n ancestor_categories?: AncestorCategory[],\n related_search?: string[],\n hidden?:any,\n isNoResults?:any,\n totalResults?:any,\n hiddenProducts?:ServerProduct[],\n pageCount?:number,\n sort_by?: SortBy,\n id_list?:number[]\n antonyms?: Record<string, number[]>\n context?: ContextFilteringData // Context-based filtering data (market contexts)\n analytics?: {\n badges?: {\n winners?: Record<string, string> // Product ID -> tooltip message\n overexposed?: Record<string, string> // Product ID -> tooltip message\n new_arrivals?: string[]\n }\n key_hidden_winners?: string\n key_overexposed?: string\n }\n matching_sets?: Record<string, string> // Product ID -> set name\n group_strategy?: Record<string, string> // Product ID -> group name\n variety_strategy?: number[] // Product IDs affected by variety strategy\n query_understanding?: QueryUnderstanding\n reformulation_source?: string\n request_url?: string // Full URL with all params that was executed (for debugging)\n rpi_methodology_assigned?: string | null\n rpi_methodology_effective?: string | null\n rpi_methodology_fallback_reason?: string | null\n rpi_snapshot_computed_at?: string | null\n rpi_snapshot_covered_until?: string | null\n rpi_candidate_available?: boolean\n rpi_candidate_unavailable_reason?: string | null\n\n}\n"]}
|
|
1
|
+
{"version":3,"file":"results.js","sourceRoot":"","sources":["../../src/@types/results.ts"],"names":[],"mappings":"","sourcesContent":["import type {Narrow, ServerNarrow} from \"./narrow\";\nimport type {SortBy} from \"./sortBy\";\n\nimport type { Facet} from \"./facets\";\nimport {AncestorCategory, RelatedCategory} from \"./categories\";\n\nimport {Product, ServerProduct} from \"./product\";\n\nexport interface PopularSearch {\n label: string\n type: \"p\"\n}\ninterface Base {\n narrow: Narrow,\n sortBy: SortBy,\n totalResults: number,\n page: number,\n totalPages: number,\n products: Product[],\n facets: Facet[],\n avoidTagPrefixes: string[],\n sort: SortBy,\n productIDS: string[],\n bannerHTML: string,\n bannerHTMLMobile: string,\n // ancestors: Ancestor[]\n}\n\nexport interface SearchResults extends Base {\n query: string,\n totalCMS: number,\n didYouMean?: string[],\n personalizedProductIds: number[],\n sessionProductIds: number[],\n resultsFor?: string,\n isRelatedResults?: boolean\n relatedSearch?: string[]\n}\n\nexport interface CategoryResults extends Base {\n categoryID: string,\n categoryName: string,\n personalizationRecencyLimit?: number,\n personalizedProductIds: number[],\n sessionProductIds: number[],\n relatedCategories: RelatedCategory[],\n}\n\nexport interface LandingPageResults extends Base {\n lpSlug: string,\n title: string,\n indexPage: number\n}\n\nexport type FacetRequired = 0 | 1 | 2\nexport type CategoryAncestor = [string, string, string]\n\nexport interface fullTextSearchProps {\n term: string\n storeID: number\n siteKey?:string\n uuid: string\n cdn?: number\n userToken: string,\n sessionStart: number,\n page?: number\n productsPerPage?: number\n sortBy?: SortBy\n narrowBy?: ServerNarrow[]\n facetRequired?: FacetRequired\n withAttributes?: boolean\n recent?: string\n searchWithinSearch?: string,\n segments?: string[]\n hasShopifyMarkets?: boolean\n disable_turbolinks?:boolean\n disable_strategies?:boolean\n disable_merchandising?:boolean\n disable_semantics?:boolean\n disable_merchandising_rules?:boolean\n disable_antonyms?:boolean\n custom_sort_settings?:{personalization_rank: number, creation_date: number, popularity: number, inventory: number}\n with_product_analytics?:boolean\n market_context?: string | null // Region code for market-specific filtering (e.g., \"US\", \"CA\", \"UK\")\n variation_id?: string | null // A/B test variation ID for reasoning/experiment tracking\n force_and?: boolean\n ps?: 'new' | 'returning' | null // Personalization segment for user segment coefficient preview (new/returning user)\n spv?: string | null // Session Product Views JSON for personalization preview (e.g., '{\"pid1\":ts,\"pid2\":ts}')\n personalization?: string | null // Comma-separated personalization types to enable (e.g., 'gender')\n session_token?: string // Session token override for AI Explainer (sent as st param)\n}\nexport interface ContextFilteringData {\n hidden: number[] // Product IDs hidden by context filtering\n unpublished: Record<number, string> // product_id -> region_code (e.g., \"US\", \"CA\")\n unsellable: Record<number, string> // product_id -> region_code (e.g., \"UK\", \"FR\")\n}\n\nexport interface fullTextSearchResponse {\n products: ServerProduct[]\n facets: Facet[]\n total_results: number\n facets_completed?: boolean\n sortBy?: SortBy,\n narrow: [string, string, string][]\n pop_products_no_results?: boolean\n page: number\n total_p: number\n personalized_products?: number[],\n ancestor_categories?: CategoryAncestor[]\n avoid_tag_prefixes?: string\n merch?: any\n}\nexport interface QueryUnderstanding {\n query: string\n has_ai_enrichment: boolean\n structured_attributes: Record<string, string[]>\n social_attributes: Record<string, string[]>\n intent_mapping: string[]\n}\n\nexport interface FullTextServerResponseAll extends fullTextSearchResponse{\n alternatives?: string[]\n term: string\n cms_number_found?: number\n within_search_results_for?: string\n banner_html: string\n banner_html_mobile: string\n turbolink?: string\n personalized_products?: number[]\n session_products?: number[]\n results_for?: string\n related_results?: boolean,\n ancestor_categories?: AncestorCategory[],\n related_search?: string[],\n hidden?:any,\n isNoResults?:any,\n totalResults?:any,\n hiddenProducts?:ServerProduct[],\n pageCount?:number,\n sort_by?: SortBy,\n id_list?:number[]\n antonyms?: Record<string, number[]>\n context?: ContextFilteringData // Context-based filtering data (market contexts)\n analytics?: {\n badges?: {\n winners?: Record<string, string> // Product ID -> tooltip message\n overexposed?: Record<string, string> // Product ID -> tooltip message\n new_arrivals?: string[]\n }\n key_hidden_winners?: string\n key_overexposed?: string\n }\n matching_sets?: Record<string, string> // Product ID -> set name\n group_strategy?: Record<string, string> // Product ID -> group name\n variety_strategy?: number[] // Product IDs affected by variety strategy\n query_understanding?: QueryUnderstanding\n reformulation_source?: string\n request_url?: string // Full URL with all params that was executed (for debugging)\n rpi_methodology_assigned?: string | null\n rpi_methodology_preview_requested?: boolean\n rpi_methodology_effective?: string | null\n rpi_methodology_fallback_reason?: string | null\n rpi_snapshot_computed_at?: string | null\n rpi_snapshot_covered_until?: string | null\n rpi_candidate_available?: boolean\n rpi_candidate_unavailable_reason?: string | null\n rpi_candidate_readiness_status?: string | null\n\n}\n"]}
|
|
@@ -152,12 +152,14 @@ export declare function fastStateReducer(state: FastStateProps, action: FastStat
|
|
|
152
152
|
reformulation_source?: string | undefined;
|
|
153
153
|
request_url?: string | undefined;
|
|
154
154
|
rpi_methodology_assigned?: string | null | undefined;
|
|
155
|
+
rpi_methodology_preview_requested?: boolean | undefined;
|
|
155
156
|
rpi_methodology_effective?: string | null | undefined;
|
|
156
157
|
rpi_methodology_fallback_reason?: string | null | undefined;
|
|
157
158
|
rpi_snapshot_computed_at?: string | null | undefined;
|
|
158
159
|
rpi_snapshot_covered_until?: string | null | undefined;
|
|
159
160
|
rpi_candidate_available?: boolean | undefined;
|
|
160
161
|
rpi_candidate_unavailable_reason?: string | null | undefined;
|
|
162
|
+
rpi_candidate_readiness_status?: string | null | undefined;
|
|
161
163
|
facets: import("../../@types/facets").Facet[];
|
|
162
164
|
total_results: number;
|
|
163
165
|
facets_completed?: boolean | undefined;
|
|
@@ -208,12 +210,14 @@ export declare function fastStateReducer(state: FastStateProps, action: FastStat
|
|
|
208
210
|
reformulation_source?: string | undefined;
|
|
209
211
|
request_url?: string | undefined;
|
|
210
212
|
rpi_methodology_assigned?: string | null | undefined;
|
|
213
|
+
rpi_methodology_preview_requested?: boolean | undefined;
|
|
211
214
|
rpi_methodology_effective?: string | null | undefined;
|
|
212
215
|
rpi_methodology_fallback_reason?: string | null | undefined;
|
|
213
216
|
rpi_snapshot_computed_at?: string | null | undefined;
|
|
214
217
|
rpi_snapshot_covered_until?: string | null | undefined;
|
|
215
218
|
rpi_candidate_available?: boolean | undefined;
|
|
216
219
|
rpi_candidate_unavailable_reason?: string | null | undefined;
|
|
220
|
+
rpi_candidate_readiness_status?: string | null | undefined;
|
|
217
221
|
} | {
|
|
218
222
|
products: import("../../@types/product").ServerProduct[];
|
|
219
223
|
alternatives?: string[] | undefined;
|
|
@@ -254,12 +258,14 @@ export declare function fastStateReducer(state: FastStateProps, action: FastStat
|
|
|
254
258
|
reformulation_source?: string | undefined;
|
|
255
259
|
request_url?: string | undefined;
|
|
256
260
|
rpi_methodology_assigned?: string | null | undefined;
|
|
261
|
+
rpi_methodology_preview_requested?: boolean | undefined;
|
|
257
262
|
rpi_methodology_effective?: string | null | undefined;
|
|
258
263
|
rpi_methodology_fallback_reason?: string | null | undefined;
|
|
259
264
|
rpi_snapshot_computed_at?: string | null | undefined;
|
|
260
265
|
rpi_snapshot_covered_until?: string | null | undefined;
|
|
261
266
|
rpi_candidate_available?: boolean | undefined;
|
|
262
267
|
rpi_candidate_unavailable_reason?: string | null | undefined;
|
|
268
|
+
rpi_candidate_readiness_status?: string | null | undefined;
|
|
263
269
|
facets: import("../../@types/facets").Facet[];
|
|
264
270
|
total_results: number;
|
|
265
271
|
facets_completed?: boolean | undefined;
|
|
@@ -310,12 +316,14 @@ export declare function fastStateReducer(state: FastStateProps, action: FastStat
|
|
|
310
316
|
reformulation_source?: string | undefined;
|
|
311
317
|
request_url?: string | undefined;
|
|
312
318
|
rpi_methodology_assigned?: string | null | undefined;
|
|
319
|
+
rpi_methodology_preview_requested?: boolean | undefined;
|
|
313
320
|
rpi_methodology_effective?: string | null | undefined;
|
|
314
321
|
rpi_methodology_fallback_reason?: string | null | undefined;
|
|
315
322
|
rpi_snapshot_computed_at?: string | null | undefined;
|
|
316
323
|
rpi_snapshot_covered_until?: string | null | undefined;
|
|
317
324
|
rpi_candidate_available?: boolean | undefined;
|
|
318
325
|
rpi_candidate_unavailable_reason?: string | null | undefined;
|
|
326
|
+
rpi_candidate_readiness_status?: string | null | undefined;
|
|
319
327
|
alternatives?: string[] | undefined;
|
|
320
328
|
term: string;
|
|
321
329
|
cms_number_found?: number | undefined;
|
|
@@ -372,12 +380,14 @@ export declare function fastStateReducer(state: FastStateProps, action: FastStat
|
|
|
372
380
|
reformulation_source?: string | undefined;
|
|
373
381
|
request_url?: string | undefined;
|
|
374
382
|
rpi_methodology_assigned?: string | null | undefined;
|
|
383
|
+
rpi_methodology_preview_requested?: boolean | undefined;
|
|
375
384
|
rpi_methodology_effective?: string | null | undefined;
|
|
376
385
|
rpi_methodology_fallback_reason?: string | null | undefined;
|
|
377
386
|
rpi_snapshot_computed_at?: string | null | undefined;
|
|
378
387
|
rpi_snapshot_covered_until?: string | null | undefined;
|
|
379
388
|
rpi_candidate_available?: boolean | undefined;
|
|
380
389
|
rpi_candidate_unavailable_reason?: string | null | undefined;
|
|
390
|
+
rpi_candidate_readiness_status?: string | null | undefined;
|
|
381
391
|
facets: import("../../@types/facets").Facet[];
|
|
382
392
|
total_results: number;
|
|
383
393
|
facets_completed?: boolean | undefined;
|
|
@@ -434,12 +444,14 @@ export declare function fastStateReducer(state: FastStateProps, action: FastStat
|
|
|
434
444
|
reformulation_source?: string | undefined;
|
|
435
445
|
request_url?: string | undefined;
|
|
436
446
|
rpi_methodology_assigned?: string | null | undefined;
|
|
447
|
+
rpi_methodology_preview_requested?: boolean | undefined;
|
|
437
448
|
rpi_methodology_effective?: string | null | undefined;
|
|
438
449
|
rpi_methodology_fallback_reason?: string | null | undefined;
|
|
439
450
|
rpi_snapshot_computed_at?: string | null | undefined;
|
|
440
451
|
rpi_snapshot_covered_until?: string | null | undefined;
|
|
441
452
|
rpi_candidate_available?: boolean | undefined;
|
|
442
453
|
rpi_candidate_unavailable_reason?: string | null | undefined;
|
|
454
|
+
rpi_candidate_readiness_status?: string | null | undefined;
|
|
443
455
|
} | {
|
|
444
456
|
products: import("../../@types/product").ServerProduct[];
|
|
445
457
|
alternatives?: string[] | undefined;
|
|
@@ -480,12 +492,14 @@ export declare function fastStateReducer(state: FastStateProps, action: FastStat
|
|
|
480
492
|
reformulation_source?: string | undefined;
|
|
481
493
|
request_url?: string | undefined;
|
|
482
494
|
rpi_methodology_assigned?: string | null | undefined;
|
|
495
|
+
rpi_methodology_preview_requested?: boolean | undefined;
|
|
483
496
|
rpi_methodology_effective?: string | null | undefined;
|
|
484
497
|
rpi_methodology_fallback_reason?: string | null | undefined;
|
|
485
498
|
rpi_snapshot_computed_at?: string | null | undefined;
|
|
486
499
|
rpi_snapshot_covered_until?: string | null | undefined;
|
|
487
500
|
rpi_candidate_available?: boolean | undefined;
|
|
488
501
|
rpi_candidate_unavailable_reason?: string | null | undefined;
|
|
502
|
+
rpi_candidate_readiness_status?: string | null | undefined;
|
|
489
503
|
facets: import("../../@types/facets").Facet[];
|
|
490
504
|
total_results: number;
|
|
491
505
|
facets_completed?: boolean | undefined;
|
|
@@ -539,12 +553,14 @@ export declare function fastStateReducer(state: FastStateProps, action: FastStat
|
|
|
539
553
|
reformulation_source?: string | undefined;
|
|
540
554
|
request_url?: string | undefined;
|
|
541
555
|
rpi_methodology_assigned?: string | null | undefined;
|
|
556
|
+
rpi_methodology_preview_requested?: boolean | undefined;
|
|
542
557
|
rpi_methodology_effective?: string | null | undefined;
|
|
543
558
|
rpi_methodology_fallback_reason?: string | null | undefined;
|
|
544
559
|
rpi_snapshot_computed_at?: string | null | undefined;
|
|
545
560
|
rpi_snapshot_covered_until?: string | null | undefined;
|
|
546
561
|
rpi_candidate_available?: boolean | undefined;
|
|
547
562
|
rpi_candidate_unavailable_reason?: string | null | undefined;
|
|
563
|
+
rpi_candidate_readiness_status?: string | null | undefined;
|
|
548
564
|
auto_facets?: boolean | undefined;
|
|
549
565
|
isp_quick_view_mode?: number | undefined;
|
|
550
566
|
term: string;
|