使用 Power BI 服務或 Power BI Desktop 建立 Cortana 的自訂回應頁面Use Power BI service or Power BI Desktop to create a custom Answer Page for Cortana

您可以使用 Power BI 的完整功能,建立稱為「Cortana 回應頁面」 (有時稱為「Cortana 回應卡」)、專為回答 Cortana 問題所設計的特殊報表頁面。Use the full capabilities of Power BI to create special report pages, called Cortana answer pages (and sometimes called "Cortana answer cards") designed specifically to answer Cortana questions.

重要

如果您試用 Cortana 和 Power BI 儀表板 Preview,則可以略過本文的其餘部分。If you are trying out the Cortana and Power BI dashboard preview, you can skip the rest of this article. 不需要進行設定,Cortana 就可以搜尋 Power BI 儀表板。There are no setup requirements for Cortana to be able to search your Power BI dashboards.

開始之前Before you begin

我們有 4 份文件引導您設定和使用 Cortana for Power BI。We have 4 documents that guide you through setting up and using Cortana for Power BI. 如果您還沒有,建議從閱讀文章 1 開始。If you haven't already, we recommend that you start by reading article 1. 文章 2 描述一些您必須採取才能開始使用 Cortana 回應頁面的步驟,因此特別重要。And article 2 is especially important because it describes some steps you'll need to take before you can begin using Cortana answer pages.

文章 1了解 Cortana 和 Power BI 如何搭配運作Article 1 Learn how Cortana and Power BI work together

文章 2針對搜尋 Power BI 報表:啟用 Cortana - Power BI - Windows 整合Article 2: For searching Power BI reports: Enable the Cortana - Power BI - Windows integration

文章 3:本文章Article 3: This article

文章 4對問題進行疑難排解Article 4: Troubleshoot issues

建立專為 Cortana 設計的 Cortana 回應頁面Create a Cortana answer page designed specifically for Cortana

報表中的「Cortana 回應頁面」會特別為 Cortana 調整大小,讓 Cortana 可以在畫面中將其顯示為問題的答案。A Cortana answer page in a report is sized specifically for Cortana so that Cortana can display it in-screen as an answer to a question. 建立 Cortana 的回應頁面:To create an answer page for Cortana:

  1. 建議從空白報表頁面開始。We recommend starting with a blank report page.
  2. 在 [視覺效果] 窗格中,選取油漆滾筒圖示,然後選擇 [頁面大小] > [類型] > [Cortana]。In the Visualizations pane, select the paint roller icon and choose Page Size > Type > Cortana.

  3. 建立您要在 Cortana 中顯示的一個或一組視覺效果,以回覆特定問題 (或問題集)。Create a visual or a set of visuals that you want to appear in Cortana in response to a particular question (or set of questions).
  4. 確定所有視覺效果都在頁面框線內。Ensure that all visuals fit within the page borders. (選擇性) 修改顯示設定、資料標籤、色彩和背景。Optionally, modify display settings, data labels, colors, and backgrounds.

  5. 命名頁面並新增替代名稱。Name the page and add alternate names. Cortana 會使用這些名稱來搜尋結果。Cortana uses these names when it searches for results. 在 [視覺效果] 窗格中,選取畫刷圖示,然後選擇 [頁面資訊]。In the Visualizations pane, select the paintbrush icon and choose Page Information. 將滑桿移至 [開啟],啟用此視覺效果的問與答。Enable Q&A for this visual by moving the slider to On.

    提示

    若要改善結果,請避免使用同時也是資料行名稱的文字。To improve results, avoid using words that are also column names.

  6. (選擇性) 如果您的報告包含頁面層級篩選,可以設定 [只可單選]。Optionally, if your report has page level filters, you may want to set Require single selection. 只有指定問題中的唯一篩選項目時,Cortana 才會將這個報表顯示為答案。Cortana will only display this report as an answer if one, and only one, of the filter items is specified in the question. 在 [篩選條件] 窗格底部可以找到 [只可單選]。Require single selection can be found at the bottom of the Filters pane.

    注意

    您不必設定 [只可單選] 也可要求 Cortana 顯示有頁面層級篩選的報表。You don't have to set Require single selection to ask Cortana to display a report with page level filters. 例如「顯示 Charlotte Lindseys 的業績」會顯示回應頁面,不論 [只可單選] 設定為何。For example “show sales for Charlotte Lindseys” will display the answer page regardless of the Require Single Selection setting.

    例如,如果您詢問 Cortana:For example, if you ask Cortana:

    • 「依店家名稱顯示銷售量」,則不會顯示這個回應頁面,因為您未在必要的頁面層級篩選中包含任何項目。"show sales by store name," this answer page will not appear because you did not include any of the items in the required page level filter.
    • 「顯示 Cary Lindseys 和 Charlotte Lindseys 的銷售量」,則不會顯示這個回應頁面,因為您已從必要的頁面層級篩選指定多個項目。"show sales for Cary Lindseys and Charlotte Lindseys," this answer page will not appear because you specified more than one item from the required page level filter.
    • 「顯示 Charlotte Lindseys 的銷售量」,則會顯示這個回應頁面。"show sales for Charlotte Lindseys," this answer page will display.

      =「顯示銷售量」,則不會顯示這個回應頁面,因為您未在必要的頁面層級篩選中包含任何項目。= "show sales" this answer page will not appear because you didn't include any of the items in the required page level filter.

重要

您必須先啟用 Cortana 的資料集,Cortana 才能存取您的 Cortana 回應頁面。Before your Cortana answer page can be accessed by Cortana, you will need to Enable the dataset for Cortana.

Cortana 如何排序結果?How does Cortana order the results?

具有高分答案的結果 (例如與指定頁面名稱完全相符的項目) 會先出現,以作為 Cortana 中的「最符合項目」 。Results with high scoring answers (such as a complete match of a specified page name) will appear first as a best match in Cortana. 如果 Power BI 中有多個 Cortana 回應頁面,就可能出現多個最符合的項目。Multiple best matches can appear if there are multiple Cortana answer pages in Power BI. 得分中等或較低的答案會以連結形式列於 Cortana 的最符合項目下方,例如答案不是以回應頁面名稱為依據,或問題含有 Power BI 無法理解的字組。Medium or lower scoring answers, such as answers not based on the name of an answer page or a question with words not understood by Power BI, are listed as links below best matches in Cortana.

注意

將新的資料集或自訂 Cortana 回應頁面新增至 Power BI 並針對 Cortana 啟用時,Cortana 最多可能需要 30 分鐘的時間,才會開始顯示結果。When a new dataset or custom Cortana answer page is added to Power BI and enabled for Cortana it can take up to 30 minutes for results to begin appearing in Cortana. 登入和登出 Windows 10,或在 Windows 10 中重新啟動 Cortana 程序,都可立即顯示新內容。Logging in and out of Windows 10, or otherwise restarting the Cortana process in Windows 10, will allow new content to appear immediately.

後續步驟Next steps

搭配 Power BI 使用 CortanaUsing Cortana with Power BI

還是無法讓 Cortana 搭配 Power BI 運作嗎?Still can't get Cortana to work with Power BI? 請嘗試 Cortana 疑難排解員Try the Cortana troubleshooter.

有其他問題嗎?More questions? 試試 Power BI 社群Try the Power BI Community