Detecting Text

The core endpoint for judging a sentence is POST /detect.

Request

Endpoint: POST https://harm-api.rhu.kr/detect

FieldTypeRequiredDescription
textstring✔The sentence to judge (up to 4000 characters)
operating_pointstringSensitivity preset (defaults to balanced)
curl -s -X POST https://harm-api.rhu.kr/detect \
  -H 'Content-Type: application/json' \
  -d '{"text":"니 수준을 아세요","operating_point":"balanced"}'
{
  "text": "니 수준을 아세요",
  "is_profane": true,
  "label": "욕설",
  "decision": "review",
  "decision_label": "검토",
  "score": 0.8975,
  "severity": 2,
  "tier": "free"
}

Operating points

The same model, with only the threshold changed — three presets to tune sensitivity.

Operating pointBehaviorWhen to use
balancedBalances precision and recall (default)Most cases
high_precisionFlags profanity only when confidentWhen you want to minimize false positives
high_recallFlags profanity when in doubtWhen you want to minimize misses

Many sentences at once

Send a texts array (up to 256 items) to POST /detect/batch to judge them together. It counts as one request for rate limiting and billing.

curl -s -X POST https://harm-api.rhu.kr/detect/batch \
  -H 'Content-Type: application/json' \
  -d '{"texts":["안녕","씨발"]}'

Each item in the response uses the same schema as Response Fields.