nuance_DURATION
Period of time described in absolute (hours, minutes, seconds, and days) or relative terms (for example, “two hours more”).
Sample language
- 7 hours
- 2.5 hours
- around two hours and fourteen minutes
- half an hour
- all day
- less than thirty minutes
Examples
The input “a year and a month” returns this response:
{
"nuance_DURATION_ABS": {
"nuance_NUMBER": 13,
"nuance_UNIT": "month"
}
}
The input “more than an hour” returns:
{
"nuance_DURATION_REL": {
"nuance_DURATION_ABS": {
"nuance_NUMBER": 1,
"nuance_UNIT": "hour"
},
"nuance_MODIFIER": "GT"
}
}
Numeric value range
<= 99,999,999
Schema
{
"$schema": "http://json-schema.org/draft-04/schema#",
"type": "object",
"properties": {
"nuance_DURATION": {
"type": "object",
"properties": {
"oneOf": [{
"nuance_DURATION_ABS": {
"type": "object",
"properties": {
"nuance_NUMBER": {
"type": "number"
},
"nuance_UNIT": {
"type": "string",
"pattern": "[millisecond|second|minute|hour|day|week|month|year]"
},
"nuance_MODIFIER": {
"type": "string",
"pattern": "[fuzzy]"
}
}
}
}, {
"nuance_DURATION_REL": {
"type": "object",
"properties": {
"nuance_DURATION_ABS": {
"type": "object",
"properties": {
"nuance_NUMBER": {
"type": "number"
},
"nuance_UNIT": {
"type": "string",
"pattern": "[millisecond|second|minute|hour|day|week|month|year]"
}
}
},
"nuance_MODIFIER": {
"type": "string",
"pattern": "[GT|LT|GE|LE|EQ|INC]"
}
},
"required": "nuance_MODIFIER"
}
}
]
}
}
},
"additionalProperties": false
}
Feedback
Was this page helpful?
Glad to hear it! Please tell us how we can improve.
Sorry to hear that. Please tell us how we can improve.