Skip to content

Segmenter docs are lacking an explanation for the InvariantOptions design #6660

@sffc

Description

@sffc

Word and Sentence segmenters have two versions of the options: one with a content_locale and the other without. The reason for the split is that the locale version can return a DataError.

It seems most/all of our examples use the InvariantOptions. When opening the docs page for either options struct, there is no clear explanation about why you would want to use each one. It also does not clearly explain that the InvariantOptions go to the constructor called new and the Options go to the one called try_new.

CC @sven-oly

Metadata

Metadata

Assignees

Labels

C-segmentationComponent: SegmentationS-tinySize: Less than an hour (trivial fixes)T-docs-testsType: Code change outside core librarymilestone-non-blockingThese issues are in a milestone, but do not block the milestone (and can be removed if necessary)

Type

No type

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions