Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add support for Hindi #108

Open
jglaszka opened this issue Jul 11, 2023 · 12 comments
Open

Add support for Hindi #108

jglaszka opened this issue Jul 11, 2023 · 12 comments
Assignees
Labels

Comments

@jglaszka
Copy link
Collaborator

jglaszka commented Jul 11, 2023

Tradukisto is the library what converts numbers to human-readable words - for example from 14 to fourteen. This issue was created to add support for counting in new language. Depending on how numeral system in your language is similar to other languages (english, arabic, german, slavic) and how many exceptions it have - it can be easy or more demanding.

Implementing unit tests will be really helpful for you, I encourage you to create them first (TDD paradigm), before developing new changes in the code. You can run them in terminal with ./gradlew test or green button in Intellij code editor.

New language needs to have implementation for Container. Depending on how your language works, having conjugation, gender forms, custom chunking (typically divider is for 3 numbers) etc it may be needed to define more advanced container with custom implementations for counting, for example turkish. Tests will really be helpful for you to see if it needs custom implementations or not.

Also define Values - translations for base numers and for plural forms (thousands, millions etc).
Feel free to ask if you have more questions, we will try to help you.
https://github.com/allegro/tradukisto/wiki/How-to-start-contributing

@jglaszka jglaszka changed the title Add suport for Hindi Add support for Hindi Jul 11, 2023
@ronisarkarexe
Copy link

@jglaszka Hey, I saw my language ( Bangla ) missing from the list, can I contribute to the change?

@jglaszka
Copy link
Collaborator Author

@jglaszka Hey, I saw my language ( Bangla ) missing from the list, can I contribute to the change?

sure, we are open for new languages :)

@ronisarkarexe
Copy link

Can you guide me to contribute? I am new to the open-source community. and I am so excited to work with you.

@jglaszka
Copy link
Collaborator Author

jglaszka commented Aug 14, 2023

Yes. What type of help do you need (language/git/business logic)? You can also check guide first: https://github.com/allegro/tradukisto/wiki/Create-your-first-Pull-Request.

@ronisarkarexe
Copy link

Question:-

  1. how can I run this project locally?
  2. What is the name of your branch mean? example my language like ( language_bangla )
  3. what is Add label?

@jglaszka
Copy link
Collaborator Author

  1. How can I run this project locally?
    This is an library. There are 2 ways to run this project.
    1. You can "run" it using unit tests (example test: https://github.com/allegro/tradukisto/blob/master/src/test/groovy/pl/allegro/finance/tradukisto/ValueConvertersTest.groovy#L116, how does tests works: https://www.youtube.com/watch?v=o5pE7L2tVV8&ab_channel=BrianFraser)
    2. Create your own app in Java and import tradukisto (example: https://github.com/allegro/tradukisto/wiki/Getting-Started-with-Tradukisto!).
  2. You can create any name of the git branch as you want, for example language_bangla_implementation
  3. Label can be added in github:
Screenshot 2023-08-22 at 11 03 04 AM

@ronisarkarexe
Copy link

@jglaszka thanks for the guidance. I created a pull request Please check it.

@girdharsourabh
Copy link
Contributor

@jglaszka Can you assign this issue to me, I will add Hindi Support.

@girdharsourabh
Copy link
Contributor

girdharsourabh commented Aug 27, 2023

@jglaszka I have written all implementation for hindi language, only one catch left - "In Hindi, its two digits as separator after thousand and not like English where its always 3 digits between denomination change". Its like "xx,xx,xx,xxx.yy" format Trying to figure out that override functionality. Need to write new custom implementation of Number chunking.

@ronisarkarexe Its same in bengali as well, I guess you missed that functionality.

@jglaszka
Copy link
Collaborator Author

@girdharsourabh Today I will take a look at it.

@jglaszka
Copy link
Collaborator Author

@girdharsourabh I reviewed your PR and added a few comments.

@jglaszka
Copy link
Collaborator Author

@ronisarkarexe I checked your PR and I left questions to ensure if the code works properly: #110 (comment)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants