如何使用其余API构建Amazon Lex Bot?
根据 http://docs.aws.amazon.com/lex/latest/dg/API_Operations_Amazon_Lex_Model_Building_Service.html 您可以创建或更新漫游器和意图/插槽(放置{Bot | Intend | Slot},创建{Bot | Intend | Slot} Version).
According to http://docs.aws.amazon.com/lex/latest/dg/API_Operations_Amazon_Lex_Model_Building_Service.html you can create or update bots and intents/slots (Put{Bot|Intend|Slot}, Create{Bot|Intend|Slot}Version).
因此,通过使用Put *,我可以配置一个机器人,并通过Create * Version,我可以发布一个机器人,但是要发布它,首先需要构建它,而我找不到用于该API的方法.
So by using Put* I can configure a bot and with Create*Version I can publish one, but in order to publish it, first you need to build it and I can't find an API method for that.
使用PutBot
时,可以为--process-behavior
标志提供值BUILD
来强制构建.
When using PutBot
you can supply the --process-behavior
flag with value BUILD
to force a build.
从文档中:
如果将
processBehavior
元素设置为Build
,则Amazon Lex会构建机器人以使其可以运行.如果将元素设置为Save
,Amazon Lex将保存该机器人,但不会对其进行构建.如果未指定此值,则默认值为Save
.
If you set the
processBehavior
element toBuild
, Amazon Lex builds the bot so that it can be run. If you set the element toSave
Amazon Lex saves the bot, but doesn't build it. If you don't specify this value, the default value isSave
.