{"id":4097,"date":"2026-04-08T15:22:30","date_gmt":"2026-04-08T15:22:30","guid":{"rendered":"https:\/\/developers-test.one2five.digital\/?post_type=docs&#038;p=4097"},"modified":"2026-05-12T09:14:55","modified_gmt":"2026-05-12T09:14:55","slug":"ai-summary","status":"publish","type":"docs","link":"https:\/\/developers-test.one2five.digital\/?docs=ai-summary","title":{"rendered":"AI Summary"},"content":{"rendered":"\n<h4 class=\"wp-block-heading\"><mark style=\"background-color:rgba(0, 0, 0, 0)\" class=\"has-inline-color has-accent-color\">Overview<\/mark><\/h4>\n\n\n\n<p class=\"wp-block-paragraph\">This feature creates <strong>AI-powered summaries of product reviews<\/strong> for specific markets, optimizing API usage and token consumption by only processing <strong>incremental review changes<\/strong> instead of re-evaluating all reviews repeatedly.<\/p>\n\n\n\n<h4 class=\"wp-block-heading\"><mark style=\"background-color:rgba(0, 0, 0, 0)\" class=\"has-inline-color has-accent-color\">Data Hierarchy<\/mark><\/h4>\n\n\n\n<p class=\"wp-block-paragraph\">Market<br>\u2514\u2500\u2500 Product<br>                \u2514\u2500\u2500 Reviews<\/p>\n\n\n\n<div class=\"wp-block-columns is-layout-flex wp-container-core-columns-is-layout-8f761849 wp-block-columns-is-layout-flex\">\n<div class=\"wp-block-column is-layout-flow wp-block-column-is-layout-flow\" style=\"flex-basis:100%\">\n<figure class=\"wp-block-table\"><table class=\"has-fixed-layout\"><tbody><tr><td>Property name<\/td><td>Description<\/td><td>Default Value<\/td><\/tr><tr><td>AI Summaries Generation<\/td><td>Toggle to enable or disable summary generation for the market<\/td><td>false<\/td><\/tr><tr><td>AI Summaries Distribution<\/td><td>Toggle to enable or disable the inclusion of summaries in the standard client feed XML file for the specified market<\/td><td>false<\/td><\/tr><tr><td>active.ai.model<\/td><td>Active ai model in use<\/td><td>GPT (can be set to &#8216;COHERE&#8217;, &#8216;MISTRAL&#8217;, &#8216;DEEPSEEK&#8217;)<\/td><\/tr><tr><td>product.review.size<\/td><td>The number of least reviews required for the product to generate a summary for<\/td><td>8<\/td><\/tr><tr><td>ai.summary.cron<\/td><td>cron expression<\/td><td>0 0 13 *\/3 * ?<\/td><\/tr><\/tbody><\/table><\/figure>\n<\/div>\n<\/div>\n\n\n\n<h4 class=\"wp-block-heading\"><mark style=\"background-color:rgba(0, 0, 0, 0)\" class=\"has-inline-color has-accent-color\">Workflow<\/mark><\/h4>\n\n\n\n<p class=\"wp-block-paragraph\">High level workflow<br><br>The system generates AI-based summaries of product reviews at the market level, where each market contains multiple products and each product has multiple reviews. A scheduled cron job runs every three days and processes only those markets where the AI summary feature is enabled. For each product, the system fetches all approved reviews and generates a summary while maintaining a state of which reviews have already been processed. In subsequent runs, instead of reprocessing all reviews, the system identifies only new or previously unprocessed reviews and generates incremental summaries for them. These new summaries are then merged with the existing summary, ensuring that only delta changes are handled. This approach significantly reduces API calls, token usage, and overall billing cost while keeping the summaries up to date efficiently.<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>Cron Trigger\n   \u2193\nFetch Enabled Markets\n   \u2193\nFor Each Market\n   \u2193\nFetch Products\n   \u2193\nFor Each Product\n   \u2193\nFetch Incremental Reviews\n   \u2193\nGenerate AI Summary (Partial)\n   \u2193\nMerge with Existing Summary\n   \u2193\nUpdate State of Review<\/code><\/pre>\n\n\n\n<h4 class=\"wp-block-heading\"><mark style=\"background-color:rgba(0, 0, 0, 0)\" class=\"has-inline-color has-accent-color\">Sample Summary<\/mark><\/h4>\n\n\n\n<pre class=\"wp-block-code\"><code>{\n  \"overall_sentiment\": \"neutral\",\n  \"summary\": \"The washing machine has received mixed feedback from customers. Many appreciate its quiet operation, ease of use, effective wash cycles, and range of features. However, concerns about durability, reliability, lengthy cycle times, and minor design issues have also been noted.\",\n  \"top_positives\": &#91;\n    \"Quiet operation\",\n    \"Easy to use with a variety of programs\",\n    \"Effective wash cycles\",\n    \"Good build quality with useful features\",\n    \"Eco-friendly settings\"\n  ],\n  \"top_negatives\": &#91;\n    \"Durability issues\",\n    \"Mechanical failures reported\",\n    \"Long cycle times\",\n    \"Problems with washing wool garments\",\n    \"Installation issues leading to water leakage\"\n  ]\n}<\/code><\/pre>\n\n\n\n<h3 class=\"wp-block-heading\">AI Summary API<\/h3>\n\n\n\n<p class=\"wp-block-paragraph\">The AI Summary API is a lightweight external API designed to programmatically retrieve pre-generated AI Review Summaries for products. It allows partners, retailers, and clients to consume AI-generated review insights without retrieving the full review payload from the Display Reviews API.<\/p>\n\n\n\n<h4 class=\"wp-block-heading\"><mark style=\"background-color:rgba(0, 0, 0, 0)\" class=\"has-inline-color has-accent-color\">Capabilities:<\/mark><\/h4>\n\n\n\n<p class=\"wp-block-paragraph\"><strong>AI Review Summary Retrieval:<\/strong><br>The API provides access to pre-generated AI Review Summaries for products using the product external identifier and market display code.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\"><strong>Overall Sentiment:<\/strong><br>Returns the overall customer sentiment derived from approved product reviews.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\"><strong>AI Generated Summary:<\/strong><br>Provides a concise AI-generated summary based on customer review content.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\"><strong>Top Positives &amp; Negatives:<\/strong><br>Returns the most commonly mentioned positive and negative aspects from customer reviews.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\"><strong>Market Specific Summaries:<\/strong><br>Summaries are returned based on the requested market and language using the displayCode parameter.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\"><strong>Lightweight Response Structure:<\/strong><br>The API returns only AI Summary related information, making it suitable for external integrations and partner consumption.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\"><strong>Read-Only API:<\/strong><br>The API serves only pre-generated summaries stored in the database. No real-time or on-demand AI generation is triggered during API requests.<\/p>\n\n\n\n<hr class=\"wp-block-separator has-alpha-channel-opacity\"\/>\n\n\n\n<h4 class=\"wp-block-heading\"><mark style=\"background-color:rgba(0, 0, 0, 0)\" class=\"has-inline-color has-accent-color\">Limitations:<\/mark><\/h4>\n\n\n\n<p class=\"wp-block-paragraph\"><strong>Passkey Validation:<\/strong><br>The API requires a valid passKey for authentication. Requests with missing, invalid, or expired passkeys are rejected.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\"><strong>Distribution Control:<\/strong><br>If AI Summary distribution is disabled for the requested market, the API returns an acknowledgement message in the response: \u201cAI Summaries distribution is not enabled for this market.\u201d<\/p>\n\n\n\n<p class=\"wp-block-paragraph\"><strong>Pre-Generated Data Only:<\/strong><br>The API does not generate summaries dynamically. Products without generated summaries return empty or null summary fields.<\/p>\n\n\n\n<hr class=\"wp-block-separator has-alpha-channel-opacity\"\/>\n\n\n\n<h4 class=\"wp-block-heading\"><mark style=\"background-color:rgba(0, 0, 0, 0)\" class=\"has-inline-color has-accent-color\">Base URL<\/mark><\/h4>\n\n\n\n<p class=\"wp-block-paragraph\"><code>&lt;base_url&gt;\/api\/ai-summary\/v1\/external<\/code><\/p>\n\n\n\n<figure class=\"wp-block-table\"><table class=\"has-fixed-layout\"><thead><tr><th>Environment<\/th><th>URL<\/th><\/tr><\/thead><tbody><tr><td>Test<\/td><td><a href=\"https:\/\/test.one2five.digital\">https:\/\/test.one2five.digital<\/a><\/td><\/tr><tr><td>Production<\/td><td><a href=\"https:\/\/app.one2five.digital\">https:\/\/app.one2five.digital<\/a><\/td><\/tr><\/tbody><\/table><\/figure>\n\n\n\n<hr class=\"wp-block-separator has-alpha-channel-opacity\"\/>\n\n\n\n<h3 class=\"wp-block-heading\"><mark style=\"background-color:rgba(0, 0, 0, 0)\" class=\"has-inline-color has-accent-color\">API Details<\/mark><\/h3>\n\n\n\n<figure class=\"wp-block-table\"><table class=\"has-fixed-layout\"><thead><tr><th>Property<\/th><th>Value<\/th><\/tr><\/thead><tbody><tr><td>Title<\/td><td>AI Summary API<\/td><\/tr><tr><td>Overview<\/td><td>Consume this API to retrieve pre-generated AI Review Summaries for a product using productExternalId and displayCode.<\/td><\/tr><tr><td>URL<\/td><td><a href=\"https:\/\/developers-test.one2five.digital\/?docs=get-review-summaries\" data-type=\"link\" data-id=\"https:\/\/developers-test.one2five.digital\/?docs=get-review-summaries\">\/api\/ai-summary\/v1\/external<\/a><\/td><\/tr><tr><td>Host<\/td><td><code>&lt;base_url&gt;<\/code><\/td><\/tr><tr><td>Method<\/td><td>HTTP GET<\/td><\/tr><tr><td>Response-Type<\/td><td>json<\/td><\/tr><\/tbody><\/table><\/figure>\n\n\n\n<hr class=\"wp-block-separator has-alpha-channel-opacity\"\/>\n\n\n\n<h4 class=\"wp-block-heading\"><mark style=\"background-color:rgba(0, 0, 0, 0)\" class=\"has-inline-color has-accent-color\">Success Response<\/mark><\/h4>\n\n\n\n<pre class=\"wp-block-code\"><code>{\n  \"aiSummary\": {\n    \"productExternalId\": \"WM12345\",\n    \"displayCode\": \"aeg-en_gb\",\n    \"overall_sentiment\": \"positive\",\n    \"summary\": \"Customers are highly satisfied with the vacuum cleaner's battery life, suction performance, and ease of use.\",\n    \"top_positives\": &#91;\n      \"Strong suction performance\",\n      \"Long battery life\",\n      \"Easy to use\"\n    ],\n    \"top_negatives\": &#91;\n      \"Small dust container\",\n      \"Charging time could be improved\"\n    ]\n  },\n  \"hasErrors\": false,\n  \"errors\": &#91;]\n}<\/code><\/pre>\n\n\n\n<hr class=\"wp-block-separator has-alpha-channel-opacity\"\/>\n\n\n\n<h4 class=\"wp-block-heading\"><mark style=\"background-color:rgba(0, 0, 0, 0)\" class=\"has-inline-color has-accent-color\">Empty Summary Response<\/mark><\/h4>\n\n\n\n<pre class=\"wp-block-code\"><code>{\n  \"aiSummary\": {\n    \"productExternalId\": \"WM12345\",\n    \"displayCode\": \"aeg-en_gb\",\n    \"overall_sentiment\": null,\n    \"summary\": null,\n    \"top_positives\": &#91;],\n    \"top_negatives\": &#91;]\n  },\n  \"hasErrors\": false,\n  \"errors\": &#91;]\n}<\/code><\/pre>\n\n\n\n<hr class=\"wp-block-separator has-alpha-channel-opacity\"\/>\n\n\n\n<h4 class=\"wp-block-heading\"><mark style=\"background-color:rgba(0, 0, 0, 0)\" class=\"has-inline-color has-accent-color\">Error Response<\/mark><\/h4>\n\n\n\n<pre class=\"wp-block-code\"><code>{<br>  \"hasErrors\": true,<br>  \"errors\": &#91;<br>    {<br>      \"Code\": \"ERROR_PARAM_INVALID_API_KEY\",<br>      \"Message\": \"The passKey provided is invalid.\"<br>    }<br>  ]<br>}<\/code><\/pre>\n\n\n\n<hr class=\"wp-block-separator has-alpha-channel-opacity\"\/>\n\n\n\n<h4 class=\"wp-block-heading\"><mark style=\"background-color:rgba(0, 0, 0, 0)\" class=\"has-inline-color has-accent-color\">Request Parameters<\/mark><\/h4>\n\n\n\n<figure class=\"wp-block-table\"><table class=\"has-fixed-layout\"><thead><tr><th>Parameter Name<\/th><th>Description<\/th><th>Additional Info<\/th><th>Example<\/th><\/tr><\/thead><tbody><tr><td>productExternalId<\/td><td>External product identifier<\/td><td>Mandatory<\/td><td>WM12345<\/td><\/tr><tr><td>passKey<\/td><td>API key provided to consuming client\/market<\/td><td>Mandatory<\/td><td>aa60c6d8-148f-4ca0-93d6-0eee26f78942<\/td><\/tr><tr><td>displayCode<\/td><td>Market display code representing company, language, and country<\/td><td>Mandatory<\/td><td>aeg-en_gb<\/td><\/tr><\/tbody><\/table><\/figure>\n\n\n\n<hr class=\"wp-block-separator has-alpha-channel-opacity\"\/>\n\n\n\n<h4 class=\"wp-block-heading\"><mark style=\"background-color:rgba(0, 0, 0, 0)\" class=\"has-inline-color has-accent-color\">Response Parameters<\/mark><\/h4>\n\n\n\n<figure class=\"wp-block-table\"><table class=\"has-fixed-layout\"><thead><tr><th>Parameter Name<\/th><th>Description<\/th><\/tr><\/thead><tbody><tr><td>hasErrors<\/td><td>&#8216;true&#8217; if response contains errors, otherwise &#8216;false&#8217;<\/td><\/tr><tr><td>errors<\/td><td>Contains error code and message if present<\/td><\/tr><tr><td>aiSummary<\/td><td>Contains AI generated review summary data<\/td><\/tr><tr><td>productExternalId<\/td><td>External product identifier<\/td><\/tr><tr><td>displayCode<\/td><td>Requested market display code<\/td><\/tr><tr><td>overall_sentiment<\/td><td>Overall sentiment derived from customer reviews<\/td><\/tr><tr><td>summary<\/td><td>AI generated review summary<\/td><\/tr><tr><td>top_positives<\/td><td>Array of commonly mentioned positive aspects<\/td><\/tr><tr><td>top_negatives<\/td><td>Array of commonly mentioned negative aspects<\/td><\/tr><\/tbody><\/table><\/figure>\n","protected":false},"excerpt":{"rendered":"<p>Overview This feature creates AI-powered summaries of product reviews for specific markets, optimizing API usage and token consumption by only processing incremental review changes instead of re-evaluating all reviews repeatedly. Data Hierarchy Market\u2514\u2500\u2500 Product \u2514\u2500\u2500 Reviews Property name Description Default Value AI Summaries Generation Toggle to enable or disable summary generation for the market false &#8230; <a title=\"AI Summary\" class=\"read-more\" href=\"https:\/\/developers-test.one2five.digital\/?docs=ai-summary\" aria-label=\"Read more about AI Summary\">Read more<\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"closed","template":"","meta":{"_eb_attr":"","inline_featured_image":false,"footnotes":""},"doc_category":[11],"doc_tag":[],"class_list":["post-4097","docs","type-docs","status-publish","hentry","doc_category-knowledge-hub"],"jetpack_sharing_enabled":true,"_links":{"self":[{"href":"https:\/\/developers-test.one2five.digital\/index.php?rest_route=\/wp\/v2\/docs\/4097","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/developers-test.one2five.digital\/index.php?rest_route=\/wp\/v2\/docs"}],"about":[{"href":"https:\/\/developers-test.one2five.digital\/index.php?rest_route=\/wp\/v2\/types\/docs"}],"author":[{"embeddable":true,"href":"https:\/\/developers-test.one2five.digital\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/developers-test.one2five.digital\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=4097"}],"version-history":[{"count":19,"href":"https:\/\/developers-test.one2five.digital\/index.php?rest_route=\/wp\/v2\/docs\/4097\/revisions"}],"predecessor-version":[{"id":4176,"href":"https:\/\/developers-test.one2five.digital\/index.php?rest_route=\/wp\/v2\/docs\/4097\/revisions\/4176"}],"wp:attachment":[{"href":"https:\/\/developers-test.one2five.digital\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=4097"}],"wp:term":[{"taxonomy":"doc_category","embeddable":true,"href":"https:\/\/developers-test.one2five.digital\/index.php?rest_route=%2Fwp%2Fv2%2Fdoc_category&post=4097"},{"taxonomy":"doc_tag","embeddable":true,"href":"https:\/\/developers-test.one2five.digital\/index.php?rest_route=%2Fwp%2Fv2%2Fdoc_tag&post=4097"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}