Skip to content
This repository has been archived by the owner on Apr 16, 2020. It is now read-only.

Pattern with '?' and how to check if the intent is for navigation #1

Open
playground opened this issue Nov 10, 2017 · 0 comments
Open

Comments

@playground
Copy link

playground commented Nov 10, 2017

Are there any documentation explaining the syntax of this example?

//military-words
{
  plurals:{
    barracks:'barracks'
  },
  patterns:{
    "#Ordinal infantry? division":'Noun',
    "major (general|lieutenant|#Person)":'Person',
    "#Posessive six":'Noun',
    "over$":'Expression'
  },
  words:{
    'niner':'Value',
    'buck sergeant':'Person'
  }
}

Sorry this is a multi parts question

  1. When I try to create a plugin with
  "patterns": {
    "to? (readme|instruction(s)?)": "Navigation"
  },

readme works as expected but can't get instruction or instructions to work.
However, this works

  "patterns": {
    "to? (readme|instructions|instruction)": "Navigation"
  },

  1. Is plugin the right tool for creating new intents and actions?

  2. Now that I can see in the terms where instructions is tagged with "Navigation" from this sentence "give me instructions". What method or how can I check programmatically that the sentence in question is indeed related to "Navigation"? And how can I train it to respond with "http://mydomain/readme.html"?

I have added the ability to provide responses as part of the plugin. I want to have a chat with you before I submit a PR.

@playground playground changed the title Can you explain how compromise-plugin works in conjunction with nlp-compromise Pattern with '?' Nov 12, 2017
@playground playground changed the title Pattern with '?' Pattern with '?' and how to check if the intent is for navigation Nov 12, 2017
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant