From 39b85101d3ab04f560795080eac464bcbb2d72bd Mon Sep 17 00:00:00 2001 From: Kuojian Lu Date: Tue, 10 Dec 2024 15:22:18 +0800 Subject: [PATCH] fix: custom copilot ClientCitation error --- .../src/app/customSayCommand.js | 2 +- .../js/custom-copilot-rag-customize/src/app/customSayCommand.js | 2 +- .../custom-copilot-rag-microsoft365/src/app/customSayCommand.js | 2 +- .../src/app/customSayCommand.ts | 2 +- .../ts/custom-copilot-rag-customize/src/app/customSayCommand.ts | 2 +- .../custom-copilot-rag-microsoft365/src/app/customSayCommand.ts | 2 +- 6 files changed, 6 insertions(+), 6 deletions(-) diff --git a/templates/js/custom-copilot-rag-azure-ai-search/src/app/customSayCommand.js b/templates/js/custom-copilot-rag-azure-ai-search/src/app/customSayCommand.js index 496191838a..dbbcecfd92 100644 --- a/templates/js/custom-copilot-rag-azure-ai-search/src/app/customSayCommand.js +++ b/templates/js/custom-copilot-rag-azure-ai-search/src/app/customSayCommand.js @@ -37,7 +37,7 @@ function sayCommand(feedbackLoopEnabled = false) { if (contentItem.citationTitle && contentItem.citationTitle.length > 0) { const clientCitation = { "@type": "Claim", - position: `${position}`, + position: position, appearance: { "@type": "DigitalDocument", name: contentItem.citationTitle || `Document #${position}`, diff --git a/templates/js/custom-copilot-rag-customize/src/app/customSayCommand.js b/templates/js/custom-copilot-rag-customize/src/app/customSayCommand.js index 496191838a..dbbcecfd92 100644 --- a/templates/js/custom-copilot-rag-customize/src/app/customSayCommand.js +++ b/templates/js/custom-copilot-rag-customize/src/app/customSayCommand.js @@ -37,7 +37,7 @@ function sayCommand(feedbackLoopEnabled = false) { if (contentItem.citationTitle && contentItem.citationTitle.length > 0) { const clientCitation = { "@type": "Claim", - position: `${position}`, + position: position, appearance: { "@type": "DigitalDocument", name: contentItem.citationTitle || `Document #${position}`, diff --git a/templates/js/custom-copilot-rag-microsoft365/src/app/customSayCommand.js b/templates/js/custom-copilot-rag-microsoft365/src/app/customSayCommand.js index 496191838a..dbbcecfd92 100644 --- a/templates/js/custom-copilot-rag-microsoft365/src/app/customSayCommand.js +++ b/templates/js/custom-copilot-rag-microsoft365/src/app/customSayCommand.js @@ -37,7 +37,7 @@ function sayCommand(feedbackLoopEnabled = false) { if (contentItem.citationTitle && contentItem.citationTitle.length > 0) { const clientCitation = { "@type": "Claim", - position: `${position}`, + position: position, appearance: { "@type": "DigitalDocument", name: contentItem.citationTitle || `Document #${position}`, diff --git a/templates/ts/custom-copilot-rag-azure-ai-search/src/app/customSayCommand.ts b/templates/ts/custom-copilot-rag-azure-ai-search/src/app/customSayCommand.ts index 7357a0bf38..dbda5195ee 100644 --- a/templates/ts/custom-copilot-rag-azure-ai-search/src/app/customSayCommand.ts +++ b/templates/ts/custom-copilot-rag-azure-ai-search/src/app/customSayCommand.ts @@ -41,7 +41,7 @@ export function sayCommand(feedbackLoopEna if (contentItem.citationTitle && contentItem.citationTitle.length > 0) { const clientCitation: ClientCitation = { "@type": "Claim", - position: `${position}`, + position: position, appearance: { "@type": "DigitalDocument", name: contentItem.citationTitle || `Document #${position}`, diff --git a/templates/ts/custom-copilot-rag-customize/src/app/customSayCommand.ts b/templates/ts/custom-copilot-rag-customize/src/app/customSayCommand.ts index 7357a0bf38..dbda5195ee 100644 --- a/templates/ts/custom-copilot-rag-customize/src/app/customSayCommand.ts +++ b/templates/ts/custom-copilot-rag-customize/src/app/customSayCommand.ts @@ -41,7 +41,7 @@ export function sayCommand(feedbackLoopEna if (contentItem.citationTitle && contentItem.citationTitle.length > 0) { const clientCitation: ClientCitation = { "@type": "Claim", - position: `${position}`, + position: position, appearance: { "@type": "DigitalDocument", name: contentItem.citationTitle || `Document #${position}`, diff --git a/templates/ts/custom-copilot-rag-microsoft365/src/app/customSayCommand.ts b/templates/ts/custom-copilot-rag-microsoft365/src/app/customSayCommand.ts index 7357a0bf38..dbda5195ee 100644 --- a/templates/ts/custom-copilot-rag-microsoft365/src/app/customSayCommand.ts +++ b/templates/ts/custom-copilot-rag-microsoft365/src/app/customSayCommand.ts @@ -41,7 +41,7 @@ export function sayCommand(feedbackLoopEna if (contentItem.citationTitle && contentItem.citationTitle.length > 0) { const clientCitation: ClientCitation = { "@type": "Claim", - position: `${position}`, + position: position, appearance: { "@type": "DigitalDocument", name: contentItem.citationTitle || `Document #${position}`,