MyHomeworkSpace / client

The MyHomeworkSpace client.
MIT License
4 stars 4 forks source link

Resolving ambiguities in Quick Add #132

Open thatoddmailbox opened 4 years ago

thatoddmailbox commented 4 years ago

Right now, the Quick Add code just tries to make its best guess as to what the user wants. However, there are some cases where the provided information is somewhat ambiguous. For example, "meet tom"--should it be a meeting with someone named Tom or a meeting tomorrow? Or, less consequentially, "write essay about book"--should the new homework item be "Write essay about book" or just "Essay about book", since they're both valid prefixes?

There are two main parts to this: structuring the Quick Add code to provide multiple guesses (maybe even sorted by probability/relevancy?) and then somehow coming up with some UI to allow the user to either pick between the options or modify their input to resolve the ambiguity.

amazansky commented 4 years ago

This also applies in the case of keywords within the user's entry for quick add (e.g. "HW Astronomy project progress update 2" will change to "HW progress update 2" because Project is a keyword).

thatoddmailbox commented 4 years ago

One thing that would be helpful is if people could come up with additional weird ambiguities, like the Tom/tomorrow thing or even just weird sentences that might hit multiple prefixes, and what you think the best result for that scenario might be.

I think this is going to end up looking like a search autocomplete, where the primary suggestion is automatically highlighted (and pressing enter selects it), and the alternatives are available via arrow keys or clicking on them. The trick is then deciding what the primary suggestion should be, which is where having a good number of test cases would help.

Ideally it would be even able to resolve examples like Tom/tom by checking for things like certain prepositions ("with tom" -> part of name, "due tom" -> due date) which, again, is where test cases would be helpful.

amazansky commented 4 years ago

Also, if for whatever reason people make custom prefixes named after dates of the week or classes in their planner.

myhomeworkspace-planbot[bot] commented 3 years ago

Hi! I've removed @thatoddmailbox from this issue due to a lack of activity. If this is a mistake, feel free to reassign yourself. If you would like to work on this issue, feel free to assign yourself.

thatoddmailbox commented 3 years ago

Another example: two classes in the same text, or a word that could get interpreted as a class. For example, "Finish other worksheet for math" where "other" and "math" are both classes.

willbarkoff commented 3 years ago

Sorry, I'm a little confused where Quick Add is getting "english" from, do you mean "Finish other worksheet for english?"

thatoddmailbox commented 3 years ago

I meant where "other" and "math" are both classes :roll_eyes: