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

Take advantage of inflection inside ICU #24

Open
richgillam opened this issue Mar 18, 2024 · 1 comment
Open

Take advantage of inflection inside ICU #24

richgillam opened this issue Mar 18, 2024 · 1 comment
Labels
discuss Discussion item

Comments

@richgillam
Copy link

Many ICU APIs produce structured output (sentences or phrases) rather than single phrases. Many of these not only may need to inflect in interesting ways to support being inserted into a message, but have individual components that affect each others' inflections. Examples include:

  • Formatted dates
  • Date ranges
  • Spelled-out numbers
  • Dimensioned numbers
  • Lists
  • Person names
  • Locale names

It'd be nice if we could use the new inflection capability to improve and simplify the formatting algorithms for these things.

@grhoten
Copy link
Member

grhoten commented Dec 10, 2024

The current inflection code supports lists with its own API. It adds functionality that is currently unavailable in ICU, and it would be hard to squeeze into ICU.

The spelled out numbers are handled with ICU's RBNF, but the inflection code allows you to add context to choose the correct RBNF rule for quantities more smoothly. Though I can see the inflection code being changed to handle such number pronunciation even more seamlessly.

There is some overlap and dependencies between ICU and the current Morphuntion code around this topic.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
discuss Discussion item
Projects
Status: Todo
Development

No branches or pull requests

3 participants