Validate an untrusted FTS tokenizer value without silently selecting a fallback. This is intentionally synchronous so callers can reject invalid CLI, config, or programmatic input before preparing any index path.
Candidate tokenizer value.
Safe, caller-facing name for the input surface.
The exact supported tokenizer mode.
If value is not exactly unicode61 or trigram.
value
unicode61
trigram
const tokenize = assertTokenizeMode(rawTokenize, "--tokenize"); Copy
const tokenize = assertTokenizeMode(rawTokenize, "--tokenize");
Validate an untrusted FTS tokenizer value without silently selecting a fallback. This is intentionally synchronous so callers can reject invalid CLI, config, or programmatic input before preparing any index path.