commit | 782c6e6025d582ba7a5e49f76ab6b8848098319d | [log] [tgz] |
---|---|---|
author | Makoto Yui <myui@apache.org> | Fri Apr 23 19:17:14 2021 +0900 |
committer | Makoto Yui <myui@apache.org> | Fri Apr 23 19:17:14 2021 +0900 |
tree | fed8fc46c48d03c9f4c34637dcdf1e67cdedfebd | |
parent | 0ee33d2f59a0c5e0a47abbecfd56fb864b831462 [diff] |
[HIVEMALL-309] Enhance tokenize_ko to support stopwords and external user dict ## What changes were proposed in this pull request? Enhance tokenize_ko to support stopwords and external user dict ## What type of PR is it? Improvement ## What is the Jira issue? https://issues.apache.org/jira/browse/HIVEMALL-309 ## How was this patch tested? unit tests, manual tests on EMR ## How to use this feature? ```sql -- default stopward (null), default stoptags (null), custom dict select tokenize_ko('나는 C++ 언어를 프로그래밍 언어로 사랑한다.', '-mode discard', null, null, array('C++')); > ["나","c++","언어","프로그래밍","언어","사랑"] select tokenize_ko('나는 c++ 프로그래밍을 즐긴다.', '-mode discard', null, null, 'https://raw.githubusercontent.com/apache/lucene/main/lucene/analysis/nori/src/test/org/apache/lucene/analysis/ko/userdict.txt'); > ["나","c++","프로그래밍","즐기"] ``` ## Checklist - [x] Did you apply source code formatter, i.e., `./bin/format_code.sh`, for your commit? - [x] Did you run system tests on Hive (or Spark)? Author: Makoto Yui <myui@apache.org> Closes #238 from myui/korean-enhancement.
Apache Hivemall is a scalable machine learning library that runs on Apache Hive, Apache Spark, and Apache Pig. Hivemall is designed to be scalable to the number of training instances as well as the number of training features.
Find more examples on our user guide and find a brief introduction to Hivemall in this slide.
Support is through user@hivemall.incubator.apache.org, not by a direct e-mail.
If you are planning to contribute to this repository, we first request you to create an issue at our JIRA page even if the topic is not related to source code itself (e.g., documentation, new idea and proposal).
All Hivemall functions are defined under resources/ddl. In order to update the definition files, the following script helps inserting function name and class path of your new UDF:
$ ./bin/update_ddls.sh
Moreover, don't forget to update function list in the document as well:
$ ./bin/update_func_md.sh
Note that, before creating a pull request including Java code, please make sure your code follows our coding conventions by applying formatter:
$ ./bin/format_code.sh