Function: assertModerationContext()
assertModerationContext(
value):asserts value is ModerationContext
Defined in: packages/agentos/src/safety/guardrails/ModerationContext.ts:41
Throws a TypeError naming the field (never its value) when a field is not a word or an id.
Parameters
value
unknown
The moderation field of a guard context.
Returns
asserts value is ModerationContext
Throws
TypeError naming the first field that does not fit.