亚马逊训练alexa的方法_Alexa对话是AI驱动的对话界面新方法
亞馬遜訓(xùn)練alexa的方法
介紹 (Introduction)
Looking at the chatbot development tools and environments currently available, there are three ailments which require remedy:
查看當(dāng)前可用的聊天機(jī)器人開(kāi)發(fā)工具和環(huán)境,有三種需要補(bǔ)救的疾病:
Compound Contextual Entities
復(fù)合上下文實(shí)體
Entity Decomposition
實(shí)體分解
Deprecation of Rigid State Machine, Dialog Management
棄用剛性狀態(tài)機(jī),對(duì)話框管理
The aim of Alexa Conversations is to take voice interactions from one shot interactions to multi-turn interactions. More complex conversations like booking a flight, ordering food or banking demands multi-turn conversations.
Alexa對(duì)話的目的是將語(yǔ)音互動(dòng)從一次射擊互動(dòng)轉(zhuǎn)變?yōu)槎嗷睾匣?dòng)。 更復(fù)雜的對(duì)話(例如預(yù)訂航班,訂購(gòu)食物或銀行業(yè)務(wù))需要多回合對(duì)話。
One could say conversational commerce demands an environment to develop multi-turn conversations fast and efficient. Amazon must have recognized this and Alexa Conversations is their foray into addressing this need.
可以說(shuō)對(duì)話商務(wù)需要一種環(huán)境來(lái)快速有效地進(jìn)行多輪對(duì)話。 亞馬遜一定已經(jīng)意識(shí)到這一點(diǎn),而Alexa Conversations是他們滿足這一需求的嘗試。
復(fù)合上下文實(shí)體 (Compound Contextual Entities)
Huge strides have been made in this area and many chatbot ecosystems accommodate these.
在這一領(lǐng)域已經(jīng)取得了長(zhǎng)足的進(jìn)步,許多聊天機(jī)器人生態(tài)系統(tǒng)都適應(yīng)了這些。
上下文實(shí)體 (Contextual Entities)
The process of annotating user utterances is a way of identifying entities by their context within a sentence.
注釋用戶話語(yǔ)的過(guò)程是一種通過(guò)句子中的上下文標(biāo)識(shí)實(shí)體的方法。
Contextual Entity Annotation In IBM Watson AssistantIBM Watson Assistant中的上下文實(shí)體注釋Often entities have a finite set of values which are defined. Then there are entities which cannot be represented by a finite list; like cities in the world or names, or addresses. These entity types have too many variations to be listed individually.
通常,實(shí)體具有一組定義的有限值。 還有一些實(shí)體不能用有限列表來(lái)表示。 例如世界上的城市或名稱或地址。 這些實(shí)體類型有太多變化,無(wú)法單獨(dú)列出。
For these entities, you must use annotations; entities defined by their contextual use. The entities are defined and detected via their context within the user utterance.
對(duì)于這些實(shí)體,必須使用批注; 由其上下文使用定義的實(shí)體。 實(shí)體是通過(guò)用戶話語(yǔ)中的上下文來(lái)定義和檢測(cè)的。
復(fù)合實(shí)體 (Compound Entities)
The basic premise is that users will utter multiple entities in one sentence.
基本前提是用戶將在一句話中說(shuō)出多個(gè)實(shí)體。
Users will most probably express multiple entities within one utterance; referred to as compound entities.
用戶很可能會(huì)在一句話中表達(dá)多個(gè)實(shí)體。 稱為復(fù)合實(shí)體。
In the example below, there are four entities defined:
在下面的示例中,定義了四個(gè)實(shí)體:
- travel_mode travel_mode
- from_city from_city
- to_cyt to_cyt
- date_time 約會(huì)時(shí)間
These entities can be detected within the first pass and confirmation solicited from the user.
可以在第一遍內(nèi)檢測(cè)到這些實(shí)體,并向用戶征求確認(rèn)。
實(shí)體分解 (Entity Decomposition)
Microsoft LUIS方法 (The Microsoft LUIS Approach)
Entity decomposition is important for both intent prediction and for data extraction with the entity. The best way to explain this is by way of an example.
實(shí)體分解對(duì)于意圖預(yù)測(cè)和與實(shí)體的數(shù)據(jù)提取都很重要。 最好的解釋方式是通過(guò)示例。
We start by defining a single entity, called
我們首先定義一個(gè)稱為
Travel Detail.
旅行細(xì)節(jié) 。
Within this entity, we defined three sub-entities. You can think of this as nested entities or sub-types. The three sub-types defined are:
在這個(gè)實(shí)體中,我們定義了三個(gè)子實(shí)體。 您可以將其視為嵌套實(shí)體或子類型。 定義的三個(gè)子類型是:
- Time Frame 大體時(shí)間
- Mode 模式
- City 市
From here, we have a sub-sub-type for City:
在這里,我們有一個(gè)City的子子類型:
- From City 從城市出發(fā)
- To City 前往城市
The leader in entity decomposition is Microsoft LUIS, you can read more about it here. I would say LUIS have a complete solution in this regards.
實(shí)體分解的領(lǐng)導(dǎo)者是Microsoft LUIS,您可以在此處了解更多信息。 我想說(shuō)LUIS在這方面有一個(gè)完整的解決方案。
亞馬遜Alexa對(duì)話 (Amazon Alexa Conversations)
Conversations have a similar option, though not as complete and comprehensive as LUIS. Within conversations you can define entities, which Amazon refers to Slots.
對(duì)話具有類似的選擇,盡管不如LUIS完整和全面。 在對(duì)話中,您可以定義實(shí)體(Amazon指插槽)。
Amazon Alexa Conversations: Slot Type With Properties (Amazon Alexa對(duì)話 :帶屬性的插槽類型( PCS)PCS )The aim during the conversations is to fill these slots (entities). Within conversations you can create a slot with multiple properties attached to it. These properties can be seen as sub-slots or sub-categories which together constitute the higher order entity.
對(duì)話期間的目的是填補(bǔ)這些空缺(實(shí)體)。 在對(duì)話中,您可以創(chuàng)建一個(gè)具有多個(gè)屬性的插槽。 這些屬性可以看作是子時(shí)隙或子類別,它們共同構(gòu)成了更高階的實(shí)體。
Alexa Conversations introduces a new slot type custom with properties (PCS).
Alexa Conversations引入了一個(gè)新的具有屬性(PCS)的自定義插槽類型。
Constituting a collection of slots which are hierarchical. This can be used to pass structured data between build-time components such as API Definitions and response templates.
構(gòu)成一組分層的插槽。 這可用于在構(gòu)建時(shí)組件(例如API定義)和響應(yīng)模板之間傳遞結(jié)構(gòu)化數(shù)據(jù)。
淘汰剛性狀態(tài)機(jī)對(duì)話框管理 (Deprecation Of Rigid State Machine Dialog Management)
Deprecating the state machine for dialog management demands a more abstract approach; many are not comfortable of relinquishing control to an AI model.
棄用狀態(tài)機(jī)進(jìn)行對(duì)話管理需要一種更抽象的方法; 許多人不愿意放棄對(duì)AI模型的控制。
The aim of Alexa Conversations (AC) is to furnish developers with the tools to build a more natural feeling Alexa skill with fewer lines of code. AC is an AI-driven approach to dialog management that enables the creating of skills that users can interact with in a natural unconstrained manner. This AI-driven
Alexa Conversations( AC )的目的是為開(kāi)發(fā)人員提供工具,以更少的代碼行構(gòu)建更自然的Alexa技能。 AC是一種由AI驅(qū)動(dòng)的對(duì)話框管理方法,可以創(chuàng)建用戶可以自然而不受限制地進(jìn)行交互的技能。 這種AI驅(qū)動(dòng)
Alexa Conversations In The Alexa Development ConsoleAlexa開(kāi)發(fā)控制臺(tái)中的Alexa對(duì)話approach is more abstract, but more conversation driven from a development process. Sample dialogs are important, together with annotation of data.
方法更抽象,但是更多的對(duì)話是由開(kāi)發(fā)過(guò)程驅(qū)動(dòng)的。 樣本對(duì)話框以及數(shù)據(jù)注釋非常重要。
You provide Alexa with a set of dialogs to demonstrate the functionalities required for the skill.
您為Alexa提供了一組對(duì)話框,以演示該技能所需的功能。
The build time systems behind Alexa Conversations will take the dialogs and create thousands of variations of these examples. This build process takes quite a while to complete.
Alexa對(duì)話背后的構(gòu)建時(shí)間系統(tǒng)將采用對(duì)話框并創(chuàng)建這些示例的數(shù)千種變體。 此構(gòu)建過(guò)程需要相當(dāng)長(zhǎng)的時(shí)間才能完成。
Fortunately any errors are surfaced at the start of the process, which is convenient.
幸運(yùn)的是,在過(guò)程開(kāi)始時(shí)會(huì)出現(xiàn)任何錯(cuò)誤,這很方便。
AC builds a statistical model which interpret customer inputs & predict the best response from the model.
AC建立了一個(gè)統(tǒng)計(jì)模型,該模型可以解釋客戶輸入并預(yù)測(cè)模型的最佳響應(yīng)。
From that information, AC will be able to make accurate assumptions .
根據(jù)這些信息, AC將能夠做出準(zhǔn)確的假設(shè)。
AC uses AI to bridge the gap between voice application you can build manually and the vast range of possible conversations.
AC使用AI彌合了您可以手動(dòng)構(gòu)建的語(yǔ)音應(yīng)用程序與各種可能的對(duì)話之間的鴻溝。
框架組件 (Framework Components)
The five build-time components are:
五個(gè)構(gòu)建時(shí)組件是:
- Dialogs 對(duì)話方塊
- Slots 插槽
- Utterance Sets 話語(yǔ)集
- Response Templates 響應(yīng)模板
- API Definitions API定義
對(duì)話方塊 (Dialogs)
Dialogs are really example conversations between the user and Alexa you define. You cans see the conversation is multi-turn and complexity is really up to you to define.
對(duì)話框?qū)嶋H上是用戶與您定義的Alexa之間的示例對(duì)話。 您可以看到對(duì)話是多回合的,而復(fù)雜度確實(shí)取決于您。
Dialogs: Example Conversations對(duì)話框 :對(duì)話示例For the prototype there are three entities or slots we want to capture, and four dialog examples with four utterances each were sufficient. Again, these conversations or dialogs will be used by AC to create an AI model to produce a natural and adaptive dialog model.
對(duì)于原型,我們要捕獲三個(gè)實(shí)體或插槽,并且四個(gè)帶有四個(gè)發(fā)音的對(duì)話示例就足夠了。 同樣, AC將使用這些對(duì)話或?qū)υ捒騺?lái)創(chuàng)建AI模型,以生成自然的自適應(yīng)對(duì)話框模型。
插槽 (Slots)
Slots are really the entities you would like to fill during the conversation. Should the user utter all three required slots in the first utterance, the conversation will only have one dialog turn.
廣告位確實(shí)是您希望在對(duì)話期間填寫(xiě)的實(shí)體。 如果用戶在第一聲中說(shuō)出了所有三個(gè)必需的位置,則對(duì)話將只有一個(gè)對(duì)話轉(zhuǎn)彎。
Two Types of Slots: Value Slots and Properties兩種類型的廣告位 :價(jià)值廣告位和屬性廣告位The conversation can be longer of course, should it take more conversation turns to solicit the relative information from the user to fill the slots. The interesting part is the two types of slots or entities. The custom defined slots with values, and the one with properties.
當(dāng)然,如果要花費(fèi)更多的會(huì)話輪流從用戶那里獲取相關(guān)信息以填補(bǔ)空缺,則會(huì)話可以更長(zhǎng)。 有趣的部分是插槽或?qū)嶓w的兩種類型。 自定義的插槽包含值,一個(gè)具有屬性。
Alexa Conversations introduces custom slot types with properties (PCS) to define the data passed between components. They can be singular or compound. As stated previously, compound entities or slots can be decomposed.
Alexa Conversations引入了具有屬性(PCS)的自定義插槽類型,以定義在組件之間傳遞的數(shù)據(jù)。 它們可以是單數(shù)或化合物 。 如前所述,復(fù)合實(shí)體或插槽可以分解。
Compound entities which can be decomposed will grow in implementation and you will start seeing it used in more frameworks.
可以分解的復(fù)合實(shí)體將在實(shí)現(xiàn)中增長(zhǎng),您將開(kāi)始看到它在更多框架中的使用。
話語(yǔ)集 (Utterance Sets)
Utterance Sets are groups of utterances that users may say to Alexa, which can include slots. They are used when annotating User Input turns in a Dialog.
話語(yǔ)集是用戶可以對(duì)Alexa說(shuō)的話語(yǔ)組,其中可以包括插槽。 當(dāng)在對(duì)話框中注釋用戶輸入時(shí)使用它們。
This is the one big drawback I see in AC, is the fact for each permutation of slots/entities, examples need to be defined.
這是我在AC中看到的一個(gè)最大缺點(diǎn),那就是對(duì)于插槽/實(shí)體的每個(gè)排列,都需要定義示例。
For example:
例如:
1. abc2. a
3. b
4. c
5. ab
6. bc
7. ac
For the three slots/entities, seven example sets need to be given. Imagine how this expands, should you have more slots/entities.
對(duì)于三個(gè)插槽/實(shí)體,需要給出七個(gè)示例集。 想象一下,如果您有更多的廣告位/實(shí)體,它會(huì)如何擴(kuò)展。
Utterance Sets話語(yǔ)集響應(yīng)模板 (Response Templates)
Responses are how Alexa responds to users in the form of audio and visual elements. They are used when annotating Alexa Response turns in a Dialog.
響應(yīng)是Alexa以音頻和視頻元素的形式對(duì)用戶做出響應(yīng)的方式。 在注釋Alexa響應(yīng)時(shí)在對(duì)話框中使用它們。
Responses Defined定義的回應(yīng)API定義 (API Definitions)
API Definitions define interfaces with your back-end service using arguments as inputs and return as output.
API定義使用參數(shù)作為輸入定義與后端服務(wù)的接口,并作為輸出返回。
結(jié)論 (Conclusion)
AC is a definite a move in the right direction…
AC無(wú)疑是朝著正確方向邁進(jìn)的一步。
善良 (The Good)
- The advent of compound slots/entities which can be decomposed. Adding data structures to Entities. 可以分解的復(fù)合縫隙/實(shí)體的出現(xiàn)。 向?qū)嶓w添加數(shù)據(jù)結(jié)構(gòu)。
- Deprecating the state machine and creating an AI model to manage the conversation. 棄用狀態(tài)機(jī)并創(chuàng)建AI模型來(lái)管理對(duì)話。
- Making voice assistants more conversational. 使語(yǔ)音助手更具對(duì)話性。
- Contextually annotated entities/slots. 上下文注釋的實(shí)體/插槽。
- Error messages during the building of the model were descriptive and helpful. 建立模型期間的錯(cuò)誤消息是描述性的且有幫助的。
不太好 (The Not So Good)
- It might sound negligible; but building the model takes a while. I found that the errors in my model was surfaced at the beginning of the model building process, and training stopped. Should your model have no errors, the build is long. 聽(tīng)起來(lái)微不足道; 但是建立模型需要一段時(shí)間。 我發(fā)現(xiàn)模型建立過(guò)程的開(kāi)始就浮出了模型中的錯(cuò)誤,并且訓(xùn)練停止了。 如果您的模型沒(méi)有錯(cuò)誤,則構(gòu)建時(shí)間很長(zhǎng)。
- Defining utterance sets are cumbersome. Creating utterance sets for all possible permutations if you have a large number of slots/entities is not ideal. 定義話語(yǔ)集很麻煩。 如果您有大量的廣告位/實(shí)體,則為所有可能的排列創(chuàng)建話語(yǔ)集是不理想的。
- It is complex, especially compared to an environment like Rasa. The art is to improve the conversational experience by introducing complex AI models; while simultaneously simplifying the development environment. 它很復(fù)雜,特別是與Rasa這樣的環(huán)境相比。 技巧是通過(guò)引入復(fù)雜的AI模型來(lái)改善對(duì)話體驗(yàn); 同時(shí)簡(jiǎn)化了開(kāi)發(fā)環(huán)境。
在這里 (Read More Here)
翻譯自: https://medium.com/@CobusGreyling/alexa-conversations-is-a-new-ai-driven-approach-to-conversational-interfaces-fe8d2a562602
亞馬遜訓(xùn)練alexa的方法
總結(jié)
以上是生活随笔為你收集整理的亚马逊训练alexa的方法_Alexa对话是AI驱动的对话界面新方法的全部?jī)?nèi)容,希望文章能夠幫你解決所遇到的問(wèn)題。
- 上一篇: 快手关注的人发作品通知怎么设置
- 下一篇: “硬件杀手”击溃RTX 4090!SE新