Tutorial: Deploy (cli)

Deploy LUIS models

  1. Run the following command for each .lu file in \Deployment\Resources\LU to parse the files to .luis files that can be imported to LUIS:
     ludown parse toluis `
         --in "path-to-lu-file" `
         --luis_culture "culture-code" `
         --out_folder "output-folder" `
         --out "output-file-name.luis"
    
  2. Run the following command to import the LUIS model into the LUIS portal.
     luis import application `
         --appName "app-name" `
         --authoringKey "luis-authoring-key" `
         --subscriptionKey "luis-authoring-key" `
         --region "region" `
         --in "path-to-luis-file" `
         --wait
    
  3. Run the following command to train the LUIS model.
     luis train version `
         --appId "app-id" `
         --region "region" `
         --authoringKey "authoring-key" `
         --versionId "version-id" `
         --wait
    
  4. Run the following command to publish the LUIS model.
     luis publish version `
         --appId "app-id" `
         --region "region" `
         --authoringKey "authoring-key" `
         --versionId "version-id" `
         --wait
    
  5. Run the following command to create a .cs representation of your LUIS model.
     luisgen "path-to-luis-file" -cs "YourModelNameLuis" -o "path-to-output-folder"
    
  6. For each LUIS model, add the following configuration to the cognitiveModels.your-locale.languageModels collection in cognitivemodels.json file:
     {
         "subscriptionkey": "",
         "appid": "",
         "id": "",
         "version": "",
         "region": "",
         "name": "",
         "authoringkey": "",
         "authoringRegion": ""
     }