chokkan / crfsuite

CRFsuite: a fast implementation of Conditional Random Fields (CRFs)
http://www.chokkan.org/software/crfsuite/
Other
641 stars 208 forks source link

How can I add more features? #79

Closed LeenaShekhar closed 7 years ago

LeenaShekhar commented 7 years ago

I want to add features like "isCapital", "isNumber" etc. Could you please tell me how can I do that?

usptact commented 7 years ago

You need to write a script which will be function of the word. If the word starts with capital letter (or all caps?), you generate an arbitrary feature, say C-ISCAPITAL. Similarly for "isNumber".

LeenaShekhar commented 7 years ago

Thank you. I will implement it- I think I got the idea. Once done, I will add details to this thread