pluskid / pymmseg-cpp Goto Github PK
View Code? Open in Web Editor NEWrmmseg-cpp with Python interface
rmmseg-cpp with Python interface
2 years ago, @Kronuz added native Python extension support. Those extensions only support Python 2. Any chance we could get Python 3 support?
Here is the content of my word dictionary file:
2 军事
3 核大国
5 军事核大国
I run the following code:
import mmseg
d = mmseg.Dictionary()
d.load_words("mydic.txt")
a = mmseg.Algorithm("军事核大")
for p in a:
print p.text
And here is the output:
军事
核大国
However, I expect the segmenter to find only one part of 5 characters. Is this a bug or am I missing something important on the way pymmseg works?
词典自定义了 '齐b' 和 '小短裤',
分词结果将 '齐' 和 'b' 分开,不能识别为一个词。
https://github.com/shuge/pymmseg-cpp/blob/master/demos/use_custom_dict.py
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.