DraftFilterDeveloper API

Developer reference

Score API

Score jobs evaluate submitted text and return public is_ai percentages. 0 means 0% AI-like, and 100 means 100% AI-like. Lower is_ai is less AI-like.

Create a score job:

text
POST /v1/score-jobs

Request body:

json
{
  "idempotencyKey": "score-batch-2026-06-30",
  "granularity": "document",
  "items": [
    {
      "id": "sentence-1",
      "text": "The onboarding checklist now includes an owner for every launch task."
    },
    {
      "id": "sentence-2",
      "text": "A shorter release window should reduce customer support handoffs."
    }
  ]
}

Score request limits from the OpenAPI contract:

text
items: 1 to 100
item id: 1 to 128 characters
item text: 1 to 20,000 characters
total text: 100,000 characters
idempotencyKey: optional, 1 to 128 characters
granularity: optional, document or sentence, default document
sentence granularity: at most 10 items, at most 50,000 total text characters

Sentence jobs score every sentence in document context, so they cost more inference time per character; requests over the sentence limits fail with 422 validation_failed.

Successful result:

json
{
  "jobId": "job_000301",
  "state": "succeeded",
  "results": [
    {
      "id": "sentence-1",
      "is_ai": 12
    },
    {
      "id": "sentence-2",
      "is_ai": 31
    }
  ]
}

Use sentence granularity when you need spans inside each submitted item:

json
{
  "granularity": "sentence",
  "items": [
    {
      "id": "draft-1",
      "text": "This first sentence is scored in place. The next sentence keeps its offsets."
    }
  ]
}
json
{
  "jobId": "job_000302",
  "state": "succeeded",
  "results": [
    {
      "id": "draft-1",
      "is_ai": 72,
      "band": "likely_ai",
      "confidence": 0.44,
      "sentences": [
        {
          "text": "This first sentence is scored in place.",
          "start": 0,
          "end": 39,
          "is_ai": 78,
          "band": "likely_ai"
        },
        {
          "text": "The next sentence keeps its offsets.",
          "start": 40,
          "end": 76,
          "is_ai": 46,
          "band": "mixed"
        }
      ]
    }
  ]
}

Sentence granularity returns submitted sentence text with exact start/end offsets: text[start:end] always reproduces the returned sentence. Sentence scores are computed in document context, then normalized to the same public is_ai direction as document results. Bands are likely_human, mixed, or likely_ai; confidence is a calibration-derived document-level distance from the mixed center. Band cut-points and confidence scaling come from the production calibration YAML, not hardcoded values.