policy_classification

Submit a text for instant policy classification

This endpoint predicts the policy categories of a single text

Example CURL:

curl -i -X POST -H "Authorization: Bearer {API_TOKEN}" -H "Content-Type: application/json"          -X POST --data  '{"text": "Test input text"}'         https://api.unitary.ai/v1/classify/policy/text/now
post/classify/policy/text/now

Response

Successful Response

job_idstring required

Example response

{
  "policy_categories": [
    {
      "description": "UNITARY ADULT SEXUAL",
      "name": "UNITARY_SEXUAL",
      "risk_level": "HIGH",
      "score": 0.8
    }
  ]
}

Changes

No recorded changes to this endpoint across all 1 revision of this API.