allo-media / text2num

Parse and convert numbers written in French, English or Spanish into their digit representation.
https://text2num.readthedocs.io/
MIT License
100 stars 47 forks source link

Does not convert numbers containing word and #35

Open Chaitanya-Jadhav opened 4 years ago

Chaitanya-Jadhav commented 4 years ago

This is a very great package. And I appreciate all the hard work.

s = 'I want five hundred and sixty six rupees' alpha2digit(s,lang='en') returns 'I want 500 and 66 rupees'

But the desired output is following: 'I want 566 rupees'

Please suggest any option or work around to make this work efficiently. Thank You.

rtxm commented 4 years ago

Thanks for the feedback! How would you write, in plain letters and punctuation, a legitimate "500 and 66 rupees"? I mean, how one can make the difference, in plain letters, between "566 rupees" and "500 and 66 rupees."? So that we can implement some heuristics.

ralphmapper commented 3 years ago

Thank you for the package.

@rtxm Where is the rust version?

rtxm commented 3 years ago

it's being prepared for release… :wink:

rtxm commented 2 years ago

There it is @ralphmapper : https://crates.io/crates/text2num

ffeldhaus commented 2 years ago

@rtxm Will this be implemented in the Python version as well?