Tid

Results comments of Tid

可以,不過你要修改一下 code https://github.com/yesseecity/hanlp-python/blob/master/hanlp.py 14 行的 _innerConvertEnable 改成 False 就行了 對應到 25行 def _innerConvert

new version for python https://github.com/hankcs/pyhanlp

You can try this https://github.com/hankcs/pyhanlp

最新commit 的檔案中 https://github.com/yesseecity/hanlp-python/blob/master/install.sh 語系設定那邊 改成 ``` sudo locale-gen es_US.UTF-8 sudo update-locale es_US.UTF-8 echo 'export LC_ALL=es_US.UTF-8' >> ~/.bashrc echo 'export LANG=es_US.UTF-8' >> ~/.bashrc echo 'export LANGUAGE=es_US.UTF-8' >> ~/.bashrc source ~/.bashrc ```...

請教一下,在ubuntu:16.10 (Docker的容器內)上 不使用IDE,發現下面問題 這該如何解? 1. "-Djava.class.path=/root/tid_home/myProject/python/hanLP/hanlp-1.3.2/hanlp-1.3.2.jar" command line 回應: >嚴重: 没有找到HanLP.properties,可能会导致找不到data >(中間略過) >现在HanLP将尝试从/root/tid_home/myProject/python/hanLP读取data…… >(後面略過) 2. 改成 "-Djava.class.path=/root/tid_home/myProject/python/hanLP/hanlp-1.3.2/hanlp-1.3.2.jar;/root/tid_home/myProject/python/hanLP/hanlp-1.3.2/" 回應: >Traceback (most recent call last): > File "hanLP-demo.py", line 11, in >...

自解: > "-Djava.class.path=/root/tid_home/myProject/python/hanLP/hanlp-1.3.2/hanlp-1.3.2.jar:/root/tid_home/myProject/python/hanLP/hanlp-1.3.2/" 把「;」換成「:」

我弄了個python接口的 https://github.com/yesseecity/hanLP-python/wiki

試試 hanlp/src/test/java/com/hankcs/demo/DemoPhraseExtractor.java 這個Demo檔案

這樣子? `JClass('com.hankcs.hanlp.corpus.occurrence.Occurrence#addAll')` 系統報錯 `java.lang.RuntimeExceptionPyRaisable: java.lang.RuntimeException: Class com.hankcs.hanlp.corpus.occurrence.Occurrence#addAll not found`

那就加入自訂詞典吧