pluots / zspell

A spellchecking library and executable written in Rust
Other
45 stars 4 forks source link

Failed to parse french hunspell dictionary #108

Closed gwen-lg closed 5 months ago

gwen-lg commented 5 months ago

In french dictionary, flags can have multiple characters. Ex: NEEDAFFIX () FORBIDDENWORD {} CIRCUMFIX ** KEEPCASE || NOSUGGEST --

and it's not correctly handeled

tgross35 commented 5 months ago

@gwen-lg I think I fixed the flag issue in https://github.com/pluots/zspell/pull/111. Any chance you could test with the French dictionary and see if you are getting reasonable results?

I'll release later today if it looks okay.

gwen-lg commented 5 months ago

@tgross35 : yes, the build of dictionary work, and give reasonable results. Thank you

gwen-lg commented 5 months ago

Probably not related, but zspell seems not to recognize plurals and verb conjugations.

tgross35 commented 5 months ago

Thanks for confirming 👍 I'll get a release ready.

Do you have a specific example of plurals or conjugations? I suspect this probably needs lazy word checking (WIP...)

gwen-lg commented 5 months ago

In the sentence : Même mourant, vous répondez présent. the word répondez is detected as error, while it's a conjugation of the verb répondre projections is not detected as plural of projection.

tgross35 commented 5 months ago

Thanks for the reproduction, I wrote that up in https://github.com/pluots/zspell/issues/116. It will unfortunately need a new feature.

The original issue should be fixed with the new release 0.5.5. I understand that unfortunately doesn't get far when there are no plurals :)