jovo-cli icon indicating copy to clipboard operation
jovo-cli copied to clipboard

Error when overridding a Jovo Model intent for Alexa

Open jrglg opened this issue 3 years ago • 4 comments

I'm submitting a...

  • [X] Bug report
  • [ ] Feature request
  • [ ] Documentation issue or request
  • [ ] Other... Please describe:

Expected Behavior

When a intent of Jovo Model is overridden in the specific platform part of the Jovo Model, boths intents are merged using some strategy.

Current Behavior

For Conversational Actions this is working with some bugs (https://github.com/jovotech/jovo-cli/issues/250) For Alexa, an error is thrown when deploying.

Error log

Initializing build process
  ✔ Collecting platform configuration from project.js.
    Platforms: alexa
  ✔ Collecting Jovo language model files from ./models folder.
    Locales: es
Validating Alexa model files
  ✔ es
Building Alexa Skill files[stage: local]
  >> Path: ./build\local\platform.alexa
  ✔ Project files
  ✔ Interaction model
    es (es-ES)

Deploying Alexa Skill [stage: local]
  ✖ Uploading skill package

x Error: --------------------------------------------------------------------------------
›
› Message:
›  Errors occured while importing your skill package
›
› Module:
›  JovoCliCore
›
› Hint:
›  DuplicateIntentName: Intent "SomeIntentName" cannot be defined more than once in the intent schema.
›
›
› If you think this is not on you, you can submit an issue here: https://github.com/jovotech/jovo-cli/issues.

Your Environment

  • Jovo Framework version used: "@jovotech/platform-alexa": "^4.1.2", "@jovotech/platform-core": "^4.1.2", "@jovotech/platform-googleassistant": "^4.1.2",
  • Operating System: Windows 10

jrglg avatar Jan 24 '22 12:01 jrglg

Hey @jrglg , could you post relevant portions of your language model?

rubenaeg avatar Jan 24 '22 15:01 rubenaeg

My model has +5000 lines right now, and it's in spanish, so would be quite complicate to understand it. Here I have a reduced example to test it. Also, there's a overriden type for Google with Fuzzy Matching, but it's not used for this example (it's for #250)

{
  "version": "4.0",
  "invocation": "test overriding stuff",
  "intents": {
    "SomeIntent": {
      "phrases": [
        "this will be overridden"
      ]
    }
  },
  "alexa": {
    "interactionModel": {
      "languageModel": {
        "intents": [
          {
            "name": "SomeIntent",
            "samples": [
              "overriddensentence for alexa"
            ]
          }
        ]
      }
    }
  }
}

Please also note that it's just an example, and the real porpuse is to overpass some restrictions between platforms when using custom types like AMAZON.SearchQuery and Google's regexp, fuzzy_matching, etc.

jrglg avatar Jan 24 '22 15:01 jrglg

This would be interesting

jrglg avatar Apr 01 '22 08:04 jrglg

@rubenaeg did you find anything?

jrglg avatar Sep 01 '22 18:09 jrglg