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

Additional yen conversion parsing #2000

Closed
0xNF opened this issue Sep 24, 2024 · 12 comments · Fixed by #2049
Closed

Additional yen conversion parsing #2000

0xNF opened this issue Sep 24, 2024 · 12 comments · Fixed by #2049

Comments

@0xNF
Copy link

0xNF commented Sep 24, 2024

In multilingual discussions on the internet, I often encounter yen-denominated sums written with k, m, or t metric suffixes, for example, 40k円, which doesn't parse in 10ten.

What do the maintainers think of allowing these suffixes to be parsed?

@birtles
Copy link
Member

birtles commented Sep 25, 2024

Absolutely. We already parse some pretty non-standard numbers and I'm more than happy to add more if they occur in the wild.

Do you happen to have any URLs with examples of these variants?

@0xNF
Copy link
Author

0xNF commented Sep 25, 2024

It's most prevalent on reddit:

But you'll sometimes see it on explainer sites in Japanese:

To say nothing of the discord chats it sometimes comes up in. It's mostly an English-Japanese speaker thing.

@birtles
Copy link
Member

birtles commented Sep 26, 2024

Thank you! So basically 洋製日本語. Nice.

@birtles
Copy link
Member

birtles commented Oct 16, 2024

In multilingual discussions on the internet, I often encounter yen-denominated sums written with k, m, or t metric suffixes, for example, 40k円, which doesn't parse in 10ten.

@0xNF What is the t suffix used for?

@SaltfishAmi
Copy link
Contributor

What is the t suffix used for?

兆円, I guess??

@0xNF
Copy link
Author

0xNF commented Oct 16, 2024

Trillion yen, often seen in discussions of government fiscal budgets.

@birtles
Copy link
Member

birtles commented Oct 16, 2024

Thanks! So I guess "b" should be a suffix too?

@0xNF
Copy link
Author

0xNF commented Oct 16, 2024

Yeah, I didn't expand in detail in my original comment which is my bad.

(m)illion yen
(b)illion yen
(t)rillion yen

Is what I had in mind.
In theory (q)uadrillon lurks out there on the net somewhere too but I've never personally seen it.

@birtles
Copy link
Member

birtles commented Oct 17, 2024

I've done a basic implementation of this over in #2049 but looking at the dentist thread from an earlier comment I guess it would be more useful if this recognized "5k yen" too?

I'm not sure if it's ever going to recognize the "40k" in "40k to 200k円", however, since that would require parsing quite a bit more of the context to make that work.

@birtles
Copy link
Member

birtles commented Oct 17, 2024

Updated #2049 to cover "5k yen" too.

@0xNF
Copy link
Author

0xNF commented Nov 13, 2024

image
This is fantastic, thanks so much.

@birtles
Copy link
Member

birtles commented Nov 13, 2024

This is fantastic, thanks so much.

Thank you!

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

Successfully merging a pull request may close this issue.

3 participants