•   over 1 year ago

how to create bot definition file for non node.js users

I have written bot in C#, don't how to create Bot Definition file.
Can someone help me with this or similar script https://github.com/awslabs/amazon-lex-bot-export
Or is there a way I can write it manually?

  • 3 comments

  •   •   over 1 year ago

    I'm not the official word on this, but the bot export script downloads the bot definition from AWS, regardless of which language your bot/client are written in.

    All you need is to have node and the aws-sdk installed to run the script.

  •   •   over 1 year ago

    +1 node.js is just to run exporting script. You can also export the bot, intents and slot-types using aws cli (more manual work):

    Setup CLI: http://docs.aws.amazon.com/lex/latest/dg/gs-set-up-cli.html
    In the following command - enter “AWS Access Key ID” and “AWS Secret Access Key” generated for the user in https://console.aws.amazon.com/iam/home#/users

    aws configure

    Settings has been saved in the file:
    .aws/credentials

    Commands to see/save bot and its content:
    (e.g. the bot name: “ShoppingBot”, its alias: “shoppingbot”, one of intents: “VegetableDepartment”, one of slot types: “VegetableDepartmentUnits”)
    aws lex-models help
    aws lex-models get-bots
    aws lex-models get-bot-versions --name ShoppingBot
    aws lex-models get-bot --name ShoppingBot --version-or-alias shoppingbot > bot.json
    aws lex-models get-intents
    aws lex-models get-intent --name VegetableDepartment --intent-version 16 > veg-dpt.json
    aws lex-models get-slot-types
    aws lex-models get-slot-type --name VegetableDepartmentUnits --slot-type-version 2 >veg-dpt-units.json
    docs.aws.amazon.com
    Step 2: Set Up the AWS Command Line Interface - Amazon Lex
    Set up the AWS CLI to test Amazon Lex.

  •   •   over 1 year ago

    if you ran into "ValueError: unknown locale: UTF-8" Error

    see this -> https://stackoverflow.com/a/22282511/1778834

Comments are closed.