對話動作已於 2023 年 6 月 13 日淘汰。詳情請參閱「
對話動作已淘汰」。
動作套件 (Dialogflow)
透過集合功能整理內容
你可以依據偏好儲存及分類內容。
您可以使用 Actions SDK 建立本地化的動作,方法是為每個語言代碼建立獨立的動作套件,然後使用 gactions
工具將其上傳至 Actions 專案。
如何使用 Actions SDK 建立本地化動作:
- 為您要支援的每個語言代碼分別建立操作套件,並為其提供本地化的名稱,例如
action.de.json
和 action.en.json
。或者,您也可以在專案中為本地化動作套件和其他資源檔案建立子目錄。
- 在動作套件頂端新增
locale
元素,並提供您想要支援的語言或語言代碼。此外,請為動作提供本地化的查詢模式,讓使用者可以針對自己所在的地區正確觸發這些模式。例如:{
"locale": "de",
"actions": [
{
"intent": {
"name": "actions.intent.MAIN",
"trigger": {
"queryPatterns": [
"<Insert German query patterns here>"
]
}
}
}
]
}
- 使用
gactions
工具將動作套件上傳至 Actions 專案,並指定每個本地化版本套件。例如:./gactions update --project my-project-id --action_package action.de.json --action_package action.en.json --action_package action.fr.json --action_package action.ja.json --action_package action.ko.json
除非另有註明,否則本頁面中的內容是採用創用 CC 姓名標示 4.0 授權,程式碼範例則為阿帕契 2.0 授權。詳情請參閱《Google Developers 網站政策》。Java 是 Oracle 和/或其關聯企業的註冊商標。
上次更新時間:2024-06-25 (世界標準時間)。
[{
"type": "thumb-down",
"id": "missingTheInformationINeed",
"label":"缺少我需要的資訊"
},{
"type": "thumb-down",
"id": "tooComplicatedTooManySteps",
"label":"過於複雜/步驟過多"
},{
"type": "thumb-down",
"id": "outOfDate",
"label":"過時"
},{
"type": "thumb-down",
"id": "translationIssue",
"label":"翻譯問題"
},{
"type": "thumb-down",
"id": "samplesCodeIssue",
"label":"示例/程式碼問題"
},{
"type": "thumb-down",
"id": "otherDown",
"label":"其他"
}]
[{
"type": "thumb-up",
"id": "easyToUnderstand",
"label":"容易理解"
},{
"type": "thumb-up",
"id": "solvedMyProblem",
"label":"確實解決了我的問題"
},{
"type": "thumb-up",
"id": "otherUp",
"label":"其他"
}]
{
"last_modified": "上次更新時間:2024-06-25 (世界標準時間)。",
"state": ""
}