Segmentation tool
The Segmentation tool marks sentence or chunk boundaries within each
block. It records them as a stand-off overlay and leaves the block's runs
unchanged, so dropping the overlay restores the unsegmented block. --engine
selects the segmenter:
srx, the default, finds sentence boundaries with built-in rules and needs no configuration.rulesPathloads an SRX 2.0 rules file in their place.uax29applies the Unicode default sentence boundaries, with no language-specific exceptions.llmasks an AI provider for meaning-based chunks rather than sentences.
Plugins can register further engines, which appear as options. Bilingual
formats write the sentence layer as segments. A block that already has a
layer keeps it unless overwriteSegmentation is set.
Parameters
| Parameter | Type | Default | Description |
|---|---|---|---|
engine | string | srx | Which segmenter to use; the default needs no configuration |
layer | string | Segmentation overlay layer name; empty uses the engine's natural layer | |
overwriteSegmentation | boolean | false | Re-segment already-segmented blocks replacing previous segmentation |
provider | string | AI provider id (anthropic | |
rulesPath | string | Path to a custom SRX 2.0 rules file (overrides the built-in ruleset) | |
model | string | Model name | |
segmentSource | boolean | true | Segment the source text |
treatIsolatedCodesAsWhitespace | boolean | false | Treat isolated inline codes as whitespace during segmentation |
credential | string | Stored credential name | |
segmentTarget | boolean | false | Segment existing target text |
trimLeadingWhitespace | boolean | true | Exclude leading whitespace from each segment span |
instruction | string | Optional guidance for how to chunk | |
trimTrailingWhitespace | boolean | true | Exclude trailing whitespace from each segment span |
maxChunkRunes | integer | Soft upper bound on chunk size in characters (0 = model default) | |
renumberCodes | boolean | false | Renumber inline code IDs when materializing segments to a bilingual format |
Configure it live
Examples
Segment the source with the default rules
Mark sentence boundaries using the built-in rules.
segmentSource: true
Re-segment with a custom SRX file
Replace existing segmentation using project-specific rules.
engine: srx
overwriteSegmentation: true
rulesPath: ./rules/segmentation.srx
Processing notes
Operates on translatable blocks only; non-translatable blocks pass through unchanged.
When the source is written to the sentence layer, the segment count is recorded in the block property
segment-count.
Limitations
The built-in rule set targets common Latin-script sentence boundaries; non-Latin scripts may need a custom SRX file.
The
llmengine calls a hosted provider unless a local one is chosen, and needs a credential for a hosted provider.
← Back to the Tool Reference