Content moderation
gamma
Synchronous explicit sexual-content checks for text. Receive a final decision and a probability for the defined policy. Availability follows the active model catalog.
Quick start
Gamma is selected in the endpoint path. Send exactly modality and text; do not include model in the body. The API key must allow moderation and gamma. Idempotency-Key is optional; when supplied, use 8–128 characters for retry safety.
curl -X POST "https://api.artany.ai/v1/moderations/models/gamma" \
-H "Authorization: Bearer $ARTANY_API_KEY" \
-H "Content-Type: application/json" \
-H "Idempotency-Key: moderation-gamma-001" \
-d '{"modality":"text","text":"A neutral product description"}'Decision policy
The policy targets explicit erotic descriptions or requests, sexual acts, sexual stimulation, graphic sexualized anatomy, and sexual exploitation. Fiction or quotation does not automatically exempt explicit erotic material. Ordinary romance and factual, non-erotic medical, educational, safety or reporting discussions do not qualify solely because they mention sex or anatomy.
The decision is block when the probability reaches the configured Gamma threshold, and allow otherwise. Violence, weapons, drugs and other risks are outside this policy. An allow result is not a general safety certification. Policies and thresholds are managed by Artany and cannot be overridden in a request.
Response
{
"sexual_suggest": "allow",
"category": null,
"sexual_score": 0.08,
"labels": [
{
"label": "sexual_explicit",
"score": 0.08
}
],
"billing": {
"charged_credits": "1",
"idempotent": false
}
}These example values are illustrative. sexual_score is a probability from 0 to 1, not severity or a score interchangeable with another model. labels contains one sexual_explicit probability. category is sexual_explicit when blocked and null otherwise. No job polling is required.
Credits are charged before evaluation. Both allow and block are completed, billable checks. Successful idempotent replays keep the original decision and charge. Evaluation failures trigger a refund; a failed refund is reported separately for reconciliation. If saving a completed result fails, its charge requires reconciliation rather than automatic resubmission.
| HTTP | Code | Meaning |
|---|---|---|
| 400 / 422 | INVALID_REQUEST / UNSUPPORTED_MODEL_INPUT | Invalid text, unsupported modality, or unknown fields. No evaluation charge. |
| 403 | KEY_SCOPE_FORBIDDEN | The API key does not allow moderation or gamma. |
| 402 | INSUFFICIENT_CREDITS | The check is not submitted. |
| 404 | MODEL_NOT_FOUND | Gamma is not currently active in the model catalog. |
| 409 | IDEMPOTENCY_CONFLICT / REQUEST_IN_PROGRESS | The key was used with different input, or the original request is still pending. |
| 502 / 503 | PROVIDER_ERROR / PROVIDER_UNAVAILABLE | The check could not complete. An invalid result is never returned as allow. |
| 500 | CREDIT_RELEASE_FAILED / INTERNAL_ERROR | A refund or persistence operation needs investigation. |
Inputs and limits
- modality must be text; nonblank text is limited to 4,096 UTF-16 code units.
- Original text is evaluated without translation. Validate results on representative examples in your languages.
- Images, videos, URLs and extra fields are rejected.
- Prices follow the published catalog; the example assumes 1 Credit per completed text check.
- The same failed idempotency key replays the failure; it does not initiate a new check.