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

Segmenter constructor options/preferences normalization #5856

Open
sffc opened this issue Nov 22, 2024 · 0 comments
Open

Segmenter constructor options/preferences normalization #5856

sffc opened this issue Nov 22, 2024 · 0 comments
Labels
C-segmentation Component: Segmentation needs-approval One or more stakeholders need to approve proposal

Comments

@sffc
Copy link
Member

sffc commented Nov 22, 2024

In #3284 we decided to add a content_locale option to segmenter.

In #5839, @zbraniecki asked some questions about the signature of the constructors.

Currently we have constructors of the following shape:

  1. new: singleton static data (infallible), no content locale tailorings
  2. try_new_unstable: dynamic data, no content locale tailorings
  3. try_new_with_options: static data with content locale tailorings
  4. try_new_with_options_unstable: dynamic data with content locale tailorings

Which of the following should we do?

  1. Keep all 4 sets of constructors listed above
  2. Remove constructor sets 1 and 2. Rename 3 and 4 to not have with_options.
  3. Remove constructor set 2. Rename 3 and 4 to not have with_options. Keep constructor 1 as a compiled data infallible optimization.

And, should we take a LanguageIdentifier or a preferences bag for the content locale? (Please understand the discussion in #3284 before stating an opinion on this)

@zbraniecki @makotokato @aethanyc @Manishearth

@sffc sffc added C-segmentation Component: Segmentation needs-approval One or more stakeholders need to approve proposal labels Nov 22, 2024
@sffc sffc added this to the ICU4X 2.0 ⟨P1⟩ milestone Nov 22, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
C-segmentation Component: Segmentation needs-approval One or more stakeholders need to approve proposal
Projects
None yet
Development

No branches or pull requests

1 participant