Criteria
A set of characteristics used to determine which recommendations apply to a situation. This is a base type that can be extended for domain-specific criteria (e.g., PropertyCriteria for construction).
Properties
| Property | Expected Type | Description |
|---|---|---|
| mustMatchAll | Boolean | Whether all criteria must match (AND logic) or any (OR logic) |
| criteria | Text or structured | List of characteristics to match |
Examples
Simple Criteria (AND logic)
JSON-LD
{
"@context": "https://causalschema.org/context.jsonld",
"@type": "Criteria",
"mustMatchAll": true,
"criteria": [
"Building age: Pre-1919",
"Wall construction: Solid brick",
"Location: Clay soil area"
]
}
Criteria with OR logic
JSON-LD
{
"@context": "https://causalschema.org/context.jsonld",
"@type": "Criteria",
"mustMatchAll": false,
"criteria": [
"Mining subsidence zone",
"Flood plain location",
"Unstable clay soil"
]
}
Usage Notes
Extending Criteria
Domain extensions can create specialised criteria types:
- PropertyCriteria (construction) — Adds
constructionEra,wallType,geology - PopulationCriteria (healthcare) — Adds
ageRange,conditions,medications - VehicleCriteria (automotive) — Adds
make,model,mileage
AND vs OR Logic
- mustMatchAll: true — All criteria must be present (more specific matching)
- mustMatchAll: false — Any criterion triggers the match (broader matching)