{ "$schema": "https://json-schema.org/draft/2020-12/schema", "$id": "#/components/schemas/FormatPlan", "title": "FormatPlan", "type": "object", "properties": { "enabled": { "type": "boolean", "description": "This determines whether the chunk is formatted before being sent to the voice provider. This helps with enunciation. This includes phone numbers, emails and addresses. Default `true`.\n\nUsage:\n- To rely on the voice provider's formatting logic, set this to `false`.\n\nIf `voice.chunkPlan.enabled` is `false`, this is automatically `false` since there's no chunk to format.\n\n@default true", "example": true }, "numberToDigitsCutoff": { "type": "number", "description": "This is the cutoff after which a number is converted to individual digits instead of being spoken as words.\n\nExample:\n- If cutoff 2025, \"12345\" is converted to \"1 2 3 4 5\" while \"1200\" is converted to \"twelve hundred\".\n\nUsage:\n- If your use case doesn't involve IDs like zip codes, set this to a high value.\n- If your use case involves IDs that are shorter than 5 digits, set this to a lower value.\n\n@default 2025", "minimum": 0, "example": 2025 }, "replacements": { "type": "array", "description": "These are the custom replacements you can make to the chunk before it is sent to the voice provider.\n\nUsage:\n- To replace a specific word or phrase with a different word or phrase, use the `ExactReplacement` type. Eg. `{ type: 'exact', key: 'hello', value: 'hi' }`\n- To replace a word or phrase that matches a pattern, use the `RegexReplacement` type. Eg. `{ type: 'regex', regex: '\\\\b[a-zA-Z]{5}\\\\b', value: 'hi' }`\n\n@default []", "items": { "oneOf": [ { "$ref": "#/components/schemas/ExactReplacement", "title": "ExactReplacement" }, { "$ref": "#/components/schemas/RegexReplacement", "title": "RegexReplacement" } ] } }, "formattersEnabled": { "type": "array", "description": "List of formatters to apply. If not provided, all default formatters will be applied.\nIf provided, only the specified formatters will be applied.\nNote: Some essential formatters like angle bracket removal will always be applied.\n@default undefined", "enum": [ "markdown", "asterisk", "quote", "dash", "newline", "colon", "acronym", "dollarAmount", "email", "date", "time", "distance", "unit", "percentage", "phoneNumber", "number", "stripAsterisk" ], "items": { "type": "string", "enum": [ "markdown", "asterisk", "quote", "dash", "newline", "colon", "acronym", "dollarAmount", "email", "date", "time", "distance", "unit", "percentage", "phoneNumber", "number", "stripAsterisk" ] } } } }