Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ambiguous contractions #20

Open
JarbasAl opened this issue Mar 25, 2022 · 1 comment
Open

ambiguous contractions #20

JarbasAl opened this issue Mar 25, 2022 · 1 comment
Assignees
Labels
bug Something isn't working enhancement New feature or request help wanted Extra attention is needed

Comments

@JarbasAl
Copy link
Member

JarbasAl commented Mar 25, 2022

the following unit tests have a TODO, we don't have anything concrete planned to solve this and should start discussing it

       # TODO: Ambiguous with "he had"
       self.assertEqual(normalize("he'd"), "he would"
       # TODO: Ambiguous with "he has"
        self.assertEqual(normalize("he's"), "he is")
        # TODO: Ambiguous with "how would"
        self.assertEqual(normalize("how'd"), "how did")
        # TODO: Ambiguous with "how has" and "how does"
        self.assertEqual(normalize("how's"), "how is")
        # TODO: Ambiguous with "I had"
        self.assertEqual(normalize("I'd"), "I would")
        # TODO: Ambiguous with "it has"
        self.assertEqual(normalize("it's"), "it is")
         # TODO: Ambiguous wiht "she had"
        self.assertEqual(normalize("she'd"), "she would")
        # TODO: Ambiguous with "someone had"
        self.assertEqual(normalize("someone'd"), "someone would")
        # TODO: Ambiguous with "someone has"
        self.assertEqual(normalize("someone's"), "someone is")
        # TODO: Ambiguous with "that has"
        self.assertEqual(normalize("that's"), "that is")
        # TODO: Ambiguous with "that had"
        self.assertEqual(normalize("that'd"), "that would")
        # TODO: Ambiguous with "there had"
        self.assertEqual(normalize("there'd"), "there would")
         # TODO: Ambiguous with "there has"
        self.assertEqual(normalize("there's"), "there is")
        # TODO: Ambiguous with "they had"
        self.assertEqual(normalize("they'd"), "they would")
          # TODO: Ambiguous wiht "we had"
        self.assertEqual(normalize("we'd"), "we would")
        # TODO: Ambiguous with "what has" / "what does")
        self.assertEqual(normalize("whats"), "what is")
         # TODO: Ambiguous with "when has"
        self.assertEqual(normalize("when's"), "when is")
        # TODO: Ambiguous with "where has" / where does"
        self.assertEqual(normalize("where's"), "where is")
          # TODO: Ambiguous with "who had" "who did")
        self.assertEqual(normalize("who'd"), "who would")
        # TODO: Ambiguous with "who has" / "who does"
        self.assertEqual(normalize("who's"), "who is")
        # TODO: Ambiguous with "why has" / "why does"
        self.assertEqual(normalize("why's"), "why is")
         # TODO: Ambiguous with "you had"
        self.assertEqual(normalize("you'd"), "you would")
         # TODO: "everyone's" is also the possessive of "everyone"
        self.assertEqual(normalize("everyone's"), "everyone is")

related PR #6

@JarbasAl JarbasAl added bug Something isn't working enhancement New feature or request help wanted Extra attention is needed labels Mar 25, 2022
@NeonDaniel
Copy link
Member

There's probably an nlp package that can do this contextually.. We could solve many of these if we have POS tags on the following word.. We could also return both and leave it to the caller to disambiguate?

JarbasAl added a commit that referenced this issue Nov 27, 2022
rebase of MycroftAI#69

Co-authored-by: jarbasal <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working enhancement New feature or request help wanted Extra attention is needed
Projects
None yet
Development

No branches or pull requests

3 participants