Chinese, Japanese and Korean words are not separated by space. If we can invoke Solr (with CJK word-segmentation tools configured) to pre-segment the search keywords, and then re-invoke the Solr to search the segmented words, the search result will be much better. This module applies to this situation.
How to use Usage:
Iin the Search API module, successfully configue to connect to a working Apache Solr server with Chinese word segmenter installed , Then download & enable this module, no configuration via UI.
Project page:
https://www.drupal.org/sandbox/fishfree/2462769
Git:
git clone http://git.drupal.org/sandbox/fishfree/2462769.git solr_pre_segment_search_words
cd solr_pre_segment_search_words
Manual reviews:
https://www.drupal.org/node/2623192#comment-10635950
https://www.drupal.org/node/2625384#comment-10635896
https://www.drupal.org/node/2597211#comment-10635908
Comments
Comment #2
PA robot commentedThere are some errors reported by automated review tools, did you already check them? See http://pareview.sh/pareview/httpgitdrupalorgsandboxfishfree2462769git
We are currently quite busy with all the project applications and we prefer projects with a review bonus. Please help reviewing and put yourself on the high priority list, then we will take a look at your project right away :-)
Also, you should get your friends, colleagues or other community members involved to review this application. Let them go through the review checklist and post a comment that sets this issue to "needs work" (they found some problems with the project) or "reviewed & tested by the community" (they found no major flaws).
I'm a robot and this is an automated message from Project Applications Scraper.
Comment #3
fishfree commentedComment #4
fishfree commentedI would have done pareview auto-scanning myself, but unfortunately I could not open http://pareview.sh yesterday. Now I can access it, and cleaned up all the errors and warnings.
Could some guys be so kind to review it manually, please? This is my first full module application. I need mentorship and encourage. :-)
Comment #5
fishfree commentedComment #6
gauravsood91 commentedManual Review
Individual user account
Yes: Follows guidelines for individual user accounts.
No duplication
Yes: Does not cause module duplication and/or fragmentation.
Master Branch
Yes: Follows the guidelines for master branch.
Licensing
Yes: Follows the licensing requirements.
3rd party assets/code
Yes: Follows the guidelines for 3rd party assets/code.
README.txt/README.md
Yes: Follows the guidelines for in-project documentation and/or the README Template.
Code long/complex enough for review
Code doesn't seem to be long/complex enough
Secure code
Yes: Meets the security requirements
Coding style & Drupal API usage
Yes: It follows code and API guidelines.
Comment #7
gauravsood91 commentedComment #8
fishfree commentedThank you, gauravsood91! But this module really solve an important problem for Chinese full text search with Apache Solr. It's not necessary to write long code to make it.
Comment #9
jungleThere are two continued underscores in naming. One underscore is enough. To rename solr__pre_segment_search_words to solr_pre_segment_search_words.
Comment #10
fishfree commentedThank you, jugle. I modified again and commit again. The original machine name was automatically generated by Drupal project system, so I still can not rename the module folder.
Comment #11
rogical commentedVery useful in Chinese Site, I tested and have used in my project now, so far all works good :)
Comment #12
fishfree commentedComment #13
jungleA tiny module solves a big problem in Chinese. Working fine for me.
Comment #14
fishfree commentedComment #15
klausimanual review:
Otherwise looks good to me. Do you want to shorten the module name or should I publish the module as "solr_pre_segment_search_words"?
Removing review bonus tag, you can add it again if you have done another 3 reviews of other projects.
Comment #16
fishfree commentedklausi, thank you very much for your manual review. Let me explain for your questions and suggestions:
I did another 3 manual reviews:
https://www.drupal.org/node/2645412#comment-10751008
https://www.drupal.org/node/2643098#comment-10751150
https://www.drupal.org/node/2650742#comment-10754764
Comment #17
klausiThanks for your contribution, fishfree!
I promoted this project for you: https://www.drupal.org/project/solr_pre_segment
Here are some recommended readings to help with excellent maintainership:
You can find lots more contributors chatting on IRC in #drupal-contribute. So, come hang out and stay involved!
Thanks, also, for your patience with the review process. Anyone is welcome to participate in the review process. Please consider reviewing other projects that are pending review. I encourage you to learn more about that process and join the group of reviewers.
Thanks to the dedicated reviewer(s) as well.
Comment #18
klausiNow that this experimental project has been promoted, you'll need to update the URL of your remote repository or reclone it.
Comment #19
fishfree commentedklausi, thank you for your approval and reminder. I will go on elaborating on this module.