Skip to main content
November 28, 2024
Question

convert numbers in alphabet form to integer

  • November 28, 2024
  • 4 replies
  • 0 views

HI All,

Example -- I am forty-five years old.

from above text i need to get 45 in integer form. How to achieve this?

Thanks,

Ganesh. 

4 replies

gayatria0439
November 28, 2024

Hi [mention:606c66593299484b93380808f2033f3f:e9ed411860ed4f2ba0265705b8793d05] ,

We also explored various concepts to achieve the expected output. However, with our solution, the number of lines of code increases, as we need to check each condition to handle places such as ones, tens, hundreds, and so on. To address this, we integrated the Azure OpenAI Connected System to obtain the desired results. However, it is important to note that this system has a limitation on the number of tokens available.let me know if you find any solution other than this Thank you.

prasantap0900
November 28, 2024

In Appian, I think you can use chatGPT integration, and with that integration you can achieve your result.

karumurua531442
November 28, 2024

hi [mention:606c66593299484b93380808f2033f3f:e9ed411860ed4f2ba0265705b8793d05]  may I know in which scenario you are using this requirement? May  I know what is your requirement

December 6, 2024

To achieve this, you can use the Python library word2number. It converts written numbers like "forty-five" into integers like 45. For example, using w2n.word_to_num("forty-five") returns 45. Split your text into words, process each word, and extract numeric values. This approach works well for simple cases. For students looking for an online platform to help with educational assignments, I discovered a website called https://domypaper.com/ domypaper. It has been very useful to me, and I have been using their service for a couple of years. domypaper provides expert writers who deliver high-quality research papers for students. They also offer professional tutors who assist users in understanding various topics.