mathewthe2 / immersion_reader

iOS Reader with Japanese popup dictionary
MIT License
27 stars 1 forks source link

Popup Dictionary Improvement Requests/Suggestions #18

Closed ccos89 closed 5 months ago

ccos89 commented 10 months ago

Hey there - first off, this is a tremendous project so huge thank you for your work thus far and it’s criminal more people don’t know about this app. I’ve told the people i know learning JP because I think it’s a great resource.

That said, I’ve used jidoujisho for a long time (another tremendous project) and while I’m super super happy to have an alternative for iOS (my primary device) there are some quality of life things I’d love to see improved in the current featureset.

One, I find that for whatever reason the “parsing”/which definition the dictionary surfaces seems to be much better in jidoujisho than Immersion Reader, even though they both use ttu. This is particularly pronounced with kana word lookups, due to their potential ambiguity- I imagine some of this is unavoidable, but I don’t see why when i look up いずれ the first definition is 意に介する. In fact, that seems to be the first result any time I look up a word starting with い which is quite irritating. This is not an issue I’ve ever experienced in ttu in jidoujisho so I suspect it may be a fixable issue for this app?

IMG_3556

I also would like, if possible, a way to organize/prioritize dictionaries. Once I’ve uploaded custom dictionaries, there doesn’t seem to be any way to reorder them and I’m not sure the lookups take any order into account at all. I think this may help with the above issue, and also should help with getting a bunch of name results from JMnedict above actual words (I want all names at the end).

IMG_3558

Semi-related to these issues, I don’t know if you plan to support frequency lists at all but it would also potentially help with examples like in the picture where 「説明して」in the text was surfacing the dictionary result ときあかす above せつめい. If there was a way to prioritize by dictionary, then by frequency, that would save a lot of scrolling time.

IMG_3557

I’m not sure if there’s a way to support any direct input to the popup dictionary, or quicker way to access the dictionary lookup feature from within the ttu reader, but that would alsp be helpful. For example when I try the popup dictionary on 大げさ in the text I only get a definition that indicates it’s the same definition as 大袈裟 but I have no way to recursively then lookup that word. If there was a way to edit the input, lookup the word recursively, or just access the dictionary without having to exit back to the main menu (which also would cause me to lose the example sentence I wanted to mine) that would be great.

IMG_3559

It would also be visually helpful to have some kind of distinction between the dictionary results, like a line divider, as visually right now the blue star helps with differentiating entries but otherwise it can be hard to tell where one stops and the next stops particularly when using monolingual dictionaries. Also, if there is a way to make clearer the ellipses indicating a dictionary entry has been truncated and can be expanded that would be very helpful as I’ve accidentally missed that before when trying to find the right definition.

I’m not a dev so I’m not sure how much of this is possible but the quality of dictionary lookups is my only main gripe right now and I’m hopeful some of the above can be enhanced. I would also love to see ability to auto-add forvo audio and google/bing images to saved words a la jidoujisho and migaku in the future, but I can always bulk add that in Anki, so mostly I just hope the existing reader experience can be improved slightly because it’s so crazy to finally be able to have an app like this on iOS! Thank you again for your efforts.

mathewthe2 commented 10 months ago

Thanks for the detailed feedback.

Immersion Reader uses a different parser than Jidoujisho. I ported Yomichan's deinflector into Dart for this app. Jidoujisho uses MeCab, which is heavier and slower.

I might have missed out certain parts of Yomichan's deinflector here, so anyone who might be able to look through this code and raise a PR would be appreciated: https://github.com/mathewthe2/immersion_reader/blob/234921ee910fa5863ff45ae767f60ad19ba4c6ef/lib/japanese/translator.dart#L252

The frequency ranking is implemented through the function getPopularity() that is based on the dictionary itself. In other words, the current implementation works for dictionaries with both frequency and glossary, but cannot depend on another ranking dictionary. Doing so might be trickier than it sounds.

I imagine some of this is unavoidable, but I don’t see why when i look up いずれ the first definition is 意に介する. In fact, that seems to be the first result any time I look up a word starting with い which is quite irritating. This is not an issue I’ve ever experienced in ttu in jidoujisho so I suspect it may be a fixable issue for this app?

I suspect this has to do with the custom dictionary you imported that I haven't tested with my implementation. Since my frequency ranking is local (based on dictionary), a dictionary without frequency would mess up the ranking algorithm. I might need a test dictionary file (with parts of your data) to test it.

Other features

ccos89 commented 10 months ago

Thanks for the quick response! That all makes sense and it seems likely it’s an issue with one of the dictionaries. I have only used Migaku and Jidoujisho in the past and have not used these with Yomichan so I suspect that is the issue (although I believe they are all originally made for Yomichan). I can try to troubleshoot on my end but would also be happy to email you a link for the dictionaries if you want.

Since I didn’t see it on your list at the end of your reply, I would just reinforce a visual “tag” for which dictionary the definition is from would be helpful both in regular use as well as in troubleshooting scenarios like this. If it was consistent with your vision for the app, it seems like adding UI tweaks like this, a clearer division between dictionary results, and ellipses/collapsed entries being clearer may be easier to implement than some of the above features.

Let me know if you want me to email you re: the dictionaries. Thanks again.

mathewthe2 commented 9 months ago

Let me know if you want me to email you re: the dictionaries. Thanks again.

Sure

a visual “tag” for which dictionary the definition is from would be helpful both in regular use as well as in troubleshooting scenarios like this

Actually I want to avoid adding metadata like dictionary names here, as I wanted a more simple and clean look for the mobile experience.